Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 195247
b: refs/heads/master
c: c8a72c0
h: refs/heads/master
i:
  195245: 3d57127
  195243: 8773f3e
  195239: 61c3e26
  195231: 5da5a62
v: v3
  • Loading branch information
Felix Fietkau authored and John W. Linville committed May 12, 2010
1 parent c21558a commit 54e52ce
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 47 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8116daf2146d8fbc5d8d925984b3d4fd34dba1b4
refs/heads/master: c8a72c00c6a58186c35901c5fb15584ebc2a081d
55 changes: 16 additions & 39 deletions trunk/drivers/net/wireless/ath/ath9k/debug.c
Original file line number Diff line number Diff line change
Expand Up @@ -721,52 +721,36 @@ int ath9k_init_debug(struct ath_hw *ah)
sc->debug.debugfs_phy = debugfs_create_dir(wiphy_name(sc->hw->wiphy),
ath9k_debugfs_root);
if (!sc->debug.debugfs_phy)
goto err;
return -ENOMEM;

#ifdef CONFIG_ATH_DEBUG
sc->debug.debugfs_debug = debugfs_create_file("debug",
S_IRUSR | S_IWUSR, sc->debug.debugfs_phy, sc, &fops_debug);
if (!sc->debug.debugfs_debug)
if (!debugfs_create_file("debug", S_IRUSR | S_IWUSR,
sc->debug.debugfs_phy, sc, &fops_debug))
goto err;
#endif

sc->debug.debugfs_dma = debugfs_create_file("dma", S_IRUSR,
sc->debug.debugfs_phy, sc, &fops_dma);
if (!sc->debug.debugfs_dma)
if (!debugfs_create_file("dma", S_IRUSR, sc->debug.debugfs_phy,
sc, &fops_dma))
goto err;

sc->debug.debugfs_interrupt = debugfs_create_file("interrupt",
S_IRUSR,
sc->debug.debugfs_phy,
sc, &fops_interrupt);
if (!sc->debug.debugfs_interrupt)
if (!debugfs_create_file("interrupt", S_IRUSR, sc->debug.debugfs_phy,
sc, &fops_interrupt))
goto err;

sc->debug.debugfs_rcstat = debugfs_create_file("rcstat",
S_IRUSR,
sc->debug.debugfs_phy,
sc, &fops_rcstat);
if (!sc->debug.debugfs_rcstat)
if (!debugfs_create_file("rcstat", S_IRUSR, sc->debug.debugfs_phy,
sc, &fops_rcstat))
goto err;

sc->debug.debugfs_wiphy = debugfs_create_file(
"wiphy", S_IRUSR | S_IWUSR, sc->debug.debugfs_phy, sc,
&fops_wiphy);
if (!sc->debug.debugfs_wiphy)
if (!debugfs_create_file("wiphy", S_IRUSR | S_IWUSR,
sc->debug.debugfs_phy, sc, &fops_wiphy))
goto err;

sc->debug.debugfs_xmit = debugfs_create_file("xmit",
S_IRUSR,
sc->debug.debugfs_phy,
sc, &fops_xmit);
if (!sc->debug.debugfs_xmit)
if (!debugfs_create_file("xmit", S_IRUSR, sc->debug.debugfs_phy,
sc, &fops_xmit))
goto err;

sc->debug.debugfs_recv = debugfs_create_file("recv",
S_IRUSR,
sc->debug.debugfs_phy,
sc, &fops_recv);
if (!sc->debug.debugfs_recv)
if (!debugfs_create_file("recv", S_IRUSR, sc->debug.debugfs_phy,
sc, &fops_recv))
goto err;

return 0;
Expand All @@ -780,14 +764,7 @@ void ath9k_exit_debug(struct ath_hw *ah)
struct ath_common *common = ath9k_hw_common(ah);
struct ath_softc *sc = (struct ath_softc *) common->priv;

debugfs_remove(sc->debug.debugfs_recv);
debugfs_remove(sc->debug.debugfs_xmit);
debugfs_remove(sc->debug.debugfs_wiphy);
debugfs_remove(sc->debug.debugfs_rcstat);
debugfs_remove(sc->debug.debugfs_interrupt);
debugfs_remove(sc->debug.debugfs_dma);
debugfs_remove(sc->debug.debugfs_debug);
debugfs_remove(sc->debug.debugfs_phy);
debugfs_remove_recursive(sc->debug.debugfs_phy);
}

int ath9k_debug_create_root(void)
Expand Down
7 changes: 0 additions & 7 deletions trunk/drivers/net/wireless/ath/ath9k/debug.h
Original file line number Diff line number Diff line change
Expand Up @@ -153,13 +153,6 @@ struct ath_stats {

struct ath9k_debug {
struct dentry *debugfs_phy;
struct dentry *debugfs_debug;
struct dentry *debugfs_dma;
struct dentry *debugfs_interrupt;
struct dentry *debugfs_rcstat;
struct dentry *debugfs_wiphy;
struct dentry *debugfs_xmit;
struct dentry *debugfs_recv;
struct ath_stats stats;
};

Expand Down

0 comments on commit 54e52ce

Please sign in to comment.