drivers/gpu/drm/panthor/panthor_hw.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/panthor/panthor_hw.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/panthor/panthor_hw.h- Extension
.h- Size
- 1754 bytes
- Lines
- 65
- Domain
- Driver Families
- Bucket
- drivers/gpu
- 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
panthor_device.hpanthor_gpu_regs.h
Detected Declarations
struct panthor_hw_opsstruct panthor_hwfunction panthor_hw_soft_resetfunction panthor_hw_l2_power_onfunction panthor_hw_l2_power_offfunction panthor_hw_has_pwr_ctrl
Annotated Snippet
struct panthor_hw_ops {
/** @soft_reset: Soft reset function pointer */
int (*soft_reset)(struct panthor_device *ptdev);
/** @l2_power_off: L2 power off function pointer */
void (*l2_power_off)(struct panthor_device *ptdev);
/** @l2_power_on: L2 power on function pointer */
int (*l2_power_on)(struct panthor_device *ptdev);
/** @power_changed_on: Start listening to power change IRQs */
int (*power_changed_on)(struct panthor_device *ptdev);
/** @power_changed_off: Stop listening to power change IRQs */
void (*power_changed_off)(struct panthor_device *ptdev);
};
/**
* struct panthor_hw - GPU specific register mapping and functions
*/
struct panthor_hw {
/** @features: Bitmap containing panthor_hw_feature */
/** @ops: Panthor HW specific operations */
struct panthor_hw_ops ops;
};
int panthor_hw_init(struct panthor_device *ptdev);
int panthor_hw_power_status_register(void);
void panthor_hw_power_status_unregister(void);
static inline int panthor_hw_soft_reset(struct panthor_device *ptdev)
{
return ptdev->hw->ops.soft_reset(ptdev);
}
static inline int panthor_hw_l2_power_on(struct panthor_device *ptdev)
{
return ptdev->hw->ops.l2_power_on(ptdev);
}
static inline void panthor_hw_l2_power_off(struct panthor_device *ptdev)
{
ptdev->hw->ops.l2_power_off(ptdev);
}
static inline bool panthor_hw_has_pwr_ctrl(struct panthor_device *ptdev)
{
return GPU_ARCH_MAJOR(ptdev->gpu_info.gpu_id) >= 14;
}
#endif /* __PANTHOR_HW_H__ */
Annotation
- Immediate include surface: `panthor_device.h`, `panthor_gpu_regs.h`.
- Detected declarations: `struct panthor_hw_ops`, `struct panthor_hw`, `function panthor_hw_soft_reset`, `function panthor_hw_l2_power_on`, `function panthor_hw_l2_power_off`, `function panthor_hw_has_pwr_ctrl`.
- Atlas domain: Driver Families / drivers/gpu.
- 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.