STRUCT DPU_ENCODER_PHYS(9)
π struct dpu_encoder_phys(9)
okay so bestie, this is the struct dpu_encoder_phys β the physical encoder that drives a single INTF block tied to a specific panel / sub-panel. it's an abstract type, meaning it gets sub-classed by phys_vid or phys_cmd for video mode or command mode encs respectively. basically it's the blueprint, not the building, iykyk π
β¨ SYNOPSIS β¨
struct dpu_encoder_phys {
struct drm_encoder *parent;
struct dpu_encoder_phys_ops ops;
struct dpu_hw_mdp *hw_mdptop;
struct dpu_hw_ctl *hw_ctl;
struct dpu_hw_pingpong *hw_pp;
struct dpu_hw_intf *hw_intf;
struct dpu_hw_wb *hw_wb;
struct dpu_hw_cdm *hw_cdm;
struct dpu_kms *dpu_kms;
struct dpu_hw_cdm_cfg cdm_cfg;
struct drm_display_mode cached_mode;
struct mutex vblank_ctl_lock;
enum dpu_enc_split_role split_role;
enum dpu_intf_mode intf_mode;
spinlock_t *enc_spinlock;
enum dpu_enc_enable_state enable_state;
int vblank_refcount;
atomic_t vsync_cnt;
atomic_t underrun_cnt;
atomic_t pending_ctlstart_cnt;
atomic_t pending_kickoff_cnt;
wait_queue_head_t pending_kickoff_wq;
unsigned int irq[INTR_IDX_MAX];
bool has_intf_te;
};
πΈ MEMBERS πΈ
like, every single field, no skips, we're doing the full tour π«Ά
parentβ pointer to the containing virtual encoder. the parent, if you will πopsβ the operations exposed to the virtual encoder. this is the whole API vibe.hw_mdptopβ hardware interface to the top registers β¨hw_ctlβ hardware interface to the ctl registershw_ppβ hardware interface to the ping pong registers πhw_intfβ hardware interface to the intf registershw_wbβ hardware interface to the wb registershw_cdmβ hardware interface to the CDM registersdpu_kmsβ pointer to thedpu_kmstop level. main character of the whole file ngl πcdm_cfgβ CDM block config needed to store WB/DP block's CDM configurationcached_modeβ DRM mode cached atmode_settime, acted on in enable. it's giving "remember it now, use it later" πvblank_ctl_lockβ Vblank ctl mutex lock to protectvblank_refcount. do NOT let the refcount out without it πsplit_roleβ role to play in a split-panel configurationintf_modeβ interface modeenc_spinlockβ Virtual-Encoder-Wide Spin Lock for IRQ purposes π₯enable_stateβ enable state tracking. keeping receipts, fr frvblank_refcountβ reference count of vblank requestvsync_cntβ Vsync count for the physical encoderunderrun_cntβ Underrun count for the physical encoder π (we track the sad stuff too)pending_ctlstart_cntβ atomic counter tracking the number of ctl start pending.pending_kickoff_cntβ atomic counter tracking the number of kickoffs vs. the number of done/vblank irqs. should hover between 0-2. incremented when a new kickoff is scheduled. decremented in irq handler. literally living in the 0-to-2 range, that's its whole personality βpending_kickoff_wqβ wait queue for blocking until kickoff completes. the "hold on, we're not done yet" energy πirqβ IRQ indiceshas_intf_teβ interface TE configuration support
π¦ SEE ALSO π¦
kernel file ./drivers/gpu/drm/msm/disp/dpu1/dpu_encoder_phys.h β and go read up on enum dpu_enc_split_role(9), enum dpu_enc_enable_state(9), struct dpu_encoder_phys_ops(9), enum dpu_intr_idx(9), struct dpu_encoder_phys_wb(9), struct dpu_encoder_phys_cmd(9), and struct dpu_enc_phys_init_params(9). the whole friend group, you'll love them π
ok that's the whole page, no notes π every field accounted for, nothing invented, periodt.
so yeah β this lives in ./drivers/gpu/drm/msm/disp/dpu1, dated October 2026, and it's titled struct dpu_encoder_phys(9) if you ever need to cite it in the group chat πβ¨ mwah, go read the header file bestie π
π¦ where this page comes from
- nixpkgs unstable: linux-manual 7.3.1
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms