-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
kernel patches for mainline 6.9 (#251)
* mtl-p mr1 release Signed-off-by: zouxiaoh <[email protected]> * MTL ECR engineer release: 6x IMX390 on kernel v6.6 Ubuntu 22.04 Signed-off-by: zouxiaoh <[email protected]> * ARL Beta release kernel v6.9 Signed-off-by: zouxiaoh <[email protected]> * Kernel patches on mainline 6.9 Signed-off-by: zouxiaoh <[email protected]> --------- Signed-off-by: zouxiaoh <[email protected]>
- Loading branch information
Showing
4 changed files
with
274 additions
and
0 deletions.
There are no files selected for viewing
49 changes: 49 additions & 0 deletions
49
kernel_patches/patch_6.9_mainline/0001-media-v4l2-Support-line-based-metadata-capture.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
From f71b076e1784fb7c89e0782a61704d8888582118 Mon Sep 17 00:00:00 2001 | ||
From: linya14x <[email protected]> | ||
Date: Wed, 10 Apr 2024 13:39:23 +0800 | ||
Subject: [PATCH 1/5] media: v4l2: Support line-based metadata capture | ||
|
||
Test Platform: | ||
ARL | ||
|
||
Signed-off-by: zouxiaoh <[email protected]> | ||
Signed-off-by: linya14x <[email protected]> | ||
--- | ||
include/uapi/linux/videodev2.h | 10 ++++++++++ | ||
1 file changed, 10 insertions(+) | ||
|
||
diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h | ||
index a8015e5e7fa4..80561e76a2f9 100644 | ||
--- a/include/uapi/linux/videodev2.h | ||
+++ b/include/uapi/linux/videodev2.h | ||
@@ -869,6 +869,7 @@ struct v4l2_fmtdesc { | ||
#define V4L2_FMT_FLAG_CSC_YCBCR_ENC 0x0080 | ||
#define V4L2_FMT_FLAG_CSC_HSV_ENC V4L2_FMT_FLAG_CSC_YCBCR_ENC | ||
#define V4L2_FMT_FLAG_CSC_QUANTIZATION 0x0100 | ||
+#define V4L2_FMT_FLAG_META_LINE_BASED 0x0200 | ||
|
||
/* Frame Size and frame rate enumeration */ | ||
/* | ||
@@ -2415,10 +2416,19 @@ struct v4l2_sdr_format { | ||
* struct v4l2_meta_format - metadata format definition | ||
* @dataformat: little endian four character code (fourcc) | ||
* @buffersize: maximum size in bytes required for data | ||
+ * @width: number of bytes of data per line (valid for line based | ||
+ * formats only, see format documentation) | ||
+ * @height: number of lines of data per buffer (valid for line based | ||
+ * formats only) | ||
+ * @bytesperline: offset between the beginnings of two adjacent lines in | ||
+ * bytes (valid for line based formats only) | ||
*/ | ||
struct v4l2_meta_format { | ||
__u32 dataformat; | ||
__u32 buffersize; | ||
+ __u32 width; | ||
+ __u32 height; | ||
+ __u32 bytesperline; | ||
} __attribute__ ((packed)); | ||
|
||
/** | ||
-- | ||
2.34.1 | ||
|
77 changes: 77 additions & 0 deletions
77
kernel_patches/patch_6.9_mainline/0002-INT3472-Support-LT6911UXC-LT6911UXE.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
From a98a33d6130dcff4509ff6e66aba432015eb4cdd Mon Sep 17 00:00:00 2001 | ||
From: linya14x <[email protected]> | ||
Date: Wed, 10 Apr 2024 13:35:14 +0800 | ||
Subject: [PATCH 2/5] INT3472: Support LT6911UXC<6911UXE | ||
|
||
Signed-off-by: linya14x <[email protected]> | ||
Signed-off-by: zouxiaoh <[email protected]> | ||
--- | ||
drivers/platform/x86/intel/int3472/common.h | 4 +++- | ||
drivers/platform/x86/intel/int3472/discrete.c | 18 ++++++++++++++++-- | ||
2 files changed, 19 insertions(+), 3 deletions(-) | ||
|
||
diff --git a/drivers/platform/x86/intel/int3472/common.h b/drivers/platform/x86/intel/int3472/common.h | ||
index 145dec66df64..0cd1af63ca2f 100644 | ||
--- a/drivers/platform/x86/intel/int3472/common.h | ||
+++ b/drivers/platform/x86/intel/int3472/common.h | ||
@@ -22,9 +22,11 @@ | ||
#define INT3472_GPIO_TYPE_POWER_ENABLE 0x0b | ||
#define INT3472_GPIO_TYPE_CLK_ENABLE 0x0c | ||
#define INT3472_GPIO_TYPE_PRIVACY_LED 0x0d | ||
+#define INT3472_GPIO_TYPE_READY_STAT 0x13 | ||
+#define INT3472_GPIO_TYPE_HDMI_DETECT 0x14 | ||
|
||
#define INT3472_PDEV_MAX_NAME_LEN 23 | ||
-#define INT3472_MAX_SENSOR_GPIOS 3 | ||
+#define INT3472_MAX_SENSOR_GPIOS 4 | ||
|
||
#define GPIO_REGULATOR_NAME_LENGTH 21 | ||
#define GPIO_REGULATOR_SUPPLY_NAME_LENGTH 9 | ||
diff --git a/drivers/platform/x86/intel/int3472/discrete.c b/drivers/platform/x86/intel/int3472/discrete.c | ||
index 07b302e09340..591de0d776f0 100644 | ||
--- a/drivers/platform/x86/intel/int3472/discrete.c | ||
+++ b/drivers/platform/x86/intel/int3472/discrete.c | ||
@@ -148,6 +148,14 @@ static void int3472_get_func_and_polarity(u8 type, const char **func, u32 *polar | ||
*func = "power-enable"; | ||
*polarity = GPIO_ACTIVE_HIGH; | ||
break; | ||
+ case INT3472_GPIO_TYPE_READY_STAT: | ||
+ *func = "readystat"; | ||
+ *polarity = GPIO_LOOKUP_FLAGS_DEFAULT; | ||
+ break; | ||
+ case INT3472_GPIO_TYPE_HDMI_DETECT: | ||
+ *func = "hdmidetect"; | ||
+ *polarity = GPIO_LOOKUP_FLAGS_DEFAULT; | ||
+ break; | ||
default: | ||
*func = "unknown"; | ||
*polarity = GPIO_ACTIVE_HIGH; | ||
@@ -239,9 +247,15 @@ static int skl_int3472_handle_gpio_resources(struct acpi_resource *ares, | ||
switch (type) { | ||
case INT3472_GPIO_TYPE_RESET: | ||
case INT3472_GPIO_TYPE_POWERDOWN: | ||
+ case INT3472_GPIO_TYPE_READY_STAT: | ||
+ case INT3472_GPIO_TYPE_HDMI_DETECT: | ||
ret = skl_int3472_map_gpio_to_sensor(int3472, agpio, func, polarity); | ||
- if (ret) | ||
+ if (ret) { | ||
err_msg = "Failed to map GPIO pin to sensor\n"; | ||
+ dev_warn(int3472->dev, | ||
+ "Failed to map GPIO pin to sensor, type %02x, func %s, polarity %u\n", | ||
+ type, func, polarity); | ||
+ } | ||
|
||
break; | ||
case INT3472_GPIO_TYPE_CLK_ENABLE: | ||
@@ -345,7 +359,7 @@ static int skl_int3472_discrete_probe(struct platform_device *pdev) | ||
return ret; | ||
} | ||
|
||
- if (cldb.control_logic_type != 1) { | ||
+ if (cldb.control_logic_type != 1 && cldb.control_logic_type != 5) { | ||
dev_err(&pdev->dev, "Unsupported control logic type %u\n", | ||
cldb.control_logic_type); | ||
return -EINVAL; | ||
-- | ||
2.34.1 | ||
|
76 changes: 76 additions & 0 deletions
76
...atches/patch_6.9_mainline/0003-media-i2c-add-ar0234-and-6911uxc-uxe-to-Kconfig-and-.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
From f0f521ed939501da5c278e6c80d3478ccedb4802 Mon Sep 17 00:00:00 2001 | ||
From: linya14x <[email protected]> | ||
Date: Wed, 10 Apr 2024 12:42:46 +0800 | ||
Subject: [PATCH 3/5] media: i2c: add ar0234 and 6911uxc/uxe to Kconfig and | ||
Makefile | ||
|
||
Signed-off-by: linya14x <[email protected]> | ||
Signed-off-by: zouxiaoh <[email protected]> | ||
--- | ||
drivers/media/i2c/Kconfig | 31 +++++++++++++++++++++++++++++++ | ||
drivers/media/i2c/Makefile | 3 +++ | ||
2 files changed, 34 insertions(+) | ||
|
||
diff --git a/drivers/media/i2c/Kconfig b/drivers/media/i2c/Kconfig | ||
index 56f276b920ab..120d55184d17 100644 | ||
--- a/drivers/media/i2c/Kconfig | ||
+++ b/drivers/media/i2c/Kconfig | ||
@@ -566,6 +566,15 @@ config VIDEO_OV8858 | ||
To compile this driver as a module, choose M here: the | ||
module will be called ov8858. | ||
|
||
+config VIDEO_AR0234 | ||
+ tristate "OnSemi AR0234 sensor support" | ||
+ depends on VIDEO_DEV && I2C | ||
+ select VIDEO_V4L2_SUBDEV_API | ||
+ depends on MEDIA_CAMERA_SUPPORT | ||
+ help | ||
+ This is a Video4Linux2 sensor-level driver for the OnSemi | ||
+ ar0234 camera. | ||
+ | ||
config VIDEO_OV8865 | ||
tristate "OmniVision OV8865 sensor support" | ||
depends on PM | ||
@@ -1526,6 +1535,28 @@ config VIDEO_THS7303 | ||
To compile this driver as a module, choose M here: the | ||
module will be called ths7303. | ||
|
||
+config VIDEO_LT6911UXC | ||
+ tristate "Lontium LT6911UXC decoder" | ||
+ depends on VIDEO_DEV && I2C | ||
+ select VIDEO_V4L2_SUBDEV_API | ||
+ help | ||
+ This is a Video4Linux2 sensor-level driver for the Lontium | ||
+ LT6911UXC HDMI to MIPI CSI-2 bridge. | ||
+ | ||
+ To compile this driver as a module, choose M here: the | ||
+ module will be called lt6911uxc. | ||
+ | ||
+config VIDEO_LT6911UXE | ||
+ tristate "Lontium LT6911UXE decoder" | ||
+ depends on VIDEO_DEV && I2C | ||
+ select VIDEO_V4L2_SUBDEV_API | ||
+ help | ||
+ This is a Video4Linux2 sensor-level driver for the Lontium | ||
+ LT6911UXE HDMI to MIPI CSI-2 bridge. | ||
+ | ||
+ To compile this driver as a module, choose M here: the | ||
+ module will be called lt6911uxe. | ||
+ | ||
endmenu | ||
|
||
# | ||
diff --git a/drivers/media/i2c/Makefile b/drivers/media/i2c/Makefile | ||
index dfbe6448b549..9e835874e0b9 100644 | ||
--- a/drivers/media/i2c/Makefile | ||
+++ b/drivers/media/i2c/Makefile | ||
@@ -152,3 +152,6 @@ obj-$(CONFIG_VIDEO_VP27SMPX) += vp27smpx.o | ||
obj-$(CONFIG_VIDEO_VPX3220) += vpx3220.o | ||
obj-$(CONFIG_VIDEO_WM8739) += wm8739.o | ||
obj-$(CONFIG_VIDEO_WM8775) += wm8775.o | ||
+obj-$(CONFIG_VIDEO_LT6911UXC) += lt6911uxc.o | ||
+obj-$(CONFIG_VIDEO_LT6911UXE) += lt6911uxe.o | ||
+obj-$(CONFIG_VIDEO_AR0234) += ar0234.o | ||
-- | ||
2.34.1 | ||
|
72 changes: 72 additions & 0 deletions
72
...atches/patch_6.9_mainline/0004-media-i2c-add-IMX390-D4XX-support-to-Makefile-and-Kc.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,72 @@ | ||
From 8a530654ff4433c116bb0c2052a2593d185cd96a Mon Sep 17 00:00:00 2001 | ||
From: linya14x <[email protected]> | ||
Date: Fri, 14 Jun 2024 16:28:18 +0800 | ||
Subject: [PATCH 4/5] media: i2c: add IMX390&D4XX support to Makefile and | ||
Kconfig | ||
|
||
Signed-off-by: linya14x <[email protected]> | ||
Signed-off-by: zouxiaoh <[email protected]> | ||
--- | ||
drivers/media/i2c/Kconfig | 19 +++++++++++++++++++ | ||
drivers/media/i2c/Makefile | 4 ++++ | ||
2 files changed, 23 insertions(+) | ||
|
||
diff --git a/drivers/media/i2c/Kconfig b/drivers/media/i2c/Kconfig | ||
index 120d55184d17..56446ce32dac 100644 | ||
--- a/drivers/media/i2c/Kconfig | ||
+++ b/drivers/media/i2c/Kconfig | ||
@@ -211,6 +211,12 @@ config VIDEO_IMX355 | ||
To compile this driver as a module, choose M here: the | ||
module will be called imx355. | ||
|
||
+config VIDEO_IMX390 | ||
+ depends on I2C && VIDEO_DEV | ||
+ tristate "IMX390 Camera Driver" | ||
+ help | ||
+ This is a Video4Linux2 sensor-level driver for Sony IMX390 camera. | ||
+ | ||
config VIDEO_IMX412 | ||
tristate "Sony IMX412 sensor support" | ||
depends on OF_GPIO | ||
@@ -1308,6 +1314,12 @@ config VIDEO_VPX3220 | ||
To compile this driver as a module, choose M here: the | ||
module will be called vpx3220. | ||
|
||
+config VIDEO_TI960 | ||
+ tristate "TI960 driver support" | ||
+ depends on I2C && VIDEO_DEV | ||
+ help | ||
+ This is a driver for TI960 Deserializer. | ||
+ | ||
comment "Video and audio decoders" | ||
|
||
config VIDEO_SAA717X | ||
@@ -1557,6 +1569,13 @@ config VIDEO_LT6911UXE | ||
To compile this driver as a module, choose M here: the | ||
module will be called lt6911uxe. | ||
|
||
+config VIDEO_D4XX | ||
+ tristate "D4XX Camera Driver" | ||
+ depends on VIDEO_DEV && I2C | ||
+ select VIDEO_V4L2_SUBDEV_API | ||
+ help | ||
+ This is a Video4Linux2 sensor-level driver for intel realsence camera. | ||
+ | ||
endmenu | ||
|
||
# | ||
diff --git a/drivers/media/i2c/Makefile b/drivers/media/i2c/Makefile | ||
index 9e835874e0b9..237c644bfaa5 100644 | ||
--- a/drivers/media/i2c/Makefile | ||
+++ b/drivers/media/i2c/Makefile | ||
@@ -155,3 +155,7 @@ obj-$(CONFIG_VIDEO_WM8775) += wm8775.o | ||
obj-$(CONFIG_VIDEO_LT6911UXC) += lt6911uxc.o | ||
obj-$(CONFIG_VIDEO_LT6911UXE) += lt6911uxe.o | ||
obj-$(CONFIG_VIDEO_AR0234) += ar0234.o | ||
+ti960-objs := ti953-ser.o ti960-des.o | ||
+obj-$(CONFIG_VIDEO_TI960) += ti960.o | ||
+obj-$(CONFIG_VIDEO_IMX390) += imx390.o | ||
+obj-$(CONFIG_VIDEO_D4XX) += d4xx.o | ||
-- | ||
2.34.1 | ||
|