drivers/media/platform/microchip/microchip-isc.h
Source file repositories/reference/linux-study-clean/drivers/media/platform/microchip/microchip-isc.h
File Facts
- System
- Linux kernel
- Corpus path
drivers/media/platform/microchip/microchip-isc.h- Extension
.h- Size
- 11168 bytes
- Lines
- 401
- Domain
- Driver Families
- Bucket
- drivers/media
- 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.
- Touches IRQ or DMA behavior; this matters for the representative real-device path.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/clk-provider.hlinux/platform_device.hmedia/v4l2-ctrls.hmedia/v4l2-device.hmedia/videobuf2-dma-contig.h
Detected Declarations
struct isc_clkstruct isc_bufferstruct isc_subdev_entitystruct isc_formatstruct fmt_configstruct isc_ctrlsstruct isc_reg_offsetsstruct isc_deviceenum isc_clk_idenum isc_mc_padsenum isc_scaler_pads
Annotated Snippet
struct isc_clk {
struct clk_hw hw;
struct clk *clk;
struct regmap *regmap;
spinlock_t lock; /* serialize access to clock registers */
u8 id;
u8 parent_id;
u32 div;
struct device *dev;
};
#define to_isc_clk(v) container_of(v, struct isc_clk, hw)
struct isc_buffer {
struct vb2_v4l2_buffer vb;
struct list_head list;
};
struct isc_subdev_entity {
struct v4l2_subdev *sd;
struct v4l2_async_connection *asd;
struct device_node *epn;
struct v4l2_async_notifier notifier;
u32 pfe_cfg0;
struct list_head list;
};
/*
* struct isc_format - ISC media bus format information
This structure represents the interface between the ISC
and the sensor. It's the input format received by
the ISC.
* @fourcc: Fourcc code for this format
* @mbus_code: V4L2 media bus format code.
* @cfa_baycfg: If this format is RAW BAYER, indicate the type of bayer.
this is either BGBG, RGRG, etc.
* @pfe_cfg0_bps: Number of hardware data lines connected to the ISC
* @raw: If the format is raw bayer.
*/
struct isc_format {
u32 fourcc;
u32 mbus_code;
u32 cfa_baycfg;
u32 pfe_cfg0_bps;
bool raw;
};
/* Pipeline bitmap */
#define DPC_DPCENABLE BIT(0)
#define DPC_GDCENABLE BIT(1)
#define DPC_BLCENABLE BIT(2)
#define WB_ENABLE BIT(3)
#define CFA_ENABLE BIT(4)
#define CC_ENABLE BIT(5)
#define GAM_ENABLE BIT(6)
#define GAM_BENABLE BIT(7)
#define GAM_GENABLE BIT(8)
#define GAM_RENABLE BIT(9)
#define VHXS_ENABLE BIT(10)
#define CSC_ENABLE BIT(11)
#define CBC_ENABLE BIT(12)
#define SUB422_ENABLE BIT(13)
#define SUB420_ENABLE BIT(14)
#define GAM_ENABLES (GAM_RENABLE | GAM_GENABLE | GAM_BENABLE | GAM_ENABLE)
/*
* struct fmt_config - ISC format configuration and internal pipeline
This structure represents the internal configuration
of the ISC.
It also holds the format that ISC will present to v4l2.
* @sd_format: Pointer to an isc_format struct that holds the sensor
configuration.
* @fourcc: Fourcc code for this format.
* @bpp: Bytes per pixel in the current format.
* @bpp_v4l2: Bytes per pixel in the current format, for v4l2.
This differs from 'bpp' in the sense that in planar
formats, it refers only to the first plane.
* @rlp_cfg_mode: Configuration of the RLP (rounding, limiting packaging)
* @dcfg_imode: Configuration of the input of the DMA module
* @dctrl_dview: Configuration of the output of the DMA module
* @bits_pipeline: Configuration of the pipeline, which modules are enabled
*/
struct fmt_config {
struct isc_format *sd_format;
Annotation
- Immediate include surface: `linux/clk-provider.h`, `linux/platform_device.h`, `media/v4l2-ctrls.h`, `media/v4l2-device.h`, `media/videobuf2-dma-contig.h`.
- Detected declarations: `struct isc_clk`, `struct isc_buffer`, `struct isc_subdev_entity`, `struct isc_format`, `struct fmt_config`, `struct isc_ctrls`, `struct isc_reg_offsets`, `struct isc_device`, `enum isc_clk_id`, `enum isc_mc_pads`.
- Atlas domain: Driver Families / drivers/media.
- Implementation status: source implementation candidate.
- IRQ or DMA behavior appears here, which is relevant to the selected PCIe/NVMe device path.
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.