-#ifdef CONFIG_CARL9170FW_RADAR
-static void radar_pattern_generator(void)
-{
- if (fw.phy.state == CARL9170_PHY_ON) {
- if (fw.wlan.soft_radar == NO_RADAR ||
- fw.wlan.soft_radar >= __CARL9170FW_NUM_RADARS)
- return;
-
- const struct radar_info *radar = &radars[fw.wlan.soft_radar];
- if (radar->pulses >= fw.wlan.pattern_index) {
- fw.wlan.pattern_index = 0;
- }
-
- if (radar->pulses > fw.wlan.pattern_index) {
- const struct radar_info_pattern *pattern = &radar->pattern[fw.wlan.pattern_index];
- if (is_after_usecs(fw.wlan.radar_last, pattern->pulse_interval)) {
- fw.wlan.radar_last = get_clock_counter();
- set(0x1C3BC0, pattern->pulse_pattern);
- set(0x1C3BBC, pattern->pulse_mode);
- udelay(pattern->pulse_width);
- set(0x1C3BBC, ~pattern->pulse_mode);
- fw.wlan.pattern_index++;
- }
- }
- }
-}
-#else
-static void radar_pattern_generator(void)
-{
-}
-#endif /* CONFIG_CARL9170FW_RADAR */
-