aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/rt2x00/rt2800lib.h
diff options
context:
space:
mode:
authorGertjan van Wingerde <gwingerde@gmail.com>2010-06-03 04:52:04 -0400
committerIvo van Doorn <IvDoorn@gmail.com>2010-06-03 04:52:04 -0400
commite3a896b9924d6dcd88ad16186d7ec77f32d12ef8 (patch)
treec1b629c50a81f005e6af11b8e32d85f632becb39 /drivers/net/wireless/rt2x00/rt2800lib.h
parent8440c292798a6a7dc70356df80de84e0082bd99d (diff)
rt2x00: Move PCI/USB specific register initializations to rt2800{pci,usb}.
This prevents us having common code depend on PCI or USB specific code. Signed-off-by: Gertjan van Wingerde <gwingerde@gmail.com> Signed-off-by: Ivo van Doorn <IvDoorn@gmail.com>
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt2800lib.h')
-rw-r--r--drivers/net/wireless/rt2x00/rt2800lib.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/net/wireless/rt2x00/rt2800lib.h b/drivers/net/wireless/rt2x00/rt2800lib.h
index b16fd6d2d22c..8313dbf441a5 100644
--- a/drivers/net/wireless/rt2x00/rt2800lib.h
+++ b/drivers/net/wireless/rt2x00/rt2800lib.h
@@ -40,6 +40,8 @@ struct rt2800_ops {
40 int (*regbusy_read)(struct rt2x00_dev *rt2x00dev, 40 int (*regbusy_read)(struct rt2x00_dev *rt2x00dev,
41 const unsigned int offset, 41 const unsigned int offset,
42 const struct rt2x00_field32 field, u32 *reg); 42 const struct rt2x00_field32 field, u32 *reg);
43
44 int (*drv_init_registers)(struct rt2x00_dev *rt2x00dev);
43}; 45};
44 46
45static inline void rt2800_register_read(struct rt2x00_dev *rt2x00dev, 47static inline void rt2800_register_read(struct rt2x00_dev *rt2x00dev,
@@ -107,6 +109,13 @@ static inline int rt2800_regbusy_read(struct rt2x00_dev *rt2x00dev,
107 return rt2800ops->regbusy_read(rt2x00dev, offset, field, reg); 109 return rt2800ops->regbusy_read(rt2x00dev, offset, field, reg);
108} 110}
109 111
112static inline int rt2800_drv_init_registers(struct rt2x00_dev *rt2x00dev)
113{
114 const struct rt2800_ops *rt2800ops = rt2x00dev->priv;
115
116 return rt2800ops->drv_init_registers(rt2x00dev);
117}
118
110void rt2800_mcu_request(struct rt2x00_dev *rt2x00dev, 119void rt2800_mcu_request(struct rt2x00_dev *rt2x00dev,
111 const u8 command, const u8 token, 120 const u8 command, const u8 token,
112 const u8 arg0, const u8 arg1); 121 const u8 arg0, const u8 arg1);