drivers/gpu/drm/nouveau/nouveau_encoder.h
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/nouveau/nouveau_encoder.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/nouveau/nouveau_encoder.h- Extension
.h- Size
- 4573 bytes
- Lines
- 178
- 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.
- Uses kernel synchronization; read lock ordering, sleepability, and interrupt context assumptions before translating.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
nvif/outp.hsubdev/bios/dcb.hdrm/display/drm_dp_helper.hdrm/display/drm_dp_mst_helper.hdispnv04/i2c/encoder_i2c.hdispnv04/disp.h
Detected Declarations
struct nv50_head_atomstruct nouveau_connectorstruct nvkm_i2c_portstruct nouveau_encoderstruct nv50_mstmenum nouveau_dp_status
Annotated Snippet
struct nouveau_encoder {
struct nouveau_i2c_encoder base;
struct dcb_output *dcb;
struct nvif_outp outp;
int or;
struct nouveau_connector *conn;
struct i2c_adapter *i2c;
/* different to drm_encoder.crtc, this reflects what's
* actually programmed on the hw, not the proposed crtc */
struct drm_crtc *crtc;
u32 ctrl;
/* Protected by nouveau_drm.audio.lock */
struct {
bool enabled;
} audio;
struct drm_display_mode mode;
int last_dpms;
struct nv04_output_reg restore;
struct {
struct {
bool enabled;
} hdmi;
struct {
struct nv50_mstm *mstm;
struct {
u8 caps[DP_LTTPR_COMMON_CAP_SIZE];
u8 nr;
} lttpr;
u8 dpcd[DP_RECEIVER_CAP_SIZE];
struct nvif_outp_dp_rate rate[8];
int rate_nr;
int link_nr;
int link_bw;
struct {
bool mst;
u8 nr;
u32 bw;
} lt;
/* Protects DP state that needs to be accessed outside
* connector reprobing contexts
*/
struct mutex hpd_irq_lock;
u8 downstream_ports[DP_MAX_DOWNSTREAM_PORTS];
struct drm_dp_desc desc;
u8 sink_count;
} dp;
};
struct {
bool dp_interlace : 1;
} caps;
void (*enc_save)(struct drm_encoder *encoder);
void (*enc_restore)(struct drm_encoder *encoder);
void (*update)(struct nouveau_encoder *, u8 head,
struct nv50_head_atom *, u8 proto, u8 depth);
};
struct nv50_mstm {
struct nouveau_encoder *outp;
struct drm_dp_mst_topology_mgr mgr;
/* Protected under nouveau_encoder->dp.hpd_irq_lock */
bool can_mst;
bool is_mst;
bool suspended;
bool modified;
bool disabled;
int links;
};
Annotation
- Immediate include surface: `nvif/outp.h`, `subdev/bios/dcb.h`, `drm/display/drm_dp_helper.h`, `drm/display/drm_dp_mst_helper.h`, `dispnv04/i2c/encoder_i2c.h`, `dispnv04/disp.h`.
- Detected declarations: `struct nv50_head_atom`, `struct nouveau_connector`, `struct nvkm_i2c_port`, `struct nouveau_encoder`, `struct nv50_mstm`, `enum nouveau_dp_status`.
- Atlas domain: Driver Families / drivers/gpu.
- Implementation status: source implementation candidate.
- Synchronization appears in or near this file; preserve lock ordering, sleepability, and interrupt-context constraints.
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.