summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/iwlwifi/iwl-dev.h
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2011-05-31 08:22:30 +0300
committerWey-Yi Guy <wey-yi.w.guy@intel.com>2011-06-18 08:05:52 -0700
commita48709c5d076aa3a3f9b6426f462abe6bf432b11 (patch)
treea6da050f84ff8b9d3ac366387b4a9c8fb412215b /drivers/net/wireless/iwlwifi/iwl-dev.h
parentc6ca8bc46cc320e31e8fcb8b104eeed044febd6f (diff)
iwlagn: introduce iwl_bus and iwl_bus_ops
iwl_bus will represent a bus, and iwl_bus_ops all the operations that can be done on this bus. For the moment only set_prv_data is implemented. More to come... Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-dev.h')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-dev.h23
1 files changed, 23 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h
index 59316fb1e8c2..8865514226b9 100644
--- a/drivers/net/wireless/iwlwifi/iwl-dev.h
+++ b/drivers/net/wireless/iwlwifi/iwl-dev.h
@@ -1188,6 +1188,26 @@ struct iwl_testmode_trace {
bool trace_enabled;
};
#endif
+
+struct iwl_bus;
+
+/**
+ * struct iwl_bus_ops - bus specific operations
+ * @set_drv_data: set the priv pointer to the bus layer
+ */
+struct iwl_bus_ops {
+ void (*set_drv_data)(struct iwl_bus *bus, void *priv);
+};
+
+struct iwl_bus {
+ /* pointer to bus specific struct */
+ void *bus_specific;
+
+ /* Common data to all buses */
+ struct iwl_priv *priv; /* driver's context */
+ struct iwl_bus_ops *ops;
+};
+
struct iwl_priv {
/* ieee device used by generic ieee processing code */
@@ -1255,12 +1275,15 @@ struct iwl_priv {
spinlock_t reg_lock; /* protect hw register access */
struct mutex mutex;
+ /* TODO: remove this after PCI abstraction is done */
/* basic pci-network driver stuff */
struct pci_dev *pci_dev;
/* pci hardware address support */
void __iomem *hw_base;
+ struct iwl_bus bus; /* bus specific data */
+
/* microcode/device supports multiple contexts */
u8 valid_contexts;