drivers/gpu/drm/panel/panel-visionox-r66451.c
Source file repositories/reference/linux-study-clean/drivers/gpu/drm/panel/panel-visionox-r66451.c
File Facts
- System
- Linux kernel
- Corpus path
drivers/gpu/drm/panel/panel-visionox-r66451.c- Extension
.c- Size
- 10728 bytes
- Lines
- 350
- 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.
- Allocates kernel memory; connect allocation flags and lifetime to context constraints.
- Defines or uses C structs; map object ownership, embedded links, reference counts, and lock ownership.
Dependency Surface
linux/backlight.hlinux/delay.hlinux/gpio/consumer.hlinux/module.hlinux/of.hlinux/regulator/consumer.hdrm/drm_mipi_dsi.hdrm/drm_probe_helper.hdrm/drm_modes.hdrm/drm_panel.hdrm/display/drm_dsc.hdrm/display/drm_dsc_helper.hvideo/mipi_display.h
Detected Declarations
struct visionox_r66451function visionox_r66451_resetfunction visionox_r66451_onfunction visionox_r66451_offfunction visionox_r66451_preparefunction visionox_r66451_unpreparefunction visionox_r66451_enablefunction visionox_r66451_disablefunction visionox_r66451_get_modesfunction visionox_r66451_bl_update_statusfunction visionox_r66451_create_backlightfunction visionox_r66451_probefunction visionox_r66451_remove
Annotated Snippet
struct visionox_r66451 {
struct drm_panel panel;
struct mipi_dsi_device *dsi;
struct gpio_desc *reset_gpio;
struct regulator_bulk_data supplies[2];
};
static inline struct visionox_r66451 *to_visionox_r66451(struct drm_panel *panel)
{
return container_of(panel, struct visionox_r66451, panel);
}
static void visionox_r66451_reset(struct visionox_r66451 *ctx)
{
gpiod_set_value_cansleep(ctx->reset_gpio, 0);
usleep_range(10000, 10100);
gpiod_set_value_cansleep(ctx->reset_gpio, 1);
usleep_range(10000, 10100);
gpiod_set_value_cansleep(ctx->reset_gpio, 0);
usleep_range(10000, 10100);
}
static int visionox_r66451_on(struct visionox_r66451 *ctx)
{
struct mipi_dsi_device *dsi = ctx->dsi;
struct mipi_dsi_multi_context dsi_ctx = { .dsi = dsi };
dsi->mode_flags |= MIPI_DSI_MODE_LPM;
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xc2,
0x09, 0x24, 0x0c, 0x00, 0x00, 0x0c, 0x00, 0x00, 0x00,
0x09, 0x3c);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xd7,
0x00, 0xb9, 0x3c, 0x00, 0x40, 0x04, 0x00, 0xa0, 0x0a,
0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19,
0x3c, 0x00, 0x40, 0x04, 0x00, 0xa0, 0x0a);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x80);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xde,
0x40, 0x00, 0x18, 0x00, 0x18, 0x00, 0x18, 0x00, 0x18,
0x10, 0x00, 0x18, 0x00, 0x18, 0x00, 0x18, 0x02, 0x00, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x04);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xe8, 0x00, 0x02);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xe4, 0x00, 0x08);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xc4,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x32);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xcf,
0x64, 0x0b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x08,
0x00, 0x0b, 0x77, 0x01, 0x01, 0x01, 0x01, 0x01, 0x01,
0x02, 0x02, 0x02, 0x02, 0x02, 0x03);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xd3,
0x45, 0x00, 0x00, 0x01, 0x13, 0x15, 0x00, 0x15, 0x07,
0x0f, 0x77, 0x77, 0x77, 0x37, 0xb2, 0x11, 0x00, 0xa0,
0x3c, 0x9c);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xd7,
0x00, 0xb9, 0x34, 0x00, 0x40, 0x04, 0x00, 0xa0, 0x0a,
0x00, 0x40, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19,
0x34, 0x00, 0x40, 0x04, 0x00, 0xa0, 0x0a);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xd8,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x3a, 0x00, 0x3a, 0x00, 0x3a, 0x00, 0x3a, 0x00, 0x3a,
0x05, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x0a, 0x00, 0x0a, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0a,
0x00, 0x32, 0x00, 0x0a, 0x00, 0x22);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xdf,
0x50, 0x42, 0x58, 0x81, 0x2d, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x6b, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x01, 0x0f, 0xff, 0xd4, 0x0e, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x0f, 0x53, 0xf1, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf7, 0x01);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x80);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xe4, 0x34, 0xb4, 0x00, 0x00, 0x00, 0x39,
0x04, 0x09, 0x34);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xe6, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xb0, 0x04);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xdf, 0x50, 0x40);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf3, 0x50, 0x00, 0x00, 0x00, 0x00);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf2, 0x11);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf3, 0x01, 0x00, 0x00, 0x00, 0x01);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf4, 0x00, 0x02);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xf2, 0x19);
mipi_dsi_dcs_write_seq_multi(&dsi_ctx, 0xdf, 0x50, 0x42);
mipi_dsi_dcs_set_tear_on_multi(&dsi_ctx, MIPI_DSI_DCS_TEAR_MODE_VBLANK);
mipi_dsi_dcs_set_column_address_multi(&dsi_ctx, 0, 1080 - 1);
mipi_dsi_dcs_set_page_address_multi(&dsi_ctx, 0, 2340 - 1);
Annotation
- Immediate include surface: `linux/backlight.h`, `linux/delay.h`, `linux/gpio/consumer.h`, `linux/module.h`, `linux/of.h`, `linux/regulator/consumer.h`, `drm/drm_mipi_dsi.h`, `drm/drm_probe_helper.h`.
- Detected declarations: `struct visionox_r66451`, `function visionox_r66451_reset`, `function visionox_r66451_on`, `function visionox_r66451_off`, `function visionox_r66451_prepare`, `function visionox_r66451_unprepare`, `function visionox_r66451_enable`, `function visionox_r66451_disable`, `function visionox_r66451_get_modes`, `function visionox_r66451_bl_update_status`.
- 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.