mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-27 09:12:39 +00:00
2e715fb4fc
Add support for BCM2712 (Raspberry Pi 5).
3bb5880ab3
Patches were generated from the diff between linux kernel branch linux-6.1.y
and rpi-6.1.y from raspberry pi kernel source:
- git format-patch linux-6.1.y...rpi-6.1.y
Build system: x86_64
Build-tested: bcm2708, bcm2709, bcm2710, bcm2711
Run-tested: bcm2710/RPi3B, bcm2711/RPi4B
Signed-off-by: Marty Jones <mj8263788@gmail.com>
[Remove applied and reverted patches, squash patches and config commits]
Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
41 lines
1.3 KiB
Diff
41 lines
1.3 KiB
Diff
From e1b03ea9e84320e6bf36a1486abaebbceadd7fc7 Mon Sep 17 00:00:00 2001
|
|
From: Ben Benson <ben.benson@raspberrypi.com>
|
|
Date: Fri, 21 Jul 2023 15:59:51 +0100
|
|
Subject: [PATCH] drivers: media: imx296: Updated imx296 driver for external
|
|
trigger
|
|
|
|
Updated imx296 driver to support external trigger mode via XTR pin.
|
|
Added module parameter to control this mode.
|
|
|
|
Signed-off-by: Ben Benson <ben.benson@raspberrypi.com>
|
|
---
|
|
drivers/media/i2c/imx296.c | 10 ++++++++++
|
|
1 file changed, 10 insertions(+)
|
|
|
|
--- a/drivers/media/i2c/imx296.c
|
|
+++ b/drivers/media/i2c/imx296.c
|
|
@@ -20,6 +20,10 @@
|
|
#include <media/v4l2-fwnode.h>
|
|
#include <media/v4l2-subdev.h>
|
|
|
|
+static int trigger_mode;
|
|
+module_param(trigger_mode, int, 0644);
|
|
+MODULE_PARM_DESC(trigger_mode, "Set trigger mode: 0=default, 1=XTRIG");
|
|
+
|
|
#define IMX296_PIXEL_ARRAY_WIDTH 1456
|
|
#define IMX296_PIXEL_ARRAY_HEIGHT 1088
|
|
|
|
@@ -645,6 +649,12 @@ static int imx296_stream_on(struct imx29
|
|
|
|
imx296_write(sensor, IMX296_CTRL00, 0, &ret);
|
|
usleep_range(2000, 5000);
|
|
+
|
|
+ if (trigger_mode == 1) {
|
|
+ imx296_write(sensor, IMX296_CTRL0B, IMX296_CTRL0B_TRIGEN, &ret);
|
|
+ imx296_write(sensor, IMX296_LOWLAGTRG, IMX296_LOWLAGTRG_FAST, &ret);
|
|
+ }
|
|
+
|
|
imx296_write(sensor, IMX296_CTRL0A, 0, &ret);
|
|
|
|
/* vflip and hflip cannot change during streaming */
|