STRUCT FIMC_DEV(9)
π struct fimc_dev β abstraction for FIMC entity π
okay bestie, gather round, because this is the big one in the FIMC corner of the kernel: struct fimc_dev is literally the whole-vibe abstraction for a FIMC entity β¨ It's the main character struct that everything else in this driver orbits around. This page lives in the Kernel API Manual, section 9 (that's the kernel-symbols girlies), and honestly? Obsessed.
πΈ SYNOPSIS πΈ
Here's the whole shape of her, verbatim, no cap β copy it exactly, don't you dare retype it by hand π
struct fimc_dev {
spinlock_t slock;
struct mutex lock;
struct platform_device *pdev;
struct s5p_platform_fimc *pdata;
struct regmap *sysreg;
const struct fimc_variant *variant;
const struct fimc_drvdata *drv_data;
int id;
struct clk *clock[MAX_FIMC_CLOCKS];
void __iomem *regs;
wait_queue_head_t irq_queue;
struct v4l2_device *v4l2_dev;
struct fimc_m2m_device m2m;
struct fimc_vid_cap vid_cap;
unsigned long state;
};
π Members π
like, member by member, here's who's who in the group chat π
slockβ the spinlock guarding this data structure π short and spicy, don't sleep in it.lockβ the mutex guarding this data structure π the chill, can-take-a-nap version of protection.pdevβ pointer to the FIMC platform device π§pdataβ pointer to the device platform data πsysregβ pointer to the SYSREG regmap πΊοΈvariantβ the IP variant information π tells you which flavour of silicon you're dealing with.drv_dataβ driver data π¦idβ FIMC device index (0..FIMC_MAX_DEVS) π’ literally her number in the lineup.clockβ clocks required for FIMC operation β° yes, plural, it's givingMAX_FIMC_CLOCKSof them.regsβ the mapped hardware registers π₯οΈ (void __iomem *, so you know it's the real hardware door.)irq_queueβ interrupt handler waitqueue π where everyone waits for the interrupt to show up.v4l2_devβ rootv4l2_deviceπΊm2mβ memory-to-memory V4L2 device information πvid_capβ camera capture device information π·stateβ flags used to synchronize m2m and capture mode operation π¦ the referee between the two modes, lowkey the most important job here.
π¦ SEE ALSO π¦
go read the source, bestie, it's right here in the kernel tree:
Kernel file ./drivers/media/platform/samsung/exynos4-is/fimc-core.h
and the whole friend group, fr fr:
struct fimc_dma_offset(9)struct fimc_effect(9)struct fimc_scaler(9)struct fimc_addr(9)struct fimc_vid_buffer(9)struct fimc_frame(9)struct fimc_m2m_device(9)struct fimc_vid_cap(9)struct fimc_pix_limit(9)struct fimc_variant(9)struct fimc_drvdata(9)struct fimc_ctrls(9)struct fimc_ctx(9)fimc_active_queue_add(9)fimc_active_queue_pop(9)fimc_pending_queue_add(9)fimc_pending_queue_pop(9)
π tiny heads-up:slockandlockare both here protecting this same struct β two different lock types, two different rules, so know which one you're holding before you touch anything. no cap, that's the classic oopsie.
okay that's the whole page, you ate that π«Ά this gem comes from ./drivers/media/platform/samsu... and it's dated October 2026 β so go forth, read the header file, and slay your FIMC bring-up, 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