diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-23 14:47:02 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-10-23 14:47:02 -0400 |
commit | 5f05647dd81c11a6a165ccc8f0c1370b16f3bcb0 (patch) | |
tree | 7851ef1c93aa1aba7ef327ca4b75fd35e6d10f29 /drivers/net/wireless/iwlwifi/iwl-debugfs.c | |
parent | 02f36038c568111ad4fc433f6fa760ff5e38fab4 (diff) | |
parent | ec37a48d1d16c30b655ac5280209edf52a6775d4 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next-2.6: (1699 commits)
bnx2/bnx2x: Unsupported Ethtool operations should return -EINVAL.
vlan: Calling vlan_hwaccel_do_receive() is always valid.
tproxy: use the interface primary IP address as a default value for --on-ip
tproxy: added IPv6 support to the socket match
cxgb3: function namespace cleanup
tproxy: added IPv6 support to the TPROXY target
tproxy: added IPv6 socket lookup function to nf_tproxy_core
be2net: Changes to use only priority codes allowed by f/w
tproxy: allow non-local binds of IPv6 sockets if IP_TRANSPARENT is enabled
tproxy: added tproxy sockopt interface in the IPV6 layer
tproxy: added udp6_lib_lookup function
tproxy: added const specifiers to udp lookup functions
tproxy: split off ipv6 defragmentation to a separate module
l2tp: small cleanup
nf_nat: restrict ICMP translation for embedded header
can: mcp251x: fix generation of error frames
can: mcp251x: fix endless loop in interrupt handler if CANINTF_MERRF is set
can-raw: add msg_flags to distinguish local traffic
9p: client code cleanup
rds: make local functions/variables static
...
Fix up conflicts in net/core/dev.c, drivers/net/pcmcia/smc91c92_cs.c and
drivers/net/wireless/ath/ath9k/debug.c as per David
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-debugfs.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-debugfs.c | 209 |
1 files changed, 176 insertions, 33 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-debugfs.c b/drivers/net/wireless/iwlwifi/iwl-debugfs.c index a32d5d337649..8fdd4efdb1d3 100644 --- a/drivers/net/wireless/iwlwifi/iwl-debugfs.c +++ b/drivers/net/wireless/iwlwifi/iwl-debugfs.c | |||
@@ -39,7 +39,6 @@ | |||
39 | #include "iwl-debug.h" | 39 | #include "iwl-debug.h" |
40 | #include "iwl-core.h" | 40 | #include "iwl-core.h" |
41 | #include "iwl-io.h" | 41 | #include "iwl-io.h" |
42 | #include "iwl-calib.h" | ||
43 | 42 | ||
44 | /* create and remove of files */ | 43 | /* create and remove of files */ |
45 | #define DEBUGFS_ADD_FILE(name, parent, mode) do { \ | 44 | #define DEBUGFS_ADD_FILE(name, parent, mode) do { \ |
@@ -359,7 +358,7 @@ static ssize_t iwl_dbgfs_nvm_read(struct file *file, | |||
359 | const u8 *ptr; | 358 | const u8 *ptr; |
360 | char *buf; | 359 | char *buf; |
361 | u16 eeprom_ver; | 360 | u16 eeprom_ver; |
362 | size_t eeprom_len = priv->cfg->eeprom_size; | 361 | size_t eeprom_len = priv->cfg->base_params->eeprom_size; |
363 | buf_size = 4 * eeprom_len + 256; | 362 | buf_size = 4 * eeprom_len + 256; |
364 | 363 | ||
365 | if (eeprom_len % 16) { | 364 | if (eeprom_len % 16) { |
@@ -470,8 +469,7 @@ static ssize_t iwl_dbgfs_channels_read(struct file *file, char __user *user_buf, | |||
470 | for (i = 0; i < supp_band->n_channels; i++) | 469 | for (i = 0; i < supp_band->n_channels; i++) |
471 | pos += scnprintf(buf + pos, bufsz - pos, | 470 | pos += scnprintf(buf + pos, bufsz - pos, |
472 | "%d: %ddBm: BSS%s%s, %s.\n", | 471 | "%d: %ddBm: BSS%s%s, %s.\n", |
473 | ieee80211_frequency_to_channel( | 472 | channels[i].hw_value, |
474 | channels[i].center_freq), | ||
475 | channels[i].max_power, | 473 | channels[i].max_power, |
476 | channels[i].flags & IEEE80211_CHAN_RADAR ? | 474 | channels[i].flags & IEEE80211_CHAN_RADAR ? |
477 | " (IEEE 802.11h required)" : "", | 475 | " (IEEE 802.11h required)" : "", |
@@ -494,8 +492,7 @@ static ssize_t iwl_dbgfs_channels_read(struct file *file, char __user *user_buf, | |||
494 | for (i = 0; i < supp_band->n_channels; i++) | 492 | for (i = 0; i < supp_band->n_channels; i++) |
495 | pos += scnprintf(buf + pos, bufsz - pos, | 493 | pos += scnprintf(buf + pos, bufsz - pos, |
496 | "%d: %ddBm: BSS%s%s, %s.\n", | 494 | "%d: %ddBm: BSS%s%s, %s.\n", |
497 | ieee80211_frequency_to_channel( | 495 | channels[i].hw_value, |
498 | channels[i].center_freq), | ||
499 | channels[i].max_power, | 496 | channels[i].max_power, |
500 | channels[i].flags & IEEE80211_CHAN_RADAR ? | 497 | channels[i].flags & IEEE80211_CHAN_RADAR ? |
501 | " (IEEE 802.11h required)" : "", | 498 | " (IEEE 802.11h required)" : "", |
@@ -580,10 +577,10 @@ static ssize_t iwl_dbgfs_interrupt_read(struct file *file, | |||
580 | priv->isr_stats.hw); | 577 | priv->isr_stats.hw); |
581 | pos += scnprintf(buf + pos, bufsz - pos, "SW Error:\t\t\t %u\n", | 578 | pos += scnprintf(buf + pos, bufsz - pos, "SW Error:\t\t\t %u\n", |
582 | priv->isr_stats.sw); | 579 | priv->isr_stats.sw); |
583 | if (priv->isr_stats.sw > 0) { | 580 | if (priv->isr_stats.sw || priv->isr_stats.hw) { |
584 | pos += scnprintf(buf + pos, bufsz - pos, | 581 | pos += scnprintf(buf + pos, bufsz - pos, |
585 | "\tLast Restarting Code: 0x%X\n", | 582 | "\tLast Restarting Code: 0x%X\n", |
586 | priv->isr_stats.sw_err); | 583 | priv->isr_stats.err_code); |
587 | } | 584 | } |
588 | #ifdef CONFIG_IWLWIFI_DEBUG | 585 | #ifdef CONFIG_IWLWIFI_DEBUG |
589 | pos += scnprintf(buf + pos, bufsz - pos, "Frame transmitted:\t\t %u\n", | 586 | pos += scnprintf(buf + pos, bufsz - pos, "Frame transmitted:\t\t %u\n", |
@@ -648,19 +645,25 @@ static ssize_t iwl_dbgfs_qos_read(struct file *file, char __user *user_buf, | |||
648 | size_t count, loff_t *ppos) | 645 | size_t count, loff_t *ppos) |
649 | { | 646 | { |
650 | struct iwl_priv *priv = file->private_data; | 647 | struct iwl_priv *priv = file->private_data; |
648 | struct iwl_rxon_context *ctx; | ||
651 | int pos = 0, i; | 649 | int pos = 0, i; |
652 | char buf[256]; | 650 | char buf[256 * NUM_IWL_RXON_CTX]; |
653 | const size_t bufsz = sizeof(buf); | 651 | const size_t bufsz = sizeof(buf); |
654 | 652 | ||
655 | for (i = 0; i < AC_NUM; i++) { | 653 | for_each_context(priv, ctx) { |
656 | pos += scnprintf(buf + pos, bufsz - pos, | 654 | pos += scnprintf(buf + pos, bufsz - pos, "context %d:\n", |
657 | "\tcw_min\tcw_max\taifsn\ttxop\n"); | 655 | ctx->ctxid); |
658 | pos += scnprintf(buf + pos, bufsz - pos, | 656 | for (i = 0; i < AC_NUM; i++) { |
657 | pos += scnprintf(buf + pos, bufsz - pos, | ||
658 | "\tcw_min\tcw_max\taifsn\ttxop\n"); | ||
659 | pos += scnprintf(buf + pos, bufsz - pos, | ||
659 | "AC[%d]\t%u\t%u\t%u\t%u\n", i, | 660 | "AC[%d]\t%u\t%u\t%u\t%u\n", i, |
660 | priv->qos_data.def_qos_parm.ac[i].cw_min, | 661 | ctx->qos_data.def_qos_parm.ac[i].cw_min, |
661 | priv->qos_data.def_qos_parm.ac[i].cw_max, | 662 | ctx->qos_data.def_qos_parm.ac[i].cw_max, |
662 | priv->qos_data.def_qos_parm.ac[i].aifsn, | 663 | ctx->qos_data.def_qos_parm.ac[i].aifsn, |
663 | priv->qos_data.def_qos_parm.ac[i].edca_txop); | 664 | ctx->qos_data.def_qos_parm.ac[i].edca_txop); |
665 | } | ||
666 | pos += scnprintf(buf + pos, bufsz - pos, "\n"); | ||
664 | } | 667 | } |
665 | return simple_read_from_buffer(user_buf, count, ppos, buf, pos); | 668 | return simple_read_from_buffer(user_buf, count, ppos, buf, pos); |
666 | } | 669 | } |
@@ -735,7 +738,7 @@ static ssize_t iwl_dbgfs_disable_ht40_write(struct file *file, | |||
735 | return -EFAULT; | 738 | return -EFAULT; |
736 | if (sscanf(buf, "%d", &ht40) != 1) | 739 | if (sscanf(buf, "%d", &ht40) != 1) |
737 | return -EFAULT; | 740 | return -EFAULT; |
738 | if (!iwl_is_associated(priv)) | 741 | if (!iwl_is_any_associated(priv)) |
739 | priv->disable_ht40 = ht40 ? true : false; | 742 | priv->disable_ht40 = ht40 ? true : false; |
740 | else { | 743 | else { |
741 | IWL_ERR(priv, "Sta associated with AP - " | 744 | IWL_ERR(priv, "Sta associated with AP - " |
@@ -871,7 +874,7 @@ static ssize_t iwl_dbgfs_traffic_log_read(struct file *file, | |||
871 | struct iwl_rx_queue *rxq = &priv->rxq; | 874 | struct iwl_rx_queue *rxq = &priv->rxq; |
872 | char *buf; | 875 | char *buf; |
873 | int bufsz = ((IWL_TRAFFIC_ENTRIES * IWL_TRAFFIC_ENTRY_SIZE * 64) * 2) + | 876 | int bufsz = ((IWL_TRAFFIC_ENTRIES * IWL_TRAFFIC_ENTRY_SIZE * 64) * 2) + |
874 | (priv->cfg->num_of_queues * 32 * 8) + 400; | 877 | (priv->cfg->base_params->num_of_queues * 32 * 8) + 400; |
875 | const u8 *ptr; | 878 | const u8 *ptr; |
876 | ssize_t ret; | 879 | ssize_t ret; |
877 | 880 | ||
@@ -970,7 +973,8 @@ static ssize_t iwl_dbgfs_tx_queue_read(struct file *file, | |||
970 | int pos = 0; | 973 | int pos = 0; |
971 | int cnt; | 974 | int cnt; |
972 | int ret; | 975 | int ret; |
973 | const size_t bufsz = sizeof(char) * 64 * priv->cfg->num_of_queues; | 976 | const size_t bufsz = sizeof(char) * 64 * |
977 | priv->cfg->base_params->num_of_queues; | ||
974 | 978 | ||
975 | if (!priv->txq) { | 979 | if (!priv->txq) { |
976 | IWL_ERR(priv, "txq not ready\n"); | 980 | IWL_ERR(priv, "txq not ready\n"); |
@@ -1324,7 +1328,8 @@ static ssize_t iwl_dbgfs_rxon_flags_read(struct file *file, | |||
1324 | int len = 0; | 1328 | int len = 0; |
1325 | char buf[20]; | 1329 | char buf[20]; |
1326 | 1330 | ||
1327 | len = sprintf(buf, "0x%04X\n", le32_to_cpu(priv->active_rxon.flags)); | 1331 | len = sprintf(buf, "0x%04X\n", |
1332 | le32_to_cpu(priv->contexts[IWL_RXON_CTX_BSS].active.flags)); | ||
1328 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 1333 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
1329 | } | 1334 | } |
1330 | 1335 | ||
@@ -1337,7 +1342,7 @@ static ssize_t iwl_dbgfs_rxon_filter_flags_read(struct file *file, | |||
1337 | char buf[20]; | 1342 | char buf[20]; |
1338 | 1343 | ||
1339 | len = sprintf(buf, "0x%04X\n", | 1344 | len = sprintf(buf, "0x%04X\n", |
1340 | le32_to_cpu(priv->active_rxon.filter_flags)); | 1345 | le32_to_cpu(priv->contexts[IWL_RXON_CTX_BSS].active.filter_flags)); |
1341 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 1346 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
1342 | } | 1347 | } |
1343 | 1348 | ||
@@ -1413,7 +1418,7 @@ static ssize_t iwl_dbgfs_plcp_delta_read(struct file *file, | |||
1413 | const size_t bufsz = sizeof(buf); | 1418 | const size_t bufsz = sizeof(buf); |
1414 | 1419 | ||
1415 | pos += scnprintf(buf + pos, bufsz - pos, "%u\n", | 1420 | pos += scnprintf(buf + pos, bufsz - pos, "%u\n", |
1416 | priv->cfg->plcp_delta_threshold); | 1421 | priv->cfg->base_params->plcp_delta_threshold); |
1417 | 1422 | ||
1418 | return simple_read_from_buffer(user_buf, count, ppos, buf, pos); | 1423 | return simple_read_from_buffer(user_buf, count, ppos, buf, pos); |
1419 | } | 1424 | } |
@@ -1435,10 +1440,10 @@ static ssize_t iwl_dbgfs_plcp_delta_write(struct file *file, | |||
1435 | return -EINVAL; | 1440 | return -EINVAL; |
1436 | if ((plcp < IWL_MAX_PLCP_ERR_THRESHOLD_MIN) || | 1441 | if ((plcp < IWL_MAX_PLCP_ERR_THRESHOLD_MIN) || |
1437 | (plcp > IWL_MAX_PLCP_ERR_THRESHOLD_MAX)) | 1442 | (plcp > IWL_MAX_PLCP_ERR_THRESHOLD_MAX)) |
1438 | priv->cfg->plcp_delta_threshold = | 1443 | priv->cfg->base_params->plcp_delta_threshold = |
1439 | IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE; | 1444 | IWL_MAX_PLCP_ERR_THRESHOLD_DISABLE; |
1440 | else | 1445 | else |
1441 | priv->cfg->plcp_delta_threshold = plcp; | 1446 | priv->cfg->base_params->plcp_delta_threshold = plcp; |
1442 | return count; | 1447 | return count; |
1443 | } | 1448 | } |
1444 | 1449 | ||
@@ -1532,6 +1537,135 @@ static ssize_t iwl_dbgfs_ucode_bt_stats_read(struct file *file, | |||
1532 | user_buf, count, ppos); | 1537 | user_buf, count, ppos); |
1533 | } | 1538 | } |
1534 | 1539 | ||
1540 | static ssize_t iwl_dbgfs_monitor_period_write(struct file *file, | ||
1541 | const char __user *user_buf, | ||
1542 | size_t count, loff_t *ppos) { | ||
1543 | |||
1544 | struct iwl_priv *priv = file->private_data; | ||
1545 | char buf[8]; | ||
1546 | int buf_size; | ||
1547 | int period; | ||
1548 | |||
1549 | memset(buf, 0, sizeof(buf)); | ||
1550 | buf_size = min(count, sizeof(buf) - 1); | ||
1551 | if (copy_from_user(buf, user_buf, buf_size)) | ||
1552 | return -EFAULT; | ||
1553 | if (sscanf(buf, "%d", &period) != 1) | ||
1554 | return -EINVAL; | ||
1555 | if (period < 0 || period > IWL_MAX_MONITORING_PERIOD) | ||
1556 | priv->cfg->base_params->monitor_recover_period = | ||
1557 | IWL_DEF_MONITORING_PERIOD; | ||
1558 | else | ||
1559 | priv->cfg->base_params->monitor_recover_period = period; | ||
1560 | |||
1561 | if (priv->cfg->base_params->monitor_recover_period) | ||
1562 | mod_timer(&priv->monitor_recover, jiffies + msecs_to_jiffies( | ||
1563 | priv->cfg->base_params->monitor_recover_period)); | ||
1564 | else | ||
1565 | del_timer_sync(&priv->monitor_recover); | ||
1566 | return count; | ||
1567 | } | ||
1568 | |||
1569 | static ssize_t iwl_dbgfs_bt_traffic_read(struct file *file, | ||
1570 | char __user *user_buf, | ||
1571 | size_t count, loff_t *ppos) { | ||
1572 | |||
1573 | struct iwl_priv *priv = (struct iwl_priv *)file->private_data; | ||
1574 | int pos = 0; | ||
1575 | char buf[200]; | ||
1576 | const size_t bufsz = sizeof(buf); | ||
1577 | ssize_t ret; | ||
1578 | |||
1579 | pos += scnprintf(buf + pos, bufsz - pos, "BT in %s mode\n", | ||
1580 | priv->bt_full_concurrent ? "full concurrency" : "3-wire"); | ||
1581 | pos += scnprintf(buf + pos, bufsz - pos, "BT status: %s, " | ||
1582 | "last traffic notif: %d\n", | ||
1583 | priv->bt_status ? "On" : "Off", priv->notif_bt_traffic_load); | ||
1584 | pos += scnprintf(buf + pos, bufsz - pos, "ch_announcement: %d, " | ||
1585 | "sco_active: %d, kill_ack_mask: %x, " | ||
1586 | "kill_cts_mask: %x\n", | ||
1587 | priv->bt_ch_announce, priv->bt_sco_active, | ||
1588 | priv->kill_ack_mask, priv->kill_cts_mask); | ||
1589 | |||
1590 | pos += scnprintf(buf + pos, bufsz - pos, "bluetooth traffic load: "); | ||
1591 | switch (priv->bt_traffic_load) { | ||
1592 | case IWL_BT_COEX_TRAFFIC_LOAD_CONTINUOUS: | ||
1593 | pos += scnprintf(buf + pos, bufsz - pos, "Continuous\n"); | ||
1594 | break; | ||
1595 | case IWL_BT_COEX_TRAFFIC_LOAD_HIGH: | ||
1596 | pos += scnprintf(buf + pos, bufsz - pos, "High\n"); | ||
1597 | break; | ||
1598 | case IWL_BT_COEX_TRAFFIC_LOAD_LOW: | ||
1599 | pos += scnprintf(buf + pos, bufsz - pos, "Low\n"); | ||
1600 | break; | ||
1601 | case IWL_BT_COEX_TRAFFIC_LOAD_NONE: | ||
1602 | default: | ||
1603 | pos += scnprintf(buf + pos, bufsz - pos, "None\n"); | ||
1604 | break; | ||
1605 | } | ||
1606 | |||
1607 | ret = simple_read_from_buffer(user_buf, count, ppos, buf, pos); | ||
1608 | return ret; | ||
1609 | } | ||
1610 | |||
1611 | static ssize_t iwl_dbgfs_protection_mode_read(struct file *file, | ||
1612 | char __user *user_buf, | ||
1613 | size_t count, loff_t *ppos) | ||
1614 | { | ||
1615 | struct iwl_priv *priv = (struct iwl_priv *)file->private_data; | ||
1616 | |||
1617 | int pos = 0; | ||
1618 | char buf[40]; | ||
1619 | const size_t bufsz = sizeof(buf); | ||
1620 | |||
1621 | if (priv->cfg->ht_params) | ||
1622 | pos += scnprintf(buf + pos, bufsz - pos, | ||
1623 | "use %s for aggregation\n", | ||
1624 | (priv->cfg->ht_params->use_rts_for_aggregation) ? | ||
1625 | "rts/cts" : "cts-to-self"); | ||
1626 | else | ||
1627 | pos += scnprintf(buf + pos, bufsz - pos, "N/A"); | ||
1628 | |||
1629 | return simple_read_from_buffer(user_buf, count, ppos, buf, pos); | ||
1630 | } | ||
1631 | |||
1632 | static ssize_t iwl_dbgfs_protection_mode_write(struct file *file, | ||
1633 | const char __user *user_buf, | ||
1634 | size_t count, loff_t *ppos) { | ||
1635 | |||
1636 | struct iwl_priv *priv = file->private_data; | ||
1637 | char buf[8]; | ||
1638 | int buf_size; | ||
1639 | int rts; | ||
1640 | |||
1641 | if (!priv->cfg->ht_params) | ||
1642 | return -EINVAL; | ||
1643 | |||
1644 | memset(buf, 0, sizeof(buf)); | ||
1645 | buf_size = min(count, sizeof(buf) - 1); | ||
1646 | if (copy_from_user(buf, user_buf, buf_size)) | ||
1647 | return -EFAULT; | ||
1648 | if (sscanf(buf, "%d", &rts) != 1) | ||
1649 | return -EINVAL; | ||
1650 | if (rts) | ||
1651 | priv->cfg->ht_params->use_rts_for_aggregation = true; | ||
1652 | else | ||
1653 | priv->cfg->ht_params->use_rts_for_aggregation = false; | ||
1654 | return count; | ||
1655 | } | ||
1656 | |||
1657 | static ssize_t iwl_dbgfs_reply_tx_error_read(struct file *file, | ||
1658 | char __user *user_buf, | ||
1659 | size_t count, loff_t *ppos) | ||
1660 | { | ||
1661 | struct iwl_priv *priv = file->private_data; | ||
1662 | |||
1663 | if (priv->cfg->ops->lib->debugfs_ops.reply_tx_error) | ||
1664 | return priv->cfg->ops->lib->debugfs_ops.reply_tx_error( | ||
1665 | file, user_buf, count, ppos); | ||
1666 | else | ||
1667 | return -ENODATA; | ||
1668 | } | ||
1535 | DEBUGFS_READ_FILE_OPS(rx_statistics); | 1669 | DEBUGFS_READ_FILE_OPS(rx_statistics); |
1536 | DEBUGFS_READ_FILE_OPS(tx_statistics); | 1670 | DEBUGFS_READ_FILE_OPS(tx_statistics); |
1537 | DEBUGFS_READ_WRITE_FILE_OPS(traffic_log); | 1671 | DEBUGFS_READ_WRITE_FILE_OPS(traffic_log); |
@@ -1555,6 +1689,10 @@ DEBUGFS_READ_FILE_OPS(rxon_flags); | |||
1555 | DEBUGFS_READ_FILE_OPS(rxon_filter_flags); | 1689 | DEBUGFS_READ_FILE_OPS(rxon_filter_flags); |
1556 | DEBUGFS_WRITE_FILE_OPS(txfifo_flush); | 1690 | DEBUGFS_WRITE_FILE_OPS(txfifo_flush); |
1557 | DEBUGFS_READ_FILE_OPS(ucode_bt_stats); | 1691 | DEBUGFS_READ_FILE_OPS(ucode_bt_stats); |
1692 | DEBUGFS_WRITE_FILE_OPS(monitor_period); | ||
1693 | DEBUGFS_READ_FILE_OPS(bt_traffic); | ||
1694 | DEBUGFS_READ_WRITE_FILE_OPS(protection_mode); | ||
1695 | DEBUGFS_READ_FILE_OPS(reply_tx_error); | ||
1558 | 1696 | ||
1559 | /* | 1697 | /* |
1560 | * Create the debugfs files and directories | 1698 | * Create the debugfs files and directories |
@@ -1590,7 +1728,7 @@ int iwl_dbgfs_register(struct iwl_priv *priv, const char *name) | |||
1590 | DEBUGFS_ADD_FILE(interrupt, dir_data, S_IWUSR | S_IRUSR); | 1728 | DEBUGFS_ADD_FILE(interrupt, dir_data, S_IWUSR | S_IRUSR); |
1591 | DEBUGFS_ADD_FILE(qos, dir_data, S_IRUSR); | 1729 | DEBUGFS_ADD_FILE(qos, dir_data, S_IRUSR); |
1592 | DEBUGFS_ADD_FILE(led, dir_data, S_IRUSR); | 1730 | DEBUGFS_ADD_FILE(led, dir_data, S_IRUSR); |
1593 | if (!priv->cfg->broken_powersave) { | 1731 | if (!priv->cfg->base_params->broken_powersave) { |
1594 | DEBUGFS_ADD_FILE(sleep_level_override, dir_data, | 1732 | DEBUGFS_ADD_FILE(sleep_level_override, dir_data, |
1595 | S_IWUSR | S_IRUSR); | 1733 | S_IWUSR | S_IRUSR); |
1596 | DEBUGFS_ADD_FILE(current_sleep_command, dir_data, S_IRUSR); | 1734 | DEBUGFS_ADD_FILE(current_sleep_command, dir_data, S_IRUSR); |
@@ -1615,24 +1753,29 @@ int iwl_dbgfs_register(struct iwl_priv *priv, const char *name) | |||
1615 | DEBUGFS_ADD_FILE(ucode_general_stats, dir_debug, S_IRUSR); | 1753 | DEBUGFS_ADD_FILE(ucode_general_stats, dir_debug, S_IRUSR); |
1616 | if (priv->cfg->ops->lib->dev_txfifo_flush) | 1754 | if (priv->cfg->ops->lib->dev_txfifo_flush) |
1617 | DEBUGFS_ADD_FILE(txfifo_flush, dir_debug, S_IWUSR); | 1755 | DEBUGFS_ADD_FILE(txfifo_flush, dir_debug, S_IWUSR); |
1756 | DEBUGFS_ADD_FILE(protection_mode, dir_debug, S_IWUSR | S_IRUSR); | ||
1618 | 1757 | ||
1619 | if (priv->cfg->sensitivity_calib_by_driver) | 1758 | if (priv->cfg->base_params->sensitivity_calib_by_driver) |
1620 | DEBUGFS_ADD_FILE(sensitivity, dir_debug, S_IRUSR); | 1759 | DEBUGFS_ADD_FILE(sensitivity, dir_debug, S_IRUSR); |
1621 | if (priv->cfg->chain_noise_calib_by_driver) | 1760 | if (priv->cfg->base_params->chain_noise_calib_by_driver) |
1622 | DEBUGFS_ADD_FILE(chain_noise, dir_debug, S_IRUSR); | 1761 | DEBUGFS_ADD_FILE(chain_noise, dir_debug, S_IRUSR); |
1623 | if (priv->cfg->ucode_tracing) | 1762 | if (priv->cfg->base_params->ucode_tracing) |
1624 | DEBUGFS_ADD_FILE(ucode_tracing, dir_debug, S_IWUSR | S_IRUSR); | 1763 | DEBUGFS_ADD_FILE(ucode_tracing, dir_debug, S_IWUSR | S_IRUSR); |
1625 | if (priv->cfg->bt_statistics) | 1764 | if (priv->cfg->bt_params && priv->cfg->bt_params->bt_statistics) |
1626 | DEBUGFS_ADD_FILE(ucode_bt_stats, dir_debug, S_IRUSR); | 1765 | DEBUGFS_ADD_FILE(ucode_bt_stats, dir_debug, S_IRUSR); |
1766 | DEBUGFS_ADD_FILE(reply_tx_error, dir_debug, S_IRUSR); | ||
1627 | DEBUGFS_ADD_FILE(rxon_flags, dir_debug, S_IWUSR); | 1767 | DEBUGFS_ADD_FILE(rxon_flags, dir_debug, S_IWUSR); |
1628 | DEBUGFS_ADD_FILE(rxon_filter_flags, dir_debug, S_IWUSR); | 1768 | DEBUGFS_ADD_FILE(rxon_filter_flags, dir_debug, S_IWUSR); |
1629 | if (priv->cfg->sensitivity_calib_by_driver) | 1769 | DEBUGFS_ADD_FILE(monitor_period, dir_debug, S_IWUSR); |
1770 | if (priv->cfg->bt_params && priv->cfg->bt_params->advanced_bt_coexist) | ||
1771 | DEBUGFS_ADD_FILE(bt_traffic, dir_debug, S_IRUSR); | ||
1772 | if (priv->cfg->base_params->sensitivity_calib_by_driver) | ||
1630 | DEBUGFS_ADD_BOOL(disable_sensitivity, dir_rf, | 1773 | DEBUGFS_ADD_BOOL(disable_sensitivity, dir_rf, |
1631 | &priv->disable_sens_cal); | 1774 | &priv->disable_sens_cal); |
1632 | if (priv->cfg->chain_noise_calib_by_driver) | 1775 | if (priv->cfg->base_params->chain_noise_calib_by_driver) |
1633 | DEBUGFS_ADD_BOOL(disable_chain_noise, dir_rf, | 1776 | DEBUGFS_ADD_BOOL(disable_chain_noise, dir_rf, |
1634 | &priv->disable_chain_noise_cal); | 1777 | &priv->disable_chain_noise_cal); |
1635 | if (priv->cfg->tx_power_by_driver) | 1778 | if (priv->cfg->base_params->tx_power_by_driver) |
1636 | DEBUGFS_ADD_BOOL(disable_tx_power, dir_rf, | 1779 | DEBUGFS_ADD_BOOL(disable_tx_power, dir_rf, |
1637 | &priv->disable_tx_power_cal); | 1780 | &priv->disable_tx_power_cal); |
1638 | return 0; | 1781 | return 0; |