summaryrefslogtreecommitdiffstats
path: root/drivers/net/fjes/fjes.h
diff options
context:
space:
mode:
authorTaku Izumi <izumi.taku@jp.fujitsu.com>2016-10-14 20:28:07 +0900
committerDavid S. Miller <davem@davemloft.net>2016-10-14 12:04:58 -0400
commitc753119e6d1a26a3df04d6fe69d75049082e3f32 (patch)
treea6108a7246d23f37bbcd5695882822c2d489802d /drivers/net/fjes/fjes.h
parentb6ba737d0b290b272452a2362088222a248fc8da (diff)
downloadlinux-c753119e6d1a26a3df04d6fe69d75049082e3f32.tar.bz2
fjes: Add debugfs entry for EP status information in fjes driver
This patch adds debugfs entry to show EP status information. You can get each EP's status information like the following: # cat /sys/kernel/debug/fjes/fjes.0/status EPID STATUS SAME_ZONE CONNECTED ep0 shared Y Y ep1 - - - ep2 unshared N N ep3 unshared N N ep4 unshared N N ep5 unshared N N ep6 unshared N N ep7 unshared N N Signed-off-by: Taku Izumi <izumi.taku@jp.fujitsu.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/fjes/fjes.h')
-rw-r--r--drivers/net/fjes/fjes.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/net/fjes/fjes.h b/drivers/net/fjes/fjes.h
index a592fe21c698..0372be3ad8e3 100644
--- a/drivers/net/fjes/fjes.h
+++ b/drivers/net/fjes/fjes.h
@@ -66,6 +66,10 @@ struct fjes_adapter {
bool interrupt_watch_enable;
struct fjes_hw hw;
+
+#ifdef CONFIG_DEBUG_FS
+ struct dentry *dbg_adapter;
+#endif
};
extern char fjes_driver_name[];
@@ -74,4 +78,16 @@ extern const u32 fjes_support_mtu[];
void fjes_set_ethtool_ops(struct net_device *);
+#ifdef CONFIG_DEBUG_FS
+void fjes_dbg_adapter_init(struct fjes_adapter *adapter);
+void fjes_dbg_adapter_exit(struct fjes_adapter *adapter);
+void fjes_dbg_init(void);
+void fjes_dbg_exit(void);
+#else
+static inline void fjes_dbg_adapter_init(struct fjes_adapter *adapter) {}
+static inline void fjes_dbg_adapter_exit(struct fjes_adapter *adapter) {}
+static inline void fjes_dbg_init(void) {}
+static inline void fjes_dbg_exit(void) {}
+#endif /* CONFIG_DEBUG_FS */
+
#endif /* FJES_H_ */