summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJustin M. Forbes <jforbes@fedoraproject.org>2020-07-13 10:05:15 -0500
committerJustin M. Forbes <jforbes@fedoraproject.org>2020-07-13 10:05:15 -0500
commitaa5ab7f890a036ab6802c7a0c8cf8459a324e3c2 (patch)
treef637c079f5bb221193d2a33f5520f477a02bae0e
parentd8d578bfa82493a49b71c8665b2f48c3e6df3617 (diff)
downloadkernel-aa5ab7f890a036ab6802c7a0c8cf8459a324e3c2.tar.gz
kernel-aa5ab7f890a036ab6802c7a0c8cf8459a324e3c2.tar.xz
kernel-aa5ab7f890a036ab6802c7a0c8cf8459a324e3c2.zip
kernel-5.8.0-0.rc5.1
* Mon Jul 13 2020 Fedora Kernel Team <kernel-team@fedoraproject.org> [5.8.0-0.rc5.1] - v5.8-rc5 rebase - arm64: dts: sun50i-a64-pinephone: Add touchscreen support (Ondrej Jirman) - arm64: dts: sun50i-a64-pinephone: Enable LCD support on PinePhone (Icenowy Zheng) - drm/panel: st7703: Assert reset prior to powering down the regulators (Ondrej Jirman) - drm/panel: st7703: Enter sleep after display off (Ondrej Jirman) - drm/panel: st7703: Add support for Xingbangda XBD599 (Ondrej Jirman) - drm/panel: st7703: Move generic part of init sequence to enable callback (Ondrej Jirman) - drm/panel: st7703: Move code specific to jh057n closer together (Ondrej Jirman) - drm/panel: st7703: Prepare for supporting multiple panels (Ondrej Jirman) - drm/panel: st7703: Rename functions from jh057n prefix to st7703 (Ondrej Jirman) - drm/panel: rocktech-jh057n00900: Rename the driver to st7703 (Ondrej Jirman) - dt-bindings: panel: Add compatible for Xingbangda XBD599 panel (Ondrej Jirman) - dt-bindings: panel: Convert rocktech, jh057n00900 to yaml (Ondrej Jirman) - dt-bindings: vendor-prefixes: Add Xingbangda (Icenowy Zheng) - Revert "arm64: allwinner: dts: a64: add LCD-related device nodes for PinePhone" (Peter Robinson) - Revert "drm/sun4i: sun6i_mipi_dsi: fix horizontal timing calculation" (Peter Robinson) - Revert "drm: panel: add Xingbangda XBD599 panel" (Peter Robinson) - Revert "dt-bindings: panel: add binding for Xingbangda XBD599 panel" (Peter Robinson) - selinux: allow reading labels before policy is loaded (Jonathan Lebon) - Fixes "acpi: prefer booting with ACPI over DTS" to be RHEL only (Peter Robinson) - Update config for renamed panel driver. (Peter Robinson) - Enable SERIAL_SC16IS7XX for SPI interfaces (Peter Robinson) - Updated changelog for the release based on dcde237b9b0e (Fedora Kernel Team) Resolves: rhbz# Signed-off-by: Justin M. Forbes <jforbes@fedoraproject.org>
-rw-r--r--0001-Drop-that-for-now.patch2
-rw-r--r--0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch36
-rw-r--r--0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch76
-rw-r--r--0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch418
-rw-r--r--0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch56
-rw-r--r--0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch71
-rw-r--r--0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch46
-rw-r--r--0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch112
-rw-r--r--0001-bpf-Add-tech-preview-taint-for-syscall.patch4
-rw-r--r--0001-bpf-set-unprivileged_bpf_disabled-to-1-by-default-ad.patch2
-rw-r--r--0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch948
-rw-r--r--0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch251
-rw-r--r--0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch29
-rw-r--r--0001-drm-panel-st7703-Enter-sleep-after-display-off.patch41
-rw-r--r--0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch84
-rw-r--r--0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch84
-rw-r--r--0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch128
-rw-r--r--0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch265
-rw-r--r--0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch37
-rw-r--r--0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch119
-rw-r--r--0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch33
-rw-r--r--0001-put-RHEL-info-into-generated-headers.patch2
-rw-r--r--0001-selinux-allow-reading-labels-before-policy-is-loaded.patch49
-rw-r--r--Patchlist19
-rw-r--r--kernel-aarch64-debug-fedora.config6
-rw-r--r--kernel-aarch64-fedora.config6
-rw-r--r--kernel-armv7hl-debug-fedora.config6
-rw-r--r--kernel-armv7hl-fedora.config6
-rw-r--r--kernel-armv7hl-lpae-debug-fedora.config6
-rw-r--r--kernel-armv7hl-lpae-fedora.config6
-rw-r--r--kernel-i686-debug-fedora.config6
-rw-r--r--kernel-i686-fedora.config6
-rw-r--r--kernel-ppc64le-debug-fedora.config6
-rw-r--r--kernel-ppc64le-fedora.config6
-rw-r--r--kernel-s390x-debug-fedora.config6
-rw-r--r--kernel-s390x-fedora.config6
-rw-r--r--kernel-x86_64-debug-fedora.config6
-rw-r--r--kernel-x86_64-fedora.config6
-rw-r--r--kernel.spec77
-rw-r--r--sources6
40 files changed, 3034 insertions, 45 deletions
diff --git a/0001-Drop-that-for-now.patch b/0001-Drop-that-for-now.patch
index 178e27e1a..233c6ddad 100644
--- a/0001-Drop-that-for-now.patch
+++ b/0001-Drop-that-for-now.patch
@@ -8,7 +8,7 @@ Subject: [PATCH] Drop that for now
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
-index 45081a0c4dcc..d22698a301b9 100644
+index 09639e0e075f..8c072a1954cb 100644
--- a/Makefile
+++ b/Makefile
@@ -496,7 +496,7 @@ KBUILD_AFLAGS := -D__ASSEMBLY__ -fno-PIE
diff --git a/0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch b/0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch
new file mode 100644
index 000000000..67a889b30
--- /dev/null
+++ b/0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch
@@ -0,0 +1,36 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Fri, 10 Jul 2020 16:18:59 +0100
+Subject: [PATCH] Fixes "acpi: prefer booting with ACPI over DTS" to be RHEL
+ only
+
+The ACPI prefernce is RHEL specific, in Fedora we use upstream defaults so
+it doesn't randomly change the expectations as to how certain hardware works
+that generally isn't classed as "enterprise". So wrap it in the special RHEL
+check as it should be for the ARK kernels.
+
+Signed-off-by: Peter Robinson <pbrobinson@gmail.com>
+CC: Mark Salter <msalter@redhat.com>
+---
+ arch/arm64/kernel/acpi.c | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/arch/arm64/kernel/acpi.c b/arch/arm64/kernel/acpi.c
+index c2a7e30e2143..169b753903d1 100644
+--- a/arch/arm64/kernel/acpi.c
++++ b/arch/arm64/kernel/acpi.c
+@@ -40,7 +40,11 @@ int acpi_pci_disabled = 1; /* skip ACPI PCI scan and IRQ initialization */
+ EXPORT_SYMBOL(acpi_pci_disabled);
+
+ static bool param_acpi_off __initdata;
++#ifdef CONFIG_RHEL_DIFFERENCES
+ static bool param_acpi_on __initdata = true;
++#else
++static bool param_acpi_on __initdata;
++#endif
+ static bool param_acpi_force __initdata;
+
+ static int __init parse_acpi(char *arg)
+--
+2.26.2
+
diff --git a/0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch b/0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch
new file mode 100644
index 000000000..0ea8f7da8
--- /dev/null
+++ b/0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch
@@ -0,0 +1,76 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Sun, 12 Jul 2020 13:42:14 +0100
+Subject: [PATCH] Revert "arm64: allwinner: dts: a64: add LCD-related device
+ nodes for PinePhone"
+
+This reverts commit 6b9deda8c30064a254bc66e3f6763281c96db7db.
+---
+ .../dts/allwinner/sun50i-a64-pinephone.dtsi | 37 -------------------
+ 1 file changed, 37 deletions(-)
+
+diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+index 96d9150423e0..cefda145c3c9 100644
+--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
++++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+@@ -16,15 +16,6 @@ aliases {
+ serial0 = &uart0;
+ };
+
+- backlight: backlight {
+- compatible = "pwm-backlight";
+- pwms = <&r_pwm 0 50000 PWM_POLARITY_INVERTED>;
+- brightness-levels = <0 16 18 20 22 24 26 29 32 35 38 42 46 51 56 62 68 75 83 91 100>;
+- default-brightness-level = <15>;
+- enable-gpios = <&pio 7 10 GPIO_ACTIVE_HIGH>; /* PH10 */
+- power-supply = <&reg_ldo_io0>;
+- };
+-
+ chosen {
+ stdout-path = "serial0:115200n8";
+ };
+@@ -93,30 +84,6 @@ &dai {
+ status = "okay";
+ };
+
+-&de {
+- status = "okay";
+-};
+-
+-&dphy {
+- status = "okay";
+-};
+-
+-&dsi {
+- vcc-dsi-supply = <&reg_dldo1>;
+- #address-cells = <1>;
+- #size-cells = <0>;
+- status = "okay";
+-
+- panel@0 {
+- compatible = "xingbangda,xbd599";
+- reg = <0>;
+- reset-gpios = <&pio 3 23 GPIO_ACTIVE_LOW>; /* PD23 */
+- iovcc-supply = <&reg_dldo2>;
+- vcc-supply = <&reg_ldo_io0>;
+- backlight = <&backlight>;
+- };
+-};
+-
+ &ehci0 {
+ status = "okay";
+ };
+@@ -221,10 +188,6 @@ &r_pio {
+ */
+ };
+
+-&r_pwm {
+- status = "okay";
+-};
+-
+ &r_rsb {
+ status = "okay";
+
+--
+2.26.2
+
diff --git a/0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch b/0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch
new file mode 100644
index 000000000..2950f8a79
--- /dev/null
+++ b/0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch
@@ -0,0 +1,418 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Sun, 12 Jul 2020 13:41:56 +0100
+Subject: [PATCH] Revert "drm: panel: add Xingbangda XBD599 panel"
+
+This reverts commit 5d53795bb19e39f048ac8028ec36ff04765e1237.
+---
+ drivers/gpu/drm/panel/Kconfig | 9 -
+ drivers/gpu/drm/panel/Makefile | 1 -
+ .../gpu/drm/panel/panel-xingbangda-xbd599.c | 366 ------------------
+ 3 files changed, 376 deletions(-)
+ delete mode 100644 drivers/gpu/drm/panel/panel-xingbangda-xbd599.c
+
+diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig
+index 1f55a87bb657..39055c1f0e2f 100644
+--- a/drivers/gpu/drm/panel/Kconfig
++++ b/drivers/gpu/drm/panel/Kconfig
+@@ -462,15 +462,6 @@ config DRM_PANEL_VISIONOX_RM69299
+ Say Y here if you want to enable support for Visionox
+ RM69299 DSI Video Mode panel.
+
+-config DRM_PANEL_XINGBANGDA_XBD599
+- tristate "Xingbangda XBD599 panel"
+- depends on OF
+- depends on DRM_MIPI_DSI
+- depends on BACKLIGHT_CLASS_DEVICE
+- help
+- Say Y here if you want to enable support for the Xingbangda XBD599
+- MIPI DSI Video Mode panel.
+-
+ config DRM_PANEL_XINPENG_XPP055C272
+ tristate "Xinpeng XPP055C272 panel driver"
+ depends on OF
+diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile
+index 7b6b0c0397d6..de74f282c433 100644
+--- a/drivers/gpu/drm/panel/Makefile
++++ b/drivers/gpu/drm/panel/Makefile
+@@ -49,5 +49,4 @@ obj-$(CONFIG_DRM_PANEL_TPO_TD043MTEA1) += panel-tpo-td043mtea1.o
+ obj-$(CONFIG_DRM_PANEL_TPO_TPG110) += panel-tpo-tpg110.o
+ obj-$(CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA) += panel-truly-nt35597.o
+ obj-$(CONFIG_DRM_PANEL_VISIONOX_RM69299) += panel-visionox-rm69299.o
+-obj-$(CONFIG_DRM_PANEL_XINGBANGDA_XBD599) += panel-xingbangda-xbd599.o
+ obj-$(CONFIG_DRM_PANEL_XINPENG_XPP055C272) += panel-xinpeng-xpp055c272.o
+diff --git a/drivers/gpu/drm/panel/panel-xingbangda-xbd599.c b/drivers/gpu/drm/panel/panel-xingbangda-xbd599.c
+deleted file mode 100644
+index b483f96ee1db..000000000000
+--- a/drivers/gpu/drm/panel/panel-xingbangda-xbd599.c
++++ /dev/null
+@@ -1,366 +0,0 @@
+-// SPDX-License-Identifier: GPL-2.0
+-/*
+- * Xingbangda XBD599 MIPI-DSI panel driver
+- *
+- * Copyright (C) 2019-2020 Icenowy Zheng <icenowy@aosc.io>
+- *
+- * Based on panel-rocktech-jh057n00900.c, which is:
+- * Copyright (C) Purism SPC 2019
+- */
+-
+-#include <linux/delay.h>
+-#include <linux/gpio/consumer.h>
+-#include <linux/mod_devicetable.h>
+-#include <linux/module.h>
+-#include <linux/of_device.h>
+-#include <linux/regulator/consumer.h>
+-
+-#include <drm/drm_mipi_dsi.h>
+-#include <drm/drm_modes.h>
+-#include <drm/drm_panel.h>
+-#include <drm/drm_print.h>
+-
+-/* Manufacturer specific Commands send via DSI */
+-#define ST7703_CMD_ALL_PIXEL_OFF 0x22
+-#define ST7703_CMD_ALL_PIXEL_ON 0x23
+-#define ST7703_CMD_SETDISP 0xB2
+-#define ST7703_CMD_SETRGBIF 0xB3
+-#define ST7703_CMD_SETCYC 0xB4
+-#define ST7703_CMD_SETBGP 0xB5
+-#define ST7703_CMD_SETVCOM 0xB6
+-#define ST7703_CMD_SETOTP 0xB7
+-#define ST7703_CMD_SETPOWER_EXT 0xB8
+-#define ST7703_CMD_SETEXTC 0xB9
+-#define ST7703_CMD_SETMIPI 0xBA
+-#define ST7703_CMD_SETVDC 0xBC
+-#define ST7703_CMD_SETSCR 0xC0
+-#define ST7703_CMD_SETPOWER 0xC1
+-#define ST7703_CMD_UNK_C6 0xC6
+-#define ST7703_CMD_SETPANEL 0xCC
+-#define ST7703_CMD_SETGAMMA 0xE0
+-#define ST7703_CMD_SETEQ 0xE3
+-#define ST7703_CMD_SETGIP1 0xE9
+-#define ST7703_CMD_SETGIP2 0xEA
+-
+-static const char * const regulator_names[] = {
+- "iovcc",
+- "vcc",
+-};
+-
+-struct xbd599 {
+- struct device *dev;
+- struct drm_panel panel;
+- struct gpio_desc *reset_gpio;
+- struct regulator_bulk_data supplies[ARRAY_SIZE(regulator_names)];
+- bool prepared;
+-};
+-
+-static inline struct xbd599 *panel_to_xbd599(struct drm_panel *panel)
+-{
+- return container_of(panel, struct xbd599, panel);
+-}
+-
+-#define dsi_dcs_write_seq(dsi, cmd, seq...) do { \
+- static const u8 d[] = { seq }; \
+- int ret; \
+- ret = mipi_dsi_dcs_write(dsi, cmd, d, ARRAY_SIZE(d)); \
+- if (ret < 0) \
+- return ret; \
+- } while (0)
+-
+-static int xbd599_init_sequence(struct xbd599 *ctx)
+-{
+- struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+- struct device *dev = ctx->dev;
+- int ret;
+-
+- /*
+- * Init sequence was supplied by the panel vendor.
+- */
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETEXTC,
+- 0xF1, 0x12, 0x83);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETMIPI,
+- 0x33, 0x81, 0x05, 0xF9, 0x0E, 0x0E, 0x20, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x25,
+- 0x00, 0x91, 0x0a, 0x00, 0x00, 0x02, 0x4F, 0x11,
+- 0x00, 0x00, 0x37);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETPOWER_EXT,
+- 0x25, 0x22, 0x20, 0x03);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETRGBIF,
+- 0x10, 0x10, 0x05, 0x05, 0x03, 0xFF, 0x00, 0x00,
+- 0x00, 0x00);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETSCR,
+- 0x73, 0x73, 0x50, 0x50, 0x00, 0xC0, 0x08, 0x70,
+- 0x00);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETVDC, 0x4E);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETPANEL, 0x0B);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETCYC, 0x80);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETDISP, 0xF0, 0x12, 0xF0);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETEQ,
+- 0x00, 0x00, 0x0B, 0x0B, 0x10, 0x10, 0x00, 0x00,
+- 0x00, 0x00, 0xFF, 0x00, 0xC0, 0x10);
+- dsi_dcs_write_seq(dsi, 0xC6, 0x01, 0x00, 0xFF, 0xFF, 0x00);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETPOWER,
+- 0x74, 0x00, 0x32, 0x32, 0x77, 0xF1, 0xFF, 0xFF,
+- 0xCC, 0xCC, 0x77, 0x77);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETBGP, 0x07, 0x07);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETVCOM, 0x2C, 0x2C);
+- dsi_dcs_write_seq(dsi, 0xBF, 0x02, 0x11, 0x00);
+-
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETGIP1,
+- 0x82, 0x10, 0x06, 0x05, 0xA2, 0x0A, 0xA5, 0x12,
+- 0x31, 0x23, 0x37, 0x83, 0x04, 0xBC, 0x27, 0x38,
+- 0x0C, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x00,
+- 0x03, 0x00, 0x00, 0x00, 0x75, 0x75, 0x31, 0x88,
+- 0x88, 0x88, 0x88, 0x88, 0x88, 0x13, 0x88, 0x64,
+- 0x64, 0x20, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
+- 0x02, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETGIP2,
+- 0x02, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x02, 0x46, 0x02, 0x88,
+- 0x88, 0x88, 0x88, 0x88, 0x88, 0x64, 0x88, 0x13,
+- 0x57, 0x13, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
+- 0x75, 0x88, 0x23, 0x14, 0x00, 0x00, 0x02, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0A,
+- 0xA5, 0x00, 0x00, 0x00, 0x00);
+- dsi_dcs_write_seq(dsi, ST7703_CMD_SETGAMMA,
+- 0x00, 0x09, 0x0D, 0x23, 0x27, 0x3C, 0x41, 0x35,
+- 0x07, 0x0D, 0x0E, 0x12, 0x13, 0x10, 0x12, 0x12,
+- 0x18, 0x00, 0x09, 0x0D, 0x23, 0x27, 0x3C, 0x41,
+- 0x35, 0x07, 0x0D, 0x0E, 0x12, 0x13, 0x10, 0x12,
+- 0x12, 0x18);
+- msleep(20);
+-
+- ret = mipi_dsi_dcs_exit_sleep_mode(dsi);
+- if (ret < 0) {
+- DRM_DEV_ERROR(dev, "Failed to exit sleep mode\n");
+- return ret;
+- }
+- msleep(250);
+-
+- ret = mipi_dsi_dcs_set_display_on(dsi);
+- if (ret)
+- return ret;
+- msleep(50);
+-
+- DRM_DEV_DEBUG_DRIVER(dev, "Panel init sequence done\n");
+- return 0;
+-}
+-
+-static int xbd599_prepare(struct drm_panel *panel)
+-{
+- struct xbd599 *ctx = panel_to_xbd599(panel);
+- int ret;
+-
+- if (ctx->prepared)
+- return 0;
+-
+- ret = regulator_bulk_enable(ARRAY_SIZE(ctx->supplies), ctx->supplies);
+- if (ret)
+- return ret;
+-
+- DRM_DEV_DEBUG_DRIVER(ctx->dev, "Resetting the panel\n");
+- gpiod_set_value_cansleep(ctx->reset_gpio, 1);
+- usleep_range(20, 40);
+- gpiod_set_value_cansleep(ctx->reset_gpio, 0);
+- msleep(20);
+-
+- ctx->prepared = true;
+-
+- return 0;
+-}
+-
+-static int xbd599_enable(struct drm_panel *panel)
+-{
+- struct xbd599 *ctx = panel_to_xbd599(panel);
+- int ret;
+-
+- ret = xbd599_init_sequence(ctx);
+- if (ret < 0) {
+- DRM_DEV_ERROR(ctx->dev, "Panel init sequence failed: %d\n",
+- ret);
+- return ret;
+- }
+-
+- return 0;
+-}
+-
+-static int xbd599_disable(struct drm_panel *panel)
+-{
+- struct xbd599 *ctx = panel_to_xbd599(panel);
+- struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+-
+- return mipi_dsi_dcs_set_display_off(dsi);
+-}
+-
+-static int xbd599_unprepare(struct drm_panel *panel)
+-{
+- struct xbd599 *ctx = panel_to_xbd599(panel);
+-
+- if (!ctx->prepared)
+- return 0;
+-
+- gpiod_set_value_cansleep(ctx->reset_gpio, 1);
+- regulator_bulk_disable(ARRAY_SIZE(ctx->supplies), ctx->supplies);
+- ctx->prepared = false;
+-
+- return 0;
+-}
+-
+-static const struct drm_display_mode xbd599_default_mode = {
+- .hdisplay = 720,
+- .hsync_start = 720 + 40,
+- .hsync_end = 720 + 40 + 40,
+- .htotal = 720 + 40 + 40 + 40,
+- .vdisplay = 1440,
+- .vsync_start = 1440 + 18,
+- .vsync_end = 1440 + 18 + 10,
+- .vtotal = 1440 + 18 + 10 + 17,
+- .vrefresh = 60,
+- .clock = 69000,
+- .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
+-
+- .width_mm = 68,
+- .height_mm = 136,
+- .type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED,
+-};
+-
+-static int xbd599_get_modes(struct drm_panel *panel,
+- struct drm_connector *connector)
+-{
+- struct xbd599 *ctx = panel_to_xbd599(panel);
+- struct drm_display_mode *mode;
+-
+- mode = drm_mode_duplicate(connector->dev, &xbd599_default_mode);
+- if (!mode) {
+- DRM_DEV_ERROR(ctx->dev, "Failed to add mode\n");
+- return -ENOMEM;
+- }
+-
+- drm_mode_set_name(mode);
+-
+- mode->type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED;
+- connector->display_info.width_mm = mode->width_mm;
+- connector->display_info.height_mm = mode->height_mm;
+- drm_mode_probed_add(connector, mode);
+-
+- return 1;
+-}
+-
+-static const struct drm_panel_funcs xbd599_drm_funcs = {
+- .prepare = xbd599_prepare,
+- .enable = xbd599_enable,
+- .disable = xbd599_disable,
+- .unprepare = xbd599_unprepare,
+- .get_modes = xbd599_get_modes,
+-};
+-
+-static int xbd599_probe(struct mipi_dsi_device *dsi)
+-{
+- struct device *dev = &dsi->dev;
+- struct xbd599 *ctx;
+- int i, ret;
+-
+- ctx = devm_kzalloc(dev, sizeof(*ctx), GFP_KERNEL);
+- if (!ctx)
+- return -ENOMEM;
+-
+- for (i = 0; i < ARRAY_SIZE(ctx->supplies); i++)
+- ctx->supplies[i].supply = regulator_names[i];
+-
+- ret = devm_regulator_bulk_get(dev, ARRAY_SIZE(ctx->supplies),
+- ctx->supplies);
+- if (ret < 0) {
+- DRM_DEV_ERROR(&dsi->dev, "cannot get regulators\n");
+- return ret;
+- }
+-
+- ctx->reset_gpio = devm_gpiod_get(dev, "reset", GPIOD_OUT_LOW);
+- if (IS_ERR(ctx->reset_gpio)) {
+- DRM_DEV_ERROR(dev, "cannot get reset gpio\n");
+- return PTR_ERR(ctx->reset_gpio);
+- }
+-
+- mipi_dsi_set_drvdata(dsi, ctx);
+-
+- ctx->dev = dev;
+-
+- dsi->lanes = 4;
+- dsi->format = MIPI_DSI_FMT_RGB888;
+- dsi->mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
+-
+- drm_panel_init(&ctx->panel, &dsi->dev, &xbd599_drm_funcs,
+- DRM_MODE_CONNECTOR_DSI);
+-
+- ret = drm_panel_of_backlight(&ctx->panel);
+- if (ret)
+- return ret;
+-
+- drm_panel_add(&ctx->panel);
+-
+- ret = mipi_dsi_attach(dsi);
+- if (ret < 0) {
+- DRM_DEV_ERROR(dev, "mipi_dsi_attach failed. Is host ready?\n");
+- drm_panel_remove(&ctx->panel);
+- return ret;
+- }
+-
+- DRM_DEV_INFO(dev, "%ux%u@%u %ubpp dsi %udl - ready\n",
+- xbd599_default_mode.hdisplay,
+- xbd599_default_mode.vdisplay,
+- xbd599_default_mode.vrefresh,
+- mipi_dsi_pixel_format_to_bpp(dsi->format), dsi->lanes);
+-
+- return 0;
+-}
+-
+-static void xbd599_shutdown(struct mipi_dsi_device *dsi)
+-{
+- struct xbd599 *ctx = mipi_dsi_get_drvdata(dsi);
+- int ret;
+-
+- ret = drm_panel_unprepare(&ctx->panel);
+- if (ret < 0)
+- DRM_DEV_ERROR(&dsi->dev, "Failed to unprepare panel: %d\n",
+- ret);
+-}
+-
+-static int xbd599_remove(struct mipi_dsi_device *dsi)
+-{
+- struct xbd599 *ctx = mipi_dsi_get_drvdata(dsi);
+- int ret;
+-
+- xbd599_shutdown(dsi);
+-
+- ret = mipi_dsi_detach(dsi);
+- if (ret < 0)
+- DRM_DEV_ERROR(&dsi->dev, "Failed to detach from DSI host: %d\n",
+- ret);
+-
+- drm_panel_remove(&ctx->panel);
+-
+- return 0;
+-}
+-
+-static const struct of_device_id xbd599_of_match[] = {
+- { .compatible = "xingbangda,xbd599", },
+- { /* sentinel */ }
+-};
+-MODULE_DEVICE_TABLE(of, xbd599_of_match);
+-
+-static struct mipi_dsi_driver xbd599_driver = {
+- .probe = xbd599_probe,
+- .remove = xbd599_remove,
+- .shutdown = xbd599_shutdown,
+- .driver = {
+- .name = "panel-xingbangda-xbd599",
+- .of_match_table = xbd599_of_match,
+- },
+-};
+-module_mipi_dsi_driver(xbd599_driver);
+-
+-MODULE_AUTHOR("Icenowy Zheng <icenowy@aosc.io>");
+-MODULE_DESCRIPTION("DRM driver for Xingbangda XBD599 MIPI DSI panel");
+-MODULE_LICENSE("GPL v2");
+--
+2.26.2
+
diff --git a/0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch b/0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch
new file mode 100644
index 000000000..c290e7ab7
--- /dev/null
+++ b/0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch
@@ -0,0 +1,56 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Sun, 12 Jul 2020 13:42:04 +0100
+Subject: [PATCH] Revert "drm/sun4i: sun6i_mipi_dsi: fix horizontal timing
+ calculation"
+
+This reverts commit d20a2ac9c6ecf514e115f06b6744b584bbc7c1b8.
+---
+ drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
+index 52e009dc632b..aa67cb037e9d 100644
+--- a/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
++++ b/drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c
+@@ -556,7 +556,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,
+ */
+ #define HSA_PACKET_OVERHEAD 10
+ hsa = max((unsigned int)HSA_PACKET_OVERHEAD,
+- (mode->hsync_end - mode->hsync_start) * Bpp) - HSA_PACKET_OVERHEAD;
++ (mode->hsync_end - mode->hsync_start) * Bpp - HSA_PACKET_OVERHEAD);
+
+ /*
+ * The backporch is set using a blanking packet (4
+@@ -565,7 +565,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,
+ */
+ #define HBP_PACKET_OVERHEAD 6
+ hbp = max((unsigned int)HBP_PACKET_OVERHEAD,
+- (mode->htotal - mode->hsync_end) * Bpp) - HBP_PACKET_OVERHEAD;
++ (mode->htotal - mode->hsync_end) * Bpp - HBP_PACKET_OVERHEAD);
+
+ /*
+ * The frontporch is set using a sync event (4 bytes)
+@@ -575,7 +575,7 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,
+ */
+ #define HFP_PACKET_OVERHEAD 16
+ hfp = max((unsigned int)HFP_PACKET_OVERHEAD,
+- (mode->hsync_start - mode->hdisplay) * Bpp) - HFP_PACKET_OVERHEAD;
++ (mode->hsync_start - mode->hdisplay) * Bpp - HFP_PACKET_OVERHEAD);
+
+ /*
+ * The blanking is set using a sync event (4 bytes)
+@@ -584,8 +584,8 @@ static void sun6i_dsi_setup_timings(struct sun6i_dsi *dsi,
+ */
+ #define HBLK_PACKET_OVERHEAD 10
+ hblk = max((unsigned int)HBLK_PACKET_OVERHEAD,
+- (mode->htotal - (mode->hsync_end - mode->hsync_start)) * Bpp) -
+- HBLK_PACKET_OVERHEAD;
++ (mode->htotal - (mode->hsync_end - mode->hsync_start)) * Bpp -
++ HBLK_PACKET_OVERHEAD);
+
+ /*
+ * And I'm not entirely sure what vblk is about. The driver in
+--
+2.26.2
+
diff --git a/0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch b/0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch
new file mode 100644
index 000000000..990e624d3
--- /dev/null
+++ b/0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch
@@ -0,0 +1,71 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Peter Robinson <pbrobinson@gmail.com>
+Date: Sun, 12 Jul 2020 13:41:49 +0100
+Subject: [PATCH] Revert "dt-bindings: panel: add binding for Xingbangda XBD599
+ panel"
+
+This reverts commit 8a717270db2000ff734d89e9448b32fbc038c49a.
+---
+ .../display/panel/xingbangda,xbd599.yaml | 50 -------------------
+ 1 file changed, 50 deletions(-)
+ delete mode 100644 Documentation/devicetree/bindings/display/panel/xingbangda,xbd599.yaml
+
+diff --git a/Documentation/devicetree/bindings/display/panel/xingbangda,xbd599.yaml b/Documentation/devicetree/bindings/display/panel/xingbangda,xbd599.yaml
+deleted file mode 100644
+index b27bcf11198f..000000000000
+--- a/Documentation/devicetree/bindings/display/panel/xingbangda,xbd599.yaml
++++ /dev/null
+@@ -1,50 +0,0 @@
+-# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
+-%YAML 1.2
+----
+-$id: http://devicetree.org/schemas/display/panel/xingbangda,xbd599.yaml#
+-$schema: http://devicetree.org/meta-schemas/core.yaml#
+-
+-title: Xingbangda XBD599 5.99in MIPI-DSI LCD panel
+-
+-maintainers:
+- - Icenowy Zheng <icenowy@aosc.io>
+-
+-allOf:
+- - $ref: panel-common.yaml#
+-
+-properties:
+- compatible:
+- const: xingbangda,xbd599
+- reg: true
+- backlight: true
+- reset-gpios: true
+- vcc-supply:
+- description: regulator that supplies the VCC voltage
+- iovcc-supply:
+- description: regulator that supplies the IOVCC voltage
+-
+-required:
+- - compatible
+- - reg
+- - backlight
+- - vcc-supply
+- - iovcc-supply
+-
+-additionalProperties: false
+-
+-examples:
+- - |
+- dsi {
+- #address-cells = <1>;
+- #size-cells = <0>;
+-
+- panel@0 {
+- compatible = "xingbangda,xbd599";
+- reg = <0>;
+- backlight = <&backlight>;
+- iovcc-supply = <&reg_dldo2>;
+- vcc-supply = <&reg_ldo_io0>;
+- };
+- };
+-
+-...
+--
+2.26.2
+
diff --git a/0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch b/0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch
new file mode 100644
index 000000000..d2511ae64
--- /dev/null
+++ b/0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch
@@ -0,0 +1,46 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:56:01 +0200
+Subject: [PATCH] arm64: dts: sun50i-a64-pinephone: Add touchscreen support
+
+Pinephone has a Goodix GT917S capacitive touchscreen controller on
+I2C0 bus. Add support for it.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ .../dts/allwinner/sun50i-a64-pinephone.dtsi | 19 +++++++++++++++++++
+ 1 file changed, 19 insertions(+)
+
+diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+index 85a7aa5efd32..2d5694446d17 100644
+--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
++++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+@@ -123,6 +123,25 @@ &ehci1 {
+ status = "okay";
+ };
+
++&i2c0 {
++ pinctrl-names = "default";
++ pinctrl-0 = <&i2c0_pins>;
++ status = "okay";
++
++ touchscreen@5d {
++ compatible = "goodix,gt917s", "goodix,gt911";
++ reg = <0x5d>;
++ interrupt-parent = <&pio>;
++ interrupts = <7 4 IRQ_TYPE_LEVEL_HIGH>; /* PH4 */
++ irq-gpios = <&pio 7 4 GPIO_ACTIVE_HIGH>; /* PH4 */
++ reset-gpios = <&pio 7 11 GPIO_ACTIVE_HIGH>; /* PH11 */
++ AVDD28-supply = <&reg_ldo_io0>;
++ VDDIO-supply = <&reg_ldo_io0>;
++ touchscreen-size-x = <720>;
++ touchscreen-size-y = <1440>;
++ };
++};
++
+ &i2c1 {
+ status = "okay";
+
+--
+2.26.2
+
diff --git a/0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch b/0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch
new file mode 100644
index 000000000..a38cd7250
--- /dev/null
+++ b/0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch
@@ -0,0 +1,112 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Icenowy Zheng <icenowy@aosc.io>
+Date: Fri, 26 Jun 2020 02:56:00 +0200
+Subject: [PATCH] arm64: dts: sun50i-a64-pinephone: Enable LCD support on
+ PinePhone
+
+PinePhone uses PWM backlight and a XBD599 LCD panel over DSI for
+display.
+
+Backlight levels curve was optimized by Martijn Braam using a
+lux meter.
+
+Add its device nodes.
+
+Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
+Signed-off-by: Martijn Braam <martijn@brixit.nl>
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ .../allwinner/sun50i-a64-pinephone-1.1.dts | 19 ++++++++++
+ .../dts/allwinner/sun50i-a64-pinephone.dtsi | 35 +++++++++++++++++++
+ 2 files changed, 54 insertions(+)
+
+diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone-1.1.dts b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone-1.1.dts
+index 06a775c41664..3e99a87e9ce5 100644
+--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone-1.1.dts
++++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone-1.1.dts
+@@ -9,3 +9,22 @@ / {
+ model = "Pine64 PinePhone Braveheart (1.1)";
+ compatible = "pine64,pinephone-1.1", "allwinner,sun50i-a64";
+ };
++
++&backlight {
++ power-supply = <&reg_ldo_io0>;
++ /*
++ * PWM backlight circuit on this PinePhone revision was changed since
++ * 1.0, and the lowest PWM duty cycle that doesn't lead to backlight
++ * being off is around 20%. Duty cycle for the lowest brightness level
++ * also varries quite a bit between individual boards, so the lowest
++ * value here was chosen as a safe default.
++ */
++ brightness-levels = <
++ 774 793 814 842
++ 882 935 1003 1088
++ 1192 1316 1462 1633
++ 1830 2054 2309 2596
++ 2916 3271 3664 4096>;
++ num-interpolated-steps = <50>;
++ default-brightness-level = <400>;
++};
+diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+index cefda145c3c9..85a7aa5efd32 100644
+--- a/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
++++ b/arch/arm64/boot/dts/allwinner/sun50i-a64-pinephone.dtsi
+@@ -16,6 +16,13 @@ aliases {
+ serial0 = &uart0;
+ };
+
++ backlight: backlight {
++ compatible = "pwm-backlight";
++ pwms = <&r_pwm 0 50000 PWM_POLARITY_INVERTED>;
++ enable-gpios = <&pio 7 10 GPIO_ACTIVE_HIGH>; /* PH10 */
++ /* Backlight configuration differs per PinePhone revision. */
++ };
++
+ chosen {
+ stdout-path = "serial0:115200n8";
+ };
+@@ -84,6 +91,30 @@ &dai {
+ status = "okay";
+ };
+
++&de {
++ status = "okay";
++};
++
++&dphy {
++ status = "okay";
++};
++
++&dsi {
++ vcc-dsi-supply = <&reg_dldo1>;
++ #address-cells = <1>;
++ #size-cells = <0>;
++ status = "okay";
++
++ panel@0 {
++ compatible = "xingbangda,xbd599";
++ reg = <0>;
++ reset-gpios = <&pio 3 23 GPIO_ACTIVE_LOW>; /* PD23 */
++ iovcc-supply = <&reg_dldo2>;
++ vcc-supply = <&reg_ldo_io0>;
++ backlight = <&backlight>;
++ };
++};
++
+ &ehci0 {
+ status = "okay";
+ };
+@@ -188,6 +219,10 @@ &r_pio {
+ */
+ };
+
++&r_pwm {
++ status = "okay";
++};
++
+ &r_rsb {
+ status = "okay";
+
+--
+2.26.2
+
diff --git a/0001-bpf-Add-tech-preview-taint-for-syscall.patch b/0001-bpf-Add-tech-preview-taint-for-syscall.patch
index 6b048f448..2487c60f1 100644
--- a/0001-bpf-Add-tech-preview-taint-for-syscall.patch
+++ b/0001-bpf-Add-tech-preview-taint-for-syscall.patch
@@ -27,10 +27,10 @@ Signed-off-by: Herton R. Krzesinski <herton@redhat.com>
1 file changed, 6 insertions(+)
diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c
-index dcdf7649f4b7..2751eb3cfe06 100644
+index 60f70f31060e..628d0ba68106 100644
--- a/kernel/bpf/syscall.c
+++ b/kernel/bpf/syscall.c
-@@ -4096,11 +4096,17 @@ static int bpf_iter_create(union bpf_attr *attr)
+@@ -4094,11 +4094,17 @@ static int bpf_iter_create(union bpf_attr *attr)
SYSCALL_DEFINE3(bpf, int, cmd, union bpf_attr __user *, uattr, unsigned int, size)
{
union bpf_attr attr;
diff --git a/0001-bpf-set-unprivileged_bpf_disabled-to-1-by-default-ad.patch b/0001-bpf-set-unprivileged_bpf_disabled-to-1-by-default-ad.patch
index a9f2600da..042d8b999 100644
--- a/0001-bpf-set-unprivileged_bpf_disabled-to-1-by-default-ad.patch
+++ b/0001-bpf-set-unprivileged_bpf_disabled-to-1-by-default-ad.patch
@@ -66,7 +66,7 @@ index 28be75396242..0a0081b10edb 100644
#define TAINT_FLAGS_COUNT 32
#define TAINT_FLAGS_MAX ((1UL << TAINT_FLAGS_COUNT) - 1)
diff --git a/kernel/bpf/syscall.c b/kernel/bpf/syscall.c
-index 859053ddf05b..dcdf7649f4b7 100644
+index 0fd80ac81f70..60f70f31060e 100644
--- a/kernel/bpf/syscall.c
+++ b/kernel/bpf/syscall.c
@@ -24,6 +24,7 @@
diff --git a/0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch b/0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch
new file mode 100644
index 000000000..d78bf5644
--- /dev/null
+++ b/0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch
@@ -0,0 +1,948 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:52 +0200
+Subject: [PATCH] drm/panel: rocktech-jh057n00900: Rename the driver to st7703
+
+This rename is done so that the driver matches the name of the
+display controller and in preparation for adding support for more
+panels to the driver.
+
+This is just a basic file rename, with no code changes.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/Kconfig | 26 +-
+ drivers/gpu/drm/panel/Makefile | 2 +-
+ .../drm/panel/panel-rocktech-jh057n00900.c | 424 ------------------
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 424 ++++++++++++++++++
+ 4 files changed, 438 insertions(+), 438 deletions(-)
+ delete mode 100644 drivers/gpu/drm/panel/panel-rocktech-jh057n00900.c
+ create mode 100644 drivers/gpu/drm/panel/panel-sitronix-st7703.c
+
+diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig
+index 39055c1f0e2f..de2f2a452be5 100644
+--- a/drivers/gpu/drm/panel/Kconfig
++++ b/drivers/gpu/drm/panel/Kconfig
+@@ -283,19 +283,6 @@ config DRM_PANEL_RAYDIUM_RM68200
+ Say Y here if you want to enable support for Raydium RM68200
+ 720x1280 DSI video mode panel.
+
+-config DRM_PANEL_ROCKTECH_JH057N00900
+- tristate "Rocktech JH057N00900 MIPI touchscreen panel"
+- depends on OF
+- depends on DRM_MIPI_DSI
+- depends on BACKLIGHT_CLASS_DEVICE
+- help
+- Say Y here if you want to enable support for Rocktech JH057N00900
+- MIPI DSI panel as e.g. used in the Librem 5 devkit. It has a
+- resolution of 720x1440 pixels, a built in backlight and touch
+- controller.
+- Touch input support is provided by the goodix driver and needs to be
+- selected separately.
+-
+ config DRM_PANEL_RONBO_RB070D30
+ tristate "Ronbo Electronics RB070D30 panel"
+ depends on OF
+@@ -395,6 +382,19 @@ config DRM_PANEL_SITRONIX_ST7701
+ ST7701 controller for 480X864 LCD panels with MIPI/RGB/SPI
+ system interfaces.
+
++config DRM_PANEL_SITRONIX_ST7703
++ tristate "Sitronix ST7703 based MIPI touchscreen panels"
++ depends on OF
++ depends on DRM_MIPI_DSI
++ depends on BACKLIGHT_CLASS_DEVICE
++ help
++ Say Y here if you want to enable support for Sitronix ST7703 based
++ panels, souch as Rocktech JH057N00900 MIPI DSI panel as e.g. used in
++ the Librem 5 devkit. It has a resolution of 720x1440 pixels, a built
++ in backlight and touch controller.
++ Touch input support is provided by the goodix driver and needs to be
++ selected separately.
++
+ config DRM_PANEL_SITRONIX_ST7789V
+ tristate "Sitronix ST7789V panel"
+ depends on OF && SPI
+diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile
+index de74f282c433..e45ceac6286f 100644
+--- a/drivers/gpu/drm/panel/Makefile
++++ b/drivers/gpu/drm/panel/Makefile
+@@ -27,7 +27,6 @@ obj-$(CONFIG_DRM_PANEL_PANASONIC_VVX10F034N00) += panel-panasonic-vvx10f034n00.o
+ obj-$(CONFIG_DRM_PANEL_RASPBERRYPI_TOUCHSCREEN) += panel-raspberrypi-touchscreen.o
+ obj-$(CONFIG_DRM_PANEL_RAYDIUM_RM67191) += panel-raydium-rm67191.o
+ obj-$(CONFIG_DRM_PANEL_RAYDIUM_RM68200) += panel-raydium-rm68200.o
+-obj-$(CONFIG_DRM_PANEL_ROCKTECH_JH057N00900) += panel-rocktech-jh057n00900.o
+ obj-$(CONFIG_DRM_PANEL_RONBO_RB070D30) += panel-ronbo-rb070d30.o
+ obj-$(CONFIG_DRM_PANEL_SAMSUNG_LD9040) += panel-samsung-ld9040.o
+ obj-$(CONFIG_DRM_PANEL_SAMSUNG_S6D16D0) += panel-samsung-s6d16d0.o
+@@ -41,6 +40,7 @@ obj-$(CONFIG_DRM_PANEL_SHARP_LQ101R1SX01) += panel-sharp-lq101r1sx01.o
+ obj-$(CONFIG_DRM_PANEL_SHARP_LS037V7DW01) += panel-sharp-ls037v7dw01.o
+ obj-$(CONFIG_DRM_PANEL_SHARP_LS043T1LE01) += panel-sharp-ls043t1le01.o
+ obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7701) += panel-sitronix-st7701.o
++obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7703) += panel-sitronix-st7703.o
+ obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7789V) += panel-sitronix-st7789v.o
+ obj-$(CONFIG_DRM_PANEL_SONY_ACX424AKP) += panel-sony-acx424akp.o
+ obj-$(CONFIG_DRM_PANEL_SONY_ACX565AKM) += panel-sony-acx565akm.o
+diff --git a/drivers/gpu/drm/panel/panel-rocktech-jh057n00900.c b/drivers/gpu/drm/panel/panel-rocktech-jh057n00900.c
+deleted file mode 100644
+index 38ff742bc120..000000000000
+--- a/drivers/gpu/drm/panel/panel-rocktech-jh057n00900.c
++++ /dev/null
+@@ -1,424 +0,0 @@
+-// SPDX-License-Identifier: GPL-2.0
+-/*
+- * Rockteck jh057n00900 5.5" MIPI-DSI panel driver
+- *
+- * Copyright (C) Purism SPC 2019
+- */
+-
+-#include <linux/debugfs.h>
+-#include <linux/delay.h>
+-#include <linux/gpio/consumer.h>
+-#include <linux/media-bus-format.h>
+-#include <linux/mod_devicetable.h>
+-#include <linux/module.h>
+-#include <linux/regulator/consumer.h>
+-
+-#include <video/display_timing.h>
+-#include <video/mipi_display.h>
+-
+-#include <drm/drm_mipi_dsi.h>
+-#include <drm/drm_modes.h>
+-#include <drm/drm_panel.h>
+-#include <drm/drm_print.h>
+-
+-#define DRV_NAME "panel-rocktech-jh057n00900"
+-
+-/* Manufacturer specific Commands send via DSI */
+-#define ST7703_CMD_ALL_PIXEL_OFF 0x22
+-#define ST7703_CMD_ALL_PIXEL_ON 0x23
+-#define ST7703_CMD_SETDISP 0xB2
+-#define ST7703_CMD_SETRGBIF 0xB3
+-#define ST7703_CMD_SETCYC 0xB4
+-#define ST7703_CMD_SETBGP 0xB5
+-#define ST7703_CMD_SETVCOM 0xB6
+-#define ST7703_CMD_SETOTP 0xB7
+-#define ST7703_CMD_SETPOWER_EXT 0xB8
+-#define ST7703_CMD_SETEXTC 0xB9
+-#define ST7703_CMD_SETMIPI 0xBA
+-#define ST7703_CMD_SETVDC 0xBC
+-#define ST7703_CMD_UNKNOWN0 0xBF
+-#define ST7703_CMD_SETSCR 0xC0
+-#define ST7703_CMD_SETPOWER 0xC1
+-#define ST7703_CMD_SETPANEL 0xCC
+-#define ST7703_CMD_SETGAMMA 0xE0
+-#define ST7703_CMD_SETEQ 0xE3
+-#define ST7703_CMD_SETGIP1 0xE9
+-#define ST7703_CMD_SETGIP2 0xEA
+-
+-struct jh057n {
+- struct device *dev;
+- struct drm_panel panel;
+- struct gpio_desc *reset_gpio;
+- struct regulator *vcc;
+- struct regulator *iovcc;
+- bool prepared;
+-
+- struct dentry *debugfs;
+-};
+-
+-static inline struct jh057n *panel_to_jh057n(struct drm_panel *panel)
+-{
+- return container_of(panel, struct jh057n, panel);
+-}
+-
+-#define dsi_generic_write_seq(dsi, seq...) do { \
+- static const u8 d[] = { seq }; \
+- int ret; \
+- ret = mipi_dsi_generic_write(dsi, d, ARRAY_SIZE(d)); \
+- if (ret < 0) \
+- return ret; \
+- } while (0)
+-
+-static int jh057n_init_sequence(struct jh057n *ctx)
+-{
+- struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+- struct device *dev = ctx->dev;
+- int ret;
+-
+- /*
+- * Init sequence was supplied by the panel vendor. Most of the commands
+- * resemble the ST7703 but the number of parameters often don't match
+- * so it's likely a clone.
+- */
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETEXTC,
+- 0xF1, 0x12, 0x83);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETRGBIF,
+- 0x10, 0x10, 0x05, 0x05, 0x03, 0xFF, 0x00, 0x00,
+- 0x00, 0x00);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETSCR,
+- 0x73, 0x73, 0x50, 0x50, 0x00, 0x00, 0x08, 0x70,
+- 0x00);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETVDC, 0x4E);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETPANEL, 0x0B);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETCYC, 0x80);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETDISP, 0xF0, 0x12, 0x30);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETEQ,
+- 0x07, 0x07, 0x0B, 0x0B, 0x03, 0x0B, 0x00, 0x00,
+- 0x00, 0x00, 0xFF, 0x00, 0xC0, 0x10);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETBGP, 0x08, 0x08);
+- msleep(20);
+-
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETVCOM, 0x3F, 0x3F);
+- dsi_generic_write_seq(dsi, ST7703_CMD_UNKNOWN0, 0x02, 0x11, 0x00);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETGIP1,
+- 0x82, 0x10, 0x06, 0x05, 0x9E, 0x0A, 0xA5, 0x12,
+- 0x31, 0x23, 0x37, 0x83, 0x04, 0xBC, 0x27, 0x38,
+- 0x0C, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x00,
+- 0x03, 0x00, 0x00, 0x00, 0x75, 0x75, 0x31, 0x88,
+- 0x88, 0x88, 0x88, 0x88, 0x88, 0x13, 0x88, 0x64,
+- 0x64, 0x20, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
+- 0x02, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETGIP2,
+- 0x02, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x02, 0x46, 0x02, 0x88,
+- 0x88, 0x88, 0x88, 0x88, 0x88, 0x64, 0x88, 0x13,
+- 0x57, 0x13, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
+- 0x75, 0x88, 0x23, 0x14, 0x00, 0x00, 0x02, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
+- 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x0A,
+- 0xA5, 0x00, 0x00, 0x00, 0x00);
+- dsi_generic_write_seq(dsi, ST7703_CMD_SETGAMMA,
+- 0x00, 0x09, 0x0E, 0x29, 0x2D, 0x3C, 0x41, 0x37,
+- 0x07, 0x0B, 0x0D, 0x10, 0x11, 0x0F, 0x10, 0x11,
+- 0x18, 0x00, 0x09, 0x0E, 0x29, 0x2D, 0x3C, 0x41,
+- 0x37, 0x07, 0x0B, 0x0D, 0x10, 0x11, 0x0F, 0x10,
+- 0x11, 0x18);
+- msleep(20);
+-
+- ret = mipi_dsi_dcs_exit_sleep_mode(dsi);
+- if (ret < 0) {
+- DRM_DEV_ERROR(dev, "Failed to exit sleep mode: %d\n", ret);
+- return ret;
+- }
+- /* Panel is operational 120 msec after reset */
+- msleep(60);
+- ret = mipi_dsi_dcs_set_display_on(dsi);
+- if (ret)
+- return ret;
+-
+- DRM_DEV_DEBUG_DRIVER(dev, "Panel init sequence done\n");
+- return 0;
+-}
+-
+-static int jh057n_enable(struct drm_panel *panel)
+-{
+- struct jh057n *ctx = panel_to_jh057n(panel);
+- int ret;
+-
+- ret = jh057n_init_sequence(ctx);
+- if (ret < 0) {
+- DRM_DEV_ERROR(ctx->dev, "Panel init sequence failed: %d\n",
+- ret);
+- return ret;
+- }
+-
+- return 0;
+-}
+-
+-static int jh057n_disable(struct drm_panel *panel)
+-{
+- struct jh057n *ctx = panel_to_jh057n(panel);
+- struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+-
+- return mipi_dsi_dcs_set_display_off(dsi);
+-}
+-
+-static int jh057n_unprepare(struct drm_panel *panel)
+-{
+- struct jh057n *ctx = panel_to_jh057n(panel);
+-
+- if (!ctx->prepared)
+- return 0;
+-
+- regulator_disable(ctx->iovcc);
+- regulator_disable(ctx->vcc);
+- ctx->prepared = false;
+-
+- return 0;
+-}
+-
+-static int jh057n_prepare(struct drm_panel *panel)
+-{
+- struct jh057n *ctx = panel_to_jh057n(panel);
+- int ret;
+-
+- if (ctx->prepared)
+- return 0;
+-
+- DRM_DEV_DEBUG_DRIVER(ctx->dev, "Resetting the panel\n");
+- ret = regulator_enable(ctx->vcc);
+- if (ret < 0) {
+- DRM_DEV_ERROR(ctx->dev,
+- "Failed to enable vcc supply: %d\n", ret);
+- return ret;
+- }
+- ret = regulator_enable(ctx->iovcc);
+- if (ret < 0) {
+- DRM_DEV_ERROR(ctx->dev,
+- "Failed to enable iovcc supply: %d\n", ret);
+- goto disable_vcc;
+- }
+-
+- gpiod_set_value_cansleep(ctx->reset_gpio, 1);
+- usleep_range(20, 40);
+- gpiod_set_value_cansleep(ctx->reset_gpio, 0);
+- msleep(20);
+-
+- ctx->prepared = true;
+-
+- return 0;
+-
+-disable_vcc:
+- regulator_disable(ctx->vcc);
+- return ret;
+-}
+-
+-static const struct drm_display_mode default_mode = {
+- .hdisplay = 720,
+- .hsync_start = 720 + 90,
+- .hsync_end = 720 + 90 + 20,
+- .htotal = 720 + 90 + 20 + 20,
+- .vdisplay = 1440,
+- .vsync_start = 1440 + 20,
+- .vsync_end = 1440 + 20 + 4,
+- .vtotal = 1440 + 20 + 4 + 12,
+- .vrefresh = 60,
+- .clock = 75276,
+- .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
+- .width_mm = 65,
+- .height_mm = 130,
+-};
+-
+-static int jh057n_get_modes(struct drm_panel *panel,
+- struct drm_connector *connector)
+-{
+- struct jh057n *ctx = panel_to_jh057n(panel);
+- struct drm_display_mode *mode;
+-
+- mode = drm_mode_duplicate(connector->dev, &default_mode);
+- if (!mode) {
+- DRM_DEV_ERROR(ctx->dev, "Failed to add mode %ux%u@%u\n",
+- default_mode.hdisplay, default_mode.vdisplay,
+- default_mode.vrefresh);
+- return -ENOMEM;
+- }
+-
+- drm_mode_set_name(mode);
+-
+- mode->type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED;
+- connector->display_info.width_mm = mode->width_mm;
+- connector->display_info.height_mm = mode->height_mm;
+- drm_mode_probed_add(connector, mode);
+-
+- return 1;
+-}
+-
+-static const struct drm_panel_funcs jh057n_drm_funcs = {
+- .disable = jh057n_disable,
+- .unprepare = jh057n_unprepare,
+- .prepare = jh057n_prepare,
+- .enable = jh057n_enable,
+- .get_modes = jh057n_get_modes,
+-};
+-
+-static int allpixelson_set(void *data, u64 val)
+-{
+- struct jh057n *ctx = data;
+- struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+-
+- DRM_DEV_DEBUG_DRIVER(ctx->dev, "Setting all pixels on\n");
+- dsi_generic_write_seq(dsi, ST7703_CMD_ALL_PIXEL_ON);
+- msleep(val * 1000);
+- /* Reset the panel to get video back */
+- drm_panel_disable(&ctx->panel);
+- drm_panel_unprepare(&ctx->panel);
+- drm_panel_prepare(&ctx->panel);
+- drm_panel_enable(&ctx->panel);
+-
+- return 0;
+-}
+-
+-DEFINE_SIMPLE_ATTRIBUTE(allpixelson_fops, NULL,
+- allpixelson_set, "%llu\n");
+-
+-static void jh057n_debugfs_init(struct jh057n *ctx)
+-{
+- ctx->debugfs = debugfs_create_dir(DRV_NAME, NULL);
+-
+- debugfs_create_file("allpixelson", 0600, ctx->debugfs, ctx,
+- &allpixelson_fops);
+-}
+-
+-static void jh057n_debugfs_remove(struct jh057n *ctx)
+-{
+- debugfs_remove_recursive(ctx->debugfs);
+- ctx->debugfs = NULL;
+-}
+-
+-static int jh057n_probe(struct mipi_dsi_device *dsi)
+-{
+- struct device *dev = &dsi->dev;
+- struct jh057n *ctx;
+- int ret;
+-
+- ctx = devm_kzalloc(dev, sizeof(*ctx), GFP_KERNEL);
+- if (!ctx)
+- return -ENOMEM;
+-
+- ctx->reset_gpio = devm_gpiod_get(dev, "reset", GPIOD_OUT_LOW);
+- if (IS_ERR(ctx->reset_gpio)) {
+- DRM_DEV_ERROR(dev, "cannot get reset gpio\n");
+- return PTR_ERR(ctx->reset_gpio);
+- }
+-
+- mipi_dsi_set_drvdata(dsi, ctx);
+-
+- ctx->dev = dev;
+-
+- dsi->lanes = 4;
+- dsi->format = MIPI_DSI_FMT_RGB888;
+- dsi->mode_flags = MIPI_DSI_MODE_VIDEO |
+- MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
+-
+- ctx->vcc = devm_regulator_get(dev, "vcc");
+- if (IS_ERR(ctx->vcc)) {
+- ret = PTR_ERR(ctx->vcc);
+- if (ret != -EPROBE_DEFER)
+- DRM_DEV_ERROR(dev,
+- "Failed to request vcc regulator: %d\n",
+- ret);
+- return ret;
+- }
+- ctx->iovcc = devm_regulator_get(dev, "iovcc");
+- if (IS_ERR(ctx->iovcc)) {
+- ret = PTR_ERR(ctx->iovcc);
+- if (ret != -EPROBE_DEFER)
+- DRM_DEV_ERROR(dev,
+- "Failed to request iovcc regulator: %d\n",
+- ret);
+- return ret;
+- }
+-
+- drm_panel_init(&ctx->panel, dev, &jh057n_drm_funcs,
+- DRM_MODE_CONNECTOR_DSI);
+-
+- ret = drm_panel_of_backlight(&ctx->panel);
+- if (ret)
+- return ret;
+-
+- drm_panel_add(&ctx->panel);
+-
+- ret = mipi_dsi_attach(dsi);
+- if (ret < 0) {
+- DRM_DEV_ERROR(dev,
+- "mipi_dsi_attach failed (%d). Is host ready?\n",
+- ret);
+- drm_panel_remove(&ctx->panel);
+- return ret;
+- }
+-
+- DRM_DEV_INFO(dev, "%ux%u@%u %ubpp dsi %udl - ready\n",
+- default_mode.hdisplay, default_mode.vdisplay,
+- default_mode.vrefresh,
+- mipi_dsi_pixel_format_to_bpp(dsi->format), dsi->lanes);
+-
+- jh057n_debugfs_init(ctx);
+- return 0;
+-}
+-
+-static void jh057n_shutdown(struct mipi_dsi_device *dsi)
+-{
+- struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
+- int ret;
+-
+- ret = drm_panel_unprepare(&ctx->panel);
+- if (ret < 0)
+- DRM_DEV_ERROR(&dsi->dev, "Failed to unprepare panel: %d\n",
+- ret);
+-
+- ret = drm_panel_disable(&ctx->panel);
+- if (ret < 0)
+- DRM_DEV_ERROR(&dsi->dev, "Failed to disable panel: %d\n",
+- ret);
+-}
+-
+-static int jh057n_remove(struct mipi_dsi_device *dsi)
+-{
+- struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
+- int ret;
+-
+- jh057n_shutdown(dsi);
+-
+- ret = mipi_dsi_detach(dsi);
+- if (ret < 0)
+- DRM_DEV_ERROR(&dsi->dev, "Failed to detach from DSI host: %d\n",
+- ret);
+-
+- drm_panel_remove(&ctx->panel);
+-
+- jh057n_debugfs_remove(ctx);
+-
+- return 0;
+-}
+-
+-static const struct of_device_id jh057n_of_match[] = {
+- { .compatible = "rocktech,jh057n00900" },
+- { /* sentinel */ }
+-};
+-MODULE_DEVICE_TABLE(of, jh057n_of_match);
+-
+-static struct mipi_dsi_driver jh057n_driver = {
+- .probe = jh057n_probe,
+- .remove = jh057n_remove,
+- .shutdown = jh057n_shutdown,
+- .driver = {
+- .name = DRV_NAME,
+- .of_match_table = jh057n_of_match,
+- },
+-};
+-module_mipi_dsi_driver(jh057n_driver);
+-
+-MODULE_AUTHOR("Guido Günther <agx@sigxcpu.org>");
+-MODULE_DESCRIPTION("DRM driver for Rocktech JH057N00900 MIPI DSI panel");
+-MODULE_LICENSE("GPL v2");
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+new file mode 100644
+index 000000000000..38ff742bc120
+--- /dev/null
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -0,0 +1,424 @@
++// SPDX-License-Identifier: GPL-2.0
++/*
++ * Rockteck jh057n00900 5.5" MIPI-DSI panel driver
++ *
++ * Copyright (C) Purism SPC 2019
++ */
++
++#include <linux/debugfs.h>
++#include <linux/delay.h>
++#include <linux/gpio/consumer.h>
++#include <linux/media-bus-format.h>
++#include <linux/mod_devicetable.h>
++#include <linux/module.h>
++#include <linux/regulator/consumer.h>
++
++#include <video/display_timing.h>
++#include <video/mipi_display.h>
++
++#include <drm/drm_mipi_dsi.h>
++#include <drm/drm_modes.h>
++#include <drm/drm_panel.h>
++#include <drm/drm_print.h>
++
++#define DRV_NAME "panel-rocktech-jh057n00900"
++
++/* Manufacturer specific Commands send via DSI */
++#define ST7703_CMD_ALL_PIXEL_OFF 0x22
++#define ST7703_CMD_ALL_PIXEL_ON 0x23
++#define ST7703_CMD_SETDISP 0xB2
++#define ST7703_CMD_SETRGBIF 0xB3
++#define ST7703_CMD_SETCYC 0xB4
++#define ST7703_CMD_SETBGP 0xB5
++#define ST7703_CMD_SETVCOM 0xB6
++#define ST7703_CMD_SETOTP 0xB7
++#define ST7703_CMD_SETPOWER_EXT 0xB8
++#define ST7703_CMD_SETEXTC 0xB9
++#define ST7703_CMD_SETMIPI 0xBA
++#define ST7703_CMD_SETVDC 0xBC
++#define ST7703_CMD_UNKNOWN0 0xBF
++#define ST7703_CMD_SETSCR 0xC0
++#define ST7703_CMD_SETPOWER 0xC1
++#define ST7703_CMD_SETPANEL 0xCC
++#define ST7703_CMD_SETGAMMA 0xE0
++#define ST7703_CMD_SETEQ 0xE3
++#define ST7703_CMD_SETGIP1 0xE9
++#define ST7703_CMD_SETGIP2 0xEA
++
++struct jh057n {
++ struct device *dev;
++ struct drm_panel panel;
++ struct gpio_desc *reset_gpio;
++ struct regulator *vcc;
++ struct regulator *iovcc;
++ bool prepared;
++
++ struct dentry *debugfs;
++};
++
++static inline struct jh057n *panel_to_jh057n(struct drm_panel *panel)
++{
++ return container_of(panel, struct jh057n, panel);
++}
++
++#define dsi_generic_write_seq(dsi, seq...) do { \
++ static const u8 d[] = { seq }; \
++ int ret; \
++ ret = mipi_dsi_generic_write(dsi, d, ARRAY_SIZE(d)); \
++ if (ret < 0) \
++ return ret; \
++ } while (0)
++
++static int jh057n_init_sequence(struct jh057n *ctx)
++{
++ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
++ struct device *dev = ctx->dev;
++ int ret;
++
++ /*
++ * Init sequence was supplied by the panel vendor. Most of the commands
++ * resemble the ST7703 but the number of parameters often don't match
++ * so it's likely a clone.
++ */
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETEXTC,
++ 0xF1, 0x12, 0x83);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETRGBIF,
++ 0x10, 0x10, 0x05, 0x05, 0x03, 0xFF, 0x00, 0x00,
++ 0x00, 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETSCR,
++ 0x73, 0x73, 0x50, 0x50, 0x00, 0x00, 0x08, 0x70,
++ 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETVDC, 0x4E);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETPANEL, 0x0B);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETCYC, 0x80);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETDISP, 0xF0, 0x12, 0x30);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETEQ,
++ 0x07, 0x07, 0x0B, 0x0B, 0x03, 0x0B, 0x00, 0x00,
++ 0x00, 0x00, 0xFF, 0x00, 0xC0, 0x10);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETBGP, 0x08, 0x08);
++ msleep(20);
++
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETVCOM, 0x3F, 0x3F);
++ dsi_generic_write_seq(dsi, ST7703_CMD_UNKNOWN0, 0x02, 0x11, 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETGIP1,
++ 0x82, 0x10, 0x06, 0x05, 0x9E, 0x0A, 0xA5, 0x12,
++ 0x31, 0x23, 0x37, 0x83, 0x04, 0xBC, 0x27, 0x38,
++ 0x0C, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x00,
++ 0x03, 0x00, 0x00, 0x00, 0x75, 0x75, 0x31, 0x88,
++ 0x88, 0x88, 0x88, 0x88, 0x88, 0x13, 0x88, 0x64,
++ 0x64, 0x20, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
++ 0x02, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETGIP2,
++ 0x02, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x02, 0x46, 0x02, 0x88,
++ 0x88, 0x88, 0x88, 0x88, 0x88, 0x64, 0x88, 0x13,
++ 0x57, 0x13, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
++ 0x75, 0x88, 0x23, 0x14, 0x00, 0x00, 0x02, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x30, 0x0A,
++ 0xA5, 0x00, 0x00, 0x00, 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_SETGAMMA,
++ 0x00, 0x09, 0x0E, 0x29, 0x2D, 0x3C, 0x41, 0x37,
++ 0x07, 0x0B, 0x0D, 0x10, 0x11, 0x0F, 0x10, 0x11,
++ 0x18, 0x00, 0x09, 0x0E, 0x29, 0x2D, 0x3C, 0x41,
++ 0x37, 0x07, 0x0B, 0x0D, 0x10, 0x11, 0x0F, 0x10,
++ 0x11, 0x18);
++ msleep(20);
++
++ ret = mipi_dsi_dcs_exit_sleep_mode(dsi);
++ if (ret < 0) {
++ DRM_DEV_ERROR(dev, "Failed to exit sleep mode: %d\n", ret);
++ return ret;
++ }
++ /* Panel is operational 120 msec after reset */
++ msleep(60);
++ ret = mipi_dsi_dcs_set_display_on(dsi);
++ if (ret)
++ return ret;
++
++ DRM_DEV_DEBUG_DRIVER(dev, "Panel init sequence done\n");
++ return 0;
++}
++
++static int jh057n_enable(struct drm_panel *panel)
++{
++ struct jh057n *ctx = panel_to_jh057n(panel);
++ int ret;
++
++ ret = jh057n_init_sequence(ctx);
++ if (ret < 0) {
++ DRM_DEV_ERROR(ctx->dev, "Panel init sequence failed: %d\n",
++ ret);
++ return ret;
++ }
++
++ return 0;
++}
++
++static int jh057n_disable(struct drm_panel *panel)
++{
++ struct jh057n *ctx = panel_to_jh057n(panel);
++ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
++
++ return mipi_dsi_dcs_set_display_off(dsi);
++}
++
++static int jh057n_unprepare(struct drm_panel *panel)
++{
++ struct jh057n *ctx = panel_to_jh057n(panel);
++
++ if (!ctx->prepared)
++ return 0;
++
++ regulator_disable(ctx->iovcc);
++ regulator_disable(ctx->vcc);
++ ctx->prepared = false;
++
++ return 0;
++}
++
++static int jh057n_prepare(struct drm_panel *panel)
++{
++ struct jh057n *ctx = panel_to_jh057n(panel);
++ int ret;
++
++ if (ctx->prepared)
++ return 0;
++
++ DRM_DEV_DEBUG_DRIVER(ctx->dev, "Resetting the panel\n");
++ ret = regulator_enable(ctx->vcc);
++ if (ret < 0) {
++ DRM_DEV_ERROR(ctx->dev,
++ "Failed to enable vcc supply: %d\n", ret);
++ return ret;
++ }
++ ret = regulator_enable(ctx->iovcc);
++ if (ret < 0) {
++ DRM_DEV_ERROR(ctx->dev,
++ "Failed to enable iovcc supply: %d\n", ret);
++ goto disable_vcc;
++ }
++
++ gpiod_set_value_cansleep(ctx->reset_gpio, 1);
++ usleep_range(20, 40);
++ gpiod_set_value_cansleep(ctx->reset_gpio, 0);
++ msleep(20);
++
++ ctx->prepared = true;
++
++ return 0;
++
++disable_vcc:
++ regulator_disable(ctx->vcc);
++ return ret;
++}
++
++static const struct drm_display_mode default_mode = {
++ .hdisplay = 720,
++ .hsync_start = 720 + 90,
++ .hsync_end = 720 + 90 + 20,
++ .htotal = 720 + 90 + 20 + 20,
++ .vdisplay = 1440,
++ .vsync_start = 1440 + 20,
++ .vsync_end = 1440 + 20 + 4,
++ .vtotal = 1440 + 20 + 4 + 12,
++ .vrefresh = 60,
++ .clock = 75276,
++ .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
++ .width_mm = 65,
++ .height_mm = 130,
++};
++
++static int jh057n_get_modes(struct drm_panel *panel,
++ struct drm_connector *connector)
++{
++ struct jh057n *ctx = panel_to_jh057n(panel);
++ struct drm_display_mode *mode;
++
++ mode = drm_mode_duplicate(connector->dev, &default_mode);
++ if (!mode) {
++ DRM_DEV_ERROR(ctx->dev, "Failed to add mode %ux%u@%u\n",
++ default_mode.hdisplay, default_mode.vdisplay,
++ default_mode.vrefresh);
++ return -ENOMEM;
++ }
++
++ drm_mode_set_name(mode);
++
++ mode->type = DRM_MODE_TYPE_DRIVER | DRM_MODE_TYPE_PREFERRED;
++ connector->display_info.width_mm = mode->width_mm;
++ connector->display_info.height_mm = mode->height_mm;
++ drm_mode_probed_add(connector, mode);
++
++ return 1;
++}
++
++static const struct drm_panel_funcs jh057n_drm_funcs = {
++ .disable = jh057n_disable,
++ .unprepare = jh057n_unprepare,
++ .prepare = jh057n_prepare,
++ .enable = jh057n_enable,
++ .get_modes = jh057n_get_modes,
++};
++
++static int allpixelson_set(void *data, u64 val)
++{
++ struct jh057n *ctx = data;
++ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
++
++ DRM_DEV_DEBUG_DRIVER(ctx->dev, "Setting all pixels on\n");
++ dsi_generic_write_seq(dsi, ST7703_CMD_ALL_PIXEL_ON);
++ msleep(val * 1000);
++ /* Reset the panel to get video back */
++ drm_panel_disable(&ctx->panel);
++ drm_panel_unprepare(&ctx->panel);
++ drm_panel_prepare(&ctx->panel);
++ drm_panel_enable(&ctx->panel);
++
++ return 0;
++}
++
++DEFINE_SIMPLE_ATTRIBUTE(allpixelson_fops, NULL,
++ allpixelson_set, "%llu\n");
++
++static void jh057n_debugfs_init(struct jh057n *ctx)
++{
++ ctx->debugfs = debugfs_create_dir(DRV_NAME, NULL);
++
++ debugfs_create_file("allpixelson", 0600, ctx->debugfs, ctx,
++ &allpixelson_fops);
++}
++
++static void jh057n_debugfs_remove(struct jh057n *ctx)
++{
++ debugfs_remove_recursive(ctx->debugfs);
++ ctx->debugfs = NULL;
++}
++
++static int jh057n_probe(struct mipi_dsi_device *dsi)
++{
++ struct device *dev = &dsi->dev;
++ struct jh057n *ctx;
++ int ret;
++
++ ctx = devm_kzalloc(dev, sizeof(*ctx), GFP_KERNEL);
++ if (!ctx)
++ return -ENOMEM;
++
++ ctx->reset_gpio = devm_gpiod_get(dev, "reset", GPIOD_OUT_LOW);
++ if (IS_ERR(ctx->reset_gpio)) {
++ DRM_DEV_ERROR(dev, "cannot get reset gpio\n");
++ return PTR_ERR(ctx->reset_gpio);
++ }
++
++ mipi_dsi_set_drvdata(dsi, ctx);
++
++ ctx->dev = dev;
++
++ dsi->lanes = 4;
++ dsi->format = MIPI_DSI_FMT_RGB888;
++ dsi->mode_flags = MIPI_DSI_MODE_VIDEO |
++ MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
++
++ ctx->vcc = devm_regulator_get(dev, "vcc");
++ if (IS_ERR(ctx->vcc)) {
++ ret = PTR_ERR(ctx->vcc);
++ if (ret != -EPROBE_DEFER)
++ DRM_DEV_ERROR(dev,
++ "Failed to request vcc regulator: %d\n",
++ ret);
++ return ret;
++ }
++ ctx->iovcc = devm_regulator_get(dev, "iovcc");
++ if (IS_ERR(ctx->iovcc)) {
++ ret = PTR_ERR(ctx->iovcc);
++ if (ret != -EPROBE_DEFER)
++ DRM_DEV_ERROR(dev,
++ "Failed to request iovcc regulator: %d\n",
++ ret);
++ return ret;
++ }
++
++ drm_panel_init(&ctx->panel, dev, &jh057n_drm_funcs,
++ DRM_MODE_CONNECTOR_DSI);
++
++ ret = drm_panel_of_backlight(&ctx->panel);
++ if (ret)
++ return ret;
++
++ drm_panel_add(&ctx->panel);
++
++ ret = mipi_dsi_attach(dsi);
++ if (ret < 0) {
++ DRM_DEV_ERROR(dev,
++ "mipi_dsi_attach failed (%d). Is host ready?\n",
++ ret);
++ drm_panel_remove(&ctx->panel);
++ return ret;
++ }
++
++ DRM_DEV_INFO(dev, "%ux%u@%u %ubpp dsi %udl - ready\n",
++ default_mode.hdisplay, default_mode.vdisplay,
++ default_mode.vrefresh,
++ mipi_dsi_pixel_format_to_bpp(dsi->format), dsi->lanes);
++
++ jh057n_debugfs_init(ctx);
++ return 0;
++}
++
++static void jh057n_shutdown(struct mipi_dsi_device *dsi)
++{
++ struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
++ int ret;
++
++ ret = drm_panel_unprepare(&ctx->panel);
++ if (ret < 0)
++ DRM_DEV_ERROR(&dsi->dev, "Failed to unprepare panel: %d\n",
++ ret);
++
++ ret = drm_panel_disable(&ctx->panel);
++ if (ret < 0)
++ DRM_DEV_ERROR(&dsi->dev, "Failed to disable panel: %d\n",
++ ret);
++}
++
++static int jh057n_remove(struct mipi_dsi_device *dsi)
++{
++ struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
++ int ret;
++
++ jh057n_shutdown(dsi);
++
++ ret = mipi_dsi_detach(dsi);
++ if (ret < 0)
++ DRM_DEV_ERROR(&dsi->dev, "Failed to detach from DSI host: %d\n",
++ ret);
++
++ drm_panel_remove(&ctx->panel);
++
++ jh057n_debugfs_remove(ctx);
++
++ return 0;
++}
++
++static const struct of_device_id jh057n_of_match[] = {
++ { .compatible = "rocktech,jh057n00900" },
++ { /* sentinel */ }
++};
++MODULE_DEVICE_TABLE(of, jh057n_of_match);
++
++static struct mipi_dsi_driver jh057n_driver = {
++ .probe = jh057n_probe,
++ .remove = jh057n_remove,
++ .shutdown = jh057n_shutdown,
++ .driver = {
++ .name = DRV_NAME,
++ .of_match_table = jh057n_of_match,
++ },
++};
++module_mipi_dsi_driver(jh057n_driver);
++
++MODULE_AUTHOR("Guido Günther <agx@sigxcpu.org>");
++MODULE_DESCRIPTION("DRM driver for Rocktech JH057N00900 MIPI DSI panel");
++MODULE_LICENSE("GPL v2");
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch b/0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch
new file mode 100644
index 000000000..1cc38fcb1
--- /dev/null
+++ b/0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch
@@ -0,0 +1,251 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:57 +0200
+Subject: [PATCH] drm/panel: st7703: Add support for Xingbangda XBD599
+
+Xingbangda XBD599 is a 5.99" 720x1440 MIPI-DSI LCD panel used in
+PinePhone. Add support for it.
+
+Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 199 +++++++++++++++++-
+ 1 file changed, 197 insertions(+), 2 deletions(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index cdbf7dfb4dd4..33611419059a 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -39,10 +39,11 @@
+ #define ST7703_CMD_SETEXTC 0xB9
+ #define ST7703_CMD_SETMIPI 0xBA
+ #define ST7703_CMD_SETVDC 0xBC
+-#define ST7703_CMD_UNKNOWN0 0xBF
++#define ST7703_CMD_UNKNOWN_BF 0xBF
+ #define ST7703_CMD_SETSCR 0xC0
+ #define ST7703_CMD_SETPOWER 0xC1
+ #define ST7703_CMD_SETPANEL 0xCC
++#define ST7703_CMD_UNKNOWN_C6 0xC6
+ #define ST7703_CMD_SETGAMMA 0xE0
+ #define ST7703_CMD_SETEQ 0xE3
+ #define ST7703_CMD_SETGIP1 0xE9
+@@ -109,7 +110,7 @@ static int jh057n_init_sequence(struct st7703 *ctx)
+ msleep(20);
+
+ dsi_generic_write_seq(dsi, ST7703_CMD_SETVCOM, 0x3F, 0x3F);
+- dsi_generic_write_seq(dsi, ST7703_CMD_UNKNOWN0, 0x02, 0x11, 0x00);
++ dsi_generic_write_seq(dsi, ST7703_CMD_UNKNOWN_BF, 0x02, 0x11, 0x00);
+ dsi_generic_write_seq(dsi, ST7703_CMD_SETGIP1,
+ 0x82, 0x10, 0x06, 0x05, 0x9E, 0x0A, 0xA5, 0x12,
+ 0x31, 0x23, 0x37, 0x83, 0x04, 0xBC, 0x27, 0x38,
+@@ -163,6 +164,199 @@ struct st7703_panel_desc jh057n00900_panel_desc = {
+ .init_sequence = jh057n_init_sequence,
+ };
+
++#define dsi_dcs_write_seq(dsi, cmd, seq...) do { \
++ static const u8 d[] = { seq }; \
++ int ret; \
++ ret = mipi_dsi_dcs_write(dsi, cmd, d, ARRAY_SIZE(d)); \
++ if (ret < 0) \
++ return ret; \
++ } while (0)
++
++
++static int xbd599_init_sequence(struct st7703 *ctx)
++{
++ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
++
++ /*
++ * Init sequence was supplied by the panel vendor.
++ */
++
++ /* Magic sequence to unlock user commands below. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETEXTC, 0xF1, 0x12, 0x83);
++
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETMIPI,
++ 0x33, /* VC_main = 0, Lane_Number = 3 (4 lanes) */
++ 0x81, /* DSI_LDO_SEL = 1.7V, RTERM = 90 Ohm */
++ 0x05, /* IHSRX = x6 (Low High Speed driving ability) */
++ 0xF9, /* TX_CLK_SEL = fDSICLK/16 */
++ 0x0E, /* HFP_OSC (min. HFP number in DSI mode) */
++ 0x0E, /* HBP_OSC (min. HBP number in DSI mode) */
++ /* The rest is undocumented in ST7703 datasheet */
++ 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x44, 0x25, 0x00, 0x91, 0x0a, 0x00, 0x00, 0x02,
++ 0x4F, 0x11, 0x00, 0x00, 0x37);
++
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETPOWER_EXT,
++ 0x25, /* PCCS = 2, ECP_DC_DIV = 1/4 HSYNC */
++ 0x22, /* DT = 15ms XDK_ECP = x2 */
++ 0x20, /* PFM_DC_DIV = /1 */
++ 0x03 /* ECP_SYNC_EN = 1, VGX_SYNC_EN = 1 */);
++
++ /* RGB I/F porch timing */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETRGBIF,
++ 0x10, /* VBP_RGB_GEN */
++ 0x10, /* VFP_RGB_GEN */
++ 0x05, /* DE_BP_RGB_GEN */
++ 0x05, /* DE_FP_RGB_GEN */
++ /* The rest is undocumented in ST7703 datasheet */
++ 0x03, 0xFF,
++ 0x00, 0x00,
++ 0x00, 0x00);
++
++ /* Source driving settings. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETSCR,
++ 0x73, /* N_POPON */
++ 0x73, /* N_NOPON */
++ 0x50, /* I_POPON */
++ 0x50, /* I_NOPON */
++ 0x00, /* SCR[31,24] */
++ 0xC0, /* SCR[23,16] */
++ 0x08, /* SCR[15,8] */
++ 0x70, /* SCR[7,0] */
++ 0x00 /* Undocumented */);
++
++ /* NVDDD_SEL = -1.8V, VDDD_SEL = out of range (possibly 1.9V?) */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETVDC, 0x4E);
++
++ /*
++ * SS_PANEL = 1 (reverse scan), GS_PANEL = 0 (normal scan)
++ * REV_PANEL = 1 (normally black panel), BGR_PANEL = 1 (BGR)
++ */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETPANEL, 0x0B);
++
++ /* Zig-Zag Type C column inversion. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETCYC, 0x80);
++
++ /* Set display resolution. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETDISP,
++ 0xF0, /* NL = 240 */
++ 0x12, /* RES_V_LSB = 0, BLK_CON = VSSD,
++ * RESO_SEL = 720RGB
++ */
++ 0xF0 /* WHITE_GND_EN = 1 (GND),
++ * WHITE_FRAME_SEL = 7 frames,
++ * ISC = 0 frames
++ */);
++
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETEQ,
++ 0x00, /* PNOEQ */
++ 0x00, /* NNOEQ */
++ 0x0B, /* PEQGND */
++ 0x0B, /* NEQGND */
++ 0x10, /* PEQVCI */
++ 0x10, /* NEQVCI */
++ 0x00, /* PEQVCI1 */
++ 0x00, /* NEQVCI1 */
++ 0x00, /* reserved */
++ 0x00, /* reserved */
++ 0xFF, /* reserved */
++ 0x00, /* reserved */
++ 0xC0, /* ESD_DET_DATA_WHITE = 1, ESD_WHITE_EN = 1 */
++ 0x10 /* SLPIN_OPTION = 1 (no need vsync after sleep-in)
++ * VEDIO_NO_CHECK_EN = 0
++ * ESD_WHITE_GND_EN = 0
++ * ESD_DET_TIME_SEL = 0 frames
++ */);
++
++ /* Undocumented command. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_UNKNOWN_C6, 0x01, 0x00, 0xFF, 0xFF, 0x00);
++
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETPOWER,
++ 0x74, /* VBTHS, VBTLS: VGH = 17V, VBL = -11V */
++ 0x00, /* FBOFF_VGH = 0, FBOFF_VGL = 0 */
++ 0x32, /* VRP */
++ 0x32, /* VRN */
++ 0x77, /* reserved */
++ 0xF1, /* APS = 1 (small),
++ * VGL_DET_EN = 1, VGH_DET_EN = 1,
++ * VGL_TURBO = 1, VGH_TURBO = 1
++ */
++ 0xFF, /* VGH1_L_DIV, VGL1_L_DIV (1.5MHz) */
++ 0xFF, /* VGH1_R_DIV, VGL1_R_DIV (1.5MHz) */
++ 0xCC, /* VGH2_L_DIV, VGL2_L_DIV (2.6MHz) */
++ 0xCC, /* VGH2_R_DIV, VGL2_R_DIV (2.6MHz) */
++ 0x77, /* VGH3_L_DIV, VGL3_L_DIV (4.5MHz) */
++ 0x77 /* VGH3_R_DIV, VGL3_R_DIV (4.5MHz) */);
++
++ /* Reference voltage. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETBGP,
++ 0x07, /* VREF_SEL = 4.2V */
++ 0x07 /* NVREF_SEL = 4.2V */);
++
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETVCOM,
++ 0x2C, /* VCOMDC_F = -0.67V */
++ 0x2C /* VCOMDC_B = -0.67V */);
++
++ /* Undocumented command. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_UNKNOWN_BF, 0x02, 0x11, 0x00);
++
++ /* This command is to set forward GIP timing. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETGIP1,
++ 0x82, 0x10, 0x06, 0x05, 0xA2, 0x0A, 0xA5, 0x12,
++ 0x31, 0x23, 0x37, 0x83, 0x04, 0xBC, 0x27, 0x38,
++ 0x0C, 0x00, 0x03, 0x00, 0x00, 0x00, 0x0C, 0x00,
++ 0x03, 0x00, 0x00, 0x00, 0x75, 0x75, 0x31, 0x88,
++ 0x88, 0x88, 0x88, 0x88, 0x88, 0x13, 0x88, 0x64,
++ 0x64, 0x20, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
++ 0x02, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00);
++
++ /* This command is to set backward GIP timing. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETGIP2,
++ 0x02, 0x21, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x02, 0x46, 0x02, 0x88,
++ 0x88, 0x88, 0x88, 0x88, 0x88, 0x64, 0x88, 0x13,
++ 0x57, 0x13, 0x88, 0x88, 0x88, 0x88, 0x88, 0x88,
++ 0x75, 0x88, 0x23, 0x14, 0x00, 0x00, 0x02, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
++ 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x0A,
++ 0xA5, 0x00, 0x00, 0x00, 0x00);
++
++ /* Adjust the gamma characteristics of the panel. */
++ dsi_dcs_write_seq(dsi, ST7703_CMD_SETGAMMA,
++ 0x00, 0x09, 0x0D, 0x23, 0x27, 0x3C, 0x41, 0x35,
++ 0x07, 0x0D, 0x0E, 0x12, 0x13, 0x10, 0x12, 0x12,
++ 0x18, 0x00, 0x09, 0x0D, 0x23, 0x27, 0x3C, 0x41,
++ 0x35, 0x07, 0x0D, 0x0E, 0x12, 0x13, 0x10, 0x12,
++ 0x12, 0x18);
++
++ return 0;
++}
++
++static const struct drm_display_mode xbd599_mode = {
++ .hdisplay = 720,
++ .hsync_start = 720 + 40,
++ .hsync_end = 720 + 40 + 40,
++ .htotal = 720 + 40 + 40 + 40,
++ .vdisplay = 1440,
++ .vsync_start = 1440 + 18,
++ .vsync_end = 1440 + 18 + 10,
++ .vtotal = 1440 + 18 + 10 + 17,
++ .vrefresh = 60,
++ .clock = 69000,
++ .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
++ .width_mm = 68,
++ .height_mm = 136,
++};
++
++static const struct st7703_panel_desc xbd599_desc = {
++ .mode = &xbd599_mode,
++ .lanes = 4,
++ .mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
++ .format = MIPI_DSI_FMT_RGB888,
++ .init_sequence = xbd599_init_sequence,
++};
++
+ static int st7703_enable(struct drm_panel *panel)
+ {
+ struct st7703 *ctx = panel_to_st7703(panel);
+@@ -428,6 +622,7 @@ static int st7703_remove(struct mipi_dsi_device *dsi)
+
+ static const struct of_device_id st7703_of_match[] = {
+ { .compatible = "rocktech,jh057n00900", .data = &jh057n00900_panel_desc },
++ { .compatible = "xingbangda,xbd599", .data = &xbd599_desc },
+ { /* sentinel */ }
+ };
+ MODULE_DEVICE_TABLE(of, st7703_of_match);
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch b/0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch
new file mode 100644
index 000000000..045875f11
--- /dev/null
+++ b/0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch
@@ -0,0 +1,29 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:59 +0200
+Subject: [PATCH] drm/panel: st7703: Assert reset prior to powering down the
+ regulators
+
+The reset pin is inverted, so if we don't assert reset, the actual gpio
+will be high and may keep driving the IO port of the panel.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index e771281eb547..92930e127559 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -416,6 +416,7 @@ static int st7703_unprepare(struct drm_panel *panel)
+ if (!ctx->prepared)
+ return 0;
+
++ gpiod_set_value_cansleep(ctx->reset_gpio, 1);
+ regulator_disable(ctx->iovcc);
+ regulator_disable(ctx->vcc);
+ ctx->prepared = false;
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Enter-sleep-after-display-off.patch b/0001-drm-panel-st7703-Enter-sleep-after-display-off.patch
new file mode 100644
index 000000000..33e52fc94
--- /dev/null
+++ b/0001-drm-panel-st7703-Enter-sleep-after-display-off.patch
@@ -0,0 +1,41 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:58 +0200
+Subject: [PATCH] drm/panel: st7703: Enter sleep after display off
+
+The datasheet suggests to issue sleep in after display off
+as a part of the panel's shutdown sequence.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 13 ++++++++++++-
+ 1 file changed, 12 insertions(+), 1 deletion(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index 33611419059a..e771281eb547 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -394,8 +394,19 @@ static int st7703_disable(struct drm_panel *panel)
+ {
+ struct st7703 *ctx = panel_to_st7703(panel);
+ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
++ int ret;
++
++ ret = mipi_dsi_dcs_set_display_off(dsi);
++ if (ret < 0)
++ DRM_DEV_ERROR(ctx->dev,
++ "Failed to turn off the display: %d\n", ret);
+
+- return mipi_dsi_dcs_set_display_off(dsi);
++ ret = mipi_dsi_dcs_enter_sleep_mode(dsi);
++ if (ret < 0)
++ DRM_DEV_ERROR(ctx->dev,
++ "Failed to enter sleep mode: %d\n", ret);
++
++ return 0;
+ }
+
+ static int st7703_unprepare(struct drm_panel *panel)
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch b/0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch
new file mode 100644
index 000000000..c3ab19fa2
--- /dev/null
+++ b/0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch
@@ -0,0 +1,84 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:55 +0200
+Subject: [PATCH] drm/panel: st7703: Move code specific to jh057n closer
+ together
+
+It's better than having it spread around the driver.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 50 +++++++++----------
+ 1 file changed, 25 insertions(+), 25 deletions(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index 08cbc316266c..d03aab10cfef 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -153,6 +153,31 @@ static int jh057n_init_sequence(struct st7703 *ctx)
+ return 0;
+ }
+
++static const struct drm_display_mode jh057n00900_mode = {
++ .hdisplay = 720,
++ .hsync_start = 720 + 90,
++ .hsync_end = 720 + 90 + 20,
++ .htotal = 720 + 90 + 20 + 20,
++ .vdisplay = 1440,
++ .vsync_start = 1440 + 20,
++ .vsync_end = 1440 + 20 + 4,
++ .vtotal = 1440 + 20 + 4 + 12,
++ .vrefresh = 60,
++ .clock = 75276,
++ .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
++ .width_mm = 65,
++ .height_mm = 130,
++};
++
++struct st7703_panel_desc jh057n00900_panel_desc = {
++ .mode = &jh057n00900_mode,
++ .lanes = 4,
++ .mode_flags = MIPI_DSI_MODE_VIDEO |
++ MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
++ .format = MIPI_DSI_FMT_RGB888,
++ .init_sequence = jh057n_init_sequence,
++};
++
+ static int st7703_enable(struct drm_panel *panel)
+ {
+ struct st7703 *ctx = panel_to_st7703(panel);
+@@ -226,31 +251,6 @@ static int st7703_prepare(struct drm_panel *panel)
+ return ret;
+ }
+
+-static const struct drm_display_mode jh057n00900_mode = {
+- .hdisplay = 720,
+- .hsync_start = 720 + 90,
+- .hsync_end = 720 + 90 + 20,
+- .htotal = 720 + 90 + 20 + 20,
+- .vdisplay = 1440,
+- .vsync_start = 1440 + 20,
+- .vsync_end = 1440 + 20 + 4,
+- .vtotal = 1440 + 20 + 4 + 12,
+- .vrefresh = 60,
+- .clock = 75276,
+- .flags = DRM_MODE_FLAG_NHSYNC | DRM_MODE_FLAG_NVSYNC,
+- .width_mm = 65,
+- .height_mm = 130,
+-};
+-
+-struct st7703_panel_desc jh057n00900_panel_desc = {
+- .mode = &jh057n00900_mode,
+- .lanes = 4,
+- .mode_flags = MIPI_DSI_MODE_VIDEO |
+- MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
+- .format = MIPI_DSI_FMT_RGB888,
+- .init_sequence = jh057n_init_sequence,
+-};
+-
+ static int st7703_get_modes(struct drm_panel *panel,
+ struct drm_connector *connector)
+ {
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch b/0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch
new file mode 100644
index 000000000..81c622060
--- /dev/null
+++ b/0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch
@@ -0,0 +1,84 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:56 +0200
+Subject: [PATCH] drm/panel: st7703: Move generic part of init sequence to
+ enable callback
+
+Calling sleep out and display on is a controller specific part
+of the initialization process. Move it out of the panel specific
+initialization function to the enable callback.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 33 ++++++++++---------
+ 1 file changed, 18 insertions(+), 15 deletions(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index d03aab10cfef..cdbf7dfb4dd4 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -84,8 +84,6 @@ static inline struct st7703 *panel_to_st7703(struct drm_panel *panel)
+ static int jh057n_init_sequence(struct st7703 *ctx)
+ {
+ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+- struct device *dev = ctx->dev;
+- int ret;
+
+ /*
+ * Init sequence was supplied by the panel vendor. Most of the commands
+@@ -136,20 +134,7 @@ static int jh057n_init_sequence(struct st7703 *ctx)
+ 0x18, 0x00, 0x09, 0x0E, 0x29, 0x2D, 0x3C, 0x41,
+ 0x37, 0x07, 0x0B, 0x0D, 0x10, 0x11, 0x0F, 0x10,
+ 0x11, 0x18);
+- msleep(20);
+-
+- ret = mipi_dsi_dcs_exit_sleep_mode(dsi);
+- if (ret < 0) {
+- DRM_DEV_ERROR(dev, "Failed to exit sleep mode: %d\n", ret);
+- return ret;
+- }
+- /* Panel is operational 120 msec after reset */
+- msleep(60);
+- ret = mipi_dsi_dcs_set_display_on(dsi);
+- if (ret)
+- return ret;
+
+- DRM_DEV_DEBUG_DRIVER(dev, "Panel init sequence done\n");
+ return 0;
+ }
+
+@@ -181,6 +166,7 @@ struct st7703_panel_desc jh057n00900_panel_desc = {
+ static int st7703_enable(struct drm_panel *panel)
+ {
+ struct st7703 *ctx = panel_to_st7703(panel);
++ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+ int ret;
+
+ ret = ctx->desc->init_sequence(ctx);
+@@ -190,6 +176,23 @@ static int st7703_enable(struct drm_panel *panel)
+ return ret;
+ }
+
++ msleep(20);
++
++ ret = mipi_dsi_dcs_exit_sleep_mode(dsi);
++ if (ret < 0) {
++ DRM_DEV_ERROR(ctx->dev, "Failed to exit sleep mode: %d\n", ret);
++ return ret;
++ }
++
++ /* Panel is operational 120 msec after reset */
++ msleep(60);
++
++ ret = mipi_dsi_dcs_set_display_on(dsi);
++ if (ret)
++ return ret;
++
++ DRM_DEV_DEBUG_DRIVER(ctx->dev, "Panel init sequence done\n");
++
+ return 0;
+ }
+
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch b/0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch
new file mode 100644
index 000000000..94b181b0d
--- /dev/null
+++ b/0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch
@@ -0,0 +1,128 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:54 +0200
+Subject: [PATCH] drm/panel: st7703: Prepare for supporting multiple panels
+
+Parametrize the driver so that it can support more panels based
+on st7703 controller.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 43 +++++++++++++------
+ 1 file changed, 31 insertions(+), 12 deletions(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index 511af659f273..08cbc316266c 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -13,6 +13,7 @@
+ #include <linux/media-bus-format.h>
+ #include <linux/mod_devicetable.h>
+ #include <linux/module.h>
++#include <linux/of_device.h>
+ #include <linux/regulator/consumer.h>
+
+ #include <video/display_timing.h>
+@@ -56,6 +57,15 @@ struct st7703 {
+ bool prepared;
+
+ struct dentry *debugfs;
++ const struct st7703_panel_desc *desc;
++};
++
++struct st7703_panel_desc {
++ const struct drm_display_mode *mode;
++ unsigned int lanes;
++ unsigned long mode_flags;
++ enum mipi_dsi_pixel_format format;
++ int (*init_sequence)(struct st7703 *ctx);
+ };
+
+ static inline struct st7703 *panel_to_st7703(struct drm_panel *panel)
+@@ -148,7 +158,7 @@ static int st7703_enable(struct drm_panel *panel)
+ struct st7703 *ctx = panel_to_st7703(panel);
+ int ret;
+
+- ret = jh057n_init_sequence(ctx);
++ ret = ctx->desc->init_sequence(ctx);
+ if (ret < 0) {
+ DRM_DEV_ERROR(ctx->dev, "Panel init sequence failed: %d\n",
+ ret);
+@@ -216,7 +226,7 @@ static int st7703_prepare(struct drm_panel *panel)
+ return ret;
+ }
+
+-static const struct drm_display_mode default_mode = {
++static const struct drm_display_mode jh057n00900_mode = {
+ .hdisplay = 720,
+ .hsync_start = 720 + 90,
+ .hsync_end = 720 + 90 + 20,
+@@ -232,17 +242,26 @@ static const struct drm_display_mode default_mode = {
+ .height_mm = 130,
+ };
+
++struct st7703_panel_desc jh057n00900_panel_desc = {
++ .mode = &jh057n00900_mode,
++ .lanes = 4,
++ .mode_flags = MIPI_DSI_MODE_VIDEO |
++ MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE,
++ .format = MIPI_DSI_FMT_RGB888,
++ .init_sequence = jh057n_init_sequence,
++};
++
+ static int st7703_get_modes(struct drm_panel *panel,
+ struct drm_connector *connector)
+ {
+ struct st7703 *ctx = panel_to_st7703(panel);
+ struct drm_display_mode *mode;
+
+- mode = drm_mode_duplicate(connector->dev, &default_mode);
++ mode = drm_mode_duplicate(connector->dev, ctx->desc->mode);
+ if (!mode) {
+ DRM_DEV_ERROR(ctx->dev, "Failed to add mode %ux%u@%u\n",
+- default_mode.hdisplay, default_mode.vdisplay,
+- default_mode.vrefresh);
++ ctx->desc->mode->hdisplay, ctx->desc->mode->vdisplay,
++ ctx->desc->mode->vrefresh);
+ return -ENOMEM;
+ }
+
+@@ -317,11 +336,11 @@ static int st7703_probe(struct mipi_dsi_device *dsi)
+ mipi_dsi_set_drvdata(dsi, ctx);
+
+ ctx->dev = dev;
++ ctx->desc = of_device_get_match_data(dev);
+
+- dsi->lanes = 4;
+- dsi->format = MIPI_DSI_FMT_RGB888;
+- dsi->mode_flags = MIPI_DSI_MODE_VIDEO |
+- MIPI_DSI_MODE_VIDEO_BURST | MIPI_DSI_MODE_VIDEO_SYNC_PULSE;
++ dsi->mode_flags = ctx->desc->mode_flags;
++ dsi->format = ctx->desc->format;
++ dsi->lanes = ctx->desc->lanes;
+
+ ctx->vcc = devm_regulator_get(dev, "vcc");
+ if (IS_ERR(ctx->vcc)) {
+@@ -361,8 +380,8 @@ static int st7703_probe(struct mipi_dsi_device *dsi)
+ }
+
+ DRM_DEV_INFO(dev, "%ux%u@%u %ubpp dsi %udl - ready\n",
+- default_mode.hdisplay, default_mode.vdisplay,
+- default_mode.vrefresh,
++ ctx->desc->mode->hdisplay, ctx->desc->mode->vdisplay,
++ ctx->desc->mode->vrefresh,
+ mipi_dsi_pixel_format_to_bpp(dsi->format), dsi->lanes);
+
+ st7703_debugfs_init(ctx);
+@@ -405,7 +424,7 @@ static int st7703_remove(struct mipi_dsi_device *dsi)
+ }
+
+ static const struct of_device_id st7703_of_match[] = {
+- { .compatible = "rocktech,jh057n00900" },
++ { .compatible = "rocktech,jh057n00900", .data = &jh057n00900_panel_desc },
+ { /* sentinel */ }
+ };
+ MODULE_DEVICE_TABLE(of, st7703_of_match);
+--
+2.26.2
+
diff --git a/0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch b/0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch
new file mode 100644
index 000000000..1d17d147e
--- /dev/null
+++ b/0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch
@@ -0,0 +1,265 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:53 +0200
+Subject: [PATCH] drm/panel: st7703: Rename functions from jh057n prefix to
+ st7703
+
+This is done so that code that's not specific to a particular
+jh057n panel is named after the controller. Functions specific
+to the panel are kept named after the panel.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ drivers/gpu/drm/panel/panel-sitronix-st7703.c | 90 ++++++++++---------
+ 1 file changed, 46 insertions(+), 44 deletions(-)
+
+diff --git a/drivers/gpu/drm/panel/panel-sitronix-st7703.c b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+index 38ff742bc120..511af659f273 100644
+--- a/drivers/gpu/drm/panel/panel-sitronix-st7703.c
++++ b/drivers/gpu/drm/panel/panel-sitronix-st7703.c
+@@ -1,6 +1,8 @@
+ // SPDX-License-Identifier: GPL-2.0
+ /*
+- * Rockteck jh057n00900 5.5" MIPI-DSI panel driver
++ * Driver for panels based on Sitronix ST7703 controller, souch as:
++ *
++ * - Rocktech jh057n00900 5.5" MIPI-DSI panel
+ *
+ * Copyright (C) Purism SPC 2019
+ */
+@@ -21,7 +23,7 @@
+ #include <drm/drm_panel.h>
+ #include <drm/drm_print.h>
+
+-#define DRV_NAME "panel-rocktech-jh057n00900"
++#define DRV_NAME "panel-sitronix-st7703"
+
+ /* Manufacturer specific Commands send via DSI */
+ #define ST7703_CMD_ALL_PIXEL_OFF 0x22
+@@ -45,7 +47,7 @@
+ #define ST7703_CMD_SETGIP1 0xE9
+ #define ST7703_CMD_SETGIP2 0xEA
+
+-struct jh057n {
++struct st7703 {
+ struct device *dev;
+ struct drm_panel panel;
+ struct gpio_desc *reset_gpio;
+@@ -56,9 +58,9 @@ struct jh057n {
+ struct dentry *debugfs;
+ };
+
+-static inline struct jh057n *panel_to_jh057n(struct drm_panel *panel)
++static inline struct st7703 *panel_to_st7703(struct drm_panel *panel)
+ {
+- return container_of(panel, struct jh057n, panel);
++ return container_of(panel, struct st7703, panel);
+ }
+
+ #define dsi_generic_write_seq(dsi, seq...) do { \
+@@ -69,7 +71,7 @@ static inline struct jh057n *panel_to_jh057n(struct drm_panel *panel)
+ return ret; \
+ } while (0)
+
+-static int jh057n_init_sequence(struct jh057n *ctx)
++static int jh057n_init_sequence(struct st7703 *ctx)
+ {
+ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+ struct device *dev = ctx->dev;
+@@ -141,9 +143,9 @@ static int jh057n_init_sequence(struct jh057n *ctx)
+ return 0;
+ }
+
+-static int jh057n_enable(struct drm_panel *panel)
++static int st7703_enable(struct drm_panel *panel)
+ {
+- struct jh057n *ctx = panel_to_jh057n(panel);
++ struct st7703 *ctx = panel_to_st7703(panel);
+ int ret;
+
+ ret = jh057n_init_sequence(ctx);
+@@ -156,17 +158,17 @@ static int jh057n_enable(struct drm_panel *panel)
+ return 0;
+ }
+
+-static int jh057n_disable(struct drm_panel *panel)
++static int st7703_disable(struct drm_panel *panel)
+ {
+- struct jh057n *ctx = panel_to_jh057n(panel);
++ struct st7703 *ctx = panel_to_st7703(panel);
+ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+
+ return mipi_dsi_dcs_set_display_off(dsi);
+ }
+
+-static int jh057n_unprepare(struct drm_panel *panel)
++static int st7703_unprepare(struct drm_panel *panel)
+ {
+- struct jh057n *ctx = panel_to_jh057n(panel);
++ struct st7703 *ctx = panel_to_st7703(panel);
+
+ if (!ctx->prepared)
+ return 0;
+@@ -178,9 +180,9 @@ static int jh057n_unprepare(struct drm_panel *panel)
+ return 0;
+ }
+
+-static int jh057n_prepare(struct drm_panel *panel)
++static int st7703_prepare(struct drm_panel *panel)
+ {
+- struct jh057n *ctx = panel_to_jh057n(panel);
++ struct st7703 *ctx = panel_to_st7703(panel);
+ int ret;
+
+ if (ctx->prepared)
+@@ -230,10 +232,10 @@ static const struct drm_display_mode default_mode = {
+ .height_mm = 130,
+ };
+
+-static int jh057n_get_modes(struct drm_panel *panel,
++static int st7703_get_modes(struct drm_panel *panel,
+ struct drm_connector *connector)
+ {
+- struct jh057n *ctx = panel_to_jh057n(panel);
++ struct st7703 *ctx = panel_to_st7703(panel);
+ struct drm_display_mode *mode;
+
+ mode = drm_mode_duplicate(connector->dev, &default_mode);
+@@ -254,17 +256,17 @@ static int jh057n_get_modes(struct drm_panel *panel,
+ return 1;
+ }
+
+-static const struct drm_panel_funcs jh057n_drm_funcs = {
+- .disable = jh057n_disable,
+- .unprepare = jh057n_unprepare,
+- .prepare = jh057n_prepare,
+- .enable = jh057n_enable,
+- .get_modes = jh057n_get_modes,
++static const struct drm_panel_funcs st7703_drm_funcs = {
++ .disable = st7703_disable,
++ .unprepare = st7703_unprepare,
++ .prepare = st7703_prepare,
++ .enable = st7703_enable,
++ .get_modes = st7703_get_modes,
+ };
+
+ static int allpixelson_set(void *data, u64 val)
+ {
+- struct jh057n *ctx = data;
++ struct st7703 *ctx = data;
+ struct mipi_dsi_device *dsi = to_mipi_dsi_device(ctx->dev);
+
+ DRM_DEV_DEBUG_DRIVER(ctx->dev, "Setting all pixels on\n");
+@@ -282,7 +284,7 @@ static int allpixelson_set(void *data, u64 val)
+ DEFINE_SIMPLE_ATTRIBUTE(allpixelson_fops, NULL,
+ allpixelson_set, "%llu\n");
+
+-static void jh057n_debugfs_init(struct jh057n *ctx)
++static void st7703_debugfs_init(struct st7703 *ctx)
+ {
+ ctx->debugfs = debugfs_create_dir(DRV_NAME, NULL);
+
+@@ -290,16 +292,16 @@ static void jh057n_debugfs_init(struct jh057n *ctx)
+ &allpixelson_fops);
+ }
+
+-static void jh057n_debugfs_remove(struct jh057n *ctx)
++static void st7703_debugfs_remove(struct st7703 *ctx)
+ {
+ debugfs_remove_recursive(ctx->debugfs);
+ ctx->debugfs = NULL;
+ }
+
+-static int jh057n_probe(struct mipi_dsi_device *dsi)
++static int st7703_probe(struct mipi_dsi_device *dsi)
+ {
+ struct device *dev = &dsi->dev;
+- struct jh057n *ctx;
++ struct st7703 *ctx;
+ int ret;
+
+ ctx = devm_kzalloc(dev, sizeof(*ctx), GFP_KERNEL);
+@@ -340,7 +342,7 @@ static int jh057n_probe(struct mipi_dsi_device *dsi)
+ return ret;
+ }
+
+- drm_panel_init(&ctx->panel, dev, &jh057n_drm_funcs,
++ drm_panel_init(&ctx->panel, dev, &st7703_drm_funcs,
+ DRM_MODE_CONNECTOR_DSI);
+
+ ret = drm_panel_of_backlight(&ctx->panel);
+@@ -363,13 +365,13 @@ static int jh057n_probe(struct mipi_dsi_device *dsi)
+ default_mode.vrefresh,
+ mipi_dsi_pixel_format_to_bpp(dsi->format), dsi->lanes);
+
+- jh057n_debugfs_init(ctx);
++ st7703_debugfs_init(ctx);
+ return 0;
+ }
+
+-static void jh057n_shutdown(struct mipi_dsi_device *dsi)
++static void st7703_shutdown(struct mipi_dsi_device *dsi)
+ {
+- struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
++ struct st7703 *ctx = mipi_dsi_get_drvdata(dsi);
+ int ret;
+
+ ret = drm_panel_unprepare(&ctx->panel);
+@@ -383,12 +385,12 @@ static void jh057n_shutdown(struct mipi_dsi_device *dsi)
+ ret);
+ }
+
+-static int jh057n_remove(struct mipi_dsi_device *dsi)
++static int st7703_remove(struct mipi_dsi_device *dsi)
+ {
+- struct jh057n *ctx = mipi_dsi_get_drvdata(dsi);
++ struct st7703 *ctx = mipi_dsi_get_drvdata(dsi);
+ int ret;
+
+- jh057n_shutdown(dsi);
++ st7703_shutdown(dsi);
+
+ ret = mipi_dsi_detach(dsi);
+ if (ret < 0)
+@@ -397,28 +399,28 @@ static int jh057n_remove(struct mipi_dsi_device *dsi)
+
+ drm_panel_remove(&ctx->panel);
+
+- jh057n_debugfs_remove(ctx);
++ st7703_debugfs_remove(ctx);
+
+ return 0;
+ }
+
+-static const struct of_device_id jh057n_of_match[] = {
++static const struct of_device_id st7703_of_match[] = {
+ { .compatible = "rocktech,jh057n00900" },
+ { /* sentinel */ }
+ };
+-MODULE_DEVICE_TABLE(of, jh057n_of_match);
++MODULE_DEVICE_TABLE(of, st7703_of_match);
+
+-static struct mipi_dsi_driver jh057n_driver = {
+- .probe = jh057n_probe,
+- .remove = jh057n_remove,
+- .shutdown = jh057n_shutdown,
++static struct mipi_dsi_driver st7703_driver = {
++ .probe = st7703_probe,
++ .remove = st7703_remove,
++ .shutdown = st7703_shutdown,
+ .driver = {
+ .name = DRV_NAME,
+- .of_match_table = jh057n_of_match,
++ .of_match_table = st7703_of_match,
+ },
+ };
+-module_mipi_dsi_driver(jh057n_driver);
++module_mipi_dsi_driver(st7703_driver);
+
+ MODULE_AUTHOR("Guido Günther <agx@sigxcpu.org>");
+-MODULE_DESCRIPTION("DRM driver for Rocktech JH057N00900 MIPI DSI panel");
++MODULE_DESCRIPTION("DRM driver for Sitronix ST7703 based MIPI DSI panels");
+ MODULE_LICENSE("GPL v2");
+--
+2.26.2
+
diff --git a/0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch b/0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch
new file mode 100644
index 000000000..74906d9b1
--- /dev/null
+++ b/0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch
@@ -0,0 +1,37 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:51 +0200
+Subject: [PATCH] dt-bindings: panel: Add compatible for Xingbangda XBD599
+ panel
+
+Xingbangda XBD599 is a 5.99" 720x1440 MIPI-DSI LCD panel. It is based on
+Sitronix ST7703 LCD controller just like rocktech,jh057n00900. It is
+used in PinePhone.
+
+Add a compatible for it.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ .../bindings/display/panel/rocktech,jh057n00900.yaml | 6 +++++-
+ 1 file changed, 5 insertions(+), 1 deletion(-)
+
+diff --git a/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml b/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
+index f97c48550741..4d43a1b36d7c 100644
+--- a/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
++++ b/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
+@@ -18,7 +18,11 @@ allOf:
+
+ properties:
+ compatible:
+- const: rocktech,jh057n00900
++ enum:
++ # Rocktech JH057N00900 5.5" 720x1440 TFT LCD panel
++ - rocktech,jh057n00900
++ # Xingbangda XBD599 5.99" 720x1440 TFT LCD panel
++ - xingbangda,xbd599
+
+ reg:
+ maxItems: 1
+--
+2.26.2
+
diff --git a/0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch b/0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch
new file mode 100644
index 000000000..0aaf4a92a
--- /dev/null
+++ b/0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch
@@ -0,0 +1,119 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Ondrej Jirman <megous@megous.com>
+Date: Fri, 26 Jun 2020 02:55:50 +0200
+Subject: [PATCH] dt-bindings: panel: Convert rocktech, jh057n00900 to yaml
+
+Convert Rocktech MIPI DSI panel driver from txt to yaml bindings.
+
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+---
+ .../display/panel/rocktech,jh057n00900.txt | 23 -------
+ .../display/panel/rocktech,jh057n00900.yaml | 66 +++++++++++++++++++
+ 2 files changed, 66 insertions(+), 23 deletions(-)
+ delete mode 100644 Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.txt
+ create mode 100644 Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
+
+diff --git a/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.txt b/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.txt
+deleted file mode 100644
+index a372c5d84695..000000000000
+--- a/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.txt
++++ /dev/null
+@@ -1,23 +0,0 @@
+-Rocktech jh057n00900 5.5" 720x1440 TFT LCD panel
+-
+-Required properties:
+-- compatible: should be "rocktech,jh057n00900"
+-- reg: DSI virtual channel of the peripheral
+-- reset-gpios: panel reset gpio
+-- backlight: phandle of the backlight device attached to the panel
+-- vcc-supply: phandle of the regulator that provides the vcc supply voltage.
+-- iovcc-supply: phandle of the regulator that provides the iovcc supply
+- voltage.
+-
+-Example:
+-
+- &mipi_dsi {
+- panel@0 {
+- compatible = "rocktech,jh057n00900";
+- reg = <0>;
+- backlight = <&backlight>;
+- reset-gpios = <&gpio3 13 GPIO_ACTIVE_LOW>;
+- vcc-supply = <&reg_2v8_p>;
+- iovcc-supply = <&reg_1v8_p>;
+- };
+- };
+diff --git a/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml b/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
+new file mode 100644
+index 000000000000..f97c48550741
+--- /dev/null
++++ b/Documentation/devicetree/bindings/display/panel/rocktech,jh057n00900.yaml
+@@ -0,0 +1,66 @@
++# SPDX-License-Identifier: (GPL-2.0-only or BSD-2-Clause)
++%YAML 1.2
++---
++$id: http://devicetree.org/schemas/display/panel/rocktech,jh057n00900.yaml#
++$schema: http://devicetree.org/meta-schemas/core.yaml#
++
++title: Rocktech JH057N00900 5.5" 720x1440 TFT LCD panel
++
++maintainers:
++ - Ondrej Jirman <megi@xff.cz>
++
++description: |
++ Rocktech JH057N00900 is a 720x1440 TFT LCD panel
++ connected using a MIPI-DSI video interface.
++
++allOf:
++ - $ref: panel-common.yaml#
++
++properties:
++ compatible:
++ const: rocktech,jh057n00900
++
++ reg:
++ maxItems: 1
++ description: DSI virtual channel
++
++ vcc-supply:
++ description: Panel power supply
++
++ vccio-supply:
++ description: I/O voltage supply
++
++ reset-gpios:
++ description: GPIO used for the reset pin
++ maxItems: 1
++
++ backlight:
++ description: Backlight used by the panel
++ $ref: "/schemas/types.yaml#/definitions/phandle"
++
++required:
++ - compatible
++ - reg
++ - vcc-supply
++ - vccio-supply
++ - reset-gpios
++
++additionalProperties: false
++
++examples:
++ - |
++ #include <dt-bindings/gpio/gpio.h>
++
++ dsi {
++ #address-cells = <1>;
++ #size-cells = <0>;
++ panel@0 {
++ compatible = "rocktech,jh057n00900";
++ reg = <0>;
++ vcc-supply = <&reg_2v8_p>;
++ iovcc-supply = <&reg_1v8_p>;
++ reset-gpios = <&gpio3 13 GPIO_ACTIVE_LOW>;
++ backlight = <&backlight>;
++ };
++ };
++...
+--
+2.26.2
+
diff --git a/0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch b/0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch
new file mode 100644
index 000000000..65dad5c77
--- /dev/null
+++ b/0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch
@@ -0,0 +1,33 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Icenowy Zheng <icenowy@aosc.io>
+Date: Fri, 26 Jun 2020 02:55:49 +0200
+Subject: [PATCH] dt-bindings: vendor-prefixes: Add Xingbangda
+
+Shenzhen Xingbangda Display Technology Co., Ltd is a company which
+produces LCD modules. It supplies the LCD panels for the PinePhone.
+
+Add the vendor prefix of it.
+
+Signed-off-by: Icenowy Zheng <icenowy@aosc.io>
+Signed-off-by: Ondrej Jirman <megous@megous.com>
+Acked-by: Rob Herring <robh@kernel.org>
+---
+ Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
+index 9aeab66be85f..740b116b179f 100644
+--- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
++++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
+@@ -1157,6 +1157,8 @@ patternProperties:
+ description: Xiaomi Technology Co., Ltd.
+ "^xillybus,.*":
+ description: Xillybus Ltd.
++ "^xingbangda,.*":
++ description: Shenzhen Xingbangda Display Technology Co., Ltd
+ "^xinpeng,.*":
+ description: Shenzhen Xinpeng Technology Co., Ltd
+ "^xlnx,.*":
+--
+2.26.2
+
diff --git a/0001-put-RHEL-info-into-generated-headers.patch b/0001-put-RHEL-info-into-generated-headers.patch
index 85f0f63e7..d1a9195bd 100644
--- a/0001-put-RHEL-info-into-generated-headers.patch
+++ b/0001-put-RHEL-info-into-generated-headers.patch
@@ -59,7 +59,7 @@ Acked-by: Prarit Bhargava <prarit@redhat.com>
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/Makefile b/Makefile
-index fe0164a654c7..45081a0c4dcc 100644
+index 0b5f8538bde5..09639e0e075f 100644
--- a/Makefile
+++ b/Makefile
@@ -1217,7 +1217,13 @@ endef
diff --git a/0001-selinux-allow-reading-labels-before-policy-is-loaded.patch b/0001-selinux-allow-reading-labels-before-policy-is-loaded.patch
new file mode 100644
index 000000000..5c2384cd6
--- /dev/null
+++ b/0001-selinux-allow-reading-labels-before-policy-is-loaded.patch
@@ -0,0 +1,49 @@
+From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
+From: Jonathan Lebon <jlebon@redhat.com>
+Date: Thu, 28 May 2020 10:39:40 -0400
+Subject: [PATCH] selinux: allow reading labels before policy is loaded
+
+This patch does for `getxattr` what commit 3e3e24b42043 ("selinux: allow
+labeling before policy is loaded") did for `setxattr`; it allows
+querying the current SELinux label on disk before the policy is loaded.
+
+One of the motivations described in that commit message also drives this
+patch: for Fedora CoreOS (and eventually RHEL CoreOS), we want to be
+able to move the root filesystem for example, from xfs to ext4 on RAID,
+on first boot, at initrd time.[1]
+
+Because such an operation works at the filesystem level, we need to be
+able to read the SELinux labels first from the original root, and apply
+them to the files of the new root. The previous commit enabled the
+second part of this process; this commit enables the first part.
+
+[1] https://github.com/coreos/fedora-coreos-tracker/issues/94
+
+Acked-by: Stephen Smalley <stephen.smalley.work@gmail.com>
+Signed-off-by: Jonathan Lebon <jlebon@redhat.com>
+Signed-off-by: Paul Moore <paul@paul-moore.com>
+---
+ security/selinux/hooks.c | 7 ++++++-
+ 1 file changed, 6 insertions(+), 1 deletion(-)
+
+diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c
+index efa6108b1ce9..ca901025802a 100644
+--- a/security/selinux/hooks.c
++++ b/security/selinux/hooks.c
+@@ -3332,7 +3332,12 @@ static int selinux_inode_getsecurity(struct inode *inode, const char *name, void
+ char *context = NULL;
+ struct inode_security_struct *isec;
+
+- if (strcmp(name, XATTR_SELINUX_SUFFIX))
++ /*
++ * If we're not initialized yet, then we can't validate contexts, so
++ * just let vfs_getxattr fall back to using the on-disk xattr.
++ */
++ if (!selinux_initialized(&selinux_state) ||
++ strcmp(name, XATTR_SELINUX_SUFFIX))
+ return -EOPNOTSUPP;
+
+ /*
+--
+2.26.2
+
diff --git a/Patchlist b/Patchlist
index 4b23af27f..5f96b327b 100644
--- a/Patchlist
+++ b/Patchlist
@@ -77,3 +77,22 @@
0001-virt-vbox-Log-unknown-ioctl-requests-as-error.patch
0001-PCI-tegra-Revert-raw_violation_fixup-for-tegra124.patch
0001-redhat-Replace-hardware.redhat.com-link-in-Unsupport.patch
+0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch
+0001-selinux-allow-reading-labels-before-policy-is-loaded.patch
+0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch
+0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch
+0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch
+0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch
+0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch
+0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch
+0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch
+0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch
+0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch
+0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch
+0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch
+0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch
+0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch
+0001-drm-panel-st7703-Enter-sleep-after-display-off.patch
+0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch
+0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch
+0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch
diff --git a/kernel-aarch64-debug-fedora.config b/kernel-aarch64-debug-fedora.config
index 86df66076..dc26af4c3 100644
--- a/kernel-aarch64-debug-fedora.config
+++ b/kernel-aarch64-debug-fedora.config
@@ -1659,6 +1659,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1667,7 +1668,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA=m
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-CONFIG_DRM_PANEL_XINGBANGDA_XBD599=m
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -5980,7 +5980,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
CONFIG_SERIAL_QCOM_GENI_CONSOLE=y
CONFIG_SERIAL_QCOM_GENI=y
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-aarch64-fedora.config b/kernel-aarch64-fedora.config
index fe25b496c..afb0e3f83 100644
--- a/kernel-aarch64-fedora.config
+++ b/kernel-aarch64-fedora.config
@@ -1651,6 +1651,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1659,7 +1660,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA=m
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-CONFIG_DRM_PANEL_XINGBANGDA_XBD599=m
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -5961,7 +5961,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
CONFIG_SERIAL_QCOM_GENI_CONSOLE=y
CONFIG_SERIAL_QCOM_GENI=y
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-armv7hl-debug-fedora.config b/kernel-armv7hl-debug-fedora.config
index a7b430a57..85e4297d3 100644
--- a/kernel-armv7hl-debug-fedora.config
+++ b/kernel-armv7hl-debug-fedora.config
@@ -1693,6 +1693,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1701,7 +1702,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -6127,7 +6127,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
# CONFIG_SERIAL_RP2 is not set
CONFIG_SERIAL_SAMSUNG_CONSOLE=y
CONFIG_SERIAL_SAMSUNG=y
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-armv7hl-fedora.config b/kernel-armv7hl-fedora.config
index 7de01847a..daa62c09f 100644
--- a/kernel-armv7hl-fedora.config
+++ b/kernel-armv7hl-fedora.config
@@ -1686,6 +1686,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1694,7 +1695,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -6109,7 +6109,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
# CONFIG_SERIAL_RP2 is not set
CONFIG_SERIAL_SAMSUNG_CONSOLE=y
CONFIG_SERIAL_SAMSUNG=y
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-armv7hl-lpae-debug-fedora.config b/kernel-armv7hl-lpae-debug-fedora.config
index f3161ac35..85edf374f 100644
--- a/kernel-armv7hl-lpae-debug-fedora.config
+++ b/kernel-armv7hl-lpae-debug-fedora.config
@@ -1648,6 +1648,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1656,7 +1657,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -5939,7 +5939,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
# CONFIG_SERIAL_RP2 is not set
CONFIG_SERIAL_SAMSUNG_CONSOLE=y
CONFIG_SERIAL_SAMSUNG=y
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-armv7hl-lpae-fedora.config b/kernel-armv7hl-lpae-fedora.config
index 766dce6ef..8e17a8a0b 100644
--- a/kernel-armv7hl-lpae-fedora.config
+++ b/kernel-armv7hl-lpae-fedora.config
@@ -1641,6 +1641,7 @@ CONFIG_DRM_PANEL_SHARP_LQ101R1SX01=m
CONFIG_DRM_PANEL_SHARP_LS043T1LE01=m
CONFIG_DRM_PANEL_SIMPLE=m
CONFIG_DRM_PANEL_SITRONIX_ST7701=m
+CONFIG_DRM_PANEL_SITRONIX_ST7703=m
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1649,7 +1650,6 @@ CONFIG_DRM_PANEL_SITRONIX_ST7701=m
CONFIG_DRM_PANEL_TPO_TPG110=m
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
CONFIG_DRM_PANFROST=m
@@ -5921,7 +5921,9 @@ CONFIG_SERIAL_OF_PLATFORM=y
# CONFIG_SERIAL_RP2 is not set
CONFIG_SERIAL_SAMSUNG_CONSOLE=y
CONFIG_SERIAL_SAMSUNG=y
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-i686-debug-fedora.config b/kernel-i686-debug-fedora.config
index df0a71a5f..409bb6c34 100644
--- a/kernel-i686-debug-fedora.config
+++ b/kernel-i686-debug-fedora.config
@@ -1401,6 +1401,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1409,7 +1410,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5415,7 +5415,9 @@ CONFIG_SERIAL_NONSTANDARD=y
CONFIG_SERIAL_OF_PLATFORM=m
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-i686-fedora.config b/kernel-i686-fedora.config
index df558becb..49a017368 100644
--- a/kernel-i686-fedora.config
+++ b/kernel-i686-fedora.config
@@ -1392,6 +1392,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1400,7 +1401,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5396,7 +5396,9 @@ CONFIG_SERIAL_NONSTANDARD=y
CONFIG_SERIAL_OF_PLATFORM=m
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-ppc64le-debug-fedora.config b/kernel-ppc64le-debug-fedora.config
index fe22919a9..f8c58aee3 100644
--- a/kernel-ppc64le-debug-fedora.config
+++ b/kernel-ppc64le-debug-fedora.config
@@ -1293,6 +1293,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1301,7 +1302,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5075,7 +5075,9 @@ CONFIG_SERIAL_NONSTANDARD=y
CONFIG_SERIAL_OF_PLATFORM=m
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-ppc64le-fedora.config b/kernel-ppc64le-fedora.config
index f33b6cfd7..5c4a5d2c1 100644
--- a/kernel-ppc64le-fedora.config
+++ b/kernel-ppc64le-fedora.config
@@ -1284,6 +1284,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1292,7 +1293,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5055,7 +5055,9 @@ CONFIG_SERIAL_NONSTANDARD=y
CONFIG_SERIAL_OF_PLATFORM=m
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-s390x-debug-fedora.config b/kernel-s390x-debug-fedora.config
index d68992b61..9e1c36f21 100644
--- a/kernel-s390x-debug-fedora.config
+++ b/kernel-s390x-debug-fedora.config
@@ -1300,6 +1300,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1308,7 +1309,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5020,7 +5020,9 @@ CONFIG_SERIAL_JSM=m
# CONFIG_SERIAL_NONSTANDARD is not set
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-s390x-fedora.config b/kernel-s390x-fedora.config
index 9d8c8faa0..5b08403c6 100644
--- a/kernel-s390x-fedora.config
+++ b/kernel-s390x-fedora.config
@@ -1291,6 +1291,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1299,7 +1300,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5000,7 +5000,9 @@ CONFIG_SERIAL_JSM=m
# CONFIG_SERIAL_NONSTANDARD is not set
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-x86_64-debug-fedora.config b/kernel-x86_64-debug-fedora.config
index a3f4205dd..2b81e82cb 100644
--- a/kernel-x86_64-debug-fedora.config
+++ b/kernel-x86_64-debug-fedora.config
@@ -1437,6 +1437,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1445,7 +1446,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5457,7 +5457,9 @@ CONFIG_SERIAL_LANTIQ=m
CONFIG_SERIAL_NONSTANDARD=y
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel-x86_64-fedora.config b/kernel-x86_64-fedora.config
index ce5d53732..d867d6920 100644
--- a/kernel-x86_64-fedora.config
+++ b/kernel-x86_64-fedora.config
@@ -1428,6 +1428,7 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_SHARP_LS043T1LE01 is not set
# CONFIG_DRM_PANEL_SIMPLE is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7701 is not set
+# CONFIG_DRM_PANEL_SITRONIX_ST7703 is not set
# CONFIG_DRM_PANEL_SITRONIX_ST7789V is not set
# CONFIG_DRM_PANEL_SONY_ACX424AKP is not set
# CONFIG_DRM_PANEL_SONY_ACX565AKM is not set
@@ -1436,7 +1437,6 @@ CONFIG_DRM_PANEL_SEIKO_43WVF1G=m
# CONFIG_DRM_PANEL_TPO_TPG110 is not set
# CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA is not set
CONFIG_DRM_PANEL_VISIONOX_RM69299=m
-# CONFIG_DRM_PANEL_XINGBANGDA_XBD599 is not set
# CONFIG_DRM_PANEL_XINPENG_XPP055C272 is not set
CONFIG_DRM_PANEL=y
# CONFIG_DRM_PARADE_PS8622 is not set
@@ -5438,7 +5438,9 @@ CONFIG_SERIAL_LANTIQ=m
CONFIG_SERIAL_NONSTANDARD=y
# CONFIG_SERIAL_PCH_UART is not set
# CONFIG_SERIAL_RP2 is not set
-# CONFIG_SERIAL_SC16IS7XX is not set
+# CONFIG_SERIAL_SC16IS7XX_I2C is not set
+CONFIG_SERIAL_SC16IS7XX=m
+CONFIG_SERIAL_SC16IS7XX_SPI=y
# CONFIG_SERIAL_SCCNXP is not set
# CONFIG_SERIAL_SIFIVE is not set
# CONFIG_SERIAL_SPRD is not set
diff --git a/kernel.spec b/kernel.spec
index fb34f2f18..e60421066 100644
--- a/kernel.spec
+++ b/kernel.spec
@@ -30,7 +30,7 @@ Summary: The Linux kernel
# For a stable, released kernel, released_kernel should be 1.
%global released_kernel 0
-%global distro_build 0.rc4.20200710git42f82040ee66.1
+%global distro_build 0.rc5.1
%if 0%{?fedora}
%define secure_boot_arch x86_64
@@ -69,13 +69,13 @@ Summary: The Linux kernel
%endif
%define rpmversion 5.8.0
-%define pkgrelease 0.rc4.20200710git42f82040ee66.1
+%define pkgrelease 0.rc5.1
# This is needed to do merge window version magic
%define patchlevel 8
# allow pkg_release to have configurable %%{?dist} tag
-%define specrelease 0.rc4.20200710git42f82040ee66.1%{?buildid}%{?dist}
+%define specrelease 0.rc5.1%{?buildid}%{?dist}
%define pkg_release %{specrelease}
@@ -166,7 +166,7 @@ Summary: The Linux kernel
# Set debugbuildsenabled to 1 for production (build separate debug kernels)
# and 0 for rawhide (all kernels are debug kernels).
# See also 'make debug' and 'make release'.
-%define debugbuildsenabled 0
+%define debugbuildsenabled 1
# The kernel tarball/base version
%define kversion 5.8
@@ -567,7 +567,7 @@ BuildRequires: asciidoc
# exact git commit you can run
#
# xzcat -qq ${TARBALL} | git get-tar-commit-id
-Source0: linux-20200710git42f82040ee66.tar.xz
+Source0: linux-5.8-rc5.tar.xz
Source1: Makefile.rhelver
@@ -785,6 +785,25 @@ Patch77: 0001-virt-vbox-Add-a-few-new-vmmdev-request-types-to-the-.patch
Patch78: 0001-virt-vbox-Log-unknown-ioctl-requests-as-error.patch
Patch79: 0001-PCI-tegra-Revert-raw_violation_fixup-for-tegra124.patch
Patch80: 0001-redhat-Replace-hardware.redhat.com-link-in-Unsupport.patch
+Patch81: 0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch
+Patch82: 0001-selinux-allow-reading-labels-before-policy-is-loaded.patch
+Patch83: 0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch
+Patch84: 0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch
+Patch85: 0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch
+Patch86: 0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch
+Patch87: 0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch
+Patch88: 0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch
+Patch89: 0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch
+Patch90: 0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch
+Patch91: 0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch
+Patch92: 0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch
+Patch93: 0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch
+Patch94: 0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch
+Patch95: 0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch
+Patch96: 0001-drm-panel-st7703-Enter-sleep-after-display-off.patch
+Patch97: 0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch
+Patch98: 0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch
+Patch99: 0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch
%endif
@@ -1280,8 +1299,8 @@ ApplyOptionalPatch()
fi
}
-%setup -q -n kernel-20200710git42f82040ee66 -c
-mv linux-20200710git42f82040ee66 linux-%{KVERREL}
+%setup -q -n kernel-5.8-rc5 -c
+mv linux-5.8-rc5 linux-%{KVERREL}
cd linux-%{KVERREL}
cp -a %{SOURCE1} .
@@ -1367,6 +1386,25 @@ ApplyOptionalPatch 0001-virt-vbox-Add-a-few-new-vmmdev-request-types-to-the-.pat
ApplyOptionalPatch 0001-virt-vbox-Log-unknown-ioctl-requests-as-error.patch
ApplyOptionalPatch 0001-PCI-tegra-Revert-raw_violation_fixup-for-tegra124.patch
ApplyOptionalPatch 0001-redhat-Replace-hardware.redhat.com-link-in-Unsupport.patch
+ApplyOptionalPatch 0001-Fixes-acpi-prefer-booting-with-ACPI-over-DTS-to-be-R.patch
+ApplyOptionalPatch 0001-selinux-allow-reading-labels-before-policy-is-loaded.patch
+ApplyOptionalPatch 0001-Revert-dt-bindings-panel-add-binding-for-Xingbangda-.patch
+ApplyOptionalPatch 0001-Revert-drm-panel-add-Xingbangda-XBD599-panel.patch
+ApplyOptionalPatch 0001-Revert-drm-sun4i-sun6i_mipi_dsi-fix-horizontal-timin.patch
+ApplyOptionalPatch 0001-Revert-arm64-allwinner-dts-a64-add-LCD-related-devic.patch
+ApplyOptionalPatch 0001-dt-bindings-vendor-prefixes-Add-Xingbangda.patch
+ApplyOptionalPatch 0001-dt-bindings-panel-Convert-rocktech-jh057n00900-to-ya.patch
+ApplyOptionalPatch 0001-dt-bindings-panel-Add-compatible-for-Xingbangda-XBD5.patch
+ApplyOptionalPatch 0001-drm-panel-rocktech-jh057n00900-Rename-the-driver-to-.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Rename-functions-from-jh057n-prefix.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Prepare-for-supporting-multiple-pan.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Move-code-specific-to-jh057n-closer.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Move-generic-part-of-init-sequence-.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Add-support-for-Xingbangda-XBD599.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Enter-sleep-after-display-off.patch
+ApplyOptionalPatch 0001-drm-panel-st7703-Assert-reset-prior-to-powering-down.patch
+ApplyOptionalPatch 0001-arm64-dts-sun50i-a64-pinephone-Enable-LCD-support-on.patch
+ApplyOptionalPatch 0001-arm64-dts-sun50i-a64-pinephone-Add-touchscreen-suppo.patch
%endif
@@ -2792,8 +2830,29 @@ fi
#
#
%changelog
-* Fri Jul 10 2020 Fedora Kernel Team <kernel-team@fedoraproject.org> [5.8.0-0.rc4.20200710git42f82040ee66.1]
-- 42f82040ee66 rebase
+* Mon Jul 13 2020 Fedora Kernel Team <kernel-team@fedoraproject.org> [5.8.0-0.rc5.1]
+- v5.8-rc5 rebase
+- arm64: dts: sun50i-a64-pinephone: Add touchscreen support (Ondrej Jirman)
+- arm64: dts: sun50i-a64-pinephone: Enable LCD support on PinePhone (Icenowy Zheng)
+- drm/panel: st7703: Assert reset prior to powering down the regulators (Ondrej Jirman)
+- drm/panel: st7703: Enter sleep after display off (Ondrej Jirman)
+- drm/panel: st7703: Add support for Xingbangda XBD599 (Ondrej Jirman)
+- drm/panel: st7703: Move generic part of init sequence to enable callback (Ondrej Jirman)
+- drm/panel: st7703: Move code specific to jh057n closer together (Ondrej Jirman)
+- drm/panel: st7703: Prepare for supporting multiple panels (Ondrej Jirman)
+- drm/panel: st7703: Rename functions from jh057n prefix to st7703 (Ondrej Jirman)
+- drm/panel: rocktech-jh057n00900: Rename the driver to st7703 (Ondrej Jirman)
+- dt-bindings: panel: Add compatible for Xingbangda XBD599 panel (Ondrej Jirman)
+- dt-bindings: panel: Convert rocktech, jh057n00900 to yaml (Ondrej Jirman)
+- dt-bindings: vendor-prefixes: Add Xingbangda (Icenowy Zheng)
+- Revert "arm64: allwinner: dts: a64: add LCD-related device nodes for PinePhone" (Peter Robinson)
+- Revert "drm/sun4i: sun6i_mipi_dsi: fix horizontal timing calculation" (Peter Robinson)
+- Revert "drm: panel: add Xingbangda XBD599 panel" (Peter Robinson)
+- Revert "dt-bindings: panel: add binding for Xingbangda XBD599 panel" (Peter Robinson)
+- selinux: allow reading labels before policy is loaded (Jonathan Lebon)
+- Fixes "acpi: prefer booting with ACPI over DTS" to be RHEL only (Peter Robinson)
+- Update config for renamed panel driver. (Peter Robinson)
+- Enable SERIAL_SC16IS7XX for SPI interfaces (Peter Robinson)
- Updated changelog for the release based on dcde237b9b0e (Fedora Kernel Team)
* Wed Jul 08 2020 Fedora Kernel Team <kernel-team@fedoraproject.org> [5.8.0-0.rc4.20200708gitdcde237b9b0e.1]
diff --git a/sources b/sources
index 954ca2540..b09009b65 100644
--- a/sources
+++ b/sources
@@ -1,3 +1,3 @@
-SHA512 (linux-20200710git42f82040ee66.tar.xz) = 77d322c8d2c61509d58b7da128336b93374a02b0a45f7a0a5b585bc1be6adaef271f5a9b6ed599c8f5e7e6316a536410ec30e6fa5aeab88bec416350bd89d48f
-SHA512 (kernel-abi-whitelists-5.8.0-0.rc4.20200710git42f82040ee66.1.tar.bz2) = 0986fcb9c13844241a0c9fdd112342745d390aa984b16ab6ad26ce3cfa2da8cf62b855e33b597a6daddf61c8e22f6e8363a394a8d4c7748ee6faf838bf50d12e
-SHA512 (kernel-kabi-dw-5.8.0-0.rc4.20200710git42f82040ee66.1.tar.bz2) = 8bdef520cdcdaa3ffa3c69e728eb9ccc67a174d884bad7417426bd6d6290018d0f64ed58590b3d2edf422528f07e1c0eeaf0a70583e778a366db1796f6685baf
+SHA512 (linux-5.8-rc5.tar.xz) = 689e81f0f3a2927896920d9ceb627211bc8ab8023c819c3863e71c2264601f85be6f22c10ce94ff353311515c6d8d87ecbc8b11787ef30af41b32d276df04190
+SHA512 (kernel-abi-whitelists-5.8.0-0.rc5.1.tar.bz2) = 432cc86a70d52448c77b0906a2ee19e5847a13279cdd3c38918281f585caf8e3cbfd4eaa6631c9c610ea097ced6d42ab12776d68034f500d505a1f11ee94661e
+SHA512 (kernel-kabi-dw-5.8.0-0.rc5.1.tar.bz2) = 1bd8c7b44b0fc562e40068430c655ee1c3d1833cf7827918739ec17fc356ff7b83fd9462a2f203a2d68f1d27eee2c92557d218731317beac8ee8a1d9df33e34d