diff options
Diffstat (limited to 'drivers/net/wireless/rt2x00/rt61pci.c')
-rw-r--r-- | drivers/net/wireless/rt2x00/rt61pci.c | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/net/wireless/rt2x00/rt61pci.c b/drivers/net/wireless/rt2x00/rt61pci.c index 432e75f960b7..b9885981f3a8 100644 --- a/drivers/net/wireless/rt2x00/rt61pci.c +++ b/drivers/net/wireless/rt2x00/rt61pci.c | |||
@@ -2118,6 +2118,14 @@ static void rt61pci_txdone(struct rt2x00_dev *rt2x00dev) | |||
2118 | } | 2118 | } |
2119 | } | 2119 | } |
2120 | 2120 | ||
2121 | static void rt61pci_wakeup(struct rt2x00_dev *rt2x00dev) | ||
2122 | { | ||
2123 | struct ieee80211_conf conf = { .flags = 0 }; | ||
2124 | struct rt2x00lib_conf libconf = { .conf = &conf }; | ||
2125 | |||
2126 | rt61pci_config(rt2x00dev, &libconf, IEEE80211_CONF_CHANGE_PS); | ||
2127 | } | ||
2128 | |||
2121 | static irqreturn_t rt61pci_interrupt(int irq, void *dev_instance) | 2129 | static irqreturn_t rt61pci_interrupt(int irq, void *dev_instance) |
2122 | { | 2130 | { |
2123 | struct rt2x00_dev *rt2x00dev = dev_instance; | 2131 | struct rt2x00_dev *rt2x00dev = dev_instance; |
@@ -2165,6 +2173,12 @@ static irqreturn_t rt61pci_interrupt(int irq, void *dev_instance) | |||
2165 | rt2x00pci_register_write(rt2x00dev, | 2173 | rt2x00pci_register_write(rt2x00dev, |
2166 | M2H_CMD_DONE_CSR, 0xffffffff); | 2174 | M2H_CMD_DONE_CSR, 0xffffffff); |
2167 | 2175 | ||
2176 | /* | ||
2177 | * 4 - MCU Autowakeup interrupt. | ||
2178 | */ | ||
2179 | if (rt2x00_get_field32(reg_mcu, MCU_INT_SOURCE_CSR_TWAKEUP)) | ||
2180 | rt61pci_wakeup(rt2x00dev); | ||
2181 | |||
2168 | return IRQ_HANDLED; | 2182 | return IRQ_HANDLED; |
2169 | } | 2183 | } |
2170 | 2184 | ||