凌云实验室推出的ARM Linux物联网网关开发板IGKBoard(IoT Gateway Kit Board)项目源码
guowenxue
2022-07-18 3d79f51902c03c07290b3a96f531f6a71f363c1f
bsp/kernel/patch/linux-imx-lf-5.10.52-2.1.0.patch
@@ -1,18 +1,18 @@
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/igkboard.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/igkboard.dts
--- linux-imx/arch/arm/boot/dts/igkboard.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/igkboard.dts   2022-06-12 13:15:34.158636100 +0800
@@ -0,0 +1,693 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/igkboard.dts   2022-07-01 23:26:14.474433030 +0800
@@ -0,0 +1,587 @@
+/*
+ * Device Tree Source for LingYun IGKBoard(IoT Gateway Kit Board)
+ * Based on imx6ul-14x14-evk.dts/imx6ul-14x14-evk.dtsi
+ *
+ * Copyright (C) 2022 LingYun IoT System Studio.
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
+ * Author: Guo Wenxue<guowenxue@gmail.com>
+ */
+
+/dts-v1/;
+
+#include "imx6ul.dtsi"
+#include "imx6ull.dtsi"
+
+/ {
+   model = "LingYun IoT System Studio IoT Gateway Board";
@@ -144,21 +144,17 @@
+      status = "disabled"; /* Enable in LCD overlay */
+   };
+
+/*
+   sound-mqs {
+      compatible = "fsl,imx-audio-mqs";
+      model = "mqs-audio";
+      cpu-dai = <&sai1>;
+      asrc-controller = <&asrc>;
+      audio-codec = <&mqs>;
+      status = "okay";
+   /* 1-Wire sentinel for overlay */
+   w1: w1 {
+      compatible = "w1-gpio";
+      status = "disabled";
+   };
+*/
+};
+
+/*+-------------------+
+  |   Misc Modules     |
+  +-------------------+*/
+
+/*+--------------+
+  | Misc Modules |
+  +--------------+*/
+
+&snvs_poweroff {
+   status = "okay";
@@ -188,9 +184,10 @@
+   status = "okay";
+};
+
+/*+-------------------+
+  |   Camera Module   |
+  +-------------------+*/
+
+/*+---------------+
+  | Camera Module |
+  +---------------+*/
+
+&i2c2 {
+   clock-frequency = <100000>;
@@ -237,7 +234,7 @@
+      mclk = <24000000>;
+      mclk_source = <0>;
+      /* rotation = <180>; */
+      status = "disabled"; /* Enable in camera overlay */
+      status = "disabled"; /* Enable in CAM overlay */
+      port {
+         ov5640_ep: endpoint {
+            remote-endpoint = <&csi1_ep>;
@@ -246,8 +243,8 @@
+   };
+};
+
+&csi { /* camera ov5640 */
+   status = "okay";
+&csi {
+   status = "disabled"; /* Enable in CAM overlay */
+   port {
+      csi1_ep: endpoint {
+         remote-endpoint = <&ov5640_ep>;
@@ -256,9 +253,9 @@
+};
+
+
+/*+-------------------+
+  |    Audio Module   |
+  +-------------------+*/
+/*+--------------+
+  | Audio Module |
+  +--------------+*/
+
+&clks {
+   assigned-clocks = <&clks IMX6UL_CLK_PLL4_AUDIO_DIV>;
@@ -285,10 +282,9 @@
+};
+
+
+
+/*+-------------------+
+  | Ethernet Modules  |
+  +-------------------+*/
+/*+------------------+
+  | Ethernet Modules |
+  +------------------+*/
+
+&fec1 { /* eth0 */
+   pinctrl-names = "default";
@@ -334,10 +330,9 @@
+};
+
+
+
+/*+-------------------+
+  |  USB interface    |
+  +-------------------+*/
+/*+---------------+
+  | USB interface |
+  +---------------+*/
+
+&usbotg1 {
+   dr_mode = "otg";
@@ -361,9 +356,9 @@
+};
+
+
+/*+-------------------+
+  | USDCHC interface  |
+  +-------------------+*/
+/*+------------------+
+  | USDCHC interface |
+  +------------------+*/
+
+&usdhc1 { /* tf card slot */
+   pinctrl-names = "default", "state_100mhz", "state_200mhz";
@@ -389,112 +384,9 @@
+};
+
+
+/*+------------------------------+
+  |   40 Pin Header GPIO iomuxc  |
+  +------------------------------+*/
+
+&iomuxc {
+   pinctrl-names = "default";
+   pinctrl-0 = <&pinctrl_extgpio>;
+   pinctrl-1 = <&pinctrl_i2c1 &pinctrl_ecspi1_master>;
+   pinctrl-2 = <&pinctrl_flexcan1 &pinctrl_flexcan2>;
+   pinctrl-3 = <&pinctrl_pwm7 &pinctrl_pwm8>;
+   pinctrl-4 = <&pinctrl_uart2 &pinctrl_uart3 &pinctrl_uart4 &pinctrl_uart7>;
+   pinctrl-5 = <&pinctrl_lcdif_dat>;
+
+   pinctrl_extgpio: extgpiogrp {
+      fsl,pins = <
+         MX6UL_PAD_UART1_CTS_B__GPIO1_IO18   0x17059 /*   7#   GPIO   */
+         MX6UL_PAD_SNVS_TAMPER1__GPIO5_IO01   0x17059 /* 35#   GPIO   */
+         MX6UL_PAD_SNVS_TAMPER8__GPIO5_IO08   0x17059 /* 37#   GPIO   */
+         MX6UL_PAD_JTAG_TMS__GPIO1_IO11      0x17059 /* 36# GPIO */
+         MX6UL_PAD_JTAG_MOD__GPIO1_IO10      0x17059 /* 38# GPIO */
+         MX6UL_PAD_SNVS_TAMPER9__GPIO5_IO09   0x17059 /* 40# GPIO */
+      >;
+   };
+
+   pinctrl_i2c1: i2c1grp {
+      fsl,pins = <
+         MX6UL_PAD_GPIO1_IO03__GPIO1_IO03   0x17059 /*   3# I2C1_SDA */
+         MX6UL_PAD_GPIO1_IO02__I2C1_SCL      0x17059 /*   5# I2C1_SCL */
+      >;
+   };
+
+   pinctrl_ecspi1_master: ecspi1grp1 {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA22__GPIO3_IO27   0x17059 /* 19# SPI1_MOSI*/
+         MX6UL_PAD_LCD_DATA23__GPIO3_IO28   0x17059 /* 21# SPI1_MISO*/
+         MX6UL_PAD_LCD_DATA20__GPIO3_IO25   0x17059 /* 23# SPI1_SCLK*/
+         MX6UL_PAD_LCD_DATA21__GPIO3_IO26   0x17059 /* 24# SPI1_SS0 */
+      >;
+   };
+
+   pinctrl_flexcan1: flexcan1grp{
+      fsl,pins = <
+         MX6UL_PAD_UART3_CTS_B__GPIO1_IO26   0x17059 /* 27# CAN1_TX   */
+         MX6UL_PAD_UART3_RTS_B__GPIO1_IO27   0x17059 /* 29# CAN1_RX   */
+      >;
+   };
+
+   pinctrl_flexcan2: flexcan2grp{
+      fsl,pins = <
+         MX6UL_PAD_UART2_CTS_B__GPIO1_IO22   0x17059 /* 31# CAN2_TX   */
+         MX6UL_PAD_UART2_RTS_B__GPIO1_IO23   0x17059 /* 33# CAN2_RX   */
+      >;
+   };
+
+   pinctrl_pwm7: pwm7grp {
+      fsl,pins = <
+         MX6UL_PAD_JTAG_TCK__GPIO1_IO14      0x17059 /* 32# PWM7      */
+      >;
+   };
+
+   pinctrl_pwm8: pwm8grp {
+      fsl,pins = <
+         MX6UL_PAD_JTAG_TRST_B__GPIO1_IO15   0x17059 /* 28# PWM8      */
+      >;
+   };
+
+   pinctrl_uart2: uart2grp {
+      fsl,pins = <
+         MX6UL_PAD_UART2_TX_DATA__GPIO1_IO20 0x17059 /* 8# UART2_TX */
+         MX6UL_PAD_UART2_RX_DATA__GPIO1_IO21 0x17059 /* 10# UART2_RX */
+      >;
+   };
+
+   pinctrl_uart3: uart3grp {
+      fsl,pins = <
+         MX6UL_PAD_UART3_TX_DATA__GPIO1_IO24 0x17059 /* 11# UART3_TX */
+         MX6UL_PAD_UART3_RX_DATA__GPIO1_IO25 0x17059 /* 12# UART3_RX */
+      >;
+   };
+
+   pinctrl_uart4: uart4grp {
+      fsl,pins = <
+         MX6UL_PAD_UART4_TX_DATA__GPIO1_IO28 0x17059 /* 13# UART4_TX */
+         MX6UL_PAD_UART4_RX_DATA__GPIO1_IO29 0x17059 /* 15# UART4_RX */
+      >;
+   };
+
+   pinctrl_uart7: uart7grp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA16__GPIO3_IO21   0x17059 /* 16# UART7_TX */
+         MX6UL_PAD_LCD_DATA17__GPIO3_IO22   0x17059 /* 18# UART7_RX */
+      >;
+   };
+
+   pinctrl_lcdif_dat: lcdifdatgrp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA18__GPIO3_IO23   0x17059 /* 22# GPIO      */
+         MX6UL_PAD_LCD_DATA19__GPIO3_IO24   0x17059 /* 26# GPIO      */
+      >;
+   };
+};
+
+
+/*+--------------------------+
+  |   Basic pinctrl iomuxc   |
+  +--------------------------+*/
+/*+----------------------+
+  | Basic pinctrl iomuxc |
+  +----------------------+*/
+&iomuxc {
+   pinctrl-names = "default";
+
@@ -526,6 +418,8 @@
+
+   pinctrl_csi1: csi1grp {
+      fsl,pins = <
+         MX6UL_PAD_SNVS_TAMPER5__GPIO5_IO05      0x17059 /* CSI_RST */
+         MX6UL_PAD_SNVS_TAMPER6__GPIO5_IO06      0x17059 /* CSI_PWDN */
+         MX6UL_PAD_CSI_MCLK__CSI_MCLK         0x1b088
+         MX6UL_PAD_CSI_PIXCLK__CSI_PIXCLK      0x1b088
+         MX6UL_PAD_CSI_VSYNC__CSI_VSYNC         0x1b088
@@ -697,7 +591,7 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/Makefile linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/Makefile
--- linux-imx/arch/arm/boot/dts/Makefile   2021-09-08 18:41:11.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/Makefile   2022-06-12 13:00:23.176939473 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/Makefile   2022-06-30 22:41:52.453623639 +0800
@@ -1490,3 +1490,6 @@
    aspeed-bmc-opp-zaius.dtb \
    aspeed-bmc-portwell-neptune.dtb \
@@ -707,8 +601,8 @@
+subdir-$(CONFIG_SOC_IMX6UL) += overlays
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/cam.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/cam.dts
--- linux-imx/arch/arm/boot/dts/overlays/cam.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/cam.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,16 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/cam.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,24 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -719,6 +613,14 @@
+
+/* MIPI-DSI2 camera overlay */
+
+&pxp { /* Pixel Pipeline (PXP) is a memory-to-memory graphics processing */
+   status = "okay";
+};
+
+&csi {
+   status = "okay";
+};
+
+&i2c2 {
+   ov5640@3c {
+      status = "okay";
@@ -727,8 +629,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/can1.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can1.dts
--- linux-imx/arch/arm/boot/dts/overlays/can1.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can1.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,29 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can1.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -749,7 +651,6 @@
+};
+
+&iomuxc {
+   pinctrl-2 = <&pinctrl_flexcan1>;
+   pinctrl_flexcan1: flexcan1grp{
+      fsl,pins = <
+         MX6UL_PAD_UART3_RTS_B__FLEXCAN1_RX   0x1b020
@@ -760,8 +661,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/can2.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can2.dts
--- linux-imx/arch/arm/boot/dts/overlays/can2.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can2.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,29 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/can2.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -782,7 +683,6 @@
+};
+
+&iomuxc {
+   pinctrl-2 = <&pinctrl_flexcan2>;
+   pinctrl_flexcan2: flexcan2grp{
+      fsl,pins = <
+         MX6UL_PAD_UART2_RTS_B__FLEXCAN2_RX   0x1b020
@@ -793,8 +693,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/i2c1.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/i2c1.dts
--- linux-imx/arch/arm/boot/dts/overlays/i2c1.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/i2c1.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,29 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/i2c1.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -815,7 +715,6 @@
+};
+
+&iomuxc {
+   pinctrl-1 = <&pinctrl_i2c1>;
+   pinctrl_i2c1: i2c1grp {
+      fsl,pins = <
+         MX6UL_PAD_GPIO1_IO02__I2C1_SCL   0x4001b8b0
@@ -826,8 +725,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/lcd.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/lcd.dts
--- linux-imx/arch/arm/boot/dts/overlays/lcd.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/lcd.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,99 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/lcd.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,89 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -855,8 +754,7 @@
+   assigned-clocks = <&clks IMX6UL_CLK_LCDIF_PRE_SEL>;
+   assigned-clock-parents = <&clks IMX6UL_CLK_PLL5_VIDEO_DIV>;
+   pinctrl-names = "default";
+   pinctrl-0 = <&pinctrl_lcdif_dat
+          &pinctrl_lcdif_ctrl>;
+   pinctrl-0 = <&pinctrl_lcdif_dat &pinctrl_lcdif_ctrl>;
+   display = <&display0>;
+   status = "okay";
+
@@ -887,7 +785,6 @@
+};
+
+&iomuxc {
+   pinctrl-5 = <&pinctrl_lcdif_dat &pinctrl_lcdif_ctrl>;
+   pinctrl_lcdif_dat: lcdifdatgrp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA00__LCDIF_DATA00   0x79
@@ -906,14 +803,6 @@
+         MX6UL_PAD_LCD_DATA13__LCDIF_DATA13   0x79
+         MX6UL_PAD_LCD_DATA14__LCDIF_DATA14   0x79
+         MX6UL_PAD_LCD_DATA15__LCDIF_DATA15   0x79
+         MX6UL_PAD_LCD_DATA16__LCDIF_DATA16   0x79
+         MX6UL_PAD_LCD_DATA17__LCDIF_DATA17   0x79
+         MX6UL_PAD_LCD_DATA18__LCDIF_DATA18   0x79
+         MX6UL_PAD_LCD_DATA19__LCDIF_DATA19   0x79
+         MX6UL_PAD_LCD_DATA20__LCDIF_DATA20   0x79
+         MX6UL_PAD_LCD_DATA21__LCDIF_DATA21   0x79
+         MX6UL_PAD_LCD_DATA22__LCDIF_DATA22   0x79
+         MX6UL_PAD_LCD_DATA23__LCDIF_DATA23   0x79
+      >;
+   };
+
@@ -929,8 +818,8 @@
+};
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/Makefile linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/Makefile
--- linux-imx/arch/arm/boot/dts/overlays/Makefile   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/Makefile   2022-06-12 13:21:24.413715140 +0800
@@ -0,0 +1,18 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/Makefile   2022-07-01 23:18:56.918832072 +0800
@@ -0,0 +1,20 @@
+# SPDX-License-Identifier: GPL-2.0
+
+# required for overlay support
@@ -946,13 +835,53 @@
+dtb-y += uart7.dtbo
+dtb-y += pwm7.dtbo
+dtb-y += pwm8.dtbo
+dtb-y += w1.dtbo
+dtb-y += lcd.dtbo
+dtb-y += cam.dtbo
+dtb-y += nbiot-4g.dtbo
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/nbiot-4g.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/nbiot-4g.dts
--- linux-imx/arch/arm/boot/dts/overlays/nbiot-4g.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/nbiot-4g.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
+ */
+
+/dts-v1/;
+/plugin/;
+
+#include "../imx6ul-pinfunc.h"
+
+/* NB-IoT/4G module use UART8 interfaces, conflict with SPI interface */
+
+&uart8 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&pinctrl_spi_uart8 &pinctrl_nbiot_ctrl>;
+   status = "okay";
+};
+
+&iomuxc {
+   pinctrl_spi_uart8: spi_uart8_grp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA20__UART8_DCE_TX      0x1b0b1 /* MRXD */
+         MX6UL_PAD_LCD_DATA21__UART8_DCE_RX      0x1b0b1 /* MTXD */
+      >;
+   };
+
+   pinctrl_nbiot_ctrl: nbiot_ctrl_grp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA22__GPIO3_IO27      0x17059 /* NB_PWREN/4G_RESET */
+         MX6UL_PAD_JTAG_TRST_B__GPIO1_IO15      0x17059 /* NB_MRST/4G_POWER_KEY */
+      >;
+   };
+};
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/pwm7.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm7.dts
--- linux-imx/arch/arm/boot/dts/overlays/pwm7.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm7.dts   2022-06-12 13:31:33.213974113 +0800
@@ -0,0 +1,29 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm7.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -974,18 +903,17 @@
+};
+
+&iomuxc {
+   pinctrl-3 = <&pinctrl_pwm7>;
+   pinctrl_pwm7: pwm7grp {
+      fsl,pins = <
+         MX6UL_PAD_ENET1_TX_CLK__PWM7_OUT   0x110b0
+         MX6UL_PAD_JTAG_TCK__PWM7_OUT   0x110b0
+      >;
+   };
+};
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/pwm8.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm8.dts
--- linux-imx/arch/arm/boot/dts/overlays/pwm8.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm8.dts   2022-06-12 13:31:40.057890125 +0800
@@ -0,0 +1,29 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/pwm8.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -997,28 +925,27 @@
+#include <dt-bindings/clock/imx6ul-clock.h>
+#include "../imx6ul-pinfunc.h"
+
+/* 40-pin extended GPIO, PWM8 interfaces */
+/* 40-pin extended GPIO, PWM8 interfaces, conflict with NB-IoT */
+
+&pwm8 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&pinctrl_pwm8>;
+   pinctrl-0 = <&pinctrl_pwm8_nbiot>;
+   clocks = <&clks IMX6UL_CLK_PWM8>, <&clks IMX6UL_CLK_PWM8>;
+   status = "okay";
+};
+
+&iomuxc {
+   pinctrl-3 = <&pinctrl_pwm8>;
+   pinctrl_pwm8: pwm8grp {
+   pinctrl_pwm8_nbiot: pwm8nbiotgrp {
+      fsl,pins = <
+         MX6UL_PAD_ENET1_RX_ER__PWM8_OUT   0x110b0
+         MX6UL_PAD_JTAG_TRST_B__PWM8_OUT   0x110b0
+      >;
+   };
+};
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/spi1.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/spi1.dts
--- linux-imx/arch/arm/boot/dts/overlays/spi1.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/spi1.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,40 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/spi1.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -1030,11 +957,11 @@
+#include <dt-bindings/gpio/gpio.h>
+#include "../imx6ul-pinfunc.h"
+
+/* 40-pin extended GPIO, SPI1 interfaces, conflict with LCD display */
+/* 40-pin extended GPIO, SPI1 interfaces, conflict with UART8 */
+
+&ecspi1 {
+   pinctrl-names = "default";
+   pinctrl-0 = <&pinctrl_ecspi1_master>;
+   pinctrl-0 = <&pinctrl_spi_uart8>;
+   cs-gpios = <&gpio3 26 GPIO_ACTIVE_LOW>;
+   status = "okay";
+
@@ -1049,8 +976,7 @@
+};
+
+&iomuxc {
+   pinctrl-1 = <&pinctrl_ecspi1_master>;
+   pinctrl_ecspi1_master: ecspi1grp1 {
+   pinctrl_spi_uart8: spi_uart8_grp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA20__ECSPI1_SCLK   0x10b0
+         MX6UL_PAD_LCD_DATA22__ECSPI1_MOSI   0x10b0
@@ -1061,8 +987,8 @@
+};
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/uart2.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart2.dts
--- linux-imx/arch/arm/boot/dts/overlays/uart2.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart2.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,27 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart2.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,26 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -1082,7 +1008,6 @@
+};
+
+&iomuxc {
+   pinctrl-4 = <&pinctrl_uart2>;
+   pinctrl_uart2: uart2grp {
+      fsl,pins = <
+         MX6UL_PAD_UART2_TX_DATA__UART2_DCE_TX   0x1b0b1
@@ -1092,8 +1017,8 @@
+};
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/uart3.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart3.dts
--- linux-imx/arch/arm/boot/dts/overlays/uart3.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart3.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,28 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart3.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -1113,7 +1038,6 @@
+};
+
+&iomuxc {
+   pinctrl-4 = <&pinctrl_uart3>;
+   pinctrl_uart3: uart3grp {
+      fsl,pins = <
+         MX6UL_PAD_UART3_TX_DATA__UART3_DCE_TX   0x1b0b1
@@ -1124,8 +1048,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/uart4.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart4.dts
--- linux-imx/arch/arm/boot/dts/overlays/uart4.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart4.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,28 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart4.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -1145,7 +1069,6 @@
+};
+
+&iomuxc {
+   pinctrl-4 = <&pinctrl_uart4>;
+   pinctrl_uart4: uart4grp {
+      fsl,pins = <
+         MX6UL_PAD_UART4_TX_DATA__UART4_DCE_TX   0x1b0b1
@@ -1156,8 +1079,8 @@
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/uart7.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart7.dts
--- linux-imx/arch/arm/boot/dts/overlays/uart7.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart7.dts   2022-06-12 13:00:23.176939473 +0800
@@ -0,0 +1,28 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/uart7.dts   2022-06-30 22:41:52.453623639 +0800
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
@@ -1177,7 +1100,6 @@
+};
+
+&iomuxc {
+   pinctrl-4 = <&pinctrl_uart7>;
+   pinctrl_uart7: uart7grp {
+      fsl,pins = <
+         MX6UL_PAD_LCD_DATA16__UART7_DCE_TX      0x1b0b1
@@ -1186,10 +1108,45 @@
+   };
+};
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/boot/dts/overlays/w1.dts linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/w1.dts
--- linux-imx/arch/arm/boot/dts/overlays/w1.dts   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/boot/dts/overlays/w1.dts   2022-07-01 23:24:26.823525995 +0800
@@ -0,0 +1,31 @@
+/*
+ * Copyright (C) 2022 LingYun IoT System Studio
+ * Author:  Guo Wenxue<guowenxue@gmail.com>
+ */
+
+/dts-v1/;
+/plugin/;
+
+#include <dt-bindings/gpio/gpio.h>
+#include "../imx6ul-pinfunc.h"
+
+/* W1(DS18B20) on 40Pin Header Pin#7 (GPIO1_IO18) */
+
+&w1 {
+    compatible = "w1-gpio";
+    status = "okay";
+
+    pinctrl-names = "default";
+    pinctrl-0 = <&pinctrl_w1>;
+    gpio = <&gpio1 18 GPIO_ACTIVE_HIGH>;
+};
+
+
+&iomuxc {
+   pinctrl_w1: w1grp {
+      fsl,pins = <
+         MX6UL_PAD_UART1_CTS_B__GPIO1_IO18   0x110b0
+      >;
+   };
+};
+
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/arch/arm/configs/igkboard_defconfig linux-imx-lf-5.10.52-2.1.0/arch/arm/configs/igkboard_defconfig
--- linux-imx/arch/arm/configs/igkboard_defconfig   1970-01-01 08:00:00.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/configs/igkboard_defconfig   2022-06-12 13:26:11.937977945 +0800
@@ -0,0 +1,722 @@
+++ linux-imx-lf-5.10.52-2.1.0/arch/arm/configs/igkboard_defconfig   2022-07-02 00:03:42.508486161 +0800
@@ -0,0 +1,725 @@
+CONFIG_KERNEL_LZO=y
+CONFIG_SYSVIPC=y
+CONFIG_POSIX_MQUEUE=y
@@ -1438,6 +1395,9 @@
+CONFIG_GPIO_PCF857X=y
+CONFIG_GPIO_STMPE=y
+CONFIG_GPIO_74X164=y
+CONFIG_W1=y
+CONFIG_W1_MASTER_GPIO=y
+CONFIG_W1_SLAVE_THERM=y
+CONFIG_POWER_RESET=y
+CONFIG_POWER_RESET_SYSCON=y
+CONFIG_POWER_RESET_SYSCON_POWEROFF=y
@@ -1914,7 +1874,7 @@
+# CONFIG_FTRACE is not set
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/drivers/video/backlight/pwm_bl.c linux-imx-lf-5.10.52-2.1.0/drivers/video/backlight/pwm_bl.c
--- linux-imx/drivers/video/backlight/pwm_bl.c   2021-09-08 18:41:11.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/drivers/video/backlight/pwm_bl.c   2022-06-12 13:00:23.176939473 +0800
+++ linux-imx-lf-5.10.52-2.1.0/drivers/video/backlight/pwm_bl.c   2022-06-30 22:41:52.453623639 +0800
@@ -558,6 +558,7 @@
    if (!state.period && (data->pwm_period_ns > 0))
       state.period = data->pwm_period_ns;
@@ -1925,7 +1885,7 @@
       dev_err(&pdev->dev, "failed to apply initial PWM state: %d\n",
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/Makefile linux-imx-lf-5.10.52-2.1.0/Makefile
--- linux-imx/Makefile   2021-09-08 18:41:11.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/Makefile   2022-06-12 13:00:23.180939431 +0800
+++ linux-imx-lf-5.10.52-2.1.0/Makefile   2022-06-30 23:05:52.907066766 +0800
@@ -367,7 +367,8 @@
 # Alternatively CROSS_COMPILE can be set in the environment.
 # Default value for CROSS_COMPILE is not to prefix executables
@@ -1946,7 +1906,7 @@
       -o -name '.*.d' -o -name '.*.tmp' -o -name '*.mod.c' \
diff -Nuar --no-dereference -x logo_linux_clut224.ppm linux-imx/scripts/Makefile.lib linux-imx-lf-5.10.52-2.1.0/scripts/Makefile.lib
--- linux-imx/scripts/Makefile.lib   2021-09-08 18:41:11.000000000 +0800
+++ linux-imx-lf-5.10.52-2.1.0/scripts/Makefile.lib   2022-06-12 13:00:23.176939473 +0800
+++ linux-imx-lf-5.10.52-2.1.0/scripts/Makefile.lib   2022-06-30 22:41:52.457623624 +0800
@@ -325,6 +325,16 @@
 $(obj)/%.dtb: $(src)/%.dts $(DTC) FORCE
    $(call if_changed_dep,dtc)