def_bool y
prompt "Experimental Features"
-config CARL9170FW_PSM
- def_bool y
- prompt "Firmware Supported Power-saving Management"
- depends on CARL9170FW_EXPERIMENTAL && CARL9170FW_RADIO_FUNCTIONS
- ---help---
- This options enables a interface for the application to
- switch off the RF/PHY (in order to save power). And the
- Firmware will automatically turn it on again, when the
- PRETBTT event fires.
-
config CARL9170FW_WOL_OPTION
def_bool n
prompt "Wakeup on WLAN"
unsigned int frequency;
unsigned int ht_settings;
-#ifdef CONFIG_CARL9170FW_PSM
struct carl9170_psm psm;
-#endif /* CONFIG_CARL9170FW_PSM */
#endif /* CONFIG_CARL9170FW_RADIO_FUNCTIONS */
} phy;
rf_notify_set_channel();
break;
-# ifdef CONFIG_CARL9170FW_PSM
case CARL9170_CMD_PSM:
resp->hdr.len = 0;
fw.phy.psm.state = le32_to_cpu(cmd->psm.state);
rf_psm();
break;
-# endif /* CONFIG_CARL9170FW_PSM */
#endif /* CONFIG_CARL9170FW_RADIO_FUNCTIOS */
default:
FILL(otus, OTUS,
.feature_set = cpu_to_le32(BIT(CARL9170FW_DUMMY_FEATURE) |
BIT(CARL9170FW_USB_RESP_EP2) |
+ BIT(CARL9170FW_PSM) |
+ BIT(CARL9170FW_RX_FILTER) |
#ifdef CONFIG_CARL9170FW_USB_INIT_FIRMWARE
BIT(CARL9170FW_USB_INIT_FIRMWARE) |
# ifdef CONFIG_CARL9170FW_USB_UP_STREAM
#ifdef CONFIG_CARL9170FW_GPIO_INTERRUPT
BIT(CARL9170FW_GPIO_INTERRUPT) |
#endif /* CONFIG_CARL9170FW_GPIO_INTERRUPT */
-#ifdef CONFIG_CARL9170FW_PSM
- BIT(CARL9170FW_PSM) |
-#endif /* CONFIG_CARL9170FW_PSM */
- BIT(CARL9170FW_RX_FILTER) |
#ifdef CONFIG_CARL9170FW_WOL
BIT(CARL9170FW_WOL) |
#endif /* CONFIG_CARL9170FW_WOL */
- (0)),
+ (0)),
.miniboot_size = cpu_to_le16(0),
.tx_descs = AR9170_TX_BLOCK_NUMBER,
resp->rf_init_res.ret = cpu_to_le32(ret);
}
-#ifdef CONFIG_CARL9170FW_PSM
void rf_psm(void)
{
u32 bank3;
set(0x1c58f0, bank3);
}
-#endif /* CONFIG_CARL9170FW_PSM */
#endif /* CONFIG_CARL9170FW_RADIO_FUNCTIONS */
# endif
#else /* CONFIG_CARL9170FW_LOOPBACK */
-# if ((defined CONFIG_CARL9170FW_DEBUG) && (defined CONFIG_CARL9170FW_PSM))
+# ifdef CONFIG_CARL9170FW_DEBUG
BUG_ON(fw.phy.psm.state != CARL9170_PSM_WAKE);
-# endif /* CONFIG_CARL9170FW_DEBUG && CONFIG_CARL9170FW_PSM */
+# endif /* CONFIG_CARL9170FW_DEBUG */
/* insert desc into the right queue */
dma_put(&fw.wlan.tx_queue[super->s.queue], desc);
fw.wlan.cab_flush_time = get_clock_counter();
#endif /* CONFIG_CARL9170FW_CAB_QUEUE */
-#ifdef CONFIG_CARL9170FW_PSM
rf_psm();
send_cmd_to_host(4, CARL9170_RSP_PRETBTT, 0x00,
(uint8_t *) &fw.phy.psm.state);
-#else
- send_cmd_to_host(0, CARL9170_RSP_PRETBTT, 0x00, NULL);
-#endif /* CONFIG_CARL9170FW_PSM */
}
static void handle_atim(void)