summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/rt2x00/rt2x00.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2x00.h')
-rw-r--r--drivers/net/wireless/rt2x00/rt2x00.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2x00.h b/drivers/net/wireless/rt2x00/rt2x00.h
index 31e48c2..ba874cf 100644
--- a/drivers/net/wireless/rt2x00/rt2x00.h
+++ b/drivers/net/wireless/rt2x00/rt2x00.h
@@ -623,7 +623,7 @@ struct rt2x00_dev {
* required for deregistration of debugfs.
*/
#ifdef CONFIG_RT2X00_LIB_DEBUGFS
- const struct rt2x00debug_intf *debugfs_intf;
+ struct rt2x00debug_intf *debugfs_intf;
#endif /* CONFIG_RT2X00_LIB_DEBUGFS */
/*
@@ -791,6 +791,12 @@ struct rt2x00_dev {
ring_loop(__entry, (__dev)->tx, ring_end(__dev))
/*
+ * Compute an array index from a pointer to an element and the base pointer.
+ */
+#define ARRAY_INDEX(__elem, __base) \
+ ( ((char *)(__elem) - (char *)(__base)) / sizeof(*(__elem)) )
+
+/*
* Generic RF access.
* The RF is being accessed by word index.
*/