include/uapi/linux/pwm.h
Source file repositories/reference/linux-study-clean/include/uapi/linux/pwm.h
File Facts
- System
- Linux kernel
- Corpus path
include/uapi/linux/pwm.h- Extension
.h- Size
- 1777 bytes
- Lines
- 54
- Domain
- Core OS
- Bucket
- Core Kernel Interface
- Inferred role
- Core OS: implementation source
- Status
- source implementation candidate
Why This File Exists
Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Core operating-system implementation surface: boot, tasks, memory, VFS, syscall-facing interfaces, synchronization, credentials, and isolation.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/ioctl.hlinux/types.h
Detected Declarations
struct pwmchip_waveform
Annotated Snippet
struct pwmchip_waveform {
__u32 hwpwm;
__u32 __pad;
__u64 period_length_ns;
__u64 duty_length_ns;
__u64 duty_offset_ns;
};
/* Reserves the passed hwpwm for exclusive control. */
#define PWM_IOCTL_REQUEST _IO(0x75, 1)
/* counter part to PWM_IOCTL_REQUEST */
#define PWM_IOCTL_FREE _IO(0x75, 2)
/*
* Modifies the passed wf according to hardware constraints. All parameters are
* rounded down to the next possible value, unless there is no such value, then
* values are rounded up. Note that zero isn't considered for rounding down
* period_length_ns.
*/
#define PWM_IOCTL_ROUNDWF _IOWR(0x75, 3, struct pwmchip_waveform)
/* Get the currently implemented waveform */
#define PWM_IOCTL_GETWF _IOWR(0x75, 4, struct pwmchip_waveform)
/* Like PWM_IOCTL_ROUNDWF + PWM_IOCTL_SETEXACTWF in one go. */
#define PWM_IOCTL_SETROUNDEDWF _IOW(0x75, 5, struct pwmchip_waveform)
/*
* Program the PWM to emit exactly the passed waveform, subject only to rounding
* down each value less than 1 ns. Returns 0 on success, -EDOM if the waveform
* cannot be implemented exactly, or other negative error codes.
*/
#define PWM_IOCTL_SETEXACTWF _IOW(0x75, 6, struct pwmchip_waveform)
#endif /* _UAPI_PWM_H_ */
Annotation
- Immediate include surface: `linux/ioctl.h`, `linux/types.h`.
- Detected declarations: `struct pwmchip_waveform`.
- Atlas domain: Core OS / Core Kernel Interface.
- 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.