drivers/platform/x86/dell/alienware-wmi.h
Source file repositories/reference/linux-study-clean/drivers/platform/x86/dell/alienware-wmi.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/platform/x86/dell/alienware-wmi.h- Extension
.h- Size
- 2573 bytes
- Lines
- 118
- Domain
- Driver Families
- Bucket
- drivers/platform
- 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/leds.hlinux/platform_device.hlinux/wmi.h
Detected Declarations
struct alienfx_quirksstruct color_platformstruct alienfx_privstruct alienfx_opsstruct alienfx_platdataenum INTERFACE_FLAGSenum LEGACY_CONTROL_STATESenum WMAX_CONTROL_STATESfunction alienware_legacy_wmi_initfunction alienware_legacy_wmi_exitfunction alienware_wmax_wmi_initfunction alienware_wmax_wmi_exit
Annotated Snippet
struct alienfx_quirks {
u8 num_zones;
bool hdmi_mux;
bool amplifier;
bool deepslp;
};
struct color_platform {
u8 blue;
u8 green;
u8 red;
} __packed;
struct alienfx_priv {
struct platform_device *pdev;
struct led_classdev global_led;
struct color_platform colors[4];
u8 global_brightness;
u8 lighting_control_state;
};
struct alienfx_ops {
int (*upd_led)(struct alienfx_priv *priv, struct wmi_device *wdev,
u8 location);
int (*upd_brightness)(struct alienfx_priv *priv, struct wmi_device *wdev,
u8 brightness);
};
struct alienfx_platdata {
struct wmi_device *wdev;
struct alienfx_ops ops;
};
extern u8 alienware_interface;
extern struct alienfx_quirks *alienfx;
int alienware_wmi_command(struct wmi_device *wdev, u32 method_id,
void *in_args, size_t in_size, u32 *out_data);
int alienware_alienfx_setup(struct alienfx_platdata *pdata);
#if IS_ENABLED(CONFIG_ALIENWARE_WMI_LEGACY)
int __init alienware_legacy_wmi_init(void);
void __exit alienware_legacy_wmi_exit(void);
#else
static inline int alienware_legacy_wmi_init(void)
{
return -ENODEV;
}
static inline void alienware_legacy_wmi_exit(void)
{
}
#endif
#if IS_ENABLED(CONFIG_ALIENWARE_WMI_WMAX)
extern const struct attribute_group wmax_hdmi_attribute_group;
extern const struct attribute_group wmax_amplifier_attribute_group;
extern const struct attribute_group wmax_deepsleep_attribute_group;
#define WMAX_DEV_GROUPS &wmax_hdmi_attribute_group, \
&wmax_amplifier_attribute_group, \
&wmax_deepsleep_attribute_group,
int __init alienware_wmax_wmi_init(void);
void __exit alienware_wmax_wmi_exit(void);
#else
#define WMAX_DEV_GROUPS
static inline int alienware_wmax_wmi_init(void)
{
return -ENODEV;
}
static inline void alienware_wmax_wmi_exit(void)
{
}
#endif
#endif
Annotation
- Immediate include surface: `linux/leds.h`, `linux/platform_device.h`, `linux/wmi.h`.
- Detected declarations: `struct alienfx_quirks`, `struct color_platform`, `struct alienfx_priv`, `struct alienfx_ops`, `struct alienfx_platdata`, `enum INTERFACE_FLAGS`, `enum LEGACY_CONTROL_STATES`, `enum WMAX_CONTROL_STATES`, `function alienware_legacy_wmi_init`, `function alienware_legacy_wmi_exit`.
- Atlas domain: Driver Families / drivers/platform.
- 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.