drivers/net/wireless/ath/dfs_pattern_detector.h
Source file repositories/reference/linux-study-clean/drivers/net/wireless/ath/dfs_pattern_detector.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/net/wireless/ath/dfs_pattern_detector.h- Extension
.h- Size
- 3943 bytes
- Lines
- 123
- Domain
- Driver Families
- Bucket
- drivers/net
- Inferred role
- Driver Families: implementation source
- Status
- source implementation candidate
Why This File Exists
Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Repeatable hardware-adapter layer. Deep compatibility for every driver is out of scope; this atlas records patterns, probe lifecycles, bus glue, IRQ/DMA usage, and links back to core abstractions.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/types.hlinux/list.hlinux/nl80211.h
Detected Declarations
struct ath_dfs_pool_statsstruct pulse_eventstruct radar_detector_specsstruct dfs_pattern_detector
Annotated Snippet
struct ath_dfs_pool_stats {
u32 pool_reference;
u32 pulse_allocated;
u32 pulse_alloc_error;
u32 pulse_used;
u32 pseq_allocated;
u32 pseq_alloc_error;
u32 pseq_used;
};
/**
* struct pulse_event - describing pulses reported by PHY
* @ts: pulse time stamp in us
* @freq: channel frequency in MHz
* @width: pulse duration in us
* @rssi: rssi of radar event
* @chirp: chirp detected in pulse
*/
struct pulse_event {
u64 ts;
u16 freq;
u8 width;
u8 rssi;
bool chirp;
};
/**
* struct radar_detector_specs - detector specs for a radar pattern type
* @type_id: pattern type, as defined by regulatory
* @width_min: minimum radar pulse width in [us]
* @width_max: maximum radar pulse width in [us]
* @pri_min: minimum pulse repetition interval in [us] (including tolerance)
* @pri_max: minimum pri in [us] (including tolerance)
* @num_pri: maximum number of different pri for this type
* @ppb: pulses per bursts for this type
* @ppb_thresh: number of pulses required to trigger detection
* @max_pri_tolerance: pulse time stamp tolerance on both sides [us]
* @chirp: chirp required for the radar pattern
*/
struct radar_detector_specs {
u8 type_id;
u8 width_min;
u8 width_max;
u16 pri_min;
u16 pri_max;
u8 num_pri;
u8 ppb;
u8 ppb_thresh;
u8 max_pri_tolerance;
bool chirp;
};
/**
* struct dfs_pattern_detector - DFS pattern detector
* @exit(): destructor
* @set_dfs_domain(): set DFS domain, resets detector lines upon domain changes
* @add_pulse(): add radar pulse to detector, returns true on detection
* @region: active DFS region, NL80211_DFS_UNSET until set
* @num_radar_types: number of different radar types
* @last_pulse_ts: time stamp of last valid pulse in usecs
* @radar_detector_specs: array of radar detection specs
* @channel_detectors: list connecting channel_detector elements
*/
struct dfs_pattern_detector {
void (*exit)(struct dfs_pattern_detector *dpd);
bool (*set_dfs_domain)(struct dfs_pattern_detector *dpd,
enum nl80211_dfs_regions region);
bool (*add_pulse)(struct dfs_pattern_detector *dpd,
struct pulse_event *pe,
struct radar_detector_specs *rs);
struct ath_dfs_pool_stats (*get_stats)(struct dfs_pattern_detector *dpd);
enum nl80211_dfs_regions region;
u8 num_radar_types;
u64 last_pulse_ts;
/* needed for ath_dbg() */
struct ath_common *common;
const struct radar_detector_specs *radar_spec;
struct list_head channel_detectors;
};
/**
* dfs_pattern_detector_init() - constructor for pattern detector class
* @param region: DFS domain to be used, can be NL80211_DFS_UNSET at creation
* @return instance pointer on success, NULL otherwise
*/
extern struct dfs_pattern_detector *
dfs_pattern_detector_init(struct ath_common *common,
enum nl80211_dfs_regions region);
Annotation
- Immediate include surface: `linux/types.h`, `linux/list.h`, `linux/nl80211.h`.
- Detected declarations: `struct ath_dfs_pool_stats`, `struct pulse_event`, `struct radar_detector_specs`, `struct dfs_pattern_detector`.
- Atlas domain: Driver Families / drivers/net.
- Implementation status: source implementation candidate.
Implementation Notes
- This generated page is the file-by-file coverage layer; curated subsystem chapters should link here when they synthesize a multi-file control flow.
- Core OS pages should be promoted from atlas-only to deep-reviewed when they explain data structures, invariants, locking, lifecycle, and C implementation snippets.
- Driver-family pages are intentionally pattern-oriented unless they are part of the selected PCIe/NVMe representative device path.