From 138af4d3cf3e8dfda1a075df609a361492153b7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=AA=B7=E9=AB=85=E5=A4=B4?= Date: Thu, 16 Mar 2023 20:33:33 +0800 Subject: [PATCH] kernel:refresh patch (#11005) * kernel: bump 5.15 to 5.15.102 * kernel:refresh patch --- ...it-the-CEC-disable-enable-functions-.patch | 4 +- ...e-sure-the-device-is-powered-with-CE.patch | 4 +- ...c4-hdmi-Raise-the-maximum-clock-rate.patch | 2 +- ...-a-spinlock-to-protect-register-acce.patch | 80 +- ...-a-mutex-to-prevent-concurrent-frame.patch | 42 +- ...vent-access-to-crtc-state-outside-of.patch | 12 +- ...mi-Check-the-device-state-in-prepare.patch | 4 +- ...dmi-Introduce-an-output_enabled-flag.patch | 4 +- ...4-hdmi-Introduce-a-scdc_enabled-flag.patch | 2 +- ...rage-the-load-tracker-on-the-BCM2711.patch | 2 +- ...ually-check-for-the-connector-status.patch | 2 +- ...Set-base-to-0-give-expected-gpio-num.patch | 4 +- ...Better-coalescing-parameter-defaults.patch | 4 +- ...-link-energy-detect-powerdown-for-ex.patch | 2 +- ...t-Workaround-2-for-Pi4-Ethernet-fail.patch | 2 +- ...trl-bcm2835-Remove-gpiochip-on-error.patch | 2 +- ...et-bcmgenet-Reset-RBUF-on-first-open.patch | 8 +- ...-interface-in-mode6-for-18-bit-color.patch | 214 --- ...lane-Add-support-for-DRM_FORMAT_P030.patch | 12 +- ...d-support-for-YUV-color-encodings-an.patch | 12 +- ...gfs-node-that-dumps-the-current-disp.patch | 2 +- ...the-HDMI-registers-into-the-debugfs-.patch | 4 +- ...he-default-DPI-format-to-being-18bpp.patch | 4 +- ...mplify-the-connector-state-retrieval.patch | 2 +- ...-Add-a-timing-for-the-Raspberry-Pi-7.patch | 4 +- ...-Sensor-should-report-RAW-color-spac.patch | 4 +- ...vc4-Add-support-for-gamma-on-BCM2711.patch | 2 +- ...gfs-node-that-dumps-the-vc5-gamma-PW.patch | 2 +- ...c4-Don-t-try-disabling-SCDC-on-Pi0-3.patch | 2 +- ...c4_hdmi-doesn-t-use-2711-HPD-registe.patch | 6 +- ...drm-vc4-Move-HDMI-reset-to-pm_resume.patch | 10 +- ...option-for-inverting-pixel-clock-and.patch | 114 -- ...-Ensure-a-default-format-is-selected.patch | 12 +- ...ertise-embedded-data-node-on-media-p.patch | 32 +- ...c4_hdmi-output_enabled-for-allowing-.patch | 6 +- ...4-Fix-build-without-DRM_VC4_HDMI_CEC.patch | 2 +- ...4-Skip-writes-to-disabled-packet-RAM.patch | 4 +- ...drm_hdmi_avi_infoframe_colorspace-to.patch | 4 +- ...m-vc4-hdmi-Add-full-range-RGB-helper.patch | 2 +- ...e-full-range-helper-in-csc-functions.patch | 2 +- ...c4-hdmi-Move-XBAR-setup-to-csc_setup.patch | 2 +- ...lace-CSC_CTL-hardcoded-value-by-defi.patch | 2 +- ...4-hdmi-Change-CSC-callback-prototype.patch | 2 +- ...e-clock-validation-to-its-own-functi.patch | 6 +- ...e-clock-calculation-into-its-own-fun.patch | 6 +- ...e-the-sink-maximum-TMDS-clock-into-a.patch | 2 +- ...e-bpp-into-account-for-the-scrambler.patch | 2 +- ...i-Always-try-to-have-the-highest-bpc.patch | 8 +- ...drm-vc4-hdmi-Support-HDMI-YUV-output.patch | 14 +- ...-Fix-no-video-output-on-DVI-monitors.patch | 2 +- ...ha_blend_mode-property-to-each-plane.patch | 8 +- ...-clock-value-used-for-validating-hdm.patch | 2 +- ...2c-Add-configuration-for-RPi-POE-HAT.patch | 2 +- ...-Broadcast-RGB-property-to-allow-ove.patch | 2 +- ...d-DRM-210101010-RGB-formats-for-hvs5.patch | 2 +- ...add-MEDIA_BUS_FMT_RGB565_1X24_CPADHI.patch | 31 - ...ort-DPI-interface-in-mode3-for-RGB56.patch | 4 +- ...nel-simple-add-Geekworm-MZP280-Panel.patch | 2 +- ...-Scale-the-pixel-clock-rate-for-the-.patch | 129 -- ...MEDIA_BUS_FMT_RGB565_1X16-is-mode-1-.patch | 25 - ...4-hvs-Defer-dlist-slots-deallocation.patch | 2 +- ...1-drm-vc4-Support-zpos-on-all-planes.patch | 6 +- ...e-Keep-fractional-source-coords-insi.patch | 32 +- ...ractional-coordinates-using-the-phas.patch | 6 +- ...-Make-use-of-chroma-siting-parameter.patch | 6 +- ...2835-Only-return-non-GPIOs-to-inputs.patch | 4 +- ...4-hvs-Defer-dlist-slots-deallocation.patch | 2 +- ..._hdmi-Force-modeset-when-bpc-changes.patch | 4 +- ...VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWA.patch | 2 +- ...i-Rework-hdmi_enable_4kp60-detection.patch | 4 +- ...event-async-update-if-we-don-t-have-.patch | 2 +- ...-Consolidate-Hardware-Revision-Check.patch | 12 +- ...gister-a-different-drm_plane_helper_.patch | 4 +- ...-arm64-dts-qcom-ipq8074-add-SPMI-bus.patch | 2 +- ...4-dts-qcom-ipq8074-Add-QUP5-I2C-node.patch | 2 +- ...sm8996-Move-clock-cells-to-QMP-PHY-c.patch | 4 +- ...-dts-qcom-Fix-IPQ8074-PCIe-PHY-nodes.patch | 94 - ...-arm64-dts-qcom-ipq8074-add-MDIO-bus.patch | 2 +- ...8-arm64-dts-ipq8074-add-SMEM-support.patch | 2 +- ...om-ipq8074-enable-the-GICv2m-support.patch | 2 +- ...dts-ipq8074-fix-PCI-related-DT-nodes.patch | 193 -- ...com-Enable-Q6v5-WCSS-for-ipq8074-SoC.patch | 4 +- ...0120-arm64-dts-ipq8074-Add-WLAN-node.patch | 2 +- ...ermal-qcom-tsens-Add-IPQ8074-support.patch | 4 +- ...-arm64-dts-ipq8074-add-thermal-nodes.patch | 4 +- ...dts-ipq8074-add-SPMI-PMIC-regulators.patch | 2 +- ...4-update-APCS-node-due-to-clock-supp.patch | 2 +- .../0600-5.15-qca-nss-ecm-support-CORE.patch | 2 +- ...chip-move-rk3568-dtsi-to-rk356x-dtsi.patch | 1678 ++++++++++++++++- ...t-phy-motorcomm-change-the-phy-id-of.patch | 2 +- ...Add-dts-support-for-Motorcomm-yt8521.patch | 14 +- ...dd-dts-support-for-Motorcomm-yt8531s.patch | 12 +- ...-driver-for-Motorcomm-yt8531-gigabit.patch | 20 +- ...motorcomm-uninitialized-variables-in.patch | 2 +- ...ockchip-rk356x-Fix-PCIe-register-map.patch | 4 +- ...568-update-gicv3-its-and-pci-msi-map.patch | 2 +- 96 files changed, 1950 insertions(+), 1082 deletions(-) delete mode 100644 target/linux/bcm27xx/patches-5.15/950-0421-Support-RPi-DPI-interface-in-mode6-for-18-bit-color.patch delete mode 100644 target/linux/bcm27xx/patches-5.15/950-0596-drm-vc4-dpi-Add-option-for-inverting-pixel-clock-and.patch delete mode 100644 target/linux/bcm27xx/patches-5.15/950-0682-media-uapi-add-MEDIA_BUS_FMT_RGB565_1X24_CPADHI.patch delete mode 100644 target/linux/bcm27xx/patches-5.15/950-0706-media-i2c-imx219-Scale-the-pixel-clock-rate-for-the-.patch delete mode 100644 target/linux/bcm27xx/patches-5.15/950-0707-drm-vc4-For-DPI-MEDIA_BUS_FMT_RGB565_1X16-is-mode-1-.patch delete mode 100644 target/linux/ipq807x/patches-5.15/0005-v5.16-arm64-dts-qcom-Fix-IPQ8074-PCIe-PHY-nodes.patch delete mode 100644 target/linux/ipq807x/patches-5.15/0110-arm64-dts-ipq8074-fix-PCI-related-DT-nodes.patch diff --git a/target/linux/bcm27xx/patches-5.15/950-0001-drm-vc4-hdmi-Split-the-CEC-disable-enable-functions-.patch b/target/linux/bcm27xx/patches-5.15/950-0001-drm-vc4-hdmi-Split-the-CEC-disable-enable-functions-.patch index bb0b56fff..b12b6843d 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0001-drm-vc4-hdmi-Split-the-CEC-disable-enable-functions-.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0001-drm-vc4-hdmi-Split-the-CEC-disable-enable-functions-.patch @@ -17,7 +17,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20210819135931.895976-5-maxi --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1748,7 +1748,7 @@ static irqreturn_t vc4_cec_irq_handler(i +@@ -1749,7 +1749,7 @@ static irqreturn_t vc4_cec_irq_handler(i return ret; } @@ -26,7 +26,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20210819135931.895976-5-maxi { struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); /* clock period in microseconds */ -@@ -1761,38 +1761,53 @@ static int vc4_hdmi_cec_adap_enable(stru +@@ -1762,38 +1762,53 @@ static int vc4_hdmi_cec_adap_enable(stru val |= ((4700 / usecs) << VC4_HDMI_CEC_CNT_TO_4700_US_SHIFT) | ((4500 / usecs) << VC4_HDMI_CEC_CNT_TO_4500_US_SHIFT); diff --git a/target/linux/bcm27xx/patches-5.15/950-0002-drm-vc4-hdmi-Make-sure-the-device-is-powered-with-CE.patch b/target/linux/bcm27xx/patches-5.15/950-0002-drm-vc4-hdmi-Make-sure-the-device-is-powered-with-CE.patch index 6132b810b..1904f1822 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0002-drm-vc4-hdmi-Make-sure-the-device-is-powered-with-CE.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0002-drm-vc4-hdmi-Make-sure-the-device-is-powered-with-CE.patch @@ -24,7 +24,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20210819135931.895976-6-maxi --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1753,8 +1753,14 @@ static int vc4_hdmi_cec_enable(struct ce +@@ -1754,8 +1754,14 @@ static int vc4_hdmi_cec_enable(struct ce struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); /* clock period in microseconds */ const u32 usecs = 1000000 / CEC_CLOCK_FREQ; @@ -40,7 +40,7 @@ Link: https://patchwork.freedesktop.org/patch/msgid/20210819135931.895976-6-maxi val &= ~(VC4_HDMI_CEC_TX_SW_RESET | VC4_HDMI_CEC_RX_SW_RESET | VC4_HDMI_CEC_CNT_TO_4700_US_MASK | VC4_HDMI_CEC_CNT_TO_4500_US_MASK); -@@ -1797,6 +1803,8 @@ static int vc4_hdmi_cec_disable(struct c +@@ -1798,6 +1804,8 @@ static int vc4_hdmi_cec_disable(struct c HDMI_WRITE(HDMI_CEC_CNTRL_5, HDMI_READ(HDMI_CEC_CNTRL_5) | VC4_HDMI_CEC_TX_SW_RESET | VC4_HDMI_CEC_RX_SW_RESET); diff --git a/target/linux/bcm27xx/patches-5.15/950-0005-drm-vc4-hdmi-Raise-the-maximum-clock-rate.patch b/target/linux/bcm27xx/patches-5.15/950-0005-drm-vc4-hdmi-Raise-the-maximum-clock-rate.patch index 21d3148af..020b56b87 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0005-drm-vc4-hdmi-Raise-the-maximum-clock-rate.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0005-drm-vc4-hdmi-Raise-the-maximum-clock-rate.patch @@ -20,7 +20,7 @@ Link: https://lore.kernel.org/r/20211025152903.1088803-9-maxime@cerno.tech --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -2386,7 +2386,7 @@ static const struct vc4_hdmi_variant bcm +@@ -2387,7 +2387,7 @@ static const struct vc4_hdmi_variant bcm .encoder_type = VC4_ENCODER_TYPE_HDMI0, .debugfs_name = "hdmi0_regs", .card_name = "vc4-hdmi-0", diff --git a/target/linux/bcm27xx/patches-5.15/950-0007-drm-vc4-hdmi-Add-a-spinlock-to-protect-register-acce.patch b/target/linux/bcm27xx/patches-5.15/950-0007-drm-vc4-hdmi-Add-a-spinlock-to-protect-register-acce.patch index fc802e56a..8691fdc49 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0007-drm-vc4-hdmi-Add-a-spinlock-to-protect-register-acce.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0007-drm-vc4-hdmi-Add-a-spinlock-to-protect-register-acce.patch @@ -281,9 +281,9 @@ Signed-off-by: Maxime Ripard } static void vc5_hdmi_set_timings(struct vc4_hdmi *vc4_hdmi, -@@ -789,10 +856,13 @@ static void vc5_hdmi_set_timings(struct +@@ -790,10 +857,13 @@ static void vc5_hdmi_set_timings(struct VC4_SET_FIELD(mode->crtc_vtotal - - mode->crtc_vsync_end - interlaced, + mode->crtc_vsync_end, VC4_HDMI_VERTB_VBP)); + unsigned long flags; unsigned char gcp; @@ -295,7 +295,7 @@ Signed-off-by: Maxime Ripard HDMI_WRITE(HDMI_VEC_INTERFACE_XBAR, 0x354021); HDMI_WRITE(HDMI_HORZA, (vsync_pos ? VC5_HDMI_HORZA_VPOS : 0) | -@@ -856,13 +926,18 @@ static void vc5_hdmi_set_timings(struct +@@ -857,13 +927,18 @@ static void vc5_hdmi_set_timings(struct HDMI_WRITE(HDMI_MISC_CONTROL, reg); HDMI_WRITE(HDMI_CLOCK_STOP, 0); @@ -314,7 +314,7 @@ Signed-off-by: Maxime Ripard drift = HDMI_READ(HDMI_FIFO_CTL); drift &= VC4_HDMI_FIFO_VALID_WRITE_MASK; -@@ -870,12 +945,20 @@ static void vc4_hdmi_recenter_fifo(struc +@@ -871,12 +946,20 @@ static void vc4_hdmi_recenter_fifo(struc drift & ~VC4_HDMI_FIFO_CTL_RECENTER); HDMI_WRITE(HDMI_FIFO_CTL, drift | VC4_HDMI_FIFO_CTL_RECENTER); @@ -335,7 +335,7 @@ Signed-off-by: Maxime Ripard ret = wait_for(HDMI_READ(HDMI_FIFO_CTL) & VC4_HDMI_FIFO_CTL_RECENTER_DONE, 1); WARN_ONCE(ret, "Timeout waiting for " -@@ -909,6 +992,7 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -910,6 +993,7 @@ static void vc4_hdmi_encoder_pre_crtc_co struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); unsigned long pixel_rate = vc4_conn_state->pixel_rate; unsigned long bvb_rate, hsm_rate; @@ -343,7 +343,7 @@ Signed-off-by: Maxime Ripard int ret; /* -@@ -977,11 +1061,15 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -978,11 +1062,15 @@ static void vc4_hdmi_encoder_pre_crtc_co if (vc4_hdmi->variant->phy_init) vc4_hdmi->variant->phy_init(vc4_hdmi, vc4_conn_state); @@ -359,7 +359,7 @@ Signed-off-by: Maxime Ripard if (vc4_hdmi->variant->set_timings) vc4_hdmi->variant->set_timings(vc4_hdmi, conn_state, mode); -@@ -1001,6 +1089,7 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1002,6 +1090,7 @@ static void vc4_hdmi_encoder_pre_crtc_en struct drm_display_mode *mode = &encoder->crtc->state->adjusted_mode; struct vc4_hdmi_encoder *vc4_encoder = to_vc4_hdmi_encoder(encoder); struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); @@ -367,7 +367,7 @@ Signed-off-by: Maxime Ripard if (vc4_encoder->hdmi_monitor && drm_default_rgb_quant_range(mode) == HDMI_QUANTIZATION_RANGE_LIMITED) { -@@ -1015,7 +1104,9 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1016,7 +1105,9 @@ static void vc4_hdmi_encoder_pre_crtc_en vc4_encoder->limited_rgb_range = false; } @@ -377,7 +377,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_encoder_post_crtc_enable(struct drm_encoder *encoder, -@@ -1026,8 +1117,11 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1027,8 +1118,11 @@ static void vc4_hdmi_encoder_post_crtc_e struct vc4_hdmi_encoder *vc4_encoder = to_vc4_hdmi_encoder(encoder); bool hsync_pos = mode->flags & DRM_MODE_FLAG_PHSYNC; bool vsync_pos = mode->flags & DRM_MODE_FLAG_PVSYNC; @@ -389,7 +389,7 @@ Signed-off-by: Maxime Ripard HDMI_WRITE(HDMI_VID_CTL, VC4_HD_VID_CTL_ENABLE | VC4_HD_VID_CTL_CLRRGB | -@@ -1044,6 +1138,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1045,6 +1139,8 @@ static void vc4_hdmi_encoder_post_crtc_e HDMI_READ(HDMI_SCHEDULER_CONTROL) | VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI); @@ -398,7 +398,7 @@ Signed-off-by: Maxime Ripard ret = wait_for(HDMI_READ(HDMI_SCHEDULER_CONTROL) & VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE, 1000); WARN_ONCE(ret, "Timeout waiting for " -@@ -1056,6 +1152,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1057,6 +1153,8 @@ static void vc4_hdmi_encoder_post_crtc_e HDMI_READ(HDMI_SCHEDULER_CONTROL) & ~VC4_HDMI_SCHEDULER_CONTROL_MODE_HDMI); @@ -407,7 +407,7 @@ Signed-off-by: Maxime Ripard ret = wait_for(!(HDMI_READ(HDMI_SCHEDULER_CONTROL) & VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE), 1000); WARN_ONCE(ret, "Timeout waiting for " -@@ -1063,6 +1161,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1064,6 +1162,8 @@ static void vc4_hdmi_encoder_post_crtc_e } if (vc4_encoder->hdmi_monitor) { @@ -416,7 +416,7 @@ Signed-off-by: Maxime Ripard WARN_ON(!(HDMI_READ(HDMI_SCHEDULER_CONTROL) & VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE)); HDMI_WRITE(HDMI_SCHEDULER_CONTROL, -@@ -1072,6 +1172,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1073,6 +1173,8 @@ static void vc4_hdmi_encoder_post_crtc_e HDMI_WRITE(HDMI_RAM_PACKET_CONFIG, VC4_HDMI_RAM_PACKET_ENABLE); @@ -425,7 +425,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi_set_infoframes(encoder); } -@@ -1195,6 +1297,7 @@ static void vc4_hdmi_audio_set_mai_clock +@@ -1196,6 +1298,7 @@ static void vc4_hdmi_audio_set_mai_clock unsigned int samplerate) { u32 hsm_clock = clk_get_rate(vc4_hdmi->audio_clock); @@ -433,7 +433,7 @@ Signed-off-by: Maxime Ripard unsigned long n, m; rational_best_approximation(hsm_clock, samplerate, -@@ -1204,9 +1307,11 @@ static void vc4_hdmi_audio_set_mai_clock +@@ -1205,9 +1308,11 @@ static void vc4_hdmi_audio_set_mai_clock VC4_HD_MAI_SMP_M_SHIFT) + 1, &n, &m); @@ -445,7 +445,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_set_n_cts(struct vc4_hdmi *vc4_hdmi, unsigned int samplerate) -@@ -1217,6 +1322,8 @@ static void vc4_hdmi_set_n_cts(struct vc +@@ -1218,6 +1323,8 @@ static void vc4_hdmi_set_n_cts(struct vc u32 n, cts; u64 tmp; @@ -454,7 +454,7 @@ Signed-off-by: Maxime Ripard n = 128 * samplerate / 1000; tmp = (u64)(mode->clock * 1000) * n; do_div(tmp, 128 * samplerate); -@@ -1246,6 +1353,7 @@ static int vc4_hdmi_audio_startup(struct +@@ -1247,6 +1354,7 @@ static int vc4_hdmi_audio_startup(struct { struct vc4_hdmi *vc4_hdmi = dev_get_drvdata(dev); struct drm_encoder *encoder = &vc4_hdmi->encoder.base.base; @@ -462,7 +462,7 @@ Signed-off-by: Maxime Ripard /* * If the HDMI encoder hasn't probed, or the encoder is -@@ -1257,12 +1365,14 @@ static int vc4_hdmi_audio_startup(struct +@@ -1258,12 +1366,14 @@ static int vc4_hdmi_audio_startup(struct vc4_hdmi->audio.streaming = true; @@ -477,7 +477,7 @@ Signed-off-by: Maxime Ripard if (vc4_hdmi->variant->phy_rng_enable) vc4_hdmi->variant->phy_rng_enable(vc4_hdmi); -@@ -1274,6 +1384,7 @@ static void vc4_hdmi_audio_reset(struct +@@ -1275,6 +1385,7 @@ static void vc4_hdmi_audio_reset(struct { struct drm_encoder *encoder = &vc4_hdmi->encoder.base.base; struct device *dev = &vc4_hdmi->pdev->dev; @@ -485,7 +485,7 @@ Signed-off-by: Maxime Ripard int ret; vc4_hdmi->audio.streaming = false; -@@ -1281,20 +1392,29 @@ static void vc4_hdmi_audio_reset(struct +@@ -1282,20 +1393,29 @@ static void vc4_hdmi_audio_reset(struct if (ret) dev_err(dev, "Failed to stop audio infoframe: %d\n", ret); @@ -515,7 +515,7 @@ Signed-off-by: Maxime Ripard if (vc4_hdmi->variant->phy_rng_disable) vc4_hdmi->variant->phy_rng_disable(vc4_hdmi); -@@ -1349,6 +1469,7 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1350,6 +1470,7 @@ static int vc4_hdmi_audio_prepare(struct struct drm_encoder *encoder = &vc4_hdmi->encoder.base.base; unsigned int sample_rate = params->sample_rate; unsigned int channels = params->channels; @@ -523,7 +523,7 @@ Signed-off-by: Maxime Ripard u32 audio_packet_config, channel_mask; u32 channel_map; u32 mai_audio_format; -@@ -1357,14 +1478,15 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1358,14 +1479,15 @@ static int vc4_hdmi_audio_prepare(struct dev_dbg(dev, "%s: %u Hz, %d bit, %d channels\n", __func__, sample_rate, params->sample_width, channels); @@ -541,7 +541,7 @@ Signed-off-by: Maxime Ripard mai_sample_rate = sample_rate_to_mai_fmt(sample_rate); if (params->iec.status[0] & IEC958_AES0_NONAUDIO && params->channels == 8) -@@ -1402,8 +1524,11 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1403,8 +1525,11 @@ static int vc4_hdmi_audio_prepare(struct channel_map = vc4_hdmi->variant->channel_map(vc4_hdmi, channel_mask); HDMI_WRITE(HDMI_MAI_CHANNEL_MAP, channel_map); HDMI_WRITE(HDMI_AUDIO_PACKET_CONFIG, audio_packet_config); @@ -553,7 +553,7 @@ Signed-off-by: Maxime Ripard memcpy(&vc4_hdmi->audio.infoframe, ¶ms->cea, sizeof(params->cea)); vc4_hdmi_set_audio_infoframe(encoder); -@@ -1677,6 +1802,8 @@ static void vc4_cec_read_msg(struct vc4_ +@@ -1678,6 +1803,8 @@ static void vc4_cec_read_msg(struct vc4_ struct cec_msg *msg = &vc4_hdmi->cec_rx_msg; unsigned int i; @@ -562,7 +562,7 @@ Signed-off-by: Maxime Ripard msg->len = 1 + ((cntrl1 & VC4_HDMI_CEC_REC_WRD_CNT_MASK) >> VC4_HDMI_CEC_REC_WRD_CNT_SHIFT); -@@ -1695,11 +1822,12 @@ static void vc4_cec_read_msg(struct vc4_ +@@ -1696,11 +1823,12 @@ static void vc4_cec_read_msg(struct vc4_ } } @@ -577,7 +577,7 @@ Signed-off-by: Maxime Ripard cntrl1 = HDMI_READ(HDMI_CEC_CNTRL_1); vc4_hdmi->cec_tx_ok = cntrl1 & VC4_HDMI_CEC_TX_STATUS_GOOD; cntrl1 &= ~VC4_HDMI_CEC_START_XMIT_BEGIN; -@@ -1708,11 +1836,24 @@ static irqreturn_t vc4_cec_irq_handler_t +@@ -1709,11 +1837,24 @@ static irqreturn_t vc4_cec_irq_handler_t return IRQ_WAKE_THREAD; } @@ -603,7 +603,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi->cec_rx_msg.len = 0; cntrl1 = HDMI_READ(HDMI_CEC_CNTRL_1); vc4_cec_read_msg(vc4_hdmi, cntrl1); -@@ -1725,6 +1866,18 @@ static irqreturn_t vc4_cec_irq_handler_r +@@ -1726,6 +1867,18 @@ static irqreturn_t vc4_cec_irq_handler_r return IRQ_WAKE_THREAD; } @@ -622,7 +622,7 @@ Signed-off-by: Maxime Ripard static irqreturn_t vc4_cec_irq_handler(int irq, void *priv) { struct vc4_hdmi *vc4_hdmi = priv; -@@ -1735,14 +1888,17 @@ static irqreturn_t vc4_cec_irq_handler(i +@@ -1736,14 +1889,17 @@ static irqreturn_t vc4_cec_irq_handler(i if (!(stat & VC4_HDMI_CPU_CEC)) return IRQ_NONE; @@ -642,7 +642,7 @@ Signed-off-by: Maxime Ripard return ret; } -@@ -1751,6 +1907,7 @@ static int vc4_hdmi_cec_enable(struct ce +@@ -1752,6 +1908,7 @@ static int vc4_hdmi_cec_enable(struct ce struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); /* clock period in microseconds */ const u32 usecs = 1000000 / CEC_CLOCK_FREQ; @@ -650,7 +650,7 @@ Signed-off-by: Maxime Ripard u32 val; int ret; -@@ -1758,6 +1915,8 @@ static int vc4_hdmi_cec_enable(struct ce +@@ -1759,6 +1916,8 @@ static int vc4_hdmi_cec_enable(struct ce if (ret) return ret; @@ -659,7 +659,7 @@ Signed-off-by: Maxime Ripard val = HDMI_READ(HDMI_CEC_CNTRL_5); val &= ~(VC4_HDMI_CEC_TX_SW_RESET | VC4_HDMI_CEC_RX_SW_RESET | VC4_HDMI_CEC_CNT_TO_4700_US_MASK | -@@ -1788,12 +1947,17 @@ static int vc4_hdmi_cec_enable(struct ce +@@ -1789,12 +1948,17 @@ static int vc4_hdmi_cec_enable(struct ce if (!vc4_hdmi->variant->external_irq_controller) HDMI_WRITE(HDMI_CEC_CPU_MASK_CLEAR, VC4_HDMI_CPU_CEC); @@ -677,7 +677,7 @@ Signed-off-by: Maxime Ripard if (!vc4_hdmi->variant->external_irq_controller) HDMI_WRITE(HDMI_CEC_CPU_MASK_SET, VC4_HDMI_CPU_CEC); -@@ -1801,6 +1965,8 @@ static int vc4_hdmi_cec_disable(struct c +@@ -1802,6 +1966,8 @@ static int vc4_hdmi_cec_disable(struct c HDMI_WRITE(HDMI_CEC_CNTRL_5, HDMI_READ(HDMI_CEC_CNTRL_5) | VC4_HDMI_CEC_TX_SW_RESET | VC4_HDMI_CEC_RX_SW_RESET); @@ -686,7 +686,7 @@ Signed-off-by: Maxime Ripard pm_runtime_put(&vc4_hdmi->pdev->dev); return 0; -@@ -1817,10 +1983,14 @@ static int vc4_hdmi_cec_adap_enable(stru +@@ -1818,10 +1984,14 @@ static int vc4_hdmi_cec_adap_enable(stru static int vc4_hdmi_cec_adap_log_addr(struct cec_adapter *adap, u8 log_addr) { struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); @@ -701,7 +701,7 @@ Signed-off-by: Maxime Ripard return 0; } -@@ -1829,6 +1999,7 @@ static int vc4_hdmi_cec_adap_transmit(st +@@ -1830,6 +2000,7 @@ static int vc4_hdmi_cec_adap_transmit(st { struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); struct drm_device *dev = vc4_hdmi->connector.dev; @@ -709,7 +709,7 @@ Signed-off-by: Maxime Ripard u32 val; unsigned int i; -@@ -1837,6 +2008,8 @@ static int vc4_hdmi_cec_adap_transmit(st +@@ -1838,6 +2009,8 @@ static int vc4_hdmi_cec_adap_transmit(st return -ENOMEM; } @@ -718,7 +718,7 @@ Signed-off-by: Maxime Ripard for (i = 0; i < msg->len; i += 4) HDMI_WRITE(HDMI_CEC_TX_DATA_1 + (i >> 2), (msg->msg[i]) | -@@ -1852,6 +2025,9 @@ static int vc4_hdmi_cec_adap_transmit(st +@@ -1853,6 +2026,9 @@ static int vc4_hdmi_cec_adap_transmit(st val |= VC4_HDMI_CEC_START_XMIT_BEGIN; HDMI_WRITE(HDMI_CEC_CNTRL_1, val); @@ -728,7 +728,7 @@ Signed-off-by: Maxime Ripard return 0; } -@@ -1866,6 +2042,7 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -1867,6 +2043,7 @@ static int vc4_hdmi_cec_init(struct vc4_ struct cec_connector_info conn_info; struct platform_device *pdev = vc4_hdmi->pdev; struct device *dev = &pdev->dev; @@ -736,7 +736,7 @@ Signed-off-by: Maxime Ripard u32 value; int ret; -@@ -1886,10 +2063,12 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -1887,10 +2064,12 @@ static int vc4_hdmi_cec_init(struct vc4_ cec_fill_conn_info_from_drm(&conn_info, &vc4_hdmi->connector); cec_s_conn_info(vc4_hdmi->cec_adap, &conn_info); @@ -749,7 +749,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi_cec_update_clk_div(vc4_hdmi); -@@ -1908,7 +2087,9 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -1909,7 +2088,9 @@ static int vc4_hdmi_cec_init(struct vc4_ if (ret) goto err_remove_cec_rx_handler; } else { @@ -759,7 +759,7 @@ Signed-off-by: Maxime Ripard ret = request_threaded_irq(platform_get_irq(pdev, 0), vc4_cec_irq_handler, -@@ -2178,6 +2359,7 @@ static int vc4_hdmi_bind(struct device * +@@ -2179,6 +2360,7 @@ static int vc4_hdmi_bind(struct device * vc4_hdmi = devm_kzalloc(dev, sizeof(*vc4_hdmi), GFP_KERNEL); if (!vc4_hdmi) return -ENOMEM; diff --git a/target/linux/bcm27xx/patches-5.15/950-0008-drm-vc4-hdmi-Use-a-mutex-to-prevent-concurrent-frame.patch b/target/linux/bcm27xx/patches-5.15/950-0008-drm-vc4-hdmi-Use-a-mutex-to-prevent-concurrent-frame.patch index 2ca86efaa..49470cdb4 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0008-drm-vc4-hdmi-Use-a-mutex-to-prevent-concurrent-frame.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0008-drm-vc4-hdmi-Use-a-mutex-to-prevent-concurrent-frame.patch @@ -169,7 +169,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_encoder_disable(struct drm_encoder *encoder) -@@ -995,6 +1024,8 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -996,6 +1025,8 @@ static void vc4_hdmi_encoder_pre_crtc_co unsigned long flags; int ret; @@ -178,7 +178,7 @@ Signed-off-by: Maxime Ripard /* * As stated in RPi's vc4 firmware "HDMI state machine (HSM) clock must * be faster than pixel clock, infinitesimally faster, tested in -@@ -1015,13 +1046,13 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -1016,13 +1047,13 @@ static void vc4_hdmi_encoder_pre_crtc_co ret = clk_set_min_rate(vc4_hdmi->hsm_clock, hsm_rate); if (ret) { DRM_ERROR("Failed to set HSM clock rate: %d\n", ret); @@ -194,7 +194,7 @@ Signed-off-by: Maxime Ripard } ret = clk_set_rate(vc4_hdmi->pixel_clock, pixel_rate); -@@ -1073,13 +1104,16 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -1074,13 +1105,16 @@ static void vc4_hdmi_encoder_pre_crtc_co if (vc4_hdmi->variant->set_timings) vc4_hdmi->variant->set_timings(vc4_hdmi, conn_state, mode); @@ -212,7 +212,7 @@ Signed-off-by: Maxime Ripard return; } -@@ -1091,6 +1125,8 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1092,6 +1126,8 @@ static void vc4_hdmi_encoder_pre_crtc_en struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); unsigned long flags; @@ -221,7 +221,7 @@ Signed-off-by: Maxime Ripard if (vc4_encoder->hdmi_monitor && drm_default_rgb_quant_range(mode) == HDMI_QUANTIZATION_RANGE_LIMITED) { if (vc4_hdmi->variant->csc_setup) -@@ -1107,6 +1143,8 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1108,6 +1144,8 @@ static void vc4_hdmi_encoder_pre_crtc_en spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); HDMI_WRITE(HDMI_FIFO_CTL, VC4_HDMI_FIFO_CTL_MASTER_SLAVE_N); spin_unlock_irqrestore(&vc4_hdmi->hw_lock, flags); @@ -230,7 +230,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_encoder_post_crtc_enable(struct drm_encoder *encoder, -@@ -1120,6 +1158,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1121,6 +1159,8 @@ static void vc4_hdmi_encoder_post_crtc_e unsigned long flags; int ret; @@ -239,7 +239,7 @@ Signed-off-by: Maxime Ripard spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); HDMI_WRITE(HDMI_VID_CTL, -@@ -1179,6 +1219,8 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1180,6 +1220,8 @@ static void vc4_hdmi_encoder_post_crtc_e vc4_hdmi_recenter_fifo(vc4_hdmi); vc4_hdmi_enable_scrambling(encoder); @@ -248,7 +248,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder) -@@ -1322,6 +1364,7 @@ static void vc4_hdmi_set_n_cts(struct vc +@@ -1323,6 +1365,7 @@ static void vc4_hdmi_set_n_cts(struct vc u32 n, cts; u64 tmp; @@ -256,7 +256,7 @@ Signed-off-by: Maxime Ripard lockdep_assert_held(&vc4_hdmi->hw_lock); n = 128 * samplerate / 1000; -@@ -1355,13 +1398,17 @@ static int vc4_hdmi_audio_startup(struct +@@ -1356,13 +1399,17 @@ static int vc4_hdmi_audio_startup(struct struct drm_encoder *encoder = &vc4_hdmi->encoder.base.base; unsigned long flags; @@ -275,7 +275,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi->audio.streaming = true; -@@ -1377,6 +1424,8 @@ static int vc4_hdmi_audio_startup(struct +@@ -1378,6 +1425,8 @@ static int vc4_hdmi_audio_startup(struct if (vc4_hdmi->variant->phy_rng_enable) vc4_hdmi->variant->phy_rng_enable(vc4_hdmi); @@ -284,7 +284,7 @@ Signed-off-by: Maxime Ripard return 0; } -@@ -1387,6 +1436,8 @@ static void vc4_hdmi_audio_reset(struct +@@ -1388,6 +1437,8 @@ static void vc4_hdmi_audio_reset(struct unsigned long flags; int ret; @@ -293,7 +293,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi->audio.streaming = false; ret = vc4_hdmi_stop_packet(encoder, HDMI_INFOFRAME_TYPE_AUDIO, false); if (ret) -@@ -1406,6 +1457,8 @@ static void vc4_hdmi_audio_shutdown(stru +@@ -1407,6 +1458,8 @@ static void vc4_hdmi_audio_shutdown(stru struct vc4_hdmi *vc4_hdmi = dev_get_drvdata(dev); unsigned long flags; @@ -302,7 +302,7 @@ Signed-off-by: Maxime Ripard spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); HDMI_WRITE(HDMI_MAI_CTL, -@@ -1420,6 +1473,8 @@ static void vc4_hdmi_audio_shutdown(stru +@@ -1421,6 +1474,8 @@ static void vc4_hdmi_audio_shutdown(stru vc4_hdmi->audio.streaming = false; vc4_hdmi_audio_reset(vc4_hdmi); @@ -311,7 +311,7 @@ Signed-off-by: Maxime Ripard } static int sample_rate_to_mai_fmt(int samplerate) -@@ -1478,6 +1533,8 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1479,6 +1534,8 @@ static int vc4_hdmi_audio_prepare(struct dev_dbg(dev, "%s: %u Hz, %d bit, %d channels\n", __func__, sample_rate, params->sample_width, channels); @@ -320,7 +320,7 @@ Signed-off-by: Maxime Ripard vc4_hdmi_audio_set_mai_clock(vc4_hdmi, sample_rate); spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); -@@ -1532,6 +1589,8 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1533,6 +1590,8 @@ static int vc4_hdmi_audio_prepare(struct memcpy(&vc4_hdmi->audio.infoframe, ¶ms->cea, sizeof(params->cea)); vc4_hdmi_set_audio_infoframe(encoder); @@ -329,7 +329,7 @@ Signed-off-by: Maxime Ripard return 0; } -@@ -1574,7 +1633,9 @@ static int vc4_hdmi_audio_get_eld(struct +@@ -1575,7 +1634,9 @@ static int vc4_hdmi_audio_get_eld(struct struct vc4_hdmi *vc4_hdmi = dev_get_drvdata(dev); struct drm_connector *connector = &vc4_hdmi->connector; @@ -339,7 +339,7 @@ Signed-off-by: Maxime Ripard return 0; } -@@ -1911,6 +1972,17 @@ static int vc4_hdmi_cec_enable(struct ce +@@ -1912,6 +1973,17 @@ static int vc4_hdmi_cec_enable(struct ce u32 val; int ret; @@ -357,7 +357,7 @@ Signed-off-by: Maxime Ripard ret = pm_runtime_resume_and_get(&vc4_hdmi->pdev->dev); if (ret) return ret; -@@ -1957,6 +2029,17 @@ static int vc4_hdmi_cec_disable(struct c +@@ -1958,6 +2030,17 @@ static int vc4_hdmi_cec_disable(struct c struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); unsigned long flags; @@ -375,7 +375,7 @@ Signed-off-by: Maxime Ripard spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); if (!vc4_hdmi->variant->external_irq_controller) -@@ -1985,6 +2068,17 @@ static int vc4_hdmi_cec_adap_log_addr(st +@@ -1986,6 +2069,17 @@ static int vc4_hdmi_cec_adap_log_addr(st struct vc4_hdmi *vc4_hdmi = cec_get_drvdata(adap); unsigned long flags; @@ -393,7 +393,7 @@ Signed-off-by: Maxime Ripard spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); HDMI_WRITE(HDMI_CEC_CNTRL_1, (HDMI_READ(HDMI_CEC_CNTRL_1) & ~VC4_HDMI_CEC_ADDR_MASK) | -@@ -2003,6 +2097,17 @@ static int vc4_hdmi_cec_adap_transmit(st +@@ -2004,6 +2098,17 @@ static int vc4_hdmi_cec_adap_transmit(st u32 val; unsigned int i; @@ -411,7 +411,7 @@ Signed-off-by: Maxime Ripard if (msg->len > 16) { drm_err(dev, "Attempting to transmit too much data (%d)\n", msg->len); return -ENOMEM; -@@ -2359,6 +2464,7 @@ static int vc4_hdmi_bind(struct device * +@@ -2360,6 +2465,7 @@ static int vc4_hdmi_bind(struct device * vc4_hdmi = devm_kzalloc(dev, sizeof(*vc4_hdmi), GFP_KERNEL); if (!vc4_hdmi) return -ENOMEM; diff --git a/target/linux/bcm27xx/patches-5.15/950-0009-drm-vc4-hdmi-Prevent-access-to-crtc-state-outside-of.patch b/target/linux/bcm27xx/patches-5.15/950-0009-drm-vc4-hdmi-Prevent-access-to-crtc-state-outside-of.patch index 117ccf3b0..c298d2cde 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0009-drm-vc4-hdmi-Prevent-access-to-crtc-state-outside-of.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0009-drm-vc4-hdmi-Prevent-access-to-crtc-state-outside-of.patch @@ -73,7 +73,7 @@ Signed-off-by: Maxime Ripard return; if (delayed_work_pending(&vc4_hdmi->scrambling_work)) -@@ -1017,8 +1019,8 @@ static void vc4_hdmi_encoder_pre_crtc_co +@@ -1018,8 +1020,8 @@ static void vc4_hdmi_encoder_pre_crtc_co vc4_hdmi_encoder_get_connector_state(encoder, state); struct vc4_hdmi_connector_state *vc4_conn_state = conn_state_to_vc4_hdmi_conn_state(conn_state); @@ -83,7 +83,7 @@ Signed-off-by: Maxime Ripard unsigned long pixel_rate = vc4_conn_state->pixel_rate; unsigned long bvb_rate, hsm_rate; unsigned long flags; -@@ -1120,9 +1122,9 @@ out: +@@ -1121,9 +1123,9 @@ out: static void vc4_hdmi_encoder_pre_crtc_enable(struct drm_encoder *encoder, struct drm_atomic_state *state) { @@ -95,7 +95,7 @@ Signed-off-by: Maxime Ripard unsigned long flags; mutex_lock(&vc4_hdmi->mutex); -@@ -1150,8 +1152,8 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1151,8 +1153,8 @@ static void vc4_hdmi_encoder_pre_crtc_en static void vc4_hdmi_encoder_post_crtc_enable(struct drm_encoder *encoder, struct drm_atomic_state *state) { @@ -105,7 +105,7 @@ Signed-off-by: Maxime Ripard struct vc4_hdmi_encoder *vc4_encoder = to_vc4_hdmi_encoder(encoder); bool hsync_pos = mode->flags & DRM_MODE_FLAG_PHSYNC; bool vsync_pos = mode->flags & DRM_MODE_FLAG_PVSYNC; -@@ -1227,6 +1229,19 @@ static void vc4_hdmi_encoder_enable(stru +@@ -1228,6 +1230,19 @@ static void vc4_hdmi_encoder_enable(stru { } @@ -125,7 +125,7 @@ Signed-off-by: Maxime Ripard #define WIFI_2_4GHz_CH1_MIN_FREQ 2400000000ULL #define WIFI_2_4GHz_CH1_MAX_FREQ 2422000000ULL -@@ -1305,6 +1320,7 @@ vc4_hdmi_encoder_mode_valid(struct drm_e +@@ -1306,6 +1321,7 @@ vc4_hdmi_encoder_mode_valid(struct drm_e static const struct drm_encoder_helper_funcs vc4_hdmi_encoder_helper_funcs = { .atomic_check = vc4_hdmi_encoder_atomic_check, @@ -133,7 +133,7 @@ Signed-off-by: Maxime Ripard .mode_valid = vc4_hdmi_encoder_mode_valid, .disable = vc4_hdmi_encoder_disable, .enable = vc4_hdmi_encoder_enable, -@@ -1358,9 +1374,7 @@ static void vc4_hdmi_audio_set_mai_clock +@@ -1359,9 +1375,7 @@ static void vc4_hdmi_audio_set_mai_clock static void vc4_hdmi_set_n_cts(struct vc4_hdmi *vc4_hdmi, unsigned int samplerate) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0010-drm-vc4-hdmi-Check-the-device-state-in-prepare.patch b/target/linux/bcm27xx/patches-5.15/950-0010-drm-vc4-hdmi-Check-the-device-state-in-prepare.patch index cf78bb0b1..31243f810 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0010-drm-vc4-hdmi-Check-the-device-state-in-prepare.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0010-drm-vc4-hdmi-Check-the-device-state-in-prepare.patch @@ -19,7 +19,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1406,20 +1406,36 @@ static inline struct vc4_hdmi *dai_to_hd +@@ -1407,20 +1407,36 @@ static inline struct vc4_hdmi *dai_to_hd return snd_soc_card_get_drvdata(card); } @@ -63,7 +63,7 @@ Signed-off-by: Maxime Ripard mutex_unlock(&vc4_hdmi->mutex); return -ENODEV; } -@@ -1549,6 +1565,11 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1550,6 +1566,11 @@ static int vc4_hdmi_audio_prepare(struct mutex_lock(&vc4_hdmi->mutex); diff --git a/target/linux/bcm27xx/patches-5.15/950-0011-drm-vc4-hdmi-Introduce-an-output_enabled-flag.patch b/target/linux/bcm27xx/patches-5.15/950-0011-drm-vc4-hdmi-Introduce-an-output_enabled-flag.patch index 40927805c..326fd7526 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0011-drm-vc4-hdmi-Introduce-an-output_enabled-flag.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0011-drm-vc4-hdmi-Introduce-an-output_enabled-flag.patch @@ -32,7 +32,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_csc_setup(struct vc4_hdmi *vc4_hdmi, bool enable) -@@ -1227,6 +1232,11 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1228,6 +1233,11 @@ static void vc4_hdmi_encoder_post_crtc_e static void vc4_hdmi_encoder_enable(struct drm_encoder *encoder) { @@ -44,7 +44,7 @@ Signed-off-by: Maxime Ripard } static void vc4_hdmi_encoder_atomic_mode_set(struct drm_encoder *encoder, -@@ -1408,14 +1418,12 @@ static inline struct vc4_hdmi *dai_to_hd +@@ -1409,14 +1419,12 @@ static inline struct vc4_hdmi *dai_to_hd static bool vc4_hdmi_audio_can_stream(struct vc4_hdmi *vc4_hdmi) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0012-drm-vc4-hdmi-Introduce-a-scdc_enabled-flag.patch b/target/linux/bcm27xx/patches-5.15/950-0012-drm-vc4-hdmi-Introduce-a-scdc_enabled-flag.patch index b11ea0570..2a7ac223a 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0012-drm-vc4-hdmi-Introduce-a-scdc_enabled-flag.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0012-drm-vc4-hdmi-Introduce-a-scdc_enabled-flag.patch @@ -69,7 +69,7 @@ Signed-off-by: Maxime Ripard if (delayed_work_pending(&vc4_hdmi->scrambling_work)) cancel_delayed_work_sync(&vc4_hdmi->scrambling_work); -@@ -2522,6 +2516,14 @@ static int vc4_hdmi_bind(struct device * +@@ -2523,6 +2517,14 @@ static int vc4_hdmi_bind(struct device * vc4_hdmi->pdev = pdev; vc4_hdmi->variant = variant; diff --git a/target/linux/bcm27xx/patches-5.15/950-0017-drm-vc4-Leverage-the-load-tracker-on-the-BCM2711.patch b/target/linux/bcm27xx/patches-5.15/950-0017-drm-vc4-Leverage-the-load-tracker-on-the-BCM2711.patch index 6f26f0f28..f13a8c73e 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0017-drm-vc4-Leverage-the-load-tracker-on-the-BCM2711.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0017-drm-vc4-Leverage-the-load-tracker-on-the-BCM2711.patch @@ -109,7 +109,7 @@ Signed-off-by: Maxime Ripard */ --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -525,11 +525,6 @@ static void vc4_plane_calc_load(struct d +@@ -527,11 +527,6 @@ static void vc4_plane_calc_load(struct d struct vc4_plane_state *vc4_state; struct drm_crtc_state *crtc_state; unsigned int vscale_factor; diff --git a/target/linux/bcm27xx/patches-5.15/950-0021-drm-vc4-hdmi-Actually-check-for-the-connector-status.patch b/target/linux/bcm27xx/patches-5.15/950-0021-drm-vc4-hdmi-Actually-check-for-the-connector-status.patch index 54c5d9302..96913ed7b 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0021-drm-vc4-hdmi-Actually-check-for-the-connector-status.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0021-drm-vc4-hdmi-Actually-check-for-the-connector-status.patch @@ -44,7 +44,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1801,10 +1801,11 @@ static void vc4_hdmi_audio_exit(struct v +@@ -1802,10 +1802,11 @@ static void vc4_hdmi_audio_exit(struct v static irqreturn_t vc4_hdmi_hpd_irq_thread(int irq, void *priv) { struct vc4_hdmi *vc4_hdmi = priv; diff --git a/target/linux/bcm27xx/patches-5.15/950-0062-pinctrl-bcm2835-Set-base-to-0-give-expected-gpio-num.patch b/target/linux/bcm27xx/patches-5.15/950-0062-pinctrl-bcm2835-Set-base-to-0-give-expected-gpio-num.patch index c4360e12e..e4aef4074 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0062-pinctrl-bcm2835-Set-base-to-0-give-expected-gpio-num.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0062-pinctrl-bcm2835-Set-base-to-0-give-expected-gpio-num.patch @@ -20,7 +20,7 @@ Signed-off-by: Phil Elwell --- a/drivers/pinctrl/bcm/pinctrl-bcm2835.c +++ b/drivers/pinctrl/bcm/pinctrl-bcm2835.c -@@ -378,7 +378,7 @@ static const struct gpio_chip bcm2835_gp +@@ -376,7 +376,7 @@ static const struct gpio_chip bcm2835_gp .get = bcm2835_gpio_get, .set = bcm2835_gpio_set, .set_config = gpiochip_generic_config, @@ -29,7 +29,7 @@ Signed-off-by: Phil Elwell .ngpio = BCM2835_NUM_GPIOS, .can_sleep = false, .of_gpio_ranges_fallback = bcm2835_of_gpio_ranges_fallback, -@@ -395,7 +395,7 @@ static const struct gpio_chip bcm2711_gp +@@ -393,7 +393,7 @@ static const struct gpio_chip bcm2711_gp .get = bcm2835_gpio_get, .set = bcm2835_gpio_set, .set_config = gpiochip_generic_config, diff --git a/target/linux/bcm27xx/patches-5.15/950-0144-bcmgenet-Better-coalescing-parameter-defaults.patch b/target/linux/bcm27xx/patches-5.15/950-0144-bcmgenet-Better-coalescing-parameter-defaults.patch index 17512cfcc..243605680 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0144-bcmgenet-Better-coalescing-parameter-defaults.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0144-bcmgenet-Better-coalescing-parameter-defaults.patch @@ -18,7 +18,7 @@ Signed-off-by: Phil Elwell --- a/drivers/net/ethernet/broadcom/genet/bcmgenet.c +++ b/drivers/net/ethernet/broadcom/genet/bcmgenet.c -@@ -2608,7 +2608,7 @@ static void bcmgenet_init_tx_ring(struct +@@ -2616,7 +2616,7 @@ static void bcmgenet_init_tx_ring(struct bcmgenet_tdma_ring_writel(priv, index, 0, TDMA_PROD_INDEX); bcmgenet_tdma_ring_writel(priv, index, 0, TDMA_CONS_INDEX); @@ -27,7 +27,7 @@ Signed-off-by: Phil Elwell /* Disable rate control for now */ bcmgenet_tdma_ring_writel(priv, index, flow_period_val, TDMA_FLOW_PERIOD); -@@ -4075,9 +4075,12 @@ static int bcmgenet_probe(struct platfor +@@ -4083,9 +4083,12 @@ static int bcmgenet_probe(struct platfor netif_set_real_num_rx_queues(priv->dev, priv->hw_params->rx_queues + 1); /* Set default coalescing parameters */ diff --git a/target/linux/bcm27xx/patches-5.15/950-0145-net-genet-enable-link-energy-detect-powerdown-for-ex.patch b/target/linux/bcm27xx/patches-5.15/950-0145-net-genet-enable-link-energy-detect-powerdown-for-ex.patch index f817fbc2b..cde33a576 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0145-net-genet-enable-link-energy-detect-powerdown-for-ex.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0145-net-genet-enable-link-energy-detect-powerdown-for-ex.patch @@ -20,7 +20,7 @@ Signed-off-by: Jonathan Bell --- a/drivers/net/ethernet/broadcom/genet/bcmmii.c +++ b/drivers/net/ethernet/broadcom/genet/bcmmii.c -@@ -293,6 +293,8 @@ int bcmgenet_mii_probe(struct net_device +@@ -286,6 +286,8 @@ int bcmgenet_mii_probe(struct net_device /* Communicate the integrated PHY revision */ if (priv->internal_phy) phy_flags = priv->gphy_rev; diff --git a/target/linux/bcm27xx/patches-5.15/950-0165-net-bcmgenet-Workaround-2-for-Pi4-Ethernet-fail.patch b/target/linux/bcm27xx/patches-5.15/950-0165-net-bcmgenet-Workaround-2-for-Pi4-Ethernet-fail.patch index b2f4e6c8c..b18208276 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0165-net-bcmgenet-Workaround-2-for-Pi4-Ethernet-fail.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0165-net-bcmgenet-Workaround-2-for-Pi4-Ethernet-fail.patch @@ -37,7 +37,7 @@ Signed-off-by: Phil Elwell static inline void bcmgenet_writel(u32 value, void __iomem *offset) { -@@ -2439,6 +2442,11 @@ static void reset_umac(struct bcmgenet_p +@@ -2447,6 +2450,11 @@ static void reset_umac(struct bcmgenet_p bcmgenet_rbuf_ctrl_set(priv, 0); udelay(10); diff --git a/target/linux/bcm27xx/patches-5.15/950-0192-pinctrl-bcm2835-Remove-gpiochip-on-error.patch b/target/linux/bcm27xx/patches-5.15/950-0192-pinctrl-bcm2835-Remove-gpiochip-on-error.patch index 5f4c605a8..3c065b0ef 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0192-pinctrl-bcm2835-Remove-gpiochip-on-error.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0192-pinctrl-bcm2835-Remove-gpiochip-on-error.patch @@ -14,7 +14,7 @@ Signed-off-by: Phil Elwell --- a/drivers/pinctrl/bcm/pinctrl-bcm2835.c +++ b/drivers/pinctrl/bcm/pinctrl-bcm2835.c -@@ -1339,7 +1339,7 @@ static int bcm2835_pinctrl_probe(struct +@@ -1337,7 +1337,7 @@ static int bcm2835_pinctrl_probe(struct girq->default_type = IRQ_TYPE_NONE; girq->handler = handle_level_irq; diff --git a/target/linux/bcm27xx/patches-5.15/950-0292-net-bcmgenet-Reset-RBUF-on-first-open.patch b/target/linux/bcm27xx/patches-5.15/950-0292-net-bcmgenet-Reset-RBUF-on-first-open.patch index 42df30457..cd50ba180 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0292-net-bcmgenet-Reset-RBUF-on-first-open.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0292-net-bcmgenet-Reset-RBUF-on-first-open.patch @@ -24,7 +24,7 @@ Signed-off-by: Phil Elwell --- a/drivers/net/ethernet/broadcom/genet/bcmgenet.c +++ b/drivers/net/ethernet/broadcom/genet/bcmgenet.c -@@ -3257,7 +3257,7 @@ static void bcmgenet_get_hw_addr(struct +@@ -3265,7 +3265,7 @@ static void bcmgenet_get_hw_addr(struct } /* Returns a reusable dma control register value */ @@ -33,7 +33,7 @@ Signed-off-by: Phil Elwell { unsigned int i; u32 reg; -@@ -3282,6 +3282,14 @@ static u32 bcmgenet_dma_disable(struct b +@@ -3290,6 +3290,14 @@ static u32 bcmgenet_dma_disable(struct b udelay(10); bcmgenet_umac_writel(priv, 0, UMAC_TX_FLUSH); @@ -48,7 +48,7 @@ Signed-off-by: Phil Elwell return dma_ctrl; } -@@ -3345,8 +3353,8 @@ static int bcmgenet_open(struct net_devi +@@ -3353,8 +3361,8 @@ static int bcmgenet_open(struct net_devi bcmgenet_set_hw_addr(priv, dev->dev_addr); @@ -59,7 +59,7 @@ Signed-off-by: Phil Elwell /* Reinitialize TDMA and RDMA and SW housekeeping */ ret = bcmgenet_init_dma(priv); -@@ -4204,7 +4212,7 @@ static int bcmgenet_resume(struct device +@@ -4212,7 +4220,7 @@ static int bcmgenet_resume(struct device bcmgenet_hfb_create_rxnfc_filter(priv, rule); /* Disable RX/TX DMA and flush TX queues */ diff --git a/target/linux/bcm27xx/patches-5.15/950-0421-Support-RPi-DPI-interface-in-mode6-for-18-bit-color.patch b/target/linux/bcm27xx/patches-5.15/950-0421-Support-RPi-DPI-interface-in-mode6-for-18-bit-color.patch deleted file mode 100644 index ef115fe2f..000000000 --- a/target/linux/bcm27xx/patches-5.15/950-0421-Support-RPi-DPI-interface-in-mode6-for-18-bit-color.patch +++ /dev/null @@ -1,214 +0,0 @@ -From a08e51a8b93f857cde93ddd7730c1cdedb6ccdd1 Mon Sep 17 00:00:00 2001 -From: Joerg Quinten -Date: Fri, 18 Jun 2021 13:02:29 +0200 -Subject: [PATCH] Support RPi DPI interface in mode6 for 18-bit color - -A matching media bus format was added and an overlay for using it, -both with FB and VC4 was added as well. - -Signed-off-by: Joerg Quinten ---- - .../bindings/display/panel/panel-simple.yaml | 2 + - .../media/v4l/subdev-formats.rst | 74 +++++++++++++++++++ - drivers/gpu/drm/panel/panel-simple.c | 35 +++++++++ - drivers/gpu/drm/vc4/vc4_dpi.c | 10 +++ - include/uapi/linux/media-bus-format.h | 4 +- - 5 files changed, 124 insertions(+), 1 deletion(-) - ---- a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml -+++ b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml -@@ -162,6 +162,8 @@ properties: - - ivo,m133nwf4-r0 - # Innolux AT043TN24 4.3" WQVGA TFT LCD panel - - innolux,at043tn24 -+ # Innolux AT056tN53V1 5.6" VGA (640x480) TFT LCD panel -+ - innolux,at056tn53v1 - # Innolux AT070TN92 7.0" WQVGA TFT LCD panel - - innolux,at070tn92 - # Innolux G070Y2-L01 7" WVGA (800x480) TFT LCD panel ---- a/Documentation/userspace-api/media/v4l/subdev-formats.rst -+++ b/Documentation/userspace-api/media/v4l/subdev-formats.rst -@@ -912,6 +912,43 @@ The following tables list existing packe - - g\ :sub:`5` - - g\ :sub:`4` - - g\ :sub:`3` -+ * .. _MEDIA-BUS-FMT-BGR666-1X18: -+ -+ - MEDIA_BUS_FMT_RGB666_1X18 -+ - 0x101f -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - b\ :sub:`5` -+ - b\ :sub:`4` -+ - b\ :sub:`3` -+ - b\ :sub:`2` -+ - b\ :sub:`1` -+ - b\ :sub:`0` -+ - g\ :sub:`5` -+ - g\ :sub:`4` -+ - g\ :sub:`3` -+ - g\ :sub:`2` -+ - g\ :sub:`1` -+ - g\ :sub:`0` -+ - r\ :sub:`5` -+ - r\ :sub:`4` -+ - r\ :sub:`3` -+ - r\ :sub:`2` -+ - r\ :sub:`1` -+ - r\ :sub:`0` - * .. _MEDIA-BUS-FMT-RGB666-1X18: - - - MEDIA_BUS_FMT_RGB666_1X18 -@@ -986,6 +1023,43 @@ The following tables list existing packe - - g\ :sub:`2` - - g\ :sub:`1` - - g\ :sub:`0` -+ * .. _MEDIA-BUS-FMT-BGR666-1X24_CPADHI: -+ -+ - MEDIA_BUS_FMT_BGR666_1X24_CPADHI -+ - 0x101e -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - -+ - 0 -+ - 0 -+ - b\ :sub:`5` -+ - b\ :sub:`4` -+ - b\ :sub:`3` -+ - b\ :sub:`2` -+ - b\ :sub:`1` -+ - b\ :sub:`0` -+ - 0 -+ - 0 -+ - g\ :sub:`5` -+ - g\ :sub:`4` -+ - g\ :sub:`3` -+ - g\ :sub:`2` -+ - g\ :sub:`1` -+ - g\ :sub:`0` -+ - 0 -+ - 0 -+ - r\ :sub:`5` -+ - r\ :sub:`4` -+ - r\ :sub:`3` -+ - r\ :sub:`2` -+ - r\ :sub:`1` -+ - r\ :sub:`0` - * .. _MEDIA-BUS-FMT-RGB666-1X24_CPADHI: - - - MEDIA_BUS_FMT_RGB666_1X24_CPADHI ---- a/drivers/gpu/drm/panel/panel-simple.c -+++ b/drivers/gpu/drm/panel/panel-simple.c -@@ -2472,6 +2472,38 @@ static const struct panel_desc innolux_a - .bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_DRIVE_POSEDGE, - }; - -+static const struct display_timing innolux_at056tn53v1_timing = { -+ .pixelclock = { 39700000, 39700000, 39700000}, -+ .hactive = { 640, 640, 640 }, -+ .hfront_porch = { 16, 16, 16 }, -+ .hback_porch = { 134, 134, 134 }, -+ .hsync_len = { 10, 10, 10}, -+ .vactive = { 480, 480, 480 }, -+ .vfront_porch = { 32, 32, 32}, -+ .vback_porch = { 11, 11, 11 }, -+ .vsync_len = { 2, 2, 2 }, -+ .flags = DRM_MODE_FLAG_PVSYNC | DRM_MODE_FLAG_PHSYNC, -+}; -+ -+static const struct panel_desc innolux_at056tn53v1 = { -+ .timings = &innolux_at056tn53v1_timing, -+ .num_timings = 1, -+ .bpc = 6, -+ .size = { -+ .width = 112, -+ .height = 84, -+ }, -+ .delay = { -+ .prepare = 50, -+ .enable = 200, -+ .disable = 110, -+ .unprepare = 200, -+ }, -+ .bus_format = MEDIA_BUS_FMT_BGR666_1X24_CPADHI, -+ .bus_flags = DRM_BUS_FLAG_PIXDATA_SAMPLE_POSEDGE, -+ .connector_type = DRM_MODE_CONNECTOR_DPI, -+}; -+ - static const struct drm_display_mode innolux_at070tn92_mode = { - .clock = 33333, - .hdisplay = 800, -@@ -4662,6 +4694,9 @@ static const struct of_device_id platfor - .compatible = "innolux,at043tn24", - .data = &innolux_at043tn24, - }, { -+ .compatible = "innolux,at056tn53v1", -+ .data = &innolux_at056tn53v1, -+ }, { - .compatible = "innolux,at070tn92", - .data = &innolux_at070tn92, - }, { ---- a/drivers/gpu/drm/vc4/vc4_dpi.c -+++ b/drivers/gpu/drm/vc4/vc4_dpi.c -@@ -165,10 +165,20 @@ static void vc4_dpi_encoder_enable(struc - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, - DPI_FORMAT); - break; -+ case MEDIA_BUS_FMT_BGR666_1X24_CPADHI: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, -+ DPI_FORMAT); -+ dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, DPI_ORDER); -+ break; - case MEDIA_BUS_FMT_RGB666_1X18: - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, - DPI_FORMAT); - break; -+ case MEDIA_BUS_FMT_BGR666_1X18: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, -+ DPI_FORMAT); -+ dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, DPI_ORDER); -+ break; - case MEDIA_BUS_FMT_RGB565_1X16: - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, - DPI_FORMAT); ---- a/include/uapi/linux/media-bus-format.h -+++ b/include/uapi/linux/media-bus-format.h -@@ -34,7 +34,7 @@ - - #define MEDIA_BUS_FMT_FIXED 0x0001 - --/* RGB - next is 0x101e */ -+/* RGB - next is 0x1020 */ - #define MEDIA_BUS_FMT_RGB444_1X12 0x1016 - #define MEDIA_BUS_FMT_RGB444_2X8_PADHI_BE 0x1001 - #define MEDIA_BUS_FMT_RGB444_2X8_PADHI_LE 0x1002 -@@ -45,8 +45,10 @@ - #define MEDIA_BUS_FMT_BGR565_2X8_LE 0x1006 - #define MEDIA_BUS_FMT_RGB565_2X8_BE 0x1007 - #define MEDIA_BUS_FMT_RGB565_2X8_LE 0x1008 -+#define MEDIA_BUS_FMT_BGR666_1X18 0x101f - #define MEDIA_BUS_FMT_RGB666_1X18 0x1009 - #define MEDIA_BUS_FMT_RBG888_1X24 0x100e -+#define MEDIA_BUS_FMT_BGR666_1X24_CPADHI 0x101e - #define MEDIA_BUS_FMT_RGB666_1X24_CPADHI 0x1015 - #define MEDIA_BUS_FMT_RGB666_1X7X3_SPWG 0x1010 - #define MEDIA_BUS_FMT_BGR888_1X24 0x1013 diff --git a/target/linux/bcm27xx/patches-5.15/950-0422-drm-vc4-plane-Add-support-for-DRM_FORMAT_P030.patch b/target/linux/bcm27xx/patches-5.15/950-0422-drm-vc4-plane-Add-support-for-DRM_FORMAT_P030.patch index 3dc01372e..43da4fad4 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0422-drm-vc4-plane-Add-support-for-DRM_FORMAT_P030.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0422-drm-vc4-plane-Add-support-for-DRM_FORMAT_P030.patch @@ -26,7 +26,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech } hvs_formats[] = { { .drm = DRM_FORMAT_XRGB8888, -@@ -128,6 +129,12 @@ static const struct hvs_format { +@@ -130,6 +131,12 @@ static const struct hvs_format { .hvs = HVS_PIXEL_FORMAT_YCBCR_YUV422_2PLANE, .pixel_order = HVS_PIXEL_ORDER_XYCRCB, }, @@ -39,7 +39,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech }; static const struct hvs_format *vc4_get_hvs_format(u32 drm_format) -@@ -758,47 +765,90 @@ static int vc4_plane_mode_set(struct drm +@@ -760,47 +767,90 @@ static int vc4_plane_mode_set(struct drm case DRM_FORMAT_MOD_BROADCOM_SAND128: case DRM_FORMAT_MOD_BROADCOM_SAND256: { uint32_t param = fourcc_mod_broadcom_param(fb->modifier); @@ -157,7 +157,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech } pitch0 = VC4_SET_FIELD(param, SCALER_TILE_HEIGHT); -@@ -951,7 +1001,8 @@ static int vc4_plane_mode_set(struct drm +@@ -953,7 +1003,8 @@ static int vc4_plane_mode_set(struct drm /* Pitch word 1/2 */ for (i = 1; i < num_planes; i++) { @@ -167,7 +167,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech vc4_dlist_write(vc4_state, VC4_SET_FIELD(fb->pitches[i], SCALER_SRC_PITCH)); -@@ -1311,6 +1362,13 @@ static bool vc4_format_mod_supported(str +@@ -1313,6 +1364,13 @@ static bool vc4_format_mod_supported(str default: return false; } @@ -181,7 +181,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech case DRM_FORMAT_RGBX1010102: case DRM_FORMAT_BGRX1010102: case DRM_FORMAT_RGBA1010102: -@@ -1343,8 +1401,11 @@ struct drm_plane *vc4_plane_init(struct +@@ -1345,8 +1403,11 @@ struct drm_plane *vc4_plane_init(struct struct drm_plane *plane = NULL; struct vc4_plane *vc4_plane; u32 formats[ARRAY_SIZE(hvs_formats)]; @@ -193,7 +193,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-3-maxime@cerno.tech static const uint64_t modifiers[] = { DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED, DRM_FORMAT_MOD_BROADCOM_SAND128, -@@ -1359,13 +1420,17 @@ struct drm_plane *vc4_plane_init(struct +@@ -1361,13 +1422,17 @@ struct drm_plane *vc4_plane_init(struct if (!vc4_plane) return ERR_PTR(-ENOMEM); diff --git a/target/linux/bcm27xx/patches-5.15/950-0423-drm-vc4-plane-Add-support-for-YUV-color-encodings-an.patch b/target/linux/bcm27xx/patches-5.15/950-0423-drm-vc4-plane-Add-support-for-YUV-color-encodings-an.patch index 8620d083d..d230566e6 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0423-drm-vc4-plane-Add-support-for-YUV-color-encodings-an.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0423-drm-vc4-plane-Add-support-for-YUV-color-encodings-an.patch @@ -21,7 +21,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -619,6 +619,51 @@ static int vc4_plane_allocate_lbm(struct +@@ -621,6 +621,51 @@ static int vc4_plane_allocate_lbm(struct return 0; } @@ -73,7 +73,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech /* Writes out a full display list for an active plane to the plane's * private dlist state. */ -@@ -1013,9 +1058,20 @@ static int vc4_plane_mode_set(struct drm +@@ -1015,9 +1060,20 @@ static int vc4_plane_mode_set(struct drm /* Colorspace conversion words */ if (vc4_state->is_yuv) { @@ -97,7 +97,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech } vc4_state->lbm_offset = 0; -@@ -1444,6 +1500,15 @@ struct drm_plane *vc4_plane_init(struct +@@ -1446,6 +1502,15 @@ struct drm_plane *vc4_plane_init(struct DRM_MODE_REFLECT_X | DRM_MODE_REFLECT_Y); @@ -115,7 +115,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -983,7 +983,10 @@ enum hvs_pixel_format { +@@ -989,7 +989,10 @@ enum hvs_pixel_format { #define SCALER_CSC0_COEF_CR_OFS_SHIFT 0 #define SCALER_CSC0_ITR_R_601_5 0x00f00000 #define SCALER_CSC0_ITR_R_709_3 0x00f00000 @@ -126,7 +126,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech /* S2.8 contribution of Cb to Green */ #define SCALER_CSC1_COEF_CB_GRN_MASK VC4_MASK(31, 22) -@@ -998,8 +1001,11 @@ enum hvs_pixel_format { +@@ -1004,8 +1007,11 @@ enum hvs_pixel_format { #define SCALER_CSC1_COEF_CR_BLU_MASK VC4_MASK(1, 0) #define SCALER_CSC1_COEF_CR_BLU_SHIFT 0 #define SCALER_CSC1_ITR_R_601_5 0xe73304a8 @@ -140,7 +140,7 @@ Link: https://lore.kernel.org/r/20211215091739.135042-4-maxime@cerno.tech /* S2.8 contribution of Cb to Red */ #define SCALER_CSC2_COEF_CB_RED_MASK VC4_MASK(29, 20) -@@ -1010,9 +1016,12 @@ enum hvs_pixel_format { +@@ -1016,9 +1022,12 @@ enum hvs_pixel_format { /* S2.8 contribution of Cb to Blue */ #define SCALER_CSC2_COEF_CB_BLU_MASK VC4_MASK(19, 10) #define SCALER_CSC2_COEF_CB_BLU_SHIFT 10 diff --git a/target/linux/bcm27xx/patches-5.15/950-0426-drm-vc4-Add-debugfs-node-that-dumps-the-current-disp.patch b/target/linux/bcm27xx/patches-5.15/950-0426-drm-vc4-Add-debugfs-node-that-dumps-the-current-disp.patch index 3fff69a67..d7a5dcaff 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0426-drm-vc4-Add-debugfs-node-that-dumps-the-current-disp.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0426-drm-vc4-Add-debugfs-node-that-dumps-the-current-disp.patch @@ -59,7 +59,7 @@ Signed-off-by: Dave Stevenson /* The filter kernel is composed of dwords each containing 3 9-bit * signed integers packed next to each other. */ -@@ -728,6 +767,8 @@ static int vc4_hvs_bind(struct device *d +@@ -739,6 +778,8 @@ static int vc4_hvs_bind(struct device *d vc4_debugfs_add_regset32(drm, "hvs_regs", &hvs->regset); vc4_debugfs_add_file(drm, "hvs_underrun", vc4_hvs_debugfs_underrun, NULL); diff --git a/target/linux/bcm27xx/patches-5.15/950-0427-drm-vc4-Add-all-the-HDMI-registers-into-the-debugfs-.patch b/target/linux/bcm27xx/patches-5.15/950-0427-drm-vc4-Add-all-the-HDMI-registers-into-the-debugfs-.patch index f25a72547..5ae2b9f48 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0427-drm-vc4-Add-all-the-HDMI-registers-into-the-debugfs-.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0427-drm-vc4-Add-all-the-HDMI-registers-into-the-debugfs-.patch @@ -29,7 +29,7 @@ Signed-off-by: Dave Stevenson return 0; } -@@ -2369,6 +2375,7 @@ static int vc5_hdmi_init_resources(struc +@@ -2370,6 +2376,7 @@ static int vc5_hdmi_init_resources(struc struct platform_device *pdev = vc4_hdmi->pdev; struct device *dev = &pdev->dev; struct resource *res; @@ -37,7 +37,7 @@ Signed-off-by: Dave Stevenson res = platform_get_resource_byname(pdev, IORESOURCE_MEM, "hdmi"); if (!res) -@@ -2465,6 +2472,38 @@ static int vc5_hdmi_init_resources(struc +@@ -2466,6 +2473,38 @@ static int vc5_hdmi_init_resources(struc return PTR_ERR(vc4_hdmi->reset); } diff --git a/target/linux/bcm27xx/patches-5.15/950-0431-drm-vc4-Change-the-default-DPI-format-to-being-18bpp.patch b/target/linux/bcm27xx/patches-5.15/950-0431-drm-vc4-Change-the-default-DPI-format-to-being-18bpp.patch index b278eb4dd..2a814ae9a 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0431-drm-vc4-Change-the-default-DPI-format-to-being-18bpp.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0431-drm-vc4-Change-the-default-DPI-format-to-being-18bpp.patch @@ -22,8 +22,8 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_dpi.c +++ b/drivers/gpu/drm/vc4/vc4_dpi.c @@ -188,8 +188,8 @@ static void vc4_dpi_encoder_enable(struc - break; - } + if (connector->display_info.bus_flags & DRM_BUS_FLAG_DE_LOW) + dpi_c |= DPI_OUTPUT_ENABLE_INVERT; } else { - /* Default to 24bit if no connector found. */ - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_24BIT_888_RGB, DPI_FORMAT); diff --git a/target/linux/bcm27xx/patches-5.15/950-0442-drm-vc4-hdmi-Simplify-the-connector-state-retrieval.patch b/target/linux/bcm27xx/patches-5.15/950-0442-drm-vc4-hdmi-Simplify-the-connector-state-retrieval.patch index aa7f0b5ae..01d9daa05 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0442-drm-vc4-hdmi-Simplify-the-connector-state-retrieval.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0442-drm-vc4-hdmi-Simplify-the-connector-state-retrieval.patch @@ -15,7 +15,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1011,30 +1011,15 @@ static void vc4_hdmi_recenter_fifo(struc +@@ -1012,30 +1012,15 @@ static void vc4_hdmi_recenter_fifo(struc "VC4_HDMI_FIFO_CTL_RECENTER_DONE"); } diff --git a/target/linux/bcm27xx/patches-5.15/950-0479-drm-panel-simple-Add-a-timing-for-the-Raspberry-Pi-7.patch b/target/linux/bcm27xx/patches-5.15/950-0479-drm-panel-simple-Add-a-timing-for-the-Raspberry-Pi-7.patch index 21aa2168a..17dc5405f 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0479-drm-panel-simple-Add-a-timing-for-the-Raspberry-Pi-7.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0479-drm-panel-simple-Add-a-timing-for-the-Raspberry-Pi-7.patch @@ -15,7 +15,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/panel/panel-simple.c +++ b/drivers/gpu/drm/panel/panel-simple.c -@@ -3761,6 +3761,31 @@ static const struct panel_desc qishenglo +@@ -3729,6 +3729,31 @@ static const struct panel_desc qishenglo .connector_type = DRM_MODE_CONNECTOR_DPI, }; @@ -47,7 +47,7 @@ Signed-off-by: Dave Stevenson static const struct display_timing rocktech_rk070er9427_timing = { .pixelclock = { 26400000, 33300000, 46800000 }, .hactive = { 800, 800, 800 }, -@@ -4841,6 +4866,9 @@ static const struct of_device_id platfor +@@ -4806,6 +4831,9 @@ static const struct of_device_id platfor .compatible = "qishenglong,gopher2b-lcd", .data = &qishenglong_gopher2b_lcd, }, { diff --git a/target/linux/bcm27xx/patches-5.15/950-0535-media-i2c-imx219-Sensor-should-report-RAW-color-spac.patch b/target/linux/bcm27xx/patches-5.15/950-0535-media-i2c-imx219-Sensor-should-report-RAW-color-spac.patch index 6a4f26252..c63a136ac 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0535-media-i2c-imx219-Sensor-should-report-RAW-color-spac.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0535-media-i2c-imx219-Sensor-should-report-RAW-color-spac.patch @@ -13,7 +13,7 @@ Signed-off-by: David Plowman --- a/drivers/media/i2c/imx219.c +++ b/drivers/media/i2c/imx219.c -@@ -674,7 +674,7 @@ static void imx219_set_default_format(st +@@ -584,7 +584,7 @@ static void imx219_set_default_format(st fmt = &imx219->fmt; fmt->code = MEDIA_BUS_FMT_SRGGB10_1X10; @@ -22,7 +22,7 @@ Signed-off-by: David Plowman fmt->ycbcr_enc = V4L2_MAP_YCBCR_ENC_DEFAULT(fmt->colorspace); fmt->quantization = V4L2_MAP_QUANTIZATION_DEFAULT(true, fmt->colorspace, -@@ -844,7 +844,7 @@ static int imx219_enum_frame_size(struct +@@ -754,7 +754,7 @@ static int imx219_enum_frame_size(struct static void imx219_reset_colorspace(struct v4l2_mbus_framefmt *fmt) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0551-drm-vc4-Add-support-for-gamma-on-BCM2711.patch b/target/linux/bcm27xx/patches-5.15/950-0551-drm-vc4-Add-support-for-gamma-on-BCM2711.patch index 555636515..302adfe98 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0551-drm-vc4-Add-support-for-gamma-on-BCM2711.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0551-drm-vc4-Add-support-for-gamma-on-BCM2711.patch @@ -241,7 +241,7 @@ Signed-off-by: Maxime Ripard /* Unsetting DISPBKGND_GAMMA skips the gamma lut step --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -499,6 +499,28 @@ +@@ -505,6 +505,28 @@ #define SCALER_DLIST_START 0x00002000 #define SCALER_DLIST_SIZE 0x00004000 diff --git a/target/linux/bcm27xx/patches-5.15/950-0552-drm-vc4-Add-debugfs-node-that-dumps-the-vc5-gamma-PW.patch b/target/linux/bcm27xx/patches-5.15/950-0552-drm-vc4-Add-debugfs-node-that-dumps-the-vc5-gamma-PW.patch index 7dbc6483d..4708dca62 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0552-drm-vc4-Add-debugfs-node-that-dumps-the-vc5-gamma-PW.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0552-drm-vc4-Add-debugfs-node-that-dumps-the-vc5-gamma-PW.patch @@ -102,7 +102,7 @@ Signed-off-by: Maxime Ripard /* The filter kernel is composed of dwords each containing 3 9-bit * signed integers packed next to each other. */ -@@ -848,6 +926,9 @@ static int vc4_hvs_bind(struct device *d +@@ -859,6 +937,9 @@ static int vc4_hvs_bind(struct device *d NULL); vc4_debugfs_add_file(drm, "hvs_dlists", vc4_hvs_debugfs_dlist, NULL); diff --git a/target/linux/bcm27xx/patches-5.15/950-0572-drm-vc4-Don-t-try-disabling-SCDC-on-Pi0-3.patch b/target/linux/bcm27xx/patches-5.15/950-0572-drm-vc4-Don-t-try-disabling-SCDC-on-Pi0-3.patch index 6b7acd8e4..3bb136f3c 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0572-drm-vc4-Don-t-try-disabling-SCDC-on-Pi0-3.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0572-drm-vc4-Don-t-try-disabling-SCDC-on-Pi0-3.patch @@ -20,7 +20,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -2557,7 +2557,8 @@ static int vc4_hdmi_bind(struct device * +@@ -2558,7 +2558,8 @@ static int vc4_hdmi_bind(struct device * * vc4_hdmi_disable_scrambling() will thus run at boot, make * sure it's disabled, and avoid any inconsistency. */ diff --git a/target/linux/bcm27xx/patches-5.15/950-0580-drm-vc4-Ensure-vc4_hdmi-doesn-t-use-2711-HPD-registe.patch b/target/linux/bcm27xx/patches-5.15/950-0580-drm-vc4-Ensure-vc4_hdmi-doesn-t-use-2711-HPD-registe.patch index 73f7ea871..689a3d952 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0580-drm-vc4-Ensure-vc4_hdmi-doesn-t-use-2711-HPD-registe.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0580-drm-vc4-Ensure-vc4_hdmi-doesn-t-use-2711-HPD-registe.patch @@ -36,7 +36,7 @@ Signed-off-by: Dave Stevenson connected = true; } -@@ -1355,6 +1349,18 @@ static u32 vc5_hdmi_channel_map(struct v +@@ -1356,6 +1350,18 @@ static u32 vc5_hdmi_channel_map(struct v return channel_map; } @@ -55,7 +55,7 @@ Signed-off-by: Dave Stevenson /* HDMI audio codec callbacks */ static void vc4_hdmi_audio_set_mai_clock(struct vc4_hdmi *vc4_hdmi, unsigned int samplerate) -@@ -2777,6 +2783,7 @@ static const struct vc4_hdmi_variant bcm +@@ -2778,6 +2784,7 @@ static const struct vc4_hdmi_variant bcm .phy_rng_disable = vc5_hdmi_phy_rng_disable, .channel_map = vc5_hdmi_channel_map, .supports_hdr = true, @@ -63,7 +63,7 @@ Signed-off-by: Dave Stevenson }; static const struct vc4_hdmi_variant bcm2711_hdmi1_variant = { -@@ -2805,6 +2812,7 @@ static const struct vc4_hdmi_variant bcm +@@ -2806,6 +2813,7 @@ static const struct vc4_hdmi_variant bcm .phy_rng_disable = vc5_hdmi_phy_rng_disable, .channel_map = vc5_hdmi_channel_map, .supports_hdr = true, diff --git a/target/linux/bcm27xx/patches-5.15/950-0590-drm-vc4-Move-HDMI-reset-to-pm_resume.patch b/target/linux/bcm27xx/patches-5.15/950-0590-drm-vc4-Move-HDMI-reset-to-pm_resume.patch index 25dd5b542..6a8ef0ebd 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0590-drm-vc4-Move-HDMI-reset-to-pm_resume.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0590-drm-vc4-Move-HDMI-reset-to-pm_resume.patch @@ -22,7 +22,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -2193,7 +2193,6 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -2194,7 +2194,6 @@ static int vc4_hdmi_cec_init(struct vc4_ struct platform_device *pdev = vc4_hdmi->pdev; struct device *dev = &pdev->dev; unsigned long flags; @@ -30,7 +30,7 @@ Signed-off-by: Dave Stevenson int ret; if (!of_find_property(dev->of_node, "interrupts", NULL)) { -@@ -2213,15 +2212,6 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -2214,15 +2213,6 @@ static int vc4_hdmi_cec_init(struct vc4_ cec_fill_conn_info_from_drm(&conn_info, &vc4_hdmi->connector); cec_s_conn_info(vc4_hdmi->cec_adap, &conn_info); @@ -46,7 +46,7 @@ Signed-off-by: Dave Stevenson if (vc4_hdmi->variant->external_irq_controller) { ret = request_threaded_irq(platform_get_irq_byname(pdev, "cec-rx"), vc4_cec_irq_handler_rx_bare, -@@ -2284,6 +2274,29 @@ static void vc4_hdmi_cec_exit(struct vc4 +@@ -2285,6 +2275,29 @@ static void vc4_hdmi_cec_exit(struct vc4 cec_unregister_adapter(vc4_hdmi->cec_adap); } @@ -76,7 +76,7 @@ Signed-off-by: Dave Stevenson #else static int vc4_hdmi_cec_init(struct vc4_hdmi *vc4_hdmi) { -@@ -2292,6 +2305,10 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -2293,6 +2306,10 @@ static int vc4_hdmi_cec_init(struct vc4_ static void vc4_hdmi_cec_exit(struct vc4_hdmi *vc4_hdmi) {}; @@ -87,7 +87,7 @@ Signed-off-by: Dave Stevenson #endif static int vc4_hdmi_build_regset(struct vc4_hdmi *vc4_hdmi, -@@ -2526,6 +2543,15 @@ static int vc4_hdmi_runtime_resume(struc +@@ -2527,6 +2544,15 @@ static int vc4_hdmi_runtime_resume(struc if (ret) return ret; diff --git a/target/linux/bcm27xx/patches-5.15/950-0596-drm-vc4-dpi-Add-option-for-inverting-pixel-clock-and.patch b/target/linux/bcm27xx/patches-5.15/950-0596-drm-vc4-dpi-Add-option-for-inverting-pixel-clock-and.patch deleted file mode 100644 index feea66713..000000000 --- a/target/linux/bcm27xx/patches-5.15/950-0596-drm-vc4-dpi-Add-option-for-inverting-pixel-clock-and.patch +++ /dev/null @@ -1,114 +0,0 @@ -From e664a91ea54b3488d6c08dd82dac2af1239c3275 Mon Sep 17 00:00:00 2001 -From: Dave Stevenson -Date: Thu, 2 Dec 2021 18:21:46 +0000 -Subject: [PATCH] drm/vc4: dpi: Add option for inverting pixel clock - and output enable - -DRM provides flags for inverting pixel clock and output enable -signals, but these were not mapped to the relevant registers. - -Add those mappings. - -Signed-off-by: Dave Stevenson ---- - drivers/gpu/drm/vc4/vc4_dpi.c | 89 ++++++++++++++++++++--------------- - 1 file changed, 51 insertions(+), 38 deletions(-) - ---- a/drivers/gpu/drm/vc4/vc4_dpi.c -+++ b/drivers/gpu/drm/vc4/vc4_dpi.c -@@ -148,45 +148,58 @@ static void vc4_dpi_encoder_enable(struc - } - drm_connector_list_iter_end(&conn_iter); - -- if (connector && connector->display_info.num_bus_formats) { -- u32 bus_format = connector->display_info.bus_formats[0]; -+ if (connector) { -+ if (connector->display_info.num_bus_formats) { -+ u32 bus_format = connector->display_info.bus_formats[0]; - -- switch (bus_format) { -- case MEDIA_BUS_FMT_RGB888_1X24: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_24BIT_888_RGB, -- DPI_FORMAT); -- break; -- case MEDIA_BUS_FMT_BGR888_1X24: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_24BIT_888_RGB, -- DPI_FORMAT); -- dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, DPI_ORDER); -- break; -- case MEDIA_BUS_FMT_RGB666_1X24_CPADHI: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, -- DPI_FORMAT); -- break; -- case MEDIA_BUS_FMT_BGR666_1X24_CPADHI: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, -- DPI_FORMAT); -- dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, DPI_ORDER); -- break; -- case MEDIA_BUS_FMT_RGB666_1X18: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, -- DPI_FORMAT); -- break; -- case MEDIA_BUS_FMT_BGR666_1X18: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, -- DPI_FORMAT); -- dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, DPI_ORDER); -- break; -- case MEDIA_BUS_FMT_RGB565_1X16: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, -- DPI_FORMAT); -- break; -- default: -- DRM_ERROR("Unknown media bus format %d\n", bus_format); -- break; -+ switch (bus_format) { -+ case MEDIA_BUS_FMT_RGB888_1X24: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_24BIT_888_RGB, -+ DPI_FORMAT); -+ break; -+ case MEDIA_BUS_FMT_BGR888_1X24: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_24BIT_888_RGB, -+ DPI_FORMAT); -+ dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, -+ DPI_ORDER); -+ break; -+ case MEDIA_BUS_FMT_RGB666_1X24_CPADHI: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, -+ DPI_FORMAT); -+ break; -+ case MEDIA_BUS_FMT_BGR666_1X24_CPADHI: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, -+ DPI_FORMAT); -+ dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, -+ DPI_ORDER); -+ break; -+ case MEDIA_BUS_FMT_RGB666_1X18: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, -+ DPI_FORMAT); -+ break; -+ case MEDIA_BUS_FMT_BGR666_1X18: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, -+ DPI_FORMAT); -+ dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, -+ DPI_ORDER); -+ break; -+ case MEDIA_BUS_FMT_RGB565_1X16: -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, -+ DPI_FORMAT); -+ break; -+ default: -+ DRM_ERROR("Unknown media bus format %d\n", -+ bus_format); -+ break; -+ } - } -+ -+ if (connector->display_info.bus_flags & -+ DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE) -+ dpi_c |= DPI_PIXEL_CLK_INVERT; -+ -+ if (connector->display_info.bus_flags & DRM_BUS_FLAG_DE_LOW) -+ dpi_c |= DPI_OUTPUT_ENABLE_INVERT; - } else { - /* Default to 18bit if no connector found. */ - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, DPI_FORMAT); diff --git a/target/linux/bcm27xx/patches-5.15/950-0597-drm-vc4-dpi-Ensure-a-default-format-is-selected.patch b/target/linux/bcm27xx/patches-5.15/950-0597-drm-vc4-dpi-Ensure-a-default-format-is-selected.patch index 7897f8af8..7ce659540 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0597-drm-vc4-dpi-Ensure-a-default-format-is-selected.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0597-drm-vc4-dpi-Ensure-a-default-format-is-selected.patch @@ -15,9 +15,9 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_dpi.c +++ b/drivers/gpu/drm/vc4/vc4_dpi.c -@@ -173,6 +173,10 @@ static void vc4_dpi_encoder_enable(struc - dpi_c |= VC4_SET_FIELD(DPI_ORDER_BGR, - DPI_ORDER); +@@ -167,6 +167,10 @@ static void vc4_dpi_encoder_enable(struc + dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_2, + DPI_FORMAT); break; + default: + DRM_ERROR("Unknown media bus format %d\n", @@ -26,8 +26,8 @@ Signed-off-by: Dave Stevenson case MEDIA_BUS_FMT_RGB666_1X18: dpi_c |= VC4_SET_FIELD(DPI_FORMAT_18BIT_666_RGB_1, DPI_FORMAT); -@@ -187,11 +191,12 @@ static void vc4_dpi_encoder_enable(struc - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, +@@ -175,11 +179,12 @@ static void vc4_dpi_encoder_enable(struc + dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_1, DPI_FORMAT); break; - default: @@ -42,4 +42,4 @@ Signed-off-by: Dave Stevenson + } - if (connector->display_info.bus_flags & + if (connector->display_info.bus_flags & DRM_BUS_FLAG_PIXDATA_DRIVE_NEGEDGE) diff --git a/target/linux/bcm27xx/patches-5.15/950-0602-media-imx219-Advertise-embedded-data-node-on-media-p.patch b/target/linux/bcm27xx/patches-5.15/950-0602-media-imx219-Advertise-embedded-data-node-on-media-p.patch index 79487b60c..9e6778858 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0602-media-imx219-Advertise-embedded-data-node-on-media-p.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0602-media-imx219-Advertise-embedded-data-node-on-media-p.patch @@ -22,7 +22,7 @@ Signed-off-by: Jean-Michel Hautbois --- a/drivers/media/i2c/imx219.c +++ b/drivers/media/i2c/imx219.c -@@ -118,6 +118,16 @@ +@@ -124,6 +124,16 @@ #define IMX219_PIXEL_ARRAY_WIDTH 3280U #define IMX219_PIXEL_ARRAY_HEIGHT 2464U @@ -39,7 +39,7 @@ Signed-off-by: Jean-Michel Hautbois struct imx219_reg { u16 address; u8 val; -@@ -538,7 +548,7 @@ static const struct imx219_mode supporte +@@ -448,7 +458,7 @@ static const struct imx219_mode supporte struct imx219 { struct v4l2_subdev sd; @@ -48,7 +48,7 @@ Signed-off-by: Jean-Michel Hautbois struct v4l2_mbus_framefmt fmt; -@@ -688,18 +698,26 @@ static void imx219_set_default_format(st +@@ -598,18 +608,26 @@ static void imx219_set_default_format(st static int imx219_open(struct v4l2_subdev *sd, struct v4l2_subdev_fh *fh) { struct imx219 *imx219 = to_imx219(sd); @@ -83,7 +83,7 @@ Signed-off-by: Jean-Michel Hautbois /* Initialize try_crop rectangle. */ try_crop = v4l2_subdev_get_try_crop(sd, fh->state, 0); -@@ -808,12 +826,21 @@ static int imx219_enum_mbus_code(struct +@@ -718,12 +736,21 @@ static int imx219_enum_mbus_code(struct { struct imx219 *imx219 = to_imx219(sd); @@ -109,7 +109,7 @@ Signed-off-by: Jean-Michel Hautbois return 0; } -@@ -823,21 +850,30 @@ static int imx219_enum_frame_size(struct +@@ -733,21 +760,30 @@ static int imx219_enum_frame_size(struct struct v4l2_subdev_frame_size_enum *fse) { struct imx219 *imx219 = to_imx219(sd); @@ -151,7 +151,7 @@ Signed-off-by: Jean-Michel Hautbois return 0; } -@@ -852,9 +888,9 @@ static void imx219_reset_colorspace(stru +@@ -762,9 +798,9 @@ static void imx219_reset_colorspace(stru fmt->xfer_func = V4L2_MAP_XFER_FUNC_DEFAULT(fmt->colorspace); } @@ -164,7 +164,7 @@ Signed-off-by: Jean-Michel Hautbois { fmt->format.width = mode->width; fmt->format.height = mode->height; -@@ -862,21 +898,39 @@ static void imx219_update_pad_format(str +@@ -772,21 +808,39 @@ static void imx219_update_pad_format(str imx219_reset_colorspace(&fmt->format); } @@ -208,7 +208,7 @@ Signed-off-by: Jean-Michel Hautbois } return 0; -@@ -906,51 +960,74 @@ static int imx219_set_pad_format(struct +@@ -816,51 +870,74 @@ static int imx219_set_pad_format(struct int exposure_max, exposure_def, hblank; unsigned int i; @@ -326,7 +326,7 @@ Signed-off-by: Jean-Michel Hautbois } mutex_unlock(&imx219->mutex); -@@ -1037,9 +1114,11 @@ static int imx219_start_streaming(struct +@@ -976,9 +1053,11 @@ static int imx219_start_streaming(struct const struct imx219_reg_list *reg_list; int ret; @@ -338,9 +338,9 @@ Signed-off-by: Jean-Michel Hautbois return ret; + } - /* Apply default values of current mode */ - reg_list = &imx219->mode->reg_list; -@@ -1133,21 +1212,22 @@ err_unlock: + /* Send all registers that are common to all modes */ + ret = imx219_write_regs(imx219, imx219_common_regs, ARRAY_SIZE(imx219_common_regs)); +@@ -1086,21 +1165,22 @@ err_unlock: /* Power/clock management functions */ static int imx219_power_on(struct device *dev) { @@ -366,7 +366,7 @@ Signed-off-by: Jean-Michel Hautbois __func__); goto reg_off; } -@@ -1166,7 +1246,8 @@ reg_off: +@@ -1119,7 +1199,8 @@ reg_off: static int imx219_power_off(struct device *dev) { @@ -376,7 +376,7 @@ Signed-off-by: Jean-Michel Hautbois struct imx219 *imx219 = to_imx219(sd); gpiod_set_value_cansleep(imx219->reset_gpio, 0); -@@ -1178,7 +1259,8 @@ static int imx219_power_off(struct devic +@@ -1131,7 +1212,8 @@ static int imx219_power_off(struct devic static int __maybe_unused imx219_suspend(struct device *dev) { @@ -386,7 +386,7 @@ Signed-off-by: Jean-Michel Hautbois struct imx219 *imx219 = to_imx219(sd); if (imx219->streaming) -@@ -1189,7 +1271,8 @@ static int __maybe_unused imx219_suspend +@@ -1142,7 +1224,8 @@ static int __maybe_unused imx219_suspend static int __maybe_unused imx219_resume(struct device *dev) { @@ -396,7 +396,7 @@ Signed-off-by: Jean-Michel Hautbois struct imx219 *imx219 = to_imx219(sd); int ret; -@@ -1525,13 +1608,14 @@ static int imx219_probe(struct i2c_clien +@@ -1478,13 +1561,14 @@ static int imx219_probe(struct i2c_clien V4L2_SUBDEV_FL_HAS_EVENTS; imx219->sd.entity.function = MEDIA_ENT_F_CAM_SENSOR; diff --git a/target/linux/bcm27xx/patches-5.15/950-0603-vc4-drm-Ignore-vc4_hdmi-output_enabled-for-allowing-.patch b/target/linux/bcm27xx/patches-5.15/950-0603-vc4-drm-Ignore-vc4_hdmi-output_enabled-for-allowing-.patch index 9ecf5db11..cb0daf15f 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0603-vc4-drm-Ignore-vc4_hdmi-output_enabled-for-allowing-.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0603-vc4-drm-Ignore-vc4_hdmi-output_enabled-for-allowing-.patch @@ -38,7 +38,7 @@ Signed-off-by: Dom Cobley static void vc4_hdmi_csc_setup(struct vc4_hdmi *vc4_hdmi, bool enable) { unsigned long flags; -@@ -1219,15 +1211,6 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1220,15 +1212,6 @@ static void vc4_hdmi_encoder_post_crtc_e mutex_unlock(&vc4_hdmi->mutex); } @@ -54,7 +54,7 @@ Signed-off-by: Dom Cobley static void vc4_hdmi_encoder_atomic_mode_set(struct drm_encoder *encoder, struct drm_crtc_state *crtc_state, struct drm_connector_state *conn_state) -@@ -1321,8 +1304,6 @@ static const struct drm_encoder_helper_f +@@ -1322,8 +1305,6 @@ static const struct drm_encoder_helper_f .atomic_check = vc4_hdmi_encoder_atomic_check, .atomic_mode_set = vc4_hdmi_encoder_atomic_mode_set, .mode_valid = vc4_hdmi_encoder_mode_valid, @@ -63,7 +63,7 @@ Signed-off-by: Dom Cobley }; static u32 vc4_hdmi_channel_map(struct vc4_hdmi *vc4_hdmi, u32 channel_mask) -@@ -1422,16 +1403,10 @@ static bool vc4_hdmi_audio_can_stream(st +@@ -1423,16 +1404,10 @@ static bool vc4_hdmi_audio_can_stream(st lockdep_assert_held(&vc4_hdmi->mutex); /* diff --git a/target/linux/bcm27xx/patches-5.15/950-0607-drm-vc4-Fix-build-without-DRM_VC4_HDMI_CEC.patch b/target/linux/bcm27xx/patches-5.15/950-0607-drm-vc4-Fix-build-without-DRM_VC4_HDMI_CEC.patch index ac2e8e983..777cdda54 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0607-drm-vc4-Fix-build-without-DRM_VC4_HDMI_CEC.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0607-drm-vc4-Fix-build-without-DRM_VC4_HDMI_CEC.patch @@ -14,7 +14,7 @@ Signed-off-by: Phil Elwell --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -2280,7 +2280,7 @@ static int vc4_hdmi_cec_init(struct vc4_ +@@ -2281,7 +2281,7 @@ static int vc4_hdmi_cec_init(struct vc4_ static void vc4_hdmi_cec_exit(struct vc4_hdmi *vc4_hdmi) {}; diff --git a/target/linux/bcm27xx/patches-5.15/950-0622-drm-vc4-Skip-writes-to-disabled-packet-RAM.patch b/target/linux/bcm27xx/patches-5.15/950-0622-drm-vc4-Skip-writes-to-disabled-packet-RAM.patch index fd1c51dd4..ab4587cb1 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0622-drm-vc4-Skip-writes-to-disabled-packet-RAM.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0622-drm-vc4-Skip-writes-to-disabled-packet-RAM.patch @@ -23,7 +23,7 @@ Signed-off-by: Dom Cobley spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); HDMI_WRITE(HDMI_RAM_PACKET_CONFIG, 0); -@@ -1201,6 +1202,7 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1202,6 +1203,7 @@ static void vc4_hdmi_encoder_post_crtc_e VC4_HDMI_RAM_PACKET_ENABLE); spin_unlock_irqrestore(&vc4_hdmi->hw_lock, flags); @@ -31,7 +31,7 @@ Signed-off-by: Dom Cobley vc4_hdmi_set_infoframes(encoder); } -@@ -1606,7 +1608,8 @@ static int vc4_hdmi_audio_prepare(struct +@@ -1607,7 +1609,8 @@ static int vc4_hdmi_audio_prepare(struct spin_unlock_irqrestore(&vc4_hdmi->hw_lock, flags); memcpy(&vc4_hdmi->audio.infoframe, ¶ms->cea, sizeof(params->cea)); diff --git a/target/linux/bcm27xx/patches-5.15/950-0623-drm-edid-Rename-drm_hdmi_avi_infoframe_colorspace-to.patch b/target/linux/bcm27xx/patches-5.15/950-0623-drm-edid-Rename-drm_hdmi_avi_infoframe_colorspace-to.patch index de80fe462..a9269e4ca 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0623-drm-edid-Rename-drm_hdmi_avi_infoframe_colorspace-to.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0623-drm-edid-Rename-drm_hdmi_avi_infoframe_colorspace-to.patch @@ -26,7 +26,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/drm_edid.c +++ b/drivers/gpu/drm/drm_edid.c -@@ -5743,13 +5743,13 @@ static const u32 hdmi_colorimetry_val[] +@@ -5746,13 +5746,13 @@ static const u32 hdmi_colorimetry_val[] #undef ACE /** @@ -43,7 +43,7 @@ Signed-off-by: Maxime Ripard const struct drm_connector_state *conn_state) { u32 colorimetry_val; -@@ -5768,7 +5768,7 @@ drm_hdmi_avi_infoframe_colorspace(struct +@@ -5771,7 +5771,7 @@ drm_hdmi_avi_infoframe_colorspace(struct frame->extended_colorimetry = (colorimetry_val >> 2) & EXTENDED_COLORIMETRY_MASK; } diff --git a/target/linux/bcm27xx/patches-5.15/950-0624-drm-vc4-hdmi-Add-full-range-RGB-helper.patch b/target/linux/bcm27xx/patches-5.15/950-0624-drm-vc4-hdmi-Add-full-range-RGB-helper.patch index 75d96d74e..f590f4fa4 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0624-drm-vc4-hdmi-Add-full-range-RGB-helper.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0624-drm-vc4-hdmi-Add-full-range-RGB-helper.patch @@ -31,7 +31,7 @@ Signed-off-by: Maxime Ripard static int vc4_hdmi_debugfs_regs(struct seq_file *m, void *unused) { struct drm_info_node *node = (struct drm_info_node *)m->private; -@@ -1116,8 +1125,7 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1117,8 +1126,7 @@ static void vc4_hdmi_encoder_pre_crtc_en mutex_lock(&vc4_hdmi->mutex); diff --git a/target/linux/bcm27xx/patches-5.15/950-0625-drm-vc4-hdmi-Use-full-range-helper-in-csc-functions.patch b/target/linux/bcm27xx/patches-5.15/950-0625-drm-vc4-hdmi-Use-full-range-helper-in-csc-functions.patch index 5ec3643a5..9f3b81e54 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0625-drm-vc4-hdmi-Use-full-range-helper-in-csc-functions.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0625-drm-vc4-hdmi-Use-full-range-helper-in-csc-functions.patch @@ -79,7 +79,7 @@ Signed-off-by: Maxime Ripard /* CEA VICs other than #1 requre limited range RGB * output unless overridden by an AVI infoframe. * Apply a colorspace conversion to squash 0-255 down -@@ -1120,22 +1121,12 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1121,22 +1122,12 @@ static void vc4_hdmi_encoder_pre_crtc_en { struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); struct drm_display_mode *mode = &vc4_hdmi->saved_adjusted_mode; diff --git a/target/linux/bcm27xx/patches-5.15/950-0626-drm-vc4-hdmi-Move-XBAR-setup-to-csc_setup.patch b/target/linux/bcm27xx/patches-5.15/950-0626-drm-vc4-hdmi-Move-XBAR-setup-to-csc_setup.patch index 879be397b..aba91b557 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0626-drm-vc4-hdmi-Move-XBAR-setup-to-csc_setup.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0626-drm-vc4-hdmi-Move-XBAR-setup-to-csc_setup.patch @@ -24,7 +24,7 @@ Signed-off-by: Maxime Ripard if (!vc4_hdmi_is_full_range_rgb(vc4_hdmi, mode)) { /* CEA VICs other than #1 requre limited range RGB * output unless overridden by an AVI infoframe. -@@ -906,7 +908,6 @@ static void vc5_hdmi_set_timings(struct +@@ -907,7 +909,6 @@ static void vc5_hdmi_set_timings(struct spin_lock_irqsave(&vc4_hdmi->hw_lock, flags); diff --git a/target/linux/bcm27xx/patches-5.15/950-0627-drm-vc4-hdmi-Replace-CSC_CTL-hardcoded-value-by-defi.patch b/target/linux/bcm27xx/patches-5.15/950-0627-drm-vc4-hdmi-Replace-CSC_CTL-hardcoded-value-by-defi.patch index 37dbb8c94..c4349f55b 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0627-drm-vc4-hdmi-Replace-CSC_CTL-hardcoded-value-by-defi.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0627-drm-vc4-hdmi-Replace-CSC_CTL-hardcoded-value-by-defi.patch @@ -30,7 +30,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -804,6 +804,9 @@ enum { +@@ -810,6 +810,9 @@ enum { # define VC4_HD_CSC_CTL_RGB2YCC BIT(1) # define VC4_HD_CSC_CTL_ENABLE BIT(0) diff --git a/target/linux/bcm27xx/patches-5.15/950-0629-drm-vc4-hdmi-Change-CSC-callback-prototype.patch b/target/linux/bcm27xx/patches-5.15/950-0629-drm-vc4-hdmi-Change-CSC-callback-prototype.patch index 61911b482..5a1328fa5 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0629-drm-vc4-hdmi-Change-CSC-callback-prototype.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0629-drm-vc4-hdmi-Change-CSC-callback-prototype.patch @@ -33,7 +33,7 @@ Signed-off-by: Maxime Ripard const struct drm_display_mode *mode) { unsigned long flags; -@@ -1141,13 +1143,16 @@ static void vc4_hdmi_encoder_pre_crtc_en +@@ -1142,13 +1144,16 @@ static void vc4_hdmi_encoder_pre_crtc_en struct drm_atomic_state *state) { struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); diff --git a/target/linux/bcm27xx/patches-5.15/950-0630-drm-vc4-hdmi-Move-clock-validation-to-its-own-functi.patch b/target/linux/bcm27xx/patches-5.15/950-0630-drm-vc4-hdmi-Move-clock-validation-to-its-own-functi.patch index f0b5b4814..539d62c3a 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0630-drm-vc4-hdmi-Move-clock-validation-to-its-own-functi.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0630-drm-vc4-hdmi-Move-clock-validation-to-its-own-functi.patch @@ -14,7 +14,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1251,6 +1251,19 @@ static void vc4_hdmi_encoder_atomic_mode +@@ -1252,6 +1252,19 @@ static void vc4_hdmi_encoder_atomic_mode mutex_unlock(&vc4_hdmi->mutex); } @@ -34,7 +34,7 @@ Signed-off-by: Maxime Ripard #define WIFI_2_4GHz_CH1_MIN_FREQ 2400000000ULL #define WIFI_2_4GHz_CH1_MAX_FREQ 2422000000ULL -@@ -1295,10 +1308,7 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1296,10 +1309,7 @@ static int vc4_hdmi_encoder_atomic_check if (mode->flags & DRM_MODE_FLAG_DBLCLK) pixel_rate = pixel_rate * 2; @@ -46,7 +46,7 @@ Signed-off-by: Maxime Ripard return -EINVAL; vc4_state->pixel_rate = pixel_rate; -@@ -1318,13 +1328,7 @@ vc4_hdmi_encoder_mode_valid(struct drm_e +@@ -1319,13 +1329,7 @@ vc4_hdmi_encoder_mode_valid(struct drm_e (mode->hsync_end % 2) || (mode->htotal % 2))) return MODE_H_ILLEGAL; diff --git a/target/linux/bcm27xx/patches-5.15/950-0631-drm-vc4-hdmi-Move-clock-calculation-into-its-own-fun.patch b/target/linux/bcm27xx/patches-5.15/950-0631-drm-vc4-hdmi-Move-clock-calculation-into-its-own-fun.patch index 7b99321e6..04a32b239 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0631-drm-vc4-hdmi-Move-clock-calculation-into-its-own-fun.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0631-drm-vc4-hdmi-Move-clock-calculation-into-its-own-fun.patch @@ -15,7 +15,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1264,6 +1264,35 @@ vc4_hdmi_encoder_clock_valid(const struc +@@ -1265,6 +1265,35 @@ vc4_hdmi_encoder_clock_valid(const struc return MODE_OK; } @@ -51,7 +51,7 @@ Signed-off-by: Maxime Ripard #define WIFI_2_4GHz_CH1_MIN_FREQ 2400000000ULL #define WIFI_2_4GHz_CH1_MAX_FREQ 2422000000ULL -@@ -1276,6 +1305,7 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1277,6 +1306,7 @@ static int vc4_hdmi_encoder_atomic_check struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); unsigned long long pixel_rate = mode->clock * 1000; unsigned long long tmds_rate; @@ -59,7 +59,7 @@ Signed-off-by: Maxime Ripard if (vc4_hdmi->variant->unsupported_odd_h_timings && !(mode->flags & DRM_MODE_FLAG_DBLCLK) && -@@ -1297,21 +1327,10 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1298,21 +1328,10 @@ static int vc4_hdmi_encoder_atomic_check pixel_rate = mode->clock * 1000; } diff --git a/target/linux/bcm27xx/patches-5.15/950-0632-drm-vc4-hdmi-Take-the-sink-maximum-TMDS-clock-into-a.patch b/target/linux/bcm27xx/patches-5.15/950-0632-drm-vc4-hdmi-Take-the-sink-maximum-TMDS-clock-into-a.patch index ee520595f..8f999472d 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0632-drm-vc4-hdmi-Take-the-sink-maximum-TMDS-clock-into-a.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0632-drm-vc4-hdmi-Take-the-sink-maximum-TMDS-clock-into-a.patch @@ -19,7 +19,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1255,12 +1255,18 @@ static enum drm_mode_status +@@ -1256,12 +1256,18 @@ static enum drm_mode_status vc4_hdmi_encoder_clock_valid(const struct vc4_hdmi *vc4_hdmi, unsigned long long clock) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0633-drm-vc4-hdmi-Take-bpp-into-account-for-the-scrambler.patch b/target/linux/bcm27xx/patches-5.15/950-0633-drm-vc4-hdmi-Take-bpp-into-account-for-the-scrambler.patch index 608cc18fd..db29d11f3 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0633-drm-vc4-hdmi-Take-bpp-into-account-for-the-scrambler.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0633-drm-vc4-hdmi-Take-bpp-into-account-for-the-scrambler.patch @@ -57,7 +57,7 @@ Signed-off-by: Maxime Ripard return; drm_scdc_set_high_tmds_clock_ratio(vc4_hdmi->ddc, true); -@@ -1245,6 +1253,7 @@ static void vc4_hdmi_encoder_atomic_mode +@@ -1246,6 +1254,7 @@ static void vc4_hdmi_encoder_atomic_mode struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); mutex_lock(&vc4_hdmi->mutex); diff --git a/target/linux/bcm27xx/patches-5.15/950-0634-drm-vc4-hdmi-Always-try-to-have-the-highest-bpc.patch b/target/linux/bcm27xx/patches-5.15/950-0634-drm-vc4-hdmi-Always-try-to-have-the-highest-bpc.patch index 50bbb7a50..869fa1964 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0634-drm-vc4-hdmi-Always-try-to-have-the-highest-bpc.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0634-drm-vc4-hdmi-Always-try-to-have-the-highest-bpc.patch @@ -38,7 +38,7 @@ Signed-off-by: Maxime Ripard bool hsync_pos = mode->flags & DRM_MODE_FLAG_PHSYNC; bool vsync_pos = mode->flags & DRM_MODE_FLAG_PVSYNC; bool interlaced = mode->flags & DRM_MODE_FLAG_INTERLACE; -@@ -961,7 +964,7 @@ static void vc5_hdmi_set_timings(struct +@@ -962,7 +965,7 @@ static void vc5_hdmi_set_timings(struct HDMI_WRITE(HDMI_VERTB0, vertb_even); HDMI_WRITE(HDMI_VERTB1, vertb); @@ -47,7 +47,7 @@ Signed-off-by: Maxime Ripard case 12: gcp = 6; gcp_en = true; -@@ -1251,9 +1254,11 @@ static void vc4_hdmi_encoder_atomic_mode +@@ -1252,9 +1255,11 @@ static void vc4_hdmi_encoder_atomic_mode struct drm_connector_state *conn_state) { struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); @@ -60,7 +60,7 @@ Signed-off-by: Maxime Ripard memcpy(&vc4_hdmi->saved_adjusted_mode, &crtc_state->adjusted_mode, sizeof(vc4_hdmi->saved_adjusted_mode)); -@@ -1308,6 +1313,38 @@ vc4_hdmi_encoder_compute_clock(const str +@@ -1309,6 +1314,38 @@ vc4_hdmi_encoder_compute_clock(const str return 0; } @@ -99,7 +99,7 @@ Signed-off-by: Maxime Ripard #define WIFI_2_4GHz_CH1_MIN_FREQ 2400000000ULL #define WIFI_2_4GHz_CH1_MAX_FREQ 2422000000ULL -@@ -1342,8 +1379,7 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1343,8 +1380,7 @@ static int vc4_hdmi_encoder_atomic_check pixel_rate = mode->clock * 1000; } diff --git a/target/linux/bcm27xx/patches-5.15/950-0635-drm-vc4-hdmi-Support-HDMI-YUV-output.patch b/target/linux/bcm27xx/patches-5.15/950-0635-drm-vc4-hdmi-Support-HDMI-YUV-output.patch index 47db6abaf..4c92bc296 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0635-drm-vc4-hdmi-Support-HDMI-YUV-output.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0635-drm-vc4-hdmi-Support-HDMI-YUV-output.patch @@ -234,7 +234,7 @@ Signed-off-by: Maxime Ripard HDMI_WRITE(HDMI_CSC_CTL, csc_ctl); spin_unlock_irqrestore(&vc4_hdmi->hw_lock, flags); -@@ -980,6 +1093,15 @@ static void vc5_hdmi_set_timings(struct +@@ -981,6 +1094,15 @@ static void vc5_hdmi_set_timings(struct break; } @@ -250,7 +250,7 @@ Signed-off-by: Maxime Ripard reg = HDMI_READ(HDMI_DEEP_COLOR_CONFIG_1); reg &= ~(VC5_HDMI_DEEP_COLOR_CONFIG_1_INIT_PACK_PHASE_MASK | VC5_HDMI_DEEP_COLOR_CONFIG_1_COLOR_DEPTH_MASK); -@@ -1259,12 +1381,97 @@ static void vc4_hdmi_encoder_atomic_mode +@@ -1260,12 +1382,97 @@ static void vc4_hdmi_encoder_atomic_mode mutex_lock(&vc4_hdmi->mutex); vc4_hdmi->output_bpc = vc4_state->output_bpc; @@ -348,7 +348,7 @@ Signed-off-by: Maxime Ripard static enum drm_mode_status vc4_hdmi_encoder_clock_valid(const struct vc4_hdmi *vc4_hdmi, unsigned long long clock) -@@ -1286,13 +1493,17 @@ vc4_hdmi_encoder_clock_valid(const struc +@@ -1287,13 +1494,17 @@ vc4_hdmi_encoder_clock_valid(const struc static unsigned long long vc4_hdmi_encoder_compute_mode_clock(const struct drm_display_mode *mode, @@ -367,7 +367,7 @@ Signed-off-by: Maxime Ripard return clock * bpc / 8; } -@@ -1300,11 +1511,11 @@ static int +@@ -1301,11 +1512,11 @@ static int vc4_hdmi_encoder_compute_clock(const struct vc4_hdmi *vc4_hdmi, struct vc4_hdmi_connector_state *vc4_state, const struct drm_display_mode *mode, @@ -381,7 +381,7 @@ Signed-off-by: Maxime Ripard if (vc4_hdmi_encoder_clock_valid(vc4_hdmi, clock) != MODE_OK) return -EINVAL; -@@ -1314,10 +1525,55 @@ vc4_hdmi_encoder_compute_clock(const str +@@ -1315,10 +1526,55 @@ vc4_hdmi_encoder_compute_clock(const str } static int @@ -437,7 +437,7 @@ Signed-off-by: Maxime Ripard struct drm_connector_state *conn_state = &vc4_state->base; unsigned int max_bpc = clamp_t(unsigned int, conn_state->max_bpc, 8, 12); unsigned int bpc; -@@ -1326,17 +1582,18 @@ vc4_hdmi_encoder_compute_config(const st +@@ -1327,17 +1583,18 @@ vc4_hdmi_encoder_compute_config(const st for (bpc = max_bpc; bpc >= 8; bpc -= 2) { drm_dbg(dev, "Trying with a %d bpc output\n", bpc); @@ -548,7 +548,7 @@ Signed-off-by: Maxime Ripard static inline --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -804,11 +804,27 @@ enum { +@@ -810,11 +810,27 @@ enum { # define VC4_HD_CSC_CTL_RGB2YCC BIT(1) # define VC4_HD_CSC_CTL_ENABLE BIT(0) diff --git a/target/linux/bcm27xx/patches-5.15/950-0643-drm-vc4-hdmi-Fix-no-video-output-on-DVI-monitors.patch b/target/linux/bcm27xx/patches-5.15/950-0643-drm-vc4-hdmi-Fix-no-video-output-on-DVI-monitors.patch index 8e1f4bb68..644ea123d 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0643-drm-vc4-hdmi-Fix-no-video-output-on-DVI-monitors.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0643-drm-vc4-hdmi-Fix-no-video-output-on-DVI-monitors.patch @@ -17,7 +17,7 @@ Signed-off-by: Matthias Reichl --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1415,9 +1415,6 @@ vc4_hdmi_sink_supports_format_bpc(const +@@ -1416,9 +1416,6 @@ vc4_hdmi_sink_supports_format_bpc(const case VC4_HDMI_OUTPUT_RGB: drm_dbg(dev, "RGB Format, checking the constraints.\n"); diff --git a/target/linux/bcm27xx/patches-5.15/950-0650-drm-vc4-Add-alpha_blend_mode-property-to-each-plane.patch b/target/linux/bcm27xx/patches-5.15/950-0650-drm-vc4-Add-alpha_blend_mode-property-to-each-plane.patch index f1b3a2af8..80e9a7285 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0650-drm-vc4-Add-alpha_blend_mode-property-to-each-plane.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0650-drm-vc4-Add-alpha_blend_mode-property-to-each-plane.patch @@ -14,7 +14,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -664,6 +664,48 @@ static const u32 colorspace_coeffs[2][DR +@@ -666,6 +666,48 @@ static const u32 colorspace_coeffs[2][DR } }; @@ -63,7 +63,7 @@ Signed-off-by: Dave Stevenson /* Writes out a full display list for an active plane to the plane's * private dlist state. */ -@@ -946,13 +988,8 @@ static int vc4_plane_mode_set(struct drm +@@ -948,13 +990,8 @@ static int vc4_plane_mode_set(struct drm /* Position Word 2: Source Image Size, Alpha */ vc4_state->pos2_offset = vc4_state->dlist_count; vc4_dlist_write(vc4_state, @@ -78,7 +78,7 @@ Signed-off-by: Dave Stevenson VC4_SET_FIELD(vc4_state->src_w[0], SCALER_POS2_WIDTH) | VC4_SET_FIELD(vc4_state->src_h[0], -@@ -997,14 +1034,9 @@ static int vc4_plane_mode_set(struct drm +@@ -999,14 +1036,9 @@ static int vc4_plane_mode_set(struct drm vc4_dlist_write(vc4_state, VC4_SET_FIELD(state->alpha >> 4, SCALER5_CTL2_ALPHA) | @@ -95,7 +95,7 @@ Signed-off-by: Dave Stevenson ); /* Position Word 1: Scaled Image Dimensions. */ -@@ -1494,6 +1526,10 @@ struct drm_plane *vc4_plane_init(struct +@@ -1496,6 +1528,10 @@ struct drm_plane *vc4_plane_init(struct drm_plane_helper_add(plane, &vc4_plane_helper_funcs); drm_plane_create_alpha_property(plane); diff --git a/target/linux/bcm27xx/patches-5.15/950-0655-drm-vc4-hdmi-Fix-clock-value-used-for-validating-hdm.patch b/target/linux/bcm27xx/patches-5.15/950-0655-drm-vc4-hdmi-Fix-clock-value-used-for-validating-hdm.patch index 815bdd0a3..67fbf40e7 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0655-drm-vc4-hdmi-Fix-clock-value-used-for-validating-hdm.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0655-drm-vc4-hdmi-Fix-clock-value-used-for-validating-hdm.patch @@ -18,7 +18,7 @@ Signed-off-by: Dom Cobley --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1496,7 +1496,7 @@ vc4_hdmi_encoder_compute_mode_clock(cons +@@ -1497,7 +1497,7 @@ vc4_hdmi_encoder_compute_mode_clock(cons unsigned int bpc, enum vc4_hdmi_output_format fmt) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0657-mfd-simple-mfd-i2c-Add-configuration-for-RPi-POE-HAT.patch b/target/linux/bcm27xx/patches-5.15/950-0657-mfd-simple-mfd-i2c-Add-configuration-for-RPi-POE-HAT.patch index 41ac28a67..5396b7b19 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0657-mfd-simple-mfd-i2c-Add-configuration-for-RPi-POE-HAT.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0657-mfd-simple-mfd-i2c-Add-configuration-for-RPi-POE-HAT.patch @@ -18,7 +18,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/mfd/Kconfig +++ b/drivers/mfd/Kconfig -@@ -1093,6 +1093,16 @@ config MFD_SPMI_PMIC +@@ -1094,6 +1094,16 @@ config MFD_SPMI_PMIC Say M here if you want to include support for the SPMI PMIC series as a module. The module will be called "qcom-spmi-pmic". diff --git a/target/linux/bcm27xx/patches-5.15/950-0669-drm-vc4_hdmi-Add-Broadcast-RGB-property-to-allow-ove.patch b/target/linux/bcm27xx/patches-5.15/950-0669-drm-vc4_hdmi-Add-Broadcast-RGB-property-to-allow-ove.patch index 00324e11e..cfad9fc7a 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0669-drm-vc4_hdmi-Add-Broadcast-RGB-property-to-allow-ove.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0669-drm-vc4_hdmi-Add-Broadcast-RGB-property-to-allow-ove.patch @@ -167,7 +167,7 @@ Signed-off-by: Dave Stevenson drm_connector_attach_encoder(connector, encoder); return 0; -@@ -1385,6 +1487,7 @@ static void vc4_hdmi_encoder_atomic_mode +@@ -1386,6 +1488,7 @@ static void vc4_hdmi_encoder_atomic_mode mutex_lock(&vc4_hdmi->mutex); vc4_hdmi->output_bpc = vc4_state->output_bpc; vc4_hdmi->output_format = vc4_state->output_format; diff --git a/target/linux/bcm27xx/patches-5.15/950-0678-drm-vc4-Add-DRM-210101010-RGB-formats-for-hvs5.patch b/target/linux/bcm27xx/patches-5.15/950-0678-drm-vc4-Add-DRM-210101010-RGB-formats-for-hvs5.patch index 76b5ee5db..0eb0af1af 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0678-drm-vc4-Add-DRM-210101010-RGB-formats-for-hvs5.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0678-drm-vc4-Add-DRM-210101010-RGB-formats-for-hvs5.patch @@ -14,7 +14,7 @@ Signed-off-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -135,6 +135,34 @@ static const struct hvs_format { +@@ -137,6 +137,34 @@ static const struct hvs_format { .pixel_order = HVS_PIXEL_ORDER_XYCBCR, .hvs5_only = true, }, diff --git a/target/linux/bcm27xx/patches-5.15/950-0682-media-uapi-add-MEDIA_BUS_FMT_RGB565_1X24_CPADHI.patch b/target/linux/bcm27xx/patches-5.15/950-0682-media-uapi-add-MEDIA_BUS_FMT_RGB565_1X24_CPADHI.patch deleted file mode 100644 index 245fcfb8e..000000000 --- a/target/linux/bcm27xx/patches-5.15/950-0682-media-uapi-add-MEDIA_BUS_FMT_RGB565_1X24_CPADHI.patch +++ /dev/null @@ -1,31 +0,0 @@ -From b27bc74f47f9e3ef6fce066b3430a6cb59c10909 Mon Sep 17 00:00:00 2001 -From: Chris Morgan -Date: Fri, 28 Jan 2022 17:38:40 -0600 -Subject: [PATCH] media: uapi: add MEDIA_BUS_FMT_RGB565_1X24_CPADHI - -Add the MEDIA_BUS_FMT_RGB565_1X24_CPADHI format used by the Geekworm -MZP280 panel for the Raspberry Pi. - -Signed-off-by: Chris Morgan ---- - include/uapi/linux/media-bus-format.h | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - ---- a/include/uapi/linux/media-bus-format.h -+++ b/include/uapi/linux/media-bus-format.h -@@ -34,13 +34,14 @@ - - #define MEDIA_BUS_FMT_FIXED 0x0001 - --/* RGB - next is 0x1020 */ -+/* RGB - next is 0x1021 */ - #define MEDIA_BUS_FMT_RGB444_1X12 0x1016 - #define MEDIA_BUS_FMT_RGB444_2X8_PADHI_BE 0x1001 - #define MEDIA_BUS_FMT_RGB444_2X8_PADHI_LE 0x1002 - #define MEDIA_BUS_FMT_RGB555_2X8_PADHI_BE 0x1003 - #define MEDIA_BUS_FMT_RGB555_2X8_PADHI_LE 0x1004 - #define MEDIA_BUS_FMT_RGB565_1X16 0x1017 -+#define MEDIA_BUS_FMT_RGB565_1X24_CPADHI 0x1020 - #define MEDIA_BUS_FMT_BGR565_2X8_BE 0x1005 - #define MEDIA_BUS_FMT_BGR565_2X8_LE 0x1006 - #define MEDIA_BUS_FMT_RGB565_2X8_BE 0x1007 diff --git a/target/linux/bcm27xx/patches-5.15/950-0683-drm-vc4-dpi-Support-DPI-interface-in-mode3-for-RGB56.patch b/target/linux/bcm27xx/patches-5.15/950-0683-drm-vc4-dpi-Support-DPI-interface-in-mode3-for-RGB56.patch index 52721d6e9..80fffe963 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0683-drm-vc4-dpi-Support-DPI-interface-in-mode3-for-RGB56.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0683-drm-vc4-dpi-Support-DPI-interface-in-mode3-for-RGB56.patch @@ -18,8 +18,8 @@ Reviewed-by: Dave Stevenson --- a/drivers/gpu/drm/vc4/vc4_dpi.c +++ b/drivers/gpu/drm/vc4/vc4_dpi.c -@@ -191,6 +191,10 @@ static void vc4_dpi_encoder_enable(struc - dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, +@@ -179,6 +179,10 @@ static void vc4_dpi_encoder_enable(struc + dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_1, DPI_FORMAT); break; + case MEDIA_BUS_FMT_RGB565_1X24_CPADHI: diff --git a/target/linux/bcm27xx/patches-5.15/950-0686-drm-panel-simple-add-Geekworm-MZP280-Panel.patch b/target/linux/bcm27xx/patches-5.15/950-0686-drm-panel-simple-add-Geekworm-MZP280-Panel.patch index 3b7ec4bf9..3153605f0 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0686-drm-panel-simple-add-Geekworm-MZP280-Panel.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0686-drm-panel-simple-add-Geekworm-MZP280-Panel.patch @@ -46,7 +46,7 @@ Acked-by: Maxime Ripard static const struct drm_display_mode giantplus_gpg482739qs5_mode = { .clock = 9000, .hdisplay = 480, -@@ -4704,6 +4730,9 @@ static const struct of_device_id platfor +@@ -4672,6 +4698,9 @@ static const struct of_device_id platfor .compatible = "friendlyarm,hd702e", .data = &friendlyarm_hd702e, }, { diff --git a/target/linux/bcm27xx/patches-5.15/950-0706-media-i2c-imx219-Scale-the-pixel-clock-rate-for-the-.patch b/target/linux/bcm27xx/patches-5.15/950-0706-media-i2c-imx219-Scale-the-pixel-clock-rate-for-the-.patch deleted file mode 100644 index 124117ce8..000000000 --- a/target/linux/bcm27xx/patches-5.15/950-0706-media-i2c-imx219-Scale-the-pixel-clock-rate-for-the-.patch +++ /dev/null @@ -1,129 +0,0 @@ -From 055e3d70b0227e26d58b2efc4561eb21a3fbf640 Mon Sep 17 00:00:00 2001 -From: Naushir Patuck -Date: Tue, 8 Feb 2022 13:49:11 +0000 -Subject: [PATCH] media: i2c: imx219: Scale the pixel clock rate for - the 640x480 mode - -The 640x480 mode uses a special binning mode for high framerate operation where -the pixel rate is effectively doubled. Account for this when setting up the -pixel clock rate, and applying the vblank and exposure controls. - -Signed-off-by: Naushir Patuck ---- - drivers/media/i2c/imx219.c | 33 ++++++++++++++++++++++++++------- - 1 file changed, 26 insertions(+), 7 deletions(-) - ---- a/drivers/media/i2c/imx219.c -+++ b/drivers/media/i2c/imx219.c -@@ -153,6 +153,9 @@ struct imx219_mode { - - /* Default register values */ - struct imx219_reg_list reg_list; -+ -+ /* Relative pixel clock rate factor for the mode. */ -+ unsigned int rate_factor; - }; - - /* -@@ -495,6 +498,7 @@ static const struct imx219_mode supporte - .num_of_regs = ARRAY_SIZE(mode_3280x2464_regs), - .regs = mode_3280x2464_regs, - }, -+ .rate_factor = 1, - }, - { - /* 1080P 30fps cropped */ -@@ -511,6 +515,7 @@ static const struct imx219_mode supporte - .num_of_regs = ARRAY_SIZE(mode_1920_1080_regs), - .regs = mode_1920_1080_regs, - }, -+ .rate_factor = 1, - }, - { - /* 2x2 binned 30fps mode */ -@@ -527,6 +532,7 @@ static const struct imx219_mode supporte - .num_of_regs = ARRAY_SIZE(mode_1640_1232_regs), - .regs = mode_1640_1232_regs, - }, -+ .rate_factor = 1, - }, - { - /* 640x480 30fps mode */ -@@ -543,6 +549,11 @@ static const struct imx219_mode supporte - .num_of_regs = ARRAY_SIZE(mode_640_480_regs), - .regs = mode_640_480_regs, - }, -+ /* -+ * This mode uses a special 2x2 binning that doubles the -+ * the internal pixel clock rate. -+ */ -+ .rate_factor = 2, - }, - }; - -@@ -765,7 +776,8 @@ static int imx219_set_ctrl(struct v4l2_c - break; - case V4L2_CID_EXPOSURE: - ret = imx219_write_reg(imx219, IMX219_REG_EXPOSURE, -- IMX219_REG_VALUE_16BIT, ctrl->val); -+ IMX219_REG_VALUE_16BIT, -+ ctrl->val / imx219->mode->rate_factor); - break; - case V4L2_CID_DIGITAL_GAIN: - ret = imx219_write_reg(imx219, IMX219_REG_DIGITAL_GAIN, -@@ -785,7 +797,8 @@ static int imx219_set_ctrl(struct v4l2_c - case V4L2_CID_VBLANK: - ret = imx219_write_reg(imx219, IMX219_REG_VTS, - IMX219_REG_VALUE_16BIT, -- imx219->mode->height + ctrl->val); -+ (imx219->mode->height + ctrl->val) / -+ imx219->mode->rate_factor); - break; - case V4L2_CID_TEST_PATTERN_RED: - ret = imx219_write_reg(imx219, IMX219_REG_TESTP_RED, -@@ -957,7 +970,7 @@ static int imx219_set_pad_format(struct - struct imx219 *imx219 = to_imx219(sd); - const struct imx219_mode *mode; - struct v4l2_mbus_framefmt *framefmt; -- int exposure_max, exposure_def, hblank; -+ int exposure_max, exposure_def, hblank, pixel_rate; - unsigned int i; - - if (fmt->pad >= NUM_PADS) -@@ -1018,6 +1031,12 @@ static int imx219_set_pad_format(struct - hblank = IMX219_PPL_DEFAULT - mode->width; - __v4l2_ctrl_modify_range(imx219->hblank, hblank, hblank, - 1, hblank); -+ -+ /* Scale the pixel rate based on the mode specific factor */ -+ pixel_rate = -+ IMX219_PIXEL_RATE * imx219->mode->rate_factor; -+ __v4l2_ctrl_modify_range(imx219->pixel_rate, pixel_rate, -+ pixel_rate, 1, pixel_rate); - } - } else { - if (fmt->which == V4L2_SUBDEV_FORMAT_TRY) { -@@ -1362,7 +1381,7 @@ static int imx219_init_controls(struct i - struct v4l2_ctrl_handler *ctrl_hdlr; - unsigned int height = imx219->mode->height; - struct v4l2_fwnode_device_properties props; -- int exposure_max, exposure_def, hblank; -+ int exposure_max, exposure_def, hblank, pixel_rate; - int i, ret; - - ctrl_hdlr = &imx219->ctrl_handler; -@@ -1374,11 +1393,11 @@ static int imx219_init_controls(struct i - ctrl_hdlr->lock = &imx219->mutex; - - /* By default, PIXEL_RATE is read only */ -+ pixel_rate = IMX219_PIXEL_RATE * imx219->mode->rate_factor; - imx219->pixel_rate = v4l2_ctrl_new_std(ctrl_hdlr, &imx219_ctrl_ops, - V4L2_CID_PIXEL_RATE, -- IMX219_PIXEL_RATE, -- IMX219_PIXEL_RATE, 1, -- IMX219_PIXEL_RATE); -+ pixel_rate, pixel_rate, -+ 1, pixel_rate); - - imx219->link_freq = - v4l2_ctrl_new_int_menu(ctrl_hdlr, &imx219_ctrl_ops, diff --git a/target/linux/bcm27xx/patches-5.15/950-0707-drm-vc4-For-DPI-MEDIA_BUS_FMT_RGB565_1X16-is-mode-1-.patch b/target/linux/bcm27xx/patches-5.15/950-0707-drm-vc4-For-DPI-MEDIA_BUS_FMT_RGB565_1X16-is-mode-1-.patch deleted file mode 100644 index 9e4b56d11..000000000 --- a/target/linux/bcm27xx/patches-5.15/950-0707-drm-vc4-For-DPI-MEDIA_BUS_FMT_RGB565_1X16-is-mode-1-.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 4626e370de018aed097d54247bae5a29391198ee Mon Sep 17 00:00:00 2001 -From: Dave Stevenson -Date: Mon, 14 Feb 2022 15:34:51 +0000 -Subject: [PATCH] drm/vc4: For DPI, MEDIA_BUS_FMT_RGB565_1X16 is mode - 1, not 3. - -The mapping is incorrect for RGB565_1X16 as it should be -DPI_FORMAT_18BIT_666_RGB_1 instead of DPI_FORMAT_18BIT_666_RGB_3. - -Signed-off-by: Dave Stevenson ---- - drivers/gpu/drm/vc4/vc4_dpi.c | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/drivers/gpu/drm/vc4/vc4_dpi.c -+++ b/drivers/gpu/drm/vc4/vc4_dpi.c -@@ -188,7 +188,7 @@ static void vc4_dpi_encoder_enable(struc - DPI_ORDER); - break; - case MEDIA_BUS_FMT_RGB565_1X16: -- dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_3, -+ dpi_c |= VC4_SET_FIELD(DPI_FORMAT_16BIT_565_RGB_1, - DPI_FORMAT); - break; - case MEDIA_BUS_FMT_RGB565_1X24_CPADHI: diff --git a/target/linux/bcm27xx/patches-5.15/950-0742-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch b/target/linux/bcm27xx/patches-5.15/950-0742-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch index 8f6996264..9fce5fec6 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0742-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0742-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch @@ -399,7 +399,7 @@ Signed-off-by: Maxime Ripard * overwrite the setup from the bootloader (just 128b out of --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -234,6 +234,7 @@ +@@ -240,6 +240,7 @@ # define SCALER_DISPCTRL_DSPEIEOLN(x) BIT(8 + ((x) * 2)) /* Enables Display 0 EOF contribution to SCALER_DISPSTAT_IRQDISP0 */ # define SCALER_DISPCTRL_DSPEIEOF(x) BIT(7 + ((x) * 2)) diff --git a/target/linux/bcm27xx/patches-5.15/950-0781-drm-vc4-Support-zpos-on-all-planes.patch b/target/linux/bcm27xx/patches-5.15/950-0781-drm-vc4-Support-zpos-on-all-planes.patch index 8c1b0ec80..d9e2b16b4 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0781-drm-vc4-Support-zpos-on-all-planes.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0781-drm-vc4-Support-zpos-on-all-planes.patch @@ -88,7 +88,7 @@ Signed-off-by: Dave Stevenson if (ret) --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -1573,9 +1573,14 @@ struct drm_plane *vc4_plane_init(struct +@@ -1575,9 +1575,14 @@ struct drm_plane *vc4_plane_init(struct DRM_COLOR_YCBCR_BT709, DRM_COLOR_YCBCR_LIMITED_RANGE); @@ -103,7 +103,7 @@ Signed-off-by: Dave Stevenson int vc4_plane_create_additional_planes(struct drm_device *drm) { struct drm_plane *cursor_plane; -@@ -1591,7 +1596,7 @@ int vc4_plane_create_additional_planes(s +@@ -1593,7 +1598,7 @@ int vc4_plane_create_additional_planes(s * modest number of planes to expose, that should hopefully * still cover any sane usecase. */ @@ -112,7 +112,7 @@ Signed-off-by: Dave Stevenson struct drm_plane *plane = vc4_plane_init(drm, DRM_PLANE_TYPE_OVERLAY); -@@ -1600,17 +1605,28 @@ int vc4_plane_create_additional_planes(s +@@ -1602,17 +1607,28 @@ int vc4_plane_create_additional_planes(s plane->possible_crtcs = GENMASK(drm->mode_config.num_crtc - 1, 0); diff --git a/target/linux/bcm27xx/patches-5.15/950-0787-vc4-drm-vc4_plane-Keep-fractional-source-coords-insi.patch b/target/linux/bcm27xx/patches-5.15/950-0787-vc4-drm-vc4_plane-Keep-fractional-source-coords-insi.patch index 7bb57aafa..ba27bbc6d 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0787-vc4-drm-vc4_plane-Keep-fractional-source-coords-insi.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0787-vc4-drm-vc4_plane-Keep-fractional-source-coords-insi.patch @@ -23,7 +23,7 @@ Signed-off-by: Dom Cobley u32 src_w[2], src_h[2]; --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -179,9 +179,9 @@ static const struct hvs_format *vc4_get_ +@@ -181,9 +181,9 @@ static const struct hvs_format *vc4_get_ static enum vc4_scaling_mode vc4_get_scaling_mode(u32 src, u32 dst) { @@ -35,7 +35,7 @@ Signed-off-by: Dom Cobley return VC4_SCALING_PPF; else return VC4_SCALING_TPZ; -@@ -388,15 +388,10 @@ static int vc4_plane_setup_clipping_and_ +@@ -390,15 +390,10 @@ static int vc4_plane_setup_clipping_and_ for (i = 0; i < num_planes; i++) vc4_state->offsets[i] = bo->paddr + fb->offsets[i]; @@ -55,7 +55,7 @@ Signed-off-by: Dom Cobley vc4_state->crtc_x = state->dst.x1; vc4_state->crtc_y = state->dst.y1; -@@ -449,7 +444,7 @@ static void vc4_write_tpz(struct vc4_pla +@@ -451,7 +446,7 @@ static void vc4_write_tpz(struct vc4_pla { u32 scale, recip; @@ -64,7 +64,7 @@ Signed-off-by: Dom Cobley /* The specs note that while the reciprocal would be defined * as (1<<32)/scale, ~0 is close enough. -@@ -495,7 +490,7 @@ static u32 vc4_lbm_size(struct drm_plane +@@ -497,7 +492,7 @@ static u32 vc4_lbm_size(struct drm_plane if (vc4_state->x_scaling[0] == VC4_SCALING_TPZ) pix_per_line = vc4_state->crtc_w; else @@ -73,7 +73,7 @@ Signed-off-by: Dom Cobley if (!vc4_state->is_yuv) { if (vc4_state->y_scaling[0] == VC4_SCALING_TPZ) -@@ -586,7 +581,8 @@ static void vc4_plane_calc_load(struct d +@@ -588,7 +583,8 @@ static void vc4_plane_calc_load(struct d for (i = 0; i < fb->format->num_planes; i++) { /* Even if the bandwidth/plane required for a single frame is * @@ -83,7 +83,7 @@ Signed-off-by: Dom Cobley * * when downscaling, we have to read more pixels per line in * the time frame reserved for a single line, so the bandwidth -@@ -595,11 +591,11 @@ static void vc4_plane_calc_load(struct d +@@ -597,11 +593,11 @@ static void vc4_plane_calc_load(struct d * load by this number. We're likely over-estimating the read * demand, but that's better than under-estimating it. */ @@ -99,7 +99,7 @@ Signed-off-by: Dom Cobley vc4_state->hvs_load += vc4_state->crtc_h * vc4_state->crtc_w; } -@@ -752,7 +748,8 @@ static int vc4_plane_mode_set(struct drm +@@ -754,7 +750,8 @@ static int vc4_plane_mode_set(struct drm bool mix_plane_alpha; bool covers_screen; u32 scl0, scl1, pitch0; @@ -109,7 +109,7 @@ Signed-off-by: Dom Cobley u32 hvs_format = format->hvs; unsigned int rotation; int ret, i; -@@ -764,6 +761,9 @@ static int vc4_plane_mode_set(struct drm +@@ -766,6 +763,9 @@ static int vc4_plane_mode_set(struct drm if (ret) return ret; @@ -119,7 +119,7 @@ Signed-off-by: Dom Cobley /* SCL1 is used for Cb/Cr scaling of planar formats. For RGB * and 4:4:4, scl1 should be set to scl0 so both channels of * the scaler do the same thing. For YUV, the Y plane needs -@@ -784,9 +784,11 @@ static int vc4_plane_mode_set(struct drm +@@ -786,9 +786,11 @@ static int vc4_plane_mode_set(struct drm DRM_MODE_REFLECT_Y); /* We must point to the last line when Y reflection is enabled. */ @@ -133,7 +133,7 @@ Signed-off-by: Dom Cobley switch (base_format_mod) { case DRM_FORMAT_MOD_LINEAR: -@@ -801,7 +803,7 @@ static int vc4_plane_mode_set(struct drm +@@ -803,7 +805,7 @@ static int vc4_plane_mode_set(struct drm (i ? v_subsample : 1) * fb->pitches[i]; @@ -142,7 +142,7 @@ Signed-off-by: Dom Cobley (i ? h_subsample : 1) * fb->format->cpp[i]; } -@@ -824,7 +826,7 @@ static int vc4_plane_mode_set(struct drm +@@ -826,7 +828,7 @@ static int vc4_plane_mode_set(struct drm * pitch * tile_h == tile_size * tiles_per_row */ u32 tiles_w = fb->pitches[0] >> (tile_size_shift - tile_h_shift); @@ -151,7 +151,7 @@ Signed-off-by: Dom Cobley u32 tiles_r = tiles_w - tiles_l; u32 tiles_t = src_y >> tile_h_shift; /* Intra-tile offsets, which modify the base address (the -@@ -834,7 +836,7 @@ static int vc4_plane_mode_set(struct drm +@@ -836,7 +838,7 @@ static int vc4_plane_mode_set(struct drm u32 tile_y = (src_y >> 4) & 1; u32 subtile_y = (src_y >> 2) & 3; u32 utile_y = src_y & 3; @@ -160,7 +160,7 @@ Signed-off-by: Dom Cobley u32 y_off = src_y & tile_h_mask; /* When Y reflection is requested we must set the -@@ -930,7 +932,7 @@ static int vc4_plane_mode_set(struct drm +@@ -932,7 +934,7 @@ static int vc4_plane_mode_set(struct drm * of the 12-pixels in that 128-bit word is the * first pixel to be used */ @@ -169,7 +169,7 @@ Signed-off-by: Dom Cobley u32 aligned = remaining_pixels / 12; u32 last_bits = remaining_pixels % 12; -@@ -952,12 +954,12 @@ static int vc4_plane_mode_set(struct drm +@@ -954,12 +956,12 @@ static int vc4_plane_mode_set(struct drm return -EINVAL; } pix_per_tile = tile_w / fb->format->cpp[0]; @@ -184,7 +184,7 @@ Signed-off-by: Dom Cobley vc4_state->offsets[i] += param * tile_w * tile; vc4_state->offsets[i] += src_y / -@@ -1018,10 +1020,8 @@ static int vc4_plane_mode_set(struct drm +@@ -1020,10 +1022,8 @@ static int vc4_plane_mode_set(struct drm vc4_dlist_write(vc4_state, (mix_plane_alpha ? SCALER_POS2_ALPHA_MIX : 0) | vc4_hvs4_get_alpha_blend_mode(state) | @@ -197,7 +197,7 @@ Signed-off-by: Dom Cobley /* Position Word 3: Context. Written by the HVS. */ vc4_dlist_write(vc4_state, 0xc0c0c0c0); -@@ -1079,10 +1079,8 @@ static int vc4_plane_mode_set(struct drm +@@ -1081,10 +1081,8 @@ static int vc4_plane_mode_set(struct drm /* Position Word 2: Source Image Size */ vc4_state->pos2_offset = vc4_state->dlist_count; vc4_dlist_write(vc4_state, diff --git a/target/linux/bcm27xx/patches-5.15/950-0788-vc4-drm-Handle-fractional-coordinates-using-the-phas.patch b/target/linux/bcm27xx/patches-5.15/950-0788-vc4-drm-Handle-fractional-coordinates-using-the-phas.patch index bfd8b07a2..92aed82ae 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0788-vc4-drm-Handle-fractional-coordinates-using-the-phas.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0788-vc4-drm-Handle-fractional-coordinates-using-the-phas.patch @@ -11,7 +11,7 @@ Signed-off-by: Dom Cobley --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -458,14 +458,47 @@ static void vc4_write_tpz(struct vc4_pla +@@ -460,14 +460,47 @@ static void vc4_write_tpz(struct vc4_pla VC4_SET_FIELD(recip, SCALER_TPZ1_RECIP)); } @@ -62,7 +62,7 @@ Signed-off-by: Dom Cobley } static u32 vc4_lbm_size(struct drm_plane_state *state) -@@ -524,13 +557,13 @@ static void vc4_write_scaling_parameters +@@ -526,13 +559,13 @@ static void vc4_write_scaling_parameters /* Ch0 H-PPF Word 0: Scaling Parameters */ if (vc4_state->x_scaling[channel] == VC4_SCALING_PPF) { vc4_write_ppf(vc4_state, @@ -78,7 +78,7 @@ Signed-off-by: Dom Cobley vc4_dlist_write(vc4_state, 0xc0c0c0c0); } -@@ -978,6 +1011,24 @@ static int vc4_plane_mode_set(struct drm +@@ -980,6 +1013,24 @@ static int vc4_plane_mode_set(struct drm return -EINVAL; } diff --git a/target/linux/bcm27xx/patches-5.15/950-0790-vc4-drm-plane-Make-use-of-chroma-siting-parameter.patch b/target/linux/bcm27xx/patches-5.15/950-0790-vc4-drm-plane-Make-use-of-chroma-siting-parameter.patch index 74ffa1020..afbde785f 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0790-vc4-drm-plane-Make-use-of-chroma-siting-parameter.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0790-vc4-drm-plane-Make-use-of-chroma-siting-parameter.patch @@ -10,7 +10,7 @@ Signed-off-by: Dom Cobley --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -461,17 +461,18 @@ static void vc4_write_tpz(struct vc4_pla +@@ -463,17 +463,18 @@ static void vc4_write_tpz(struct vc4_pla /* phase magnitude bits */ #define PHASE_BITS 6 @@ -31,7 +31,7 @@ Signed-off-by: Dom Cobley offset += -(1 << PHASE_BITS >> 2); } else { /* the phase is relative to scale_src->x, so shift it for display list's x value */ -@@ -557,13 +558,15 @@ static void vc4_write_scaling_parameters +@@ -559,13 +560,15 @@ static void vc4_write_scaling_parameters /* Ch0 H-PPF Word 0: Scaling Parameters */ if (vc4_state->x_scaling[channel] == VC4_SCALING_PPF) { vc4_write_ppf(vc4_state, @@ -49,7 +49,7 @@ Signed-off-by: Dom Cobley vc4_dlist_write(vc4_state, 0xc0c0c0c0); } -@@ -1622,6 +1625,8 @@ struct drm_plane *vc4_plane_init(struct +@@ -1624,6 +1627,8 @@ struct drm_plane *vc4_plane_init(struct DRM_COLOR_YCBCR_BT709, DRM_COLOR_YCBCR_LIMITED_RANGE); diff --git a/target/linux/bcm27xx/patches-5.15/950-0801-pinctrl-bcm2835-Only-return-non-GPIOs-to-inputs.patch b/target/linux/bcm27xx/patches-5.15/950-0801-pinctrl-bcm2835-Only-return-non-GPIOs-to-inputs.patch index 340007741..831f54a08 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0801-pinctrl-bcm2835-Only-return-non-GPIOs-to-inputs.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0801-pinctrl-bcm2835-Only-return-non-GPIOs-to-inputs.patch @@ -13,7 +13,7 @@ Signed-off-by: Phil Elwell --- a/drivers/pinctrl/bcm/pinctrl-bcm2835.c +++ b/drivers/pinctrl/bcm/pinctrl-bcm2835.c -@@ -910,9 +910,12 @@ static int bcm2835_pmx_free(struct pinct +@@ -908,9 +908,12 @@ static int bcm2835_pmx_free(struct pinct unsigned offset) { struct bcm2835_pinctrl *pc = pinctrl_dev_get_drvdata(pctldev); @@ -28,7 +28,7 @@ Signed-off-by: Phil Elwell return 0; } -@@ -954,10 +957,7 @@ static void bcm2835_pmx_gpio_disable_fre +@@ -952,10 +955,7 @@ static void bcm2835_pmx_gpio_disable_fre struct pinctrl_gpio_range *range, unsigned offset) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0807-Revert-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch b/target/linux/bcm27xx/patches-5.15/950-0807-Revert-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch index 9a14da02b..afc0957f6 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0807-Revert-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0807-Revert-drm-vc4-hvs-Defer-dlist-slots-deallocation.patch @@ -332,7 +332,7 @@ This reverts commit e99a1b69da07ee3b89a6b8005b854e6c04bfb450. * overwrite the setup from the bootloader (just 128b out of --- a/drivers/gpu/drm/vc4/vc4_regs.h +++ b/drivers/gpu/drm/vc4/vc4_regs.h -@@ -234,7 +234,6 @@ +@@ -240,7 +240,6 @@ # define SCALER_DISPCTRL_DSPEIEOLN(x) BIT(8 + ((x) * 2)) /* Enables Display 0 EOF contribution to SCALER_DISPSTAT_IRQDISP0 */ # define SCALER_DISPCTRL_DSPEIEOF(x) BIT(7 + ((x) * 2)) diff --git a/target/linux/bcm27xx/patches-5.15/950-0808-drm-vc4_hdmi-Force-modeset-when-bpc-changes.patch b/target/linux/bcm27xx/patches-5.15/950-0808-drm-vc4_hdmi-Force-modeset-when-bpc-changes.patch index 7e1458734..2eb71df02 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0808-drm-vc4_hdmi-Force-modeset-when-bpc-changes.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0808-drm-vc4_hdmi-Force-modeset-when-bpc-changes.patch @@ -25,7 +25,7 @@ Signed-off-by: Dom Cobley --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1809,6 +1809,9 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1810,6 +1810,9 @@ static int vc4_hdmi_encoder_atomic_check struct vc4_hdmi_connector_state *vc4_state = conn_state_to_vc4_hdmi_conn_state(conn_state); struct drm_display_mode *mode = &crtc_state->adjusted_mode; struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); @@ -35,7 +35,7 @@ Signed-off-by: Dom Cobley unsigned long long pixel_rate = mode->clock * 1000; unsigned long long tmds_rate; int ret; -@@ -1837,6 +1840,11 @@ static int vc4_hdmi_encoder_atomic_check +@@ -1838,6 +1841,11 @@ static int vc4_hdmi_encoder_atomic_check if (ret) return ret; diff --git a/target/linux/bcm27xx/patches-5.15/950-0829-vc4_hdmi-Remove-VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWA.patch b/target/linux/bcm27xx/patches-5.15/950-0829-vc4_hdmi-Remove-VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWA.patch index 4b811662d..fb521499a 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0829-vc4_hdmi-Remove-VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWA.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0829-vc4_hdmi-Remove-VC4_HDMI_SCHEDULER_CONTROL_VERT_ALWA.patch @@ -14,7 +14,7 @@ Signed-off-by: Dom Cobley --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c -@@ -1551,9 +1551,6 @@ static void vc4_hdmi_encoder_post_crtc_e +@@ -1552,9 +1552,6 @@ static void vc4_hdmi_encoder_post_crtc_e WARN_ON(!(HDMI_READ(HDMI_SCHEDULER_CONTROL) & VC4_HDMI_SCHEDULER_CONTROL_HDMI_ACTIVE)); diff --git a/target/linux/bcm27xx/patches-5.15/950-0868-drm-vc4-hdmi-Rework-hdmi_enable_4kp60-detection.patch b/target/linux/bcm27xx/patches-5.15/950-0868-drm-vc4-hdmi-Rework-hdmi_enable_4kp60-detection.patch index 8776f648f..d54597355 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0868-drm-vc4-hdmi-Rework-hdmi_enable_4kp60-detection.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0868-drm-vc4-hdmi-Rework-hdmi_enable_4kp60-detection.patch @@ -65,7 +65,7 @@ Signed-off-by: Maxime Ripard struct drm_device *drm = connector->dev; struct drm_display_mode *mode; -@@ -1672,11 +1673,12 @@ vc4_hdmi_encoder_clock_valid(const struc +@@ -1673,11 +1674,12 @@ vc4_hdmi_encoder_clock_valid(const struc { const struct drm_connector *connector = &vc4_hdmi->connector; const struct drm_display_info *info = &connector->display_info; @@ -79,7 +79,7 @@ Signed-off-by: Maxime Ripard return MODE_CLOCK_HIGH; if (info->max_tmds_clock && clock > (info->max_tmds_clock * 1000)) -@@ -3157,14 +3159,6 @@ static int vc4_hdmi_bind(struct device * +@@ -3158,14 +3160,6 @@ static int vc4_hdmi_bind(struct device * vc4_hdmi->disable_wifi_frequencies = of_property_read_bool(dev->of_node, "wifi-2.4ghz-coexistence"); diff --git a/target/linux/bcm27xx/patches-5.15/950-0897-drm-vc4-plane-Prevent-async-update-if-we-don-t-have-.patch b/target/linux/bcm27xx/patches-5.15/950-0897-drm-vc4-plane-Prevent-async-update-if-we-don-t-have-.patch index a6d539ecd..d02f52c55 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0897-drm-vc4-plane-Prevent-async-update-if-we-don-t-have-.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0897-drm-vc4-plane-Prevent-async-update-if-we-don-t-have-.patch @@ -24,7 +24,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -1429,6 +1429,10 @@ static int vc4_plane_atomic_async_check( +@@ -1431,6 +1431,10 @@ static int vc4_plane_atomic_async_check( old_vc4_state = to_vc4_plane_state(plane->state); new_vc4_state = to_vc4_plane_state(new_plane_state); diff --git a/target/linux/bcm27xx/patches-5.15/950-0898-drm-vc4-Consolidate-Hardware-Revision-Check.patch b/target/linux/bcm27xx/patches-5.15/950-0898-drm-vc4-Consolidate-Hardware-Revision-Check.patch index 8699bed00..78237355b 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0898-drm-vc4-Consolidate-Hardware-Revision-Check.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0898-drm-vc4-Consolidate-Hardware-Revision-Check.patch @@ -227,7 +227,7 @@ Signed-off-by: Maxime Ripard /* 48k words of 2x12-bit pixels */ drm_mm_init(&hvs->lbm_mm, 0, 48 * 1024); else -@@ -1008,7 +1008,7 @@ static int vc4_hvs_bind(struct device *d +@@ -1019,7 +1019,7 @@ static int vc4_hvs_bind(struct device *d NULL); vc4_debugfs_add_file(drm, "hvs_dlists", vc4_hvs_debugfs_dlist, NULL); @@ -294,7 +294,7 @@ Signed-off-by: Maxime Ripard } else { --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -542,10 +542,10 @@ static u32 vc4_lbm_size(struct drm_plane +@@ -544,10 +544,10 @@ static u32 vc4_lbm_size(struct drm_plane } /* Align it to 64 or 128 (hvs5) bytes */ @@ -307,7 +307,7 @@ Signed-off-by: Maxime Ripard return lbm; } -@@ -664,7 +664,7 @@ static int vc4_plane_allocate_lbm(struct +@@ -666,7 +666,7 @@ static int vc4_plane_allocate_lbm(struct ret = drm_mm_insert_node_generic(&vc4->hvs->lbm_mm, &vc4_state->lbm, lbm_size, @@ -316,7 +316,7 @@ Signed-off-by: Maxime Ripard 0, 0); spin_unlock_irqrestore(&vc4->hvs->mm_lock, irqflags); -@@ -1039,7 +1039,7 @@ static int vc4_plane_mode_set(struct drm +@@ -1041,7 +1041,7 @@ static int vc4_plane_mode_set(struct drm mix_plane_alpha = state->alpha != DRM_BLEND_ALPHA_OPAQUE && fb->format->has_alpha; @@ -325,7 +325,7 @@ Signed-off-by: Maxime Ripard /* Control word */ vc4_dlist_write(vc4_state, SCALER_CTL0_VALID | -@@ -1570,14 +1570,13 @@ static const struct drm_plane_funcs vc4_ +@@ -1572,14 +1572,13 @@ static const struct drm_plane_funcs vc4_ struct drm_plane *vc4_plane_init(struct drm_device *dev, enum drm_plane_type type) { @@ -341,7 +341,7 @@ Signed-off-by: Maxime Ripard static const uint64_t modifiers[] = { DRM_FORMAT_MOD_BROADCOM_VC4_T_TILED, DRM_FORMAT_MOD_BROADCOM_SAND128, -@@ -1593,7 +1592,7 @@ struct drm_plane *vc4_plane_init(struct +@@ -1595,7 +1594,7 @@ struct drm_plane *vc4_plane_init(struct return ERR_PTR(-ENOMEM); for (i = 0; i < ARRAY_SIZE(hvs_formats); i++) { diff --git a/target/linux/bcm27xx/patches-5.15/950-0903-drm-vc4-plane-Register-a-different-drm_plane_helper_.patch b/target/linux/bcm27xx/patches-5.15/950-0903-drm-vc4-plane-Register-a-different-drm_plane_helper_.patch index c861170b4..e44aa408c 100644 --- a/target/linux/bcm27xx/patches-5.15/950-0903-drm-vc4-plane-Register-a-different-drm_plane_helper_.patch +++ b/target/linux/bcm27xx/patches-5.15/950-0903-drm-vc4-plane-Register-a-different-drm_plane_helper_.patch @@ -20,7 +20,7 @@ Signed-off-by: Maxime Ripard --- a/drivers/gpu/drm/vc4/vc4_plane.c +++ b/drivers/gpu/drm/vc4/vc4_plane.c -@@ -1502,6 +1502,13 @@ static const struct drm_plane_helper_fun +@@ -1504,6 +1504,13 @@ static const struct drm_plane_helper_fun .atomic_async_update = vc4_plane_atomic_async_update, }; @@ -34,7 +34,7 @@ Signed-off-by: Maxime Ripard static bool vc4_format_mod_supported(struct drm_plane *plane, uint32_t format, uint64_t modifier) -@@ -1606,7 +1613,10 @@ struct drm_plane *vc4_plane_init(struct +@@ -1608,7 +1615,10 @@ struct drm_plane *vc4_plane_init(struct if (ret) return ERR_PTR(ret); diff --git a/target/linux/ipq807x/patches-5.15/0001-v5.16-arm64-dts-qcom-ipq8074-add-SPMI-bus.patch b/target/linux/ipq807x/patches-5.15/0001-v5.16-arm64-dts-qcom-ipq8074-add-SPMI-bus.patch index d9515cef2..1679c25ba 100644 --- a/target/linux/ipq807x/patches-5.15/0001-v5.16-arm64-dts-qcom-ipq8074-add-SPMI-bus.patch +++ b/target/linux/ipq807x/patches-5.15/0001-v5.16-arm64-dts-qcom-ipq8074-add-SPMI-bus.patch @@ -15,7 +15,7 @@ Link: https://lore.kernel.org/r/20210905165816.655275-1-robimarko@gmail.com --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -293,6 +293,25 @@ +@@ -320,6 +320,25 @@ #reset-cells = <0x1>; }; diff --git a/target/linux/ipq807x/patches-5.15/0002-v5.16-arm64-dts-qcom-ipq8074-Add-QUP5-I2C-node.patch b/target/linux/ipq807x/patches-5.15/0002-v5.16-arm64-dts-qcom-ipq8074-Add-QUP5-I2C-node.patch index e6ddc9ed2..329dcf3aa 100644 --- a/target/linux/ipq807x/patches-5.15/0002-v5.16-arm64-dts-qcom-ipq8074-Add-QUP5-I2C-node.patch +++ b/target/linux/ipq807x/patches-5.15/0002-v5.16-arm64-dts-qcom-ipq8074-Add-QUP5-I2C-node.patch @@ -16,7 +16,7 @@ Link: https://lore.kernel.org/r/20211001145421.18302-1-amadeus@jmu.edu.cn --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -430,6 +430,21 @@ +@@ -457,6 +457,21 @@ status = "disabled"; }; diff --git a/target/linux/ipq807x/patches-5.15/0003-v5.16-arm64-dts-qcom-msm8996-Move-clock-cells-to-QMP-PHY-c.patch b/target/linux/ipq807x/patches-5.15/0003-v5.16-arm64-dts-qcom-msm8996-Move-clock-cells-to-QMP-PHY-c.patch index ac8b6a29a..0f7b0c642 100644 --- a/target/linux/ipq807x/patches-5.15/0003-v5.16-arm64-dts-qcom-msm8996-Move-clock-cells-to-QMP-PHY-c.patch +++ b/target/linux/ipq807x/patches-5.15/0003-v5.16-arm64-dts-qcom-msm8996-Move-clock-cells-to-QMP-PHY-c.patch @@ -37,7 +37,7 @@ Link: https://lore.kernel.org/r/20210929034253.24570-4-shawn.guo@linaro.org + #clock-cells = <1>; clocks = <&gcc GCC_USB1_PIPE_CLK>; clock-names = "pipe0"; - clock-output-names = "gcc_usb1_pipe_clk_src"; + clock-output-names = "usb3phy_1_cc_pipe_clk"; @@ -134,7 +134,6 @@ ssphy_0: phy@78000 { compatible = "qcom,ipq8074-qmp-usb3-phy"; @@ -53,7 +53,7 @@ Link: https://lore.kernel.org/r/20210929034253.24570-4-shawn.guo@linaro.org + #clock-cells = <1>; clocks = <&gcc GCC_USB0_PIPE_CLK>; clock-names = "pipe0"; - clock-output-names = "gcc_usb0_pipe_clk_src"; + clock-output-names = "usb3phy_0_cc_pipe_clk"; --- a/arch/arm64/boot/dts/qcom/msm8996.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8996.dtsi @@ -602,7 +602,6 @@ diff --git a/target/linux/ipq807x/patches-5.15/0005-v5.16-arm64-dts-qcom-Fix-IPQ8074-PCIe-PHY-nodes.patch b/target/linux/ipq807x/patches-5.15/0005-v5.16-arm64-dts-qcom-Fix-IPQ8074-PCIe-PHY-nodes.patch deleted file mode 100644 index b3dce7dd4..000000000 --- a/target/linux/ipq807x/patches-5.15/0005-v5.16-arm64-dts-qcom-Fix-IPQ8074-PCIe-PHY-nodes.patch +++ /dev/null @@ -1,94 +0,0 @@ -From 942bcd33ed455ad40b71a59901bd926bbf4a500e Mon Sep 17 00:00:00 2001 -From: Shawn Guo -Date: Wed, 29 Sep 2021 11:42:51 +0800 -Subject: [PATCH] arm64: dts: qcom: Fix IPQ8074 PCIe PHY nodes - -IPQ8074 PCIe PHY nodes are broken in the many ways: - -- '#address-cells', '#size-cells' and 'ranges' are missing. -- Child phy/lane node is missing, and the child properties like - '#phy-cells' and 'clocks' are mistakenly put into parent node. -- The clocks properties for parent node are missing. - -Fix them to get the nodes comply with the bindings schema. - -Signed-off-by: Shawn Guo -Signed-off-by: Bjorn Andersson -Link: https://lore.kernel.org/r/20210929034253.24570-9-shawn.guo@linaro.org ---- - arch/arm64/boot/dts/qcom/ipq8074.dtsi | 46 +++++++++++++++++++++------ - 1 file changed, 36 insertions(+), 10 deletions(-) - ---- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi -+++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -174,34 +174,60 @@ - status = "disabled"; - }; - -- pcie_phy0: phy@86000 { -+ pcie_qmp0: phy@86000 { - compatible = "qcom,ipq8074-qmp-pcie-phy"; - reg = <0x00086000 0x1000>; -- #phy-cells = <0>; -- clocks = <&gcc GCC_PCIE0_PIPE_CLK>; -- clock-names = "pipe_clk"; -- clock-output-names = "pcie20_phy0_pipe_clk"; -+ #address-cells = <1>; -+ #size-cells = <1>; -+ ranges; - -+ clocks = <&gcc GCC_PCIE0_AUX_CLK>, -+ <&gcc GCC_PCIE0_AHB_CLK>; -+ clock-names = "aux", "cfg_ahb"; - resets = <&gcc GCC_PCIE0_PHY_BCR>, - <&gcc GCC_PCIE0PHY_PHY_BCR>; - reset-names = "phy", - "common"; - status = "disabled"; -+ -+ pcie_phy0: phy@86200 { -+ reg = <0x86200 0x16c>, -+ <0x86400 0x200>, -+ <0x86800 0x4f4>; -+ #phy-cells = <0>; -+ #clock-cells = <0>; -+ clocks = <&gcc GCC_PCIE0_PIPE_CLK>; -+ clock-names = "pipe0"; -+ clock-output-names = "pcie_0_pipe_clk"; -+ }; - }; - -- pcie_phy1: phy@8e000 { -+ pcie_qmp1: phy@8e000 { - compatible = "qcom,ipq8074-qmp-pcie-phy"; - reg = <0x0008e000 0x1000>; -- #phy-cells = <0>; -- clocks = <&gcc GCC_PCIE1_PIPE_CLK>; -- clock-names = "pipe_clk"; -- clock-output-names = "pcie20_phy1_pipe_clk"; -+ #address-cells = <1>; -+ #size-cells = <1>; -+ ranges; - -+ clocks = <&gcc GCC_PCIE1_AUX_CLK>, -+ <&gcc GCC_PCIE1_AHB_CLK>; -+ clock-names = "aux", "cfg_ahb"; - resets = <&gcc GCC_PCIE1_PHY_BCR>, - <&gcc GCC_PCIE1PHY_PHY_BCR>; - reset-names = "phy", - "common"; - status = "disabled"; -+ -+ pcie_phy1: phy@8e200 { -+ reg = <0x8e200 0x16c>, -+ <0x8e400 0x200>, -+ <0x8e800 0x4f4>; -+ #phy-cells = <0>; -+ #clock-cells = <0>; -+ clocks = <&gcc GCC_PCIE1_PIPE_CLK>; -+ clock-names = "pipe0"; -+ clock-output-names = "pcie_1_pipe_clk"; -+ }; - }; - - prng: rng@e3000 { diff --git a/target/linux/ipq807x/patches-5.15/0006-v5.17-arm64-dts-qcom-ipq8074-add-MDIO-bus.patch b/target/linux/ipq807x/patches-5.15/0006-v5.17-arm64-dts-qcom-ipq8074-add-MDIO-bus.patch index aeeafbb62..40be96bb5 100644 --- a/target/linux/ipq807x/patches-5.15/0006-v5.17-arm64-dts-qcom-ipq8074-add-MDIO-bus.patch +++ b/target/linux/ipq807x/patches-5.15/0006-v5.17-arm64-dts-qcom-ipq8074-add-MDIO-bus.patch @@ -15,7 +15,7 @@ Link: https://lore.kernel.org/r/20211007115846.26255-1-robimarko@gmail.com --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -230,6 +230,18 @@ +@@ -231,6 +231,18 @@ }; }; diff --git a/target/linux/ipq807x/patches-5.15/0011-v5.18-arm64-dts-ipq8074-add-SMEM-support.patch b/target/linux/ipq807x/patches-5.15/0011-v5.18-arm64-dts-ipq8074-add-SMEM-support.patch index dd7ff3e5a..43e4a36b5 100644 --- a/target/linux/ipq807x/patches-5.15/0011-v5.18-arm64-dts-ipq8074-add-SMEM-support.patch +++ b/target/linux/ipq807x/patches-5.15/0011-v5.18-arm64-dts-ipq8074-add-SMEM-support.patch @@ -34,7 +34,7 @@ Signed-off-by: Robert Marko firmware { scm { compatible = "qcom,scm-ipq8074", "qcom,scm"; -@@ -331,6 +345,12 @@ +@@ -332,6 +346,12 @@ #reset-cells = <0x1>; }; diff --git a/target/linux/ipq807x/patches-5.15/0104-arm64-dts-qcom-ipq8074-enable-the-GICv2m-support.patch b/target/linux/ipq807x/patches-5.15/0104-arm64-dts-qcom-ipq8074-enable-the-GICv2m-support.patch index 72e3a4086..5bbba4fa0 100644 --- a/target/linux/ipq807x/patches-5.15/0104-arm64-dts-qcom-ipq8074-enable-the-GICv2m-support.patch +++ b/target/linux/ipq807x/patches-5.15/0104-arm64-dts-qcom-ipq8074-enable-the-GICv2m-support.patch @@ -13,7 +13,7 @@ Signed-off-by: Kathiravan T --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -669,9 +669,18 @@ +@@ -670,9 +670,18 @@ intc: interrupt-controller@b000000 { compatible = "qcom,msm-qgic2"; diff --git a/target/linux/ipq807x/patches-5.15/0110-arm64-dts-ipq8074-fix-PCI-related-DT-nodes.patch b/target/linux/ipq807x/patches-5.15/0110-arm64-dts-ipq8074-fix-PCI-related-DT-nodes.patch deleted file mode 100644 index b79f1bd7a..000000000 --- a/target/linux/ipq807x/patches-5.15/0110-arm64-dts-ipq8074-fix-PCI-related-DT-nodes.patch +++ /dev/null @@ -1,193 +0,0 @@ -From 9e280276de874970d03cdc124d8bfa7afbb6aef1 Mon Sep 17 00:00:00 2001 -From: Robert Marko -Date: Mon, 20 Dec 2021 15:08:04 +0100 -Subject: [PATCH] arm64: dts: ipq8074: fix PCI related DT nodes - -Currently present PCI PHY and PCI controller nodes are not working -and are incorrect for the v2 of IPQ8074 which is the only version -supported upstream. - -So, correct the PCI related nodes. - -Signed-off-by: Robert Marko ---- - arch/arm64/boot/dts/qcom/ipq8074.dtsi | 73 +++++++++++++++------------ - 1 file changed, 42 insertions(+), 31 deletions(-) - ---- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi -+++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -228,9 +228,9 @@ - status = "disabled"; - }; - -- pcie_qmp0: phy@86000 { -- compatible = "qcom,ipq8074-qmp-pcie-phy"; -- reg = <0x00086000 0x1000>; -+ pcie_qmp0: phy@84000 { -+ compatible = "qcom,ipq8074-qmp-pcie-gen3-phy"; -+ reg = <0x00084000 0x1bc>; - #address-cells = <1>; - #size-cells = <1>; - ranges; -@@ -244,21 +244,22 @@ - "common"; - status = "disabled"; - -- pcie_phy0: phy@86200 { -- reg = <0x86200 0x16c>, -- <0x86400 0x200>, -- <0x86800 0x4f4>; -+ pcie_phy0: phy@84200 { -+ reg = <0x84200 0x16c>, -+ <0x84400 0x200>, -+ <0x84800 0x4f4>; - #phy-cells = <0>; - #clock-cells = <0>; - clocks = <&gcc GCC_PCIE0_PIPE_CLK>; - clock-names = "pipe0"; - clock-output-names = "pcie_0_pipe_clk"; -+ clock-output-rate = <250000000>; - }; - }; - - pcie_qmp1: phy@8e000 { - compatible = "qcom,ipq8074-qmp-pcie-phy"; -- reg = <0x0008e000 0x1000>; -+ reg = <0x0008e000 0x1c4>; - #address-cells = <1>; - #size-cells = <1>; - ranges; -@@ -273,14 +274,15 @@ - status = "disabled"; - - pcie_phy1: phy@8e200 { -- reg = <0x8e200 0x16c>, -+ reg = <0x8e200 0x130>, - <0x8e400 0x200>, -- <0x8e800 0x4f4>; -+ <0x8e800 0x1f8>; - #phy-cells = <0>; - #clock-cells = <0>; - clocks = <&gcc GCC_PCIE1_PIPE_CLK>; - clock-names = "pipe0"; - clock-output-names = "pcie_1_pipe_clk"; -+ clock-output-rate = <125000000>; - }; - }; - -@@ -676,7 +678,7 @@ - reg = <0x0b000000 0x1000>, <0x0b002000 0x1000>; - ranges = <0 0xb00a000 0xffd>; - -- v2m@0 { -+ gic_v2m0: v2m@0 { - compatible = "arm,gic-v2m-frame"; - msi-controller; - reg = <0x0 0xffd>; -@@ -769,6 +771,7 @@ - linux,pci-domain = <1>; - bus-range = <0x00 0xff>; - num-lanes = <1>; -+ max-link-speed = <2>; - #address-cells = <3>; - #size-cells = <2>; - -@@ -776,12 +779,12 @@ - phy-names = "pciephy"; - - ranges = <0x81000000 0 0x10200000 0x10200000 -- 0 0x100000 /* downstream I/O */ -- 0x82000000 0 0x10300000 0x10300000 -- 0 0xd00000>; /* non-prefetchable memory */ -+ 0 0x10000>, /* downstream I/O */ -+ <0x82000000 0 0x10220000 0x10220000 -+ 0 0xfde0000>; /* non-prefetchable memory */ -+ -+ msi-parent = <&gic_v2m0>; - -- interrupts = ; -- interrupt-names = "msi"; - #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0x7>; - interrupt-map = <0 0 0 1 &intc 0 142 -@@ -821,16 +824,18 @@ - }; - - pcie0: pci@20000000 { -- compatible = "qcom,pcie-ipq8074"; -- reg = <0x20000000 0xf1d>, -- <0x20000f20 0xa8>, -- <0x00080000 0x2000>, -- <0x20100000 0x1000>; -- reg-names = "dbi", "elbi", "parf", "config"; -+ compatible = "qcom,pcie-ipq8074-gen3"; -+ reg = <0x20000000 0xf1d>, -+ <0x20000f20 0xa8>, -+ <0x20001000 0x1000>, -+ <0x00080000 0x4000>, -+ <0x20100000 0x1000>; -+ reg-names = "dbi", "elbi", "atu", "parf", "config"; - device_type = "pci"; - linux,pci-domain = <0>; - bus-range = <0x00 0xff>; - num-lanes = <1>; -+ max-link-speed = <3>; - #address-cells = <3>; - #size-cells = <2>; - -@@ -838,12 +843,12 @@ - phy-names = "pciephy"; - - ranges = <0x81000000 0 0x20200000 0x20200000 -- 0 0x100000 /* downstream I/O */ -- 0x82000000 0 0x20300000 0x20300000 -- 0 0xd00000>; /* non-prefetchable memory */ -+ 0 0x10000>, /* downstream I/O */ -+ <0x82000000 0 0x20220000 0x20220000 -+ 0 0xfde0000>; /* non-prefetchable memory */ -+ -+ msi-parent = <&gic_v2m0>; - -- interrupts = ; -- interrupt-names = "msi"; - #interrupt-cells = <1>; - interrupt-map-mask = <0 0 0 0x7>; - interrupt-map = <0 0 0 1 &intc 0 75 -@@ -859,27 +864,33 @@ - <&gcc GCC_PCIE0_AXI_M_CLK>, - <&gcc GCC_PCIE0_AXI_S_CLK>, - <&gcc GCC_PCIE0_AHB_CLK>, -- <&gcc GCC_PCIE0_AUX_CLK>; -+ <&gcc GCC_PCIE0_AUX_CLK>, -+ <&gcc GCC_PCIE0_AXI_S_BRIDGE_CLK>, -+ <&gcc GCC_PCIE0_RCHNG_CLK>; - - clock-names = "iface", - "axi_m", - "axi_s", - "ahb", -- "aux"; -+ "aux", -+ "axi_bridge", -+ "rchng"; - resets = <&gcc GCC_PCIE0_PIPE_ARES>, - <&gcc GCC_PCIE0_SLEEP_ARES>, - <&gcc GCC_PCIE0_CORE_STICKY_ARES>, - <&gcc GCC_PCIE0_AXI_MASTER_ARES>, - <&gcc GCC_PCIE0_AXI_SLAVE_ARES>, - <&gcc GCC_PCIE0_AHB_ARES>, -- <&gcc GCC_PCIE0_AXI_MASTER_STICKY_ARES>; -+ <&gcc GCC_PCIE0_AXI_MASTER_STICKY_ARES>, -+ <&gcc GCC_PCIE0_AXI_SLAVE_STICKY_ARES>; - reset-names = "pipe", - "sleep", - "sticky", - "axi_m", - "axi_s", - "ahb", -- "axi_m_sticky"; -+ "axi_m_sticky", -+ "axi_s_sticky"; - status = "disabled"; - }; - }; diff --git a/target/linux/ipq807x/patches-5.15/0119-arm64-dts-qcom-Enable-Q6v5-WCSS-for-ipq8074-SoC.patch b/target/linux/ipq807x/patches-5.15/0119-arm64-dts-qcom-Enable-Q6v5-WCSS-for-ipq8074-SoC.patch index 15cbd86cb..eeb5907fa 100644 --- a/target/linux/ipq807x/patches-5.15/0119-arm64-dts-qcom-Enable-Q6v5-WCSS-for-ipq8074-SoC.patch +++ b/target/linux/ipq807x/patches-5.15/0119-arm64-dts-qcom-Enable-Q6v5-WCSS-for-ipq8074-SoC.patch @@ -49,7 +49,7 @@ Signed-off-by: Robert Marko soc: soc { #address-cells = <0x1>; #size-cells = <0x1>; -@@ -393,6 +419,11 @@ +@@ -392,6 +418,11 @@ #hwlock-cells = <1>; }; @@ -61,7 +61,7 @@ Signed-off-by: Robert Marko spmi_bus: spmi@200f000 { compatible = "qcom,spmi-pmic-arb"; reg = <0x0200f000 0x001000>, -@@ -893,5 +924,62 @@ +@@ -887,5 +918,62 @@ "axi_s_sticky"; status = "disabled"; }; diff --git a/target/linux/ipq807x/patches-5.15/0120-arm64-dts-ipq8074-Add-WLAN-node.patch b/target/linux/ipq807x/patches-5.15/0120-arm64-dts-ipq8074-Add-WLAN-node.patch index ca22d048b..92fe73d8a 100644 --- a/target/linux/ipq807x/patches-5.15/0120-arm64-dts-ipq8074-Add-WLAN-node.patch +++ b/target/linux/ipq807x/patches-5.15/0120-arm64-dts-ipq8074-Add-WLAN-node.patch @@ -15,7 +15,7 @@ Signed-off-by: Robert Marko --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -981,5 +981,116 @@ +@@ -975,5 +975,116 @@ }; }; }; diff --git a/target/linux/ipq807x/patches-5.15/0121-thermal-qcom-tsens-Add-IPQ8074-support.patch b/target/linux/ipq807x/patches-5.15/0121-thermal-qcom-tsens-Add-IPQ8074-support.patch index e55bc0bdb..2f8f1d72c 100644 --- a/target/linux/ipq807x/patches-5.15/0121-thermal-qcom-tsens-Add-IPQ8074-support.patch +++ b/target/linux/ipq807x/patches-5.15/0121-thermal-qcom-tsens-Add-IPQ8074-support.patch @@ -77,7 +77,7 @@ Signed-off-by: Robert Marko } else { /* No mask register on older TSENS */ d->up_irq_mask = 0; -@@ -993,6 +999,9 @@ static const struct of_device_id tsens_t +@@ -999,6 +1005,9 @@ static const struct of_device_id tsens_t }, { .compatible = "qcom,tsens-v2", .data = &data_tsens_v2, @@ -90,7 +90,7 @@ Signed-off-by: Robert Marko --- a/drivers/thermal/qcom/tsens.h +++ b/drivers/thermal/qcom/tsens.h @@ -593,6 +593,6 @@ extern struct tsens_plat_data data_8916, - extern struct tsens_plat_data data_tsens_v1, data_8976; + extern struct tsens_plat_data data_tsens_v1, data_8976, data_8956; /* TSENS v2 targets */ -extern struct tsens_plat_data data_8996, data_tsens_v2; diff --git a/target/linux/ipq807x/patches-5.15/0122-arm64-dts-ipq8074-add-thermal-nodes.patch b/target/linux/ipq807x/patches-5.15/0122-arm64-dts-ipq8074-add-thermal-nodes.patch index bd991c08b..8fecc869c 100644 --- a/target/linux/ipq807x/patches-5.15/0122-arm64-dts-ipq8074-add-thermal-nodes.patch +++ b/target/linux/ipq807x/patches-5.15/0122-arm64-dts-ipq8074-add-thermal-nodes.patch @@ -18,7 +18,7 @@ Signed-off-by: Robert Marko --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -332,6 +332,16 @@ +@@ -331,6 +331,16 @@ status = "disabled"; }; @@ -35,7 +35,7 @@ Signed-off-by: Robert Marko cryptobam: dma@704000 { compatible = "qcom,bam-v1.7.0"; reg = <0x00704000 0x20000>; -@@ -1093,4 +1103,90 @@ +@@ -1087,4 +1097,90 @@ status = "disabled"; }; }; diff --git a/target/linux/ipq807x/patches-5.15/0129-arm64-dts-ipq8074-add-SPMI-PMIC-regulators.patch b/target/linux/ipq807x/patches-5.15/0129-arm64-dts-ipq8074-add-SPMI-PMIC-regulators.patch index 297d77f0e..ce32bb366 100644 --- a/target/linux/ipq807x/patches-5.15/0129-arm64-dts-ipq8074-add-SPMI-PMIC-regulators.patch +++ b/target/linux/ipq807x/patches-5.15/0129-arm64-dts-ipq8074-add-SPMI-PMIC-regulators.patch @@ -23,7 +23,7 @@ Signed-off-by: Robert Marko / { model = "Qualcomm Technologies, Inc. IPQ8074"; -@@ -451,6 +452,39 @@ +@@ -450,6 +451,39 @@ interrupt-controller; #interrupt-cells = <4>; cell-index = <0>; diff --git a/target/linux/ipq807x/patches-5.15/0134-arm64-dts-ipq8074-update-APCS-node-due-to-clock-supp.patch b/target/linux/ipq807x/patches-5.15/0134-arm64-dts-ipq8074-update-APCS-node-due-to-clock-supp.patch index 64e89de82..5b1f0d2df 100644 --- a/target/linux/ipq807x/patches-5.15/0134-arm64-dts-ipq8074-update-APCS-node-due-to-clock-supp.patch +++ b/target/linux/ipq807x/patches-5.15/0134-arm64-dts-ipq8074-update-APCS-node-due-to-clock-supp.patch @@ -15,7 +15,7 @@ Signed-off-by: Robert Marko --- a/arch/arm64/boot/dts/qcom/ipq8074.dtsi +++ b/arch/arm64/boot/dts/qcom/ipq8074.dtsi -@@ -971,8 +971,9 @@ +@@ -965,8 +965,9 @@ apcs_glb: mailbox@b111000 { compatible = "qcom,ipq8074-apcs-apps-global"; diff --git a/target/linux/ipq807x/patches-5.15/0600-5.15-qca-nss-ecm-support-CORE.patch b/target/linux/ipq807x/patches-5.15/0600-5.15-qca-nss-ecm-support-CORE.patch index 912d20987..e6934e75f 100644 --- a/target/linux/ipq807x/patches-5.15/0600-5.15-qca-nss-ecm-support-CORE.patch +++ b/target/linux/ipq807x/patches-5.15/0600-5.15-qca-nss-ecm-support-CORE.patch @@ -592,7 +592,7 @@ out: fib6_info_release(rt); return err; -@@ -6352,6 +6362,20 @@ static int ip6_route_dev_notify(struct n +@@ -6353,6 +6363,20 @@ static int ip6_route_dev_notify(struct n return NOTIFY_OK; } diff --git a/target/linux/rockchip/patches-5.15/013-v5.16-arm64-dts-rockchip-move-rk3568-dtsi-to-rk356x-dtsi.patch b/target/linux/rockchip/patches-5.15/013-v5.16-arm64-dts-rockchip-move-rk3568-dtsi-to-rk356x-dtsi.patch index f75c2f04c..46cf89206 100644 --- a/target/linux/rockchip/patches-5.15/013-v5.16-arm64-dts-rockchip-move-rk3568-dtsi-to-rk356x-dtsi.patch +++ b/target/linux/rockchip/patches-5.15/013-v5.16-arm64-dts-rockchip-move-rk3568-dtsi-to-rk356x-dtsi.patch @@ -15,7 +15,1677 @@ Signed-off-by: Heiko Stuebner 1 file changed, 0 insertions(+), 0 deletions(-) rename arch/arm64/boot/dts/rockchip/{rk3568.dtsi => rk356x.dtsi} (100%) -diff --git a/arch/arm64/boot/dts/rockchip/rk3568.dtsi b/arch/arm64/boot/dts/rockchip/rk356x.dtsi -similarity index 100% -rename from arch/arm64/boot/dts/rockchip/rk3568.dtsi -rename to arch/arm64/boot/dts/rockchip/rk356x.dtsi +--- a/arch/arm64/boot/dts/rockchip/rk3568.dtsi ++++ /dev/null +@@ -1,834 +0,0 @@ +-// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +-/* +- * Copyright (c) 2021 Rockchip Electronics Co., Ltd. +- */ +- +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include +- +-/ { +- compatible = "rockchip,rk3568"; +- +- interrupt-parent = <&gic>; +- #address-cells = <2>; +- #size-cells = <2>; +- +- aliases { +- gpio0 = &gpio0; +- gpio1 = &gpio1; +- gpio2 = &gpio2; +- gpio3 = &gpio3; +- gpio4 = &gpio4; +- i2c0 = &i2c0; +- i2c1 = &i2c1; +- i2c2 = &i2c2; +- i2c3 = &i2c3; +- i2c4 = &i2c4; +- i2c5 = &i2c5; +- serial0 = &uart0; +- serial1 = &uart1; +- serial2 = &uart2; +- serial3 = &uart3; +- serial4 = &uart4; +- serial5 = &uart5; +- serial6 = &uart6; +- serial7 = &uart7; +- serial8 = &uart8; +- serial9 = &uart9; +- }; +- +- cpus { +- #address-cells = <2>; +- #size-cells = <0>; +- +- cpu0: cpu@0 { +- device_type = "cpu"; +- compatible = "arm,cortex-a55"; +- reg = <0x0 0x0>; +- clocks = <&scmi_clk 0>; +- enable-method = "psci"; +- operating-points-v2 = <&cpu0_opp_table>; +- }; +- +- cpu1: cpu@100 { +- device_type = "cpu"; +- compatible = "arm,cortex-a55"; +- reg = <0x0 0x100>; +- enable-method = "psci"; +- operating-points-v2 = <&cpu0_opp_table>; +- }; +- +- cpu2: cpu@200 { +- device_type = "cpu"; +- compatible = "arm,cortex-a55"; +- reg = <0x0 0x200>; +- enable-method = "psci"; +- operating-points-v2 = <&cpu0_opp_table>; +- }; +- +- cpu3: cpu@300 { +- device_type = "cpu"; +- compatible = "arm,cortex-a55"; +- reg = <0x0 0x300>; +- enable-method = "psci"; +- operating-points-v2 = <&cpu0_opp_table>; +- }; +- }; +- +- cpu0_opp_table: cpu0-opp-table { +- compatible = "operating-points-v2"; +- opp-shared; +- +- opp-408000000 { +- opp-hz = /bits/ 64 <408000000>; +- opp-microvolt = <900000 900000 1150000>; +- clock-latency-ns = <40000>; +- }; +- +- opp-600000000 { +- opp-hz = /bits/ 64 <600000000>; +- opp-microvolt = <900000 900000 1150000>; +- }; +- +- opp-816000000 { +- opp-hz = /bits/ 64 <816000000>; +- opp-microvolt = <900000 900000 1150000>; +- opp-suspend; +- }; +- +- opp-1104000000 { +- opp-hz = /bits/ 64 <1104000000>; +- opp-microvolt = <900000 900000 1150000>; +- }; +- +- opp-1416000000 { +- opp-hz = /bits/ 64 <1416000000>; +- opp-microvolt = <900000 900000 1150000>; +- }; +- +- opp-1608000000 { +- opp-hz = /bits/ 64 <1608000000>; +- opp-microvolt = <975000 975000 1150000>; +- }; +- +- opp-1800000000 { +- opp-hz = /bits/ 64 <1800000000>; +- opp-microvolt = <1050000 1050000 1150000>; +- }; +- +- opp-1992000000 { +- opp-hz = /bits/ 64 <1992000000>; +- opp-microvolt = <1150000 1150000 1150000>; +- }; +- }; +- +- firmware { +- scmi: scmi { +- compatible = "arm,scmi-smc"; +- arm,smc-id = <0x82000010>; +- shmem = <&scmi_shmem>; +- #address-cells = <1>; +- #size-cells = <0>; +- +- scmi_clk: protocol@14 { +- reg = <0x14>; +- #clock-cells = <1>; +- }; +- }; +- }; +- +- pmu { +- compatible = "arm,cortex-a55-pmu"; +- interrupts = , +- , +- , +- ; +- interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>; +- }; +- +- psci { +- compatible = "arm,psci-1.0"; +- method = "smc"; +- }; +- +- timer { +- compatible = "arm,armv8-timer"; +- interrupts = , +- , +- , +- ; +- arm,no-tick-in-suspend; +- }; +- +- xin24m: xin24m { +- compatible = "fixed-clock"; +- clock-frequency = <24000000>; +- clock-output-names = "xin24m"; +- #clock-cells = <0>; +- }; +- +- xin32k: xin32k { +- compatible = "fixed-clock"; +- clock-frequency = <32768>; +- clock-output-names = "xin32k"; +- pinctrl-0 = <&clk32k_out0>; +- pinctrl-names = "default"; +- #clock-cells = <0>; +- }; +- +- sram@10f000 { +- compatible = "mmio-sram"; +- reg = <0x0 0x0010f000 0x0 0x100>; +- #address-cells = <1>; +- #size-cells = <1>; +- ranges = <0 0x0 0x0010f000 0x100>; +- +- scmi_shmem: sram@0 { +- compatible = "arm,scmi-shmem"; +- reg = <0x0 0x100>; +- }; +- }; +- +- gic: interrupt-controller@fd400000 { +- compatible = "arm,gic-v3"; +- reg = <0x0 0xfd400000 0 0x10000>, /* GICD */ +- <0x0 0xfd460000 0 0x80000>; /* GICR */ +- interrupts = ; +- interrupt-controller; +- #interrupt-cells = <3>; +- mbi-alias = <0x0 0xfd100000>; +- mbi-ranges = <296 24>; +- msi-controller; +- }; +- +- pmugrf: syscon@fdc20000 { +- compatible = "rockchip,rk3568-pmugrf", "syscon", "simple-mfd"; +- reg = <0x0 0xfdc20000 0x0 0x10000>; +- }; +- +- grf: syscon@fdc60000 { +- compatible = "rockchip,rk3568-grf", "syscon", "simple-mfd"; +- reg = <0x0 0xfdc60000 0x0 0x10000>; +- }; +- +- pmucru: clock-controller@fdd00000 { +- compatible = "rockchip,rk3568-pmucru"; +- reg = <0x0 0xfdd00000 0x0 0x1000>; +- #clock-cells = <1>; +- #reset-cells = <1>; +- }; +- +- cru: clock-controller@fdd20000 { +- compatible = "rockchip,rk3568-cru"; +- reg = <0x0 0xfdd20000 0x0 0x1000>; +- #clock-cells = <1>; +- #reset-cells = <1>; +- }; +- +- i2c0: i2c@fdd40000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfdd40000 0x0 0x1000>; +- interrupts = ; +- clocks = <&pmucru CLK_I2C0>, <&pmucru PCLK_I2C0>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c0_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- uart0: serial@fdd50000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfdd50000 0x0 0x100>; +- interrupts = ; +- clocks = <&pmucru SCLK_UART0>, <&pmucru PCLK_UART0>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 0>, <&dmac0 1>; +- pinctrl-0 = <&uart0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- pmu: power-management@fdd90000 { +- compatible = "rockchip,rk3568-pmu", "syscon", "simple-mfd"; +- reg = <0x0 0xfdd90000 0x0 0x1000>; +- +- power: power-controller { +- compatible = "rockchip,rk3568-power-controller"; +- #power-domain-cells = <1>; +- #address-cells = <1>; +- #size-cells = <0>; +- +- /* These power domains are grouped by VD_GPU */ +- power-domain@RK3568_PD_GPU { +- reg = ; +- clocks = <&cru ACLK_GPU_PRE>, +- <&cru PCLK_GPU_PRE>; +- pm_qos = <&qos_gpu>; +- #power-domain-cells = <0>; +- }; +- +- /* These power domains are grouped by VD_LOGIC */ +- power-domain@RK3568_PD_VI { +- reg = ; +- clocks = <&cru HCLK_VI>, +- <&cru PCLK_VI>; +- pm_qos = <&qos_isp>, +- <&qos_vicap0>, +- <&qos_vicap1>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_VO { +- reg = ; +- clocks = <&cru HCLK_VO>, +- <&cru PCLK_VO>, +- <&cru ACLK_VOP_PRE>; +- pm_qos = <&qos_hdcp>, +- <&qos_vop_m0>, +- <&qos_vop_m1>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_RGA { +- reg = ; +- clocks = <&cru HCLK_RGA_PRE>, +- <&cru PCLK_RGA_PRE>; +- pm_qos = <&qos_ebc>, +- <&qos_iep>, +- <&qos_jpeg_dec>, +- <&qos_jpeg_enc>, +- <&qos_rga_rd>, +- <&qos_rga_wr>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_VPU { +- reg = ; +- clocks = <&cru HCLK_VPU_PRE>; +- pm_qos = <&qos_vpu>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_RKVDEC { +- clocks = <&cru HCLK_RKVDEC_PRE>; +- reg = ; +- pm_qos = <&qos_rkvdec>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_RKVENC { +- reg = ; +- clocks = <&cru HCLK_RKVENC_PRE>; +- pm_qos = <&qos_rkvenc_rd_m0>, +- <&qos_rkvenc_rd_m1>, +- <&qos_rkvenc_wr_m0>; +- #power-domain-cells = <0>; +- }; +- +- power-domain@RK3568_PD_PIPE { +- reg = ; +- clocks = <&cru PCLK_PIPE>; +- pm_qos = <&qos_pcie2x1>, +- <&qos_pcie3x1>, +- <&qos_pcie3x2>, +- <&qos_sata0>, +- <&qos_sata1>, +- <&qos_sata2>, +- <&qos_usb3_0>, +- <&qos_usb3_1>; +- #power-domain-cells = <0>; +- }; +- }; +- }; +- +- sdmmc2: mmc@fe000000 { +- compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; +- reg = <0x0 0xfe000000 0x0 0x4000>; +- interrupts = ; +- clocks = <&cru HCLK_SDMMC2>, <&cru CLK_SDMMC2>, +- <&cru SCLK_SDMMC2_DRV>, <&cru SCLK_SDMMC2_SAMPLE>; +- clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; +- fifo-depth = <0x100>; +- max-frequency = <150000000>; +- resets = <&cru SRST_SDMMC2>; +- reset-names = "reset"; +- status = "disabled"; +- }; +- +- qos_gpu: qos@fe128000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe128000 0x0 0x20>; +- }; +- +- qos_rkvenc_rd_m0: qos@fe138080 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe138080 0x0 0x20>; +- }; +- +- qos_rkvenc_rd_m1: qos@fe138100 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe138100 0x0 0x20>; +- }; +- +- qos_rkvenc_wr_m0: qos@fe138180 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe138180 0x0 0x20>; +- }; +- +- qos_isp: qos@fe148000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe148000 0x0 0x20>; +- }; +- +- qos_vicap0: qos@fe148080 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe148080 0x0 0x20>; +- }; +- +- qos_vicap1: qos@fe148100 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe148100 0x0 0x20>; +- }; +- +- qos_vpu: qos@fe150000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe150000 0x0 0x20>; +- }; +- +- qos_ebc: qos@fe158000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158000 0x0 0x20>; +- }; +- +- qos_iep: qos@fe158100 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158100 0x0 0x20>; +- }; +- +- qos_jpeg_dec: qos@fe158180 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158180 0x0 0x20>; +- }; +- +- qos_jpeg_enc: qos@fe158200 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158200 0x0 0x20>; +- }; +- +- qos_rga_rd: qos@fe158280 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158280 0x0 0x20>; +- }; +- +- qos_rga_wr: qos@fe158300 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe158300 0x0 0x20>; +- }; +- +- qos_npu: qos@fe180000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe180000 0x0 0x20>; +- }; +- +- qos_pcie2x1: qos@fe190000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190000 0x0 0x20>; +- }; +- +- qos_pcie3x1: qos@fe190080 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190080 0x0 0x20>; +- }; +- +- qos_pcie3x2: qos@fe190100 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190100 0x0 0x20>; +- }; +- +- qos_sata0: qos@fe190200 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190200 0x0 0x20>; +- }; +- +- qos_sata1: qos@fe190280 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190280 0x0 0x20>; +- }; +- +- qos_sata2: qos@fe190300 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190300 0x0 0x20>; +- }; +- +- qos_usb3_0: qos@fe190380 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190380 0x0 0x20>; +- }; +- +- qos_usb3_1: qos@fe190400 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe190400 0x0 0x20>; +- }; +- +- qos_rkvdec: qos@fe198000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe198000 0x0 0x20>; +- }; +- +- qos_hdcp: qos@fe1a8000 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe1a8000 0x0 0x20>; +- }; +- +- qos_vop_m0: qos@fe1a8080 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe1a8080 0x0 0x20>; +- }; +- +- qos_vop_m1: qos@fe1a8100 { +- compatible = "rockchip,rk3568-qos", "syscon"; +- reg = <0x0 0xfe1a8100 0x0 0x20>; +- }; +- +- sdmmc0: mmc@fe2b0000 { +- compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; +- reg = <0x0 0xfe2b0000 0x0 0x4000>; +- interrupts = ; +- clocks = <&cru HCLK_SDMMC0>, <&cru CLK_SDMMC0>, +- <&cru SCLK_SDMMC0_DRV>, <&cru SCLK_SDMMC0_SAMPLE>; +- clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; +- fifo-depth = <0x100>; +- max-frequency = <150000000>; +- resets = <&cru SRST_SDMMC0>; +- reset-names = "reset"; +- status = "disabled"; +- }; +- +- sdmmc1: mmc@fe2c0000 { +- compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; +- reg = <0x0 0xfe2c0000 0x0 0x4000>; +- interrupts = ; +- clocks = <&cru HCLK_SDMMC1>, <&cru CLK_SDMMC1>, +- <&cru SCLK_SDMMC1_DRV>, <&cru SCLK_SDMMC1_SAMPLE>; +- clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; +- fifo-depth = <0x100>; +- max-frequency = <150000000>; +- resets = <&cru SRST_SDMMC1>; +- reset-names = "reset"; +- status = "disabled"; +- }; +- +- sdhci: mmc@fe310000 { +- compatible = "rockchip,rk3568-dwcmshc"; +- reg = <0x0 0xfe310000 0x0 0x10000>; +- interrupts = ; +- assigned-clocks = <&cru BCLK_EMMC>, <&cru TCLK_EMMC>; +- assigned-clock-rates = <200000000>, <24000000>; +- clocks = <&cru CCLK_EMMC>, <&cru HCLK_EMMC>, +- <&cru ACLK_EMMC>, <&cru BCLK_EMMC>, +- <&cru TCLK_EMMC>; +- clock-names = "core", "bus", "axi", "block", "timer"; +- status = "disabled"; +- }; +- +- dmac0: dmac@fe530000 { +- compatible = "arm,pl330", "arm,primecell"; +- reg = <0x0 0xfe530000 0x0 0x4000>; +- interrupts = , +- ; +- arm,pl330-periph-burst; +- clocks = <&cru ACLK_BUS>; +- clock-names = "apb_pclk"; +- #dma-cells = <1>; +- }; +- +- dmac1: dmac@fe550000 { +- compatible = "arm,pl330", "arm,primecell"; +- reg = <0x0 0xfe550000 0x0 0x4000>; +- interrupts = , +- ; +- arm,pl330-periph-burst; +- clocks = <&cru ACLK_BUS>; +- clock-names = "apb_pclk"; +- #dma-cells = <1>; +- }; +- +- i2c1: i2c@fe5a0000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfe5a0000 0x0 0x1000>; +- interrupts = ; +- clocks = <&cru CLK_I2C1>, <&cru PCLK_I2C1>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c1_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- i2c2: i2c@fe5b0000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfe5b0000 0x0 0x1000>; +- interrupts = ; +- clocks = <&cru CLK_I2C2>, <&cru PCLK_I2C2>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c2m0_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- i2c3: i2c@fe5c0000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfe5c0000 0x0 0x1000>; +- interrupts = ; +- clocks = <&cru CLK_I2C3>, <&cru PCLK_I2C3>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c3m0_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- i2c4: i2c@fe5d0000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfe5d0000 0x0 0x1000>; +- interrupts = ; +- clocks = <&cru CLK_I2C4>, <&cru PCLK_I2C4>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c4m0_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- i2c5: i2c@fe5e0000 { +- compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; +- reg = <0x0 0xfe5e0000 0x0 0x1000>; +- interrupts = ; +- clocks = <&cru CLK_I2C5>, <&cru PCLK_I2C5>; +- clock-names = "i2c", "pclk"; +- pinctrl-0 = <&i2c5m0_xfer>; +- pinctrl-names = "default"; +- #address-cells = <1>; +- #size-cells = <0>; +- status = "disabled"; +- }; +- +- uart1: serial@fe650000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe650000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 2>, <&dmac0 3>; +- pinctrl-0 = <&uart1m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart2: serial@fe660000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe660000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART2>, <&cru PCLK_UART2>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 4>, <&dmac0 5>; +- pinctrl-0 = <&uart2m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart3: serial@fe670000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe670000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART3>, <&cru PCLK_UART3>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 6>, <&dmac0 7>; +- pinctrl-0 = <&uart3m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart4: serial@fe680000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe680000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART4>, <&cru PCLK_UART4>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 8>, <&dmac0 9>; +- pinctrl-0 = <&uart4m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart5: serial@fe690000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe690000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART5>, <&cru PCLK_UART5>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 10>, <&dmac0 11>; +- pinctrl-0 = <&uart5m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart6: serial@fe6a0000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe6a0000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART6>, <&cru PCLK_UART6>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 12>, <&dmac0 13>; +- pinctrl-0 = <&uart6m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart7: serial@fe6b0000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe6b0000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART7>, <&cru PCLK_UART7>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 14>, <&dmac0 15>; +- pinctrl-0 = <&uart7m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart8: serial@fe6c0000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe6c0000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART8>, <&cru PCLK_UART8>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 16>, <&dmac0 17>; +- pinctrl-0 = <&uart8m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- uart9: serial@fe6d0000 { +- compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; +- reg = <0x0 0xfe6d0000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru SCLK_UART9>, <&cru PCLK_UART9>; +- clock-names = "baudclk", "apb_pclk"; +- dmas = <&dmac0 18>, <&dmac0 19>; +- pinctrl-0 = <&uart9m0_xfer>; +- pinctrl-names = "default"; +- reg-io-width = <4>; +- reg-shift = <2>; +- status = "disabled"; +- }; +- +- saradc: saradc@fe720000 { +- compatible = "rockchip,rk3568-saradc", "rockchip,rk3399-saradc"; +- reg = <0x0 0xfe720000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru CLK_SARADC>, <&cru PCLK_SARADC>; +- clock-names = "saradc", "apb_pclk"; +- resets = <&cru SRST_P_SARADC>; +- reset-names = "saradc-apb"; +- #io-channel-cells = <1>; +- status = "disabled"; +- }; +- +- pinctrl: pinctrl { +- compatible = "rockchip,rk3568-pinctrl"; +- rockchip,grf = <&grf>; +- rockchip,pmu = <&pmugrf>; +- #address-cells = <2>; +- #size-cells = <2>; +- ranges; +- +- gpio0: gpio@fdd60000 { +- compatible = "rockchip,gpio-bank"; +- reg = <0x0 0xfdd60000 0x0 0x100>; +- interrupts = ; +- clocks = <&pmucru PCLK_GPIO0>; +- gpio-controller; +- #gpio-cells = <2>; +- interrupt-controller; +- #interrupt-cells = <2>; +- }; +- +- gpio1: gpio@fe740000 { +- compatible = "rockchip,gpio-bank"; +- reg = <0x0 0xfe740000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru PCLK_GPIO1>; +- gpio-controller; +- #gpio-cells = <2>; +- interrupt-controller; +- #interrupt-cells = <2>; +- }; +- +- gpio2: gpio@fe750000 { +- compatible = "rockchip,gpio-bank"; +- reg = <0x0 0xfe750000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru PCLK_GPIO2>; +- gpio-controller; +- #gpio-cells = <2>; +- interrupt-controller; +- #interrupt-cells = <2>; +- }; +- +- gpio3: gpio@fe760000 { +- compatible = "rockchip,gpio-bank"; +- reg = <0x0 0xfe760000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru PCLK_GPIO3>; +- gpio-controller; +- #gpio-cells = <2>; +- interrupt-controller; +- #interrupt-cells = <2>; +- }; +- +- gpio4: gpio@fe770000 { +- compatible = "rockchip,gpio-bank"; +- reg = <0x0 0xfe770000 0x0 0x100>; +- interrupts = ; +- clocks = <&cru PCLK_GPIO4>; +- gpio-controller; +- #gpio-cells = <2>; +- interrupt-controller; +- #interrupt-cells = <2>; +- }; +- }; +-}; +- +-#include "rk3568-pinctrl.dtsi" +--- /dev/null ++++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi +@@ -0,0 +1,834 @@ ++// SPDX-License-Identifier: (GPL-2.0+ OR MIT) ++/* ++ * Copyright (c) 2021 Rockchip Electronics Co., Ltd. ++ */ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++/ { ++ compatible = "rockchip,rk3568"; ++ ++ interrupt-parent = <&gic>; ++ #address-cells = <2>; ++ #size-cells = <2>; ++ ++ aliases { ++ gpio0 = &gpio0; ++ gpio1 = &gpio1; ++ gpio2 = &gpio2; ++ gpio3 = &gpio3; ++ gpio4 = &gpio4; ++ i2c0 = &i2c0; ++ i2c1 = &i2c1; ++ i2c2 = &i2c2; ++ i2c3 = &i2c3; ++ i2c4 = &i2c4; ++ i2c5 = &i2c5; ++ serial0 = &uart0; ++ serial1 = &uart1; ++ serial2 = &uart2; ++ serial3 = &uart3; ++ serial4 = &uart4; ++ serial5 = &uart5; ++ serial6 = &uart6; ++ serial7 = &uart7; ++ serial8 = &uart8; ++ serial9 = &uart9; ++ }; ++ ++ cpus { ++ #address-cells = <2>; ++ #size-cells = <0>; ++ ++ cpu0: cpu@0 { ++ device_type = "cpu"; ++ compatible = "arm,cortex-a55"; ++ reg = <0x0 0x0>; ++ clocks = <&scmi_clk 0>; ++ enable-method = "psci"; ++ operating-points-v2 = <&cpu0_opp_table>; ++ }; ++ ++ cpu1: cpu@100 { ++ device_type = "cpu"; ++ compatible = "arm,cortex-a55"; ++ reg = <0x0 0x100>; ++ enable-method = "psci"; ++ operating-points-v2 = <&cpu0_opp_table>; ++ }; ++ ++ cpu2: cpu@200 { ++ device_type = "cpu"; ++ compatible = "arm,cortex-a55"; ++ reg = <0x0 0x200>; ++ enable-method = "psci"; ++ operating-points-v2 = <&cpu0_opp_table>; ++ }; ++ ++ cpu3: cpu@300 { ++ device_type = "cpu"; ++ compatible = "arm,cortex-a55"; ++ reg = <0x0 0x300>; ++ enable-method = "psci"; ++ operating-points-v2 = <&cpu0_opp_table>; ++ }; ++ }; ++ ++ cpu0_opp_table: cpu0-opp-table { ++ compatible = "operating-points-v2"; ++ opp-shared; ++ ++ opp-408000000 { ++ opp-hz = /bits/ 64 <408000000>; ++ opp-microvolt = <900000 900000 1150000>; ++ clock-latency-ns = <40000>; ++ }; ++ ++ opp-600000000 { ++ opp-hz = /bits/ 64 <600000000>; ++ opp-microvolt = <900000 900000 1150000>; ++ }; ++ ++ opp-816000000 { ++ opp-hz = /bits/ 64 <816000000>; ++ opp-microvolt = <900000 900000 1150000>; ++ opp-suspend; ++ }; ++ ++ opp-1104000000 { ++ opp-hz = /bits/ 64 <1104000000>; ++ opp-microvolt = <900000 900000 1150000>; ++ }; ++ ++ opp-1416000000 { ++ opp-hz = /bits/ 64 <1416000000>; ++ opp-microvolt = <900000 900000 1150000>; ++ }; ++ ++ opp-1608000000 { ++ opp-hz = /bits/ 64 <1608000000>; ++ opp-microvolt = <975000 975000 1150000>; ++ }; ++ ++ opp-1800000000 { ++ opp-hz = /bits/ 64 <1800000000>; ++ opp-microvolt = <1050000 1050000 1150000>; ++ }; ++ ++ opp-1992000000 { ++ opp-hz = /bits/ 64 <1992000000>; ++ opp-microvolt = <1150000 1150000 1150000>; ++ }; ++ }; ++ ++ firmware { ++ scmi: scmi { ++ compatible = "arm,scmi-smc"; ++ arm,smc-id = <0x82000010>; ++ shmem = <&scmi_shmem>; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ ++ scmi_clk: protocol@14 { ++ reg = <0x14>; ++ #clock-cells = <1>; ++ }; ++ }; ++ }; ++ ++ pmu { ++ compatible = "arm,cortex-a55-pmu"; ++ interrupts = , ++ , ++ , ++ ; ++ interrupt-affinity = <&cpu0>, <&cpu1>, <&cpu2>, <&cpu3>; ++ }; ++ ++ psci { ++ compatible = "arm,psci-1.0"; ++ method = "smc"; ++ }; ++ ++ timer { ++ compatible = "arm,armv8-timer"; ++ interrupts = , ++ , ++ , ++ ; ++ arm,no-tick-in-suspend; ++ }; ++ ++ xin24m: xin24m { ++ compatible = "fixed-clock"; ++ clock-frequency = <24000000>; ++ clock-output-names = "xin24m"; ++ #clock-cells = <0>; ++ }; ++ ++ xin32k: xin32k { ++ compatible = "fixed-clock"; ++ clock-frequency = <32768>; ++ clock-output-names = "xin32k"; ++ pinctrl-0 = <&clk32k_out0>; ++ pinctrl-names = "default"; ++ #clock-cells = <0>; ++ }; ++ ++ sram@10f000 { ++ compatible = "mmio-sram"; ++ reg = <0x0 0x0010f000 0x0 0x100>; ++ #address-cells = <1>; ++ #size-cells = <1>; ++ ranges = <0 0x0 0x0010f000 0x100>; ++ ++ scmi_shmem: sram@0 { ++ compatible = "arm,scmi-shmem"; ++ reg = <0x0 0x100>; ++ }; ++ }; ++ ++ gic: interrupt-controller@fd400000 { ++ compatible = "arm,gic-v3"; ++ reg = <0x0 0xfd400000 0 0x10000>, /* GICD */ ++ <0x0 0xfd460000 0 0x80000>; /* GICR */ ++ interrupts = ; ++ interrupt-controller; ++ #interrupt-cells = <3>; ++ mbi-alias = <0x0 0xfd100000>; ++ mbi-ranges = <296 24>; ++ msi-controller; ++ }; ++ ++ pmugrf: syscon@fdc20000 { ++ compatible = "rockchip,rk3568-pmugrf", "syscon", "simple-mfd"; ++ reg = <0x0 0xfdc20000 0x0 0x10000>; ++ }; ++ ++ grf: syscon@fdc60000 { ++ compatible = "rockchip,rk3568-grf", "syscon", "simple-mfd"; ++ reg = <0x0 0xfdc60000 0x0 0x10000>; ++ }; ++ ++ pmucru: clock-controller@fdd00000 { ++ compatible = "rockchip,rk3568-pmucru"; ++ reg = <0x0 0xfdd00000 0x0 0x1000>; ++ #clock-cells = <1>; ++ #reset-cells = <1>; ++ }; ++ ++ cru: clock-controller@fdd20000 { ++ compatible = "rockchip,rk3568-cru"; ++ reg = <0x0 0xfdd20000 0x0 0x1000>; ++ #clock-cells = <1>; ++ #reset-cells = <1>; ++ }; ++ ++ i2c0: i2c@fdd40000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfdd40000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&pmucru CLK_I2C0>, <&pmucru PCLK_I2C0>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c0_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ uart0: serial@fdd50000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfdd50000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&pmucru SCLK_UART0>, <&pmucru PCLK_UART0>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 0>, <&dmac0 1>; ++ pinctrl-0 = <&uart0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ pmu: power-management@fdd90000 { ++ compatible = "rockchip,rk3568-pmu", "syscon", "simple-mfd"; ++ reg = <0x0 0xfdd90000 0x0 0x1000>; ++ ++ power: power-controller { ++ compatible = "rockchip,rk3568-power-controller"; ++ #power-domain-cells = <1>; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ ++ /* These power domains are grouped by VD_GPU */ ++ power-domain@RK3568_PD_GPU { ++ reg = ; ++ clocks = <&cru ACLK_GPU_PRE>, ++ <&cru PCLK_GPU_PRE>; ++ pm_qos = <&qos_gpu>; ++ #power-domain-cells = <0>; ++ }; ++ ++ /* These power domains are grouped by VD_LOGIC */ ++ power-domain@RK3568_PD_VI { ++ reg = ; ++ clocks = <&cru HCLK_VI>, ++ <&cru PCLK_VI>; ++ pm_qos = <&qos_isp>, ++ <&qos_vicap0>, ++ <&qos_vicap1>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_VO { ++ reg = ; ++ clocks = <&cru HCLK_VO>, ++ <&cru PCLK_VO>, ++ <&cru ACLK_VOP_PRE>; ++ pm_qos = <&qos_hdcp>, ++ <&qos_vop_m0>, ++ <&qos_vop_m1>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_RGA { ++ reg = ; ++ clocks = <&cru HCLK_RGA_PRE>, ++ <&cru PCLK_RGA_PRE>; ++ pm_qos = <&qos_ebc>, ++ <&qos_iep>, ++ <&qos_jpeg_dec>, ++ <&qos_jpeg_enc>, ++ <&qos_rga_rd>, ++ <&qos_rga_wr>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_VPU { ++ reg = ; ++ clocks = <&cru HCLK_VPU_PRE>; ++ pm_qos = <&qos_vpu>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_RKVDEC { ++ clocks = <&cru HCLK_RKVDEC_PRE>; ++ reg = ; ++ pm_qos = <&qos_rkvdec>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_RKVENC { ++ reg = ; ++ clocks = <&cru HCLK_RKVENC_PRE>; ++ pm_qos = <&qos_rkvenc_rd_m0>, ++ <&qos_rkvenc_rd_m1>, ++ <&qos_rkvenc_wr_m0>; ++ #power-domain-cells = <0>; ++ }; ++ ++ power-domain@RK3568_PD_PIPE { ++ reg = ; ++ clocks = <&cru PCLK_PIPE>; ++ pm_qos = <&qos_pcie2x1>, ++ <&qos_pcie3x1>, ++ <&qos_pcie3x2>, ++ <&qos_sata0>, ++ <&qos_sata1>, ++ <&qos_sata2>, ++ <&qos_usb3_0>, ++ <&qos_usb3_1>; ++ #power-domain-cells = <0>; ++ }; ++ }; ++ }; ++ ++ sdmmc2: mmc@fe000000 { ++ compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; ++ reg = <0x0 0xfe000000 0x0 0x4000>; ++ interrupts = ; ++ clocks = <&cru HCLK_SDMMC2>, <&cru CLK_SDMMC2>, ++ <&cru SCLK_SDMMC2_DRV>, <&cru SCLK_SDMMC2_SAMPLE>; ++ clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; ++ fifo-depth = <0x100>; ++ max-frequency = <150000000>; ++ resets = <&cru SRST_SDMMC2>; ++ reset-names = "reset"; ++ status = "disabled"; ++ }; ++ ++ qos_gpu: qos@fe128000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe128000 0x0 0x20>; ++ }; ++ ++ qos_rkvenc_rd_m0: qos@fe138080 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe138080 0x0 0x20>; ++ }; ++ ++ qos_rkvenc_rd_m1: qos@fe138100 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe138100 0x0 0x20>; ++ }; ++ ++ qos_rkvenc_wr_m0: qos@fe138180 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe138180 0x0 0x20>; ++ }; ++ ++ qos_isp: qos@fe148000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe148000 0x0 0x20>; ++ }; ++ ++ qos_vicap0: qos@fe148080 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe148080 0x0 0x20>; ++ }; ++ ++ qos_vicap1: qos@fe148100 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe148100 0x0 0x20>; ++ }; ++ ++ qos_vpu: qos@fe150000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe150000 0x0 0x20>; ++ }; ++ ++ qos_ebc: qos@fe158000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158000 0x0 0x20>; ++ }; ++ ++ qos_iep: qos@fe158100 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158100 0x0 0x20>; ++ }; ++ ++ qos_jpeg_dec: qos@fe158180 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158180 0x0 0x20>; ++ }; ++ ++ qos_jpeg_enc: qos@fe158200 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158200 0x0 0x20>; ++ }; ++ ++ qos_rga_rd: qos@fe158280 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158280 0x0 0x20>; ++ }; ++ ++ qos_rga_wr: qos@fe158300 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe158300 0x0 0x20>; ++ }; ++ ++ qos_npu: qos@fe180000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe180000 0x0 0x20>; ++ }; ++ ++ qos_pcie2x1: qos@fe190000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190000 0x0 0x20>; ++ }; ++ ++ qos_pcie3x1: qos@fe190080 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190080 0x0 0x20>; ++ }; ++ ++ qos_pcie3x2: qos@fe190100 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190100 0x0 0x20>; ++ }; ++ ++ qos_sata0: qos@fe190200 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190200 0x0 0x20>; ++ }; ++ ++ qos_sata1: qos@fe190280 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190280 0x0 0x20>; ++ }; ++ ++ qos_sata2: qos@fe190300 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190300 0x0 0x20>; ++ }; ++ ++ qos_usb3_0: qos@fe190380 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190380 0x0 0x20>; ++ }; ++ ++ qos_usb3_1: qos@fe190400 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe190400 0x0 0x20>; ++ }; ++ ++ qos_rkvdec: qos@fe198000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe198000 0x0 0x20>; ++ }; ++ ++ qos_hdcp: qos@fe1a8000 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe1a8000 0x0 0x20>; ++ }; ++ ++ qos_vop_m0: qos@fe1a8080 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe1a8080 0x0 0x20>; ++ }; ++ ++ qos_vop_m1: qos@fe1a8100 { ++ compatible = "rockchip,rk3568-qos", "syscon"; ++ reg = <0x0 0xfe1a8100 0x0 0x20>; ++ }; ++ ++ sdmmc0: mmc@fe2b0000 { ++ compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; ++ reg = <0x0 0xfe2b0000 0x0 0x4000>; ++ interrupts = ; ++ clocks = <&cru HCLK_SDMMC0>, <&cru CLK_SDMMC0>, ++ <&cru SCLK_SDMMC0_DRV>, <&cru SCLK_SDMMC0_SAMPLE>; ++ clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; ++ fifo-depth = <0x100>; ++ max-frequency = <150000000>; ++ resets = <&cru SRST_SDMMC0>; ++ reset-names = "reset"; ++ status = "disabled"; ++ }; ++ ++ sdmmc1: mmc@fe2c0000 { ++ compatible = "rockchip,rk3568-dw-mshc", "rockchip,rk3288-dw-mshc"; ++ reg = <0x0 0xfe2c0000 0x0 0x4000>; ++ interrupts = ; ++ clocks = <&cru HCLK_SDMMC1>, <&cru CLK_SDMMC1>, ++ <&cru SCLK_SDMMC1_DRV>, <&cru SCLK_SDMMC1_SAMPLE>; ++ clock-names = "biu", "ciu", "ciu-drive", "ciu-sample"; ++ fifo-depth = <0x100>; ++ max-frequency = <150000000>; ++ resets = <&cru SRST_SDMMC1>; ++ reset-names = "reset"; ++ status = "disabled"; ++ }; ++ ++ sdhci: mmc@fe310000 { ++ compatible = "rockchip,rk3568-dwcmshc"; ++ reg = <0x0 0xfe310000 0x0 0x10000>; ++ interrupts = ; ++ assigned-clocks = <&cru BCLK_EMMC>, <&cru TCLK_EMMC>; ++ assigned-clock-rates = <200000000>, <24000000>; ++ clocks = <&cru CCLK_EMMC>, <&cru HCLK_EMMC>, ++ <&cru ACLK_EMMC>, <&cru BCLK_EMMC>, ++ <&cru TCLK_EMMC>; ++ clock-names = "core", "bus", "axi", "block", "timer"; ++ status = "disabled"; ++ }; ++ ++ dmac0: dmac@fe530000 { ++ compatible = "arm,pl330", "arm,primecell"; ++ reg = <0x0 0xfe530000 0x0 0x4000>; ++ interrupts = , ++ ; ++ arm,pl330-periph-burst; ++ clocks = <&cru ACLK_BUS>; ++ clock-names = "apb_pclk"; ++ #dma-cells = <1>; ++ }; ++ ++ dmac1: dmac@fe550000 { ++ compatible = "arm,pl330", "arm,primecell"; ++ reg = <0x0 0xfe550000 0x0 0x4000>; ++ interrupts = , ++ ; ++ arm,pl330-periph-burst; ++ clocks = <&cru ACLK_BUS>; ++ clock-names = "apb_pclk"; ++ #dma-cells = <1>; ++ }; ++ ++ i2c1: i2c@fe5a0000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfe5a0000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&cru CLK_I2C1>, <&cru PCLK_I2C1>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c1_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ i2c2: i2c@fe5b0000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfe5b0000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&cru CLK_I2C2>, <&cru PCLK_I2C2>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c2m0_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ i2c3: i2c@fe5c0000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfe5c0000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&cru CLK_I2C3>, <&cru PCLK_I2C3>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c3m0_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ i2c4: i2c@fe5d0000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfe5d0000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&cru CLK_I2C4>, <&cru PCLK_I2C4>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c4m0_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ i2c5: i2c@fe5e0000 { ++ compatible = "rockchip,rk3568-i2c", "rockchip,rk3399-i2c"; ++ reg = <0x0 0xfe5e0000 0x0 0x1000>; ++ interrupts = ; ++ clocks = <&cru CLK_I2C5>, <&cru PCLK_I2C5>; ++ clock-names = "i2c", "pclk"; ++ pinctrl-0 = <&i2c5m0_xfer>; ++ pinctrl-names = "default"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ status = "disabled"; ++ }; ++ ++ uart1: serial@fe650000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe650000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART1>, <&cru PCLK_UART1>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 2>, <&dmac0 3>; ++ pinctrl-0 = <&uart1m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart2: serial@fe660000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe660000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART2>, <&cru PCLK_UART2>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 4>, <&dmac0 5>; ++ pinctrl-0 = <&uart2m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart3: serial@fe670000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe670000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART3>, <&cru PCLK_UART3>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 6>, <&dmac0 7>; ++ pinctrl-0 = <&uart3m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart4: serial@fe680000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe680000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART4>, <&cru PCLK_UART4>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 8>, <&dmac0 9>; ++ pinctrl-0 = <&uart4m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart5: serial@fe690000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe690000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART5>, <&cru PCLK_UART5>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 10>, <&dmac0 11>; ++ pinctrl-0 = <&uart5m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart6: serial@fe6a0000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe6a0000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART6>, <&cru PCLK_UART6>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 12>, <&dmac0 13>; ++ pinctrl-0 = <&uart6m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart7: serial@fe6b0000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe6b0000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART7>, <&cru PCLK_UART7>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 14>, <&dmac0 15>; ++ pinctrl-0 = <&uart7m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart8: serial@fe6c0000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe6c0000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART8>, <&cru PCLK_UART8>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 16>, <&dmac0 17>; ++ pinctrl-0 = <&uart8m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ uart9: serial@fe6d0000 { ++ compatible = "rockchip,rk3568-uart", "snps,dw-apb-uart"; ++ reg = <0x0 0xfe6d0000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru SCLK_UART9>, <&cru PCLK_UART9>; ++ clock-names = "baudclk", "apb_pclk"; ++ dmas = <&dmac0 18>, <&dmac0 19>; ++ pinctrl-0 = <&uart9m0_xfer>; ++ pinctrl-names = "default"; ++ reg-io-width = <4>; ++ reg-shift = <2>; ++ status = "disabled"; ++ }; ++ ++ saradc: saradc@fe720000 { ++ compatible = "rockchip,rk3568-saradc", "rockchip,rk3399-saradc"; ++ reg = <0x0 0xfe720000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru CLK_SARADC>, <&cru PCLK_SARADC>; ++ clock-names = "saradc", "apb_pclk"; ++ resets = <&cru SRST_P_SARADC>; ++ reset-names = "saradc-apb"; ++ #io-channel-cells = <1>; ++ status = "disabled"; ++ }; ++ ++ pinctrl: pinctrl { ++ compatible = "rockchip,rk3568-pinctrl"; ++ rockchip,grf = <&grf>; ++ rockchip,pmu = <&pmugrf>; ++ #address-cells = <2>; ++ #size-cells = <2>; ++ ranges; ++ ++ gpio0: gpio@fdd60000 { ++ compatible = "rockchip,gpio-bank"; ++ reg = <0x0 0xfdd60000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&pmucru PCLK_GPIO0>; ++ gpio-controller; ++ #gpio-cells = <2>; ++ interrupt-controller; ++ #interrupt-cells = <2>; ++ }; ++ ++ gpio1: gpio@fe740000 { ++ compatible = "rockchip,gpio-bank"; ++ reg = <0x0 0xfe740000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru PCLK_GPIO1>; ++ gpio-controller; ++ #gpio-cells = <2>; ++ interrupt-controller; ++ #interrupt-cells = <2>; ++ }; ++ ++ gpio2: gpio@fe750000 { ++ compatible = "rockchip,gpio-bank"; ++ reg = <0x0 0xfe750000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru PCLK_GPIO2>; ++ gpio-controller; ++ #gpio-cells = <2>; ++ interrupt-controller; ++ #interrupt-cells = <2>; ++ }; ++ ++ gpio3: gpio@fe760000 { ++ compatible = "rockchip,gpio-bank"; ++ reg = <0x0 0xfe760000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru PCLK_GPIO3>; ++ gpio-controller; ++ #gpio-cells = <2>; ++ interrupt-controller; ++ #interrupt-cells = <2>; ++ }; ++ ++ gpio4: gpio@fe770000 { ++ compatible = "rockchip,gpio-bank"; ++ reg = <0x0 0xfe770000 0x0 0x100>; ++ interrupts = ; ++ clocks = <&cru PCLK_GPIO4>; ++ gpio-controller; ++ #gpio-cells = <2>; ++ interrupt-controller; ++ #interrupt-cells = <2>; ++ }; ++ }; ++}; ++ ++#include "rk3568-pinctrl.dtsi" diff --git a/target/linux/rockchip/patches-5.15/074-v6.3-net-phy-motorcomm-change-the-phy-id-of.patch b/target/linux/rockchip/patches-5.15/074-v6.3-net-phy-motorcomm-change-the-phy-id-of.patch index 01ec856f6..ac67c1d62 100644 --- a/target/linux/rockchip/patches-5.15/074-v6.3-net-phy-motorcomm-change-the-phy-id-of.patch +++ b/target/linux/rockchip/patches-5.15/074-v6.3-net-phy-motorcomm-change-the-phy-id-of.patch @@ -27,7 +27,7 @@ Signed-off-by: Jakub Kicinski /* YT8521/YT8531S Register Overview * UTP Register space | FIBER Register space -@@ -1804,7 +1804,7 @@ static const struct mdio_device_id __maybe_unused motorcomm_tbl[] = { +@@ -1804,7 +1804,7 @@ static const struct mdio_device_id __may { PHY_ID_MATCH_EXACT(PHY_ID_YT8511) }, { PHY_ID_MATCH_EXACT(PHY_ID_YT8521) }, { PHY_ID_MATCH_EXACT(PHY_ID_YT8531S) }, diff --git a/target/linux/rockchip/patches-5.15/076-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8521.patch b/target/linux/rockchip/patches-5.15/076-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8521.patch index 2814beaed..6d89fae84 100644 --- a/target/linux/rockchip/patches-5.15/076-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8521.patch +++ b/target/linux/rockchip/patches-5.15/076-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8521.patch @@ -60,11 +60,10 @@ Signed-off-by: David S. Miller struct yt8521_priv { /* combo_advertising is used for case of YT8521 in combo mode, * this means that yt8521 may work in utp or fiber mode which depends -@@ -640,6 +633,142 @@ static int yt8521_write_page(struct phy_device *phydev, int page) - return ytphy_modify_ext(phydev, YT8521_REG_SPACE_SELECT_REG, mask, set); +@@ -641,6 +634,142 @@ static int yt8521_write_page(struct phy_ }; -+/** + /** + * struct ytphy_cfg_reg_map - map a config value to a register value + * @cfg: value in device configuration + * @reg: value in the register @@ -200,10 +199,11 @@ Signed-off-by: David S. Miller + return ytphy_modify_ext(phydev, YT8521_RGMII_CONFIG1_REG, mask, val); +} + - /** ++/** * yt8521_probe() - read chip config then set suitable polling_mode * @phydev: a pointer to a &struct phy_device -@@ -648,9 +777,12 @@ static int yt8521_write_page(struct phy_device *phydev, int page) + * +@@ -648,9 +777,12 @@ static int yt8521_write_page(struct phy_ */ static int yt8521_probe(struct phy_device *phydev) { @@ -216,7 +216,7 @@ Signed-off-by: David S. Miller int ret; priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL); -@@ -695,7 +827,45 @@ static int yt8521_probe(struct phy_device *phydev) +@@ -695,7 +827,45 @@ static int yt8521_probe(struct phy_devic return ret; } @@ -263,7 +263,7 @@ Signed-off-by: David S. Miller } /** -@@ -1180,61 +1350,36 @@ static int yt8521_resume(struct phy_device *phydev) +@@ -1180,61 +1350,36 @@ static int yt8521_resume(struct phy_devi */ static int yt8521_config_init(struct phy_device *phydev) { diff --git a/target/linux/rockchip/patches-5.15/077-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8531s.patch b/target/linux/rockchip/patches-5.15/077-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8531s.patch index 9c679b26a..86fc04695 100644 --- a/target/linux/rockchip/patches-5.15/077-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8531s.patch +++ b/target/linux/rockchip/patches-5.15/077-v6.3-net-phy-Add-dts-support-for-Motorcomm-yt8531s.patch @@ -28,7 +28,7 @@ Signed-off-by: David S. Miller /* Extended Register end */ -@@ -858,7 +856,32 @@ static int yt8521_probe(struct phy_device *phydev) +@@ -858,7 +856,32 @@ static int yt8521_probe(struct phy_devic return -EINVAL; } } else if (phydev->drv->phy_id == PHY_ID_YT8531S) { @@ -62,11 +62,10 @@ Signed-off-by: David S. Miller } else { phydev_warn(phydev, "PHY id err\n"); return -EINVAL; -@@ -868,26 +891,6 @@ static int yt8521_probe(struct phy_device *phydev) - val); +@@ -869,26 +892,6 @@ static int yt8521_probe(struct phy_devic } --/** + /** - * yt8531s_probe() - read chip config then set suitable polling_mode - * @phydev: a pointer to a &struct phy_device - * @@ -86,10 +85,11 @@ Signed-off-by: David S. Miller - return yt8521_probe(phydev); -} - - /** +-/** * ytphy_utp_read_lpa() - read LPA then setup lp_advertising for utp * @phydev: a pointer to a &struct phy_device -@@ -1970,7 +1973,7 @@ static struct phy_driver motorcomm_phy_drvs[] = { + * +@@ -1970,7 +1973,7 @@ static struct phy_driver motorcomm_phy_d PHY_ID_MATCH_EXACT(PHY_ID_YT8531S), .name = "YT8531S Gigabit Ethernet", .get_features = yt8521_get_features, diff --git a/target/linux/rockchip/patches-5.15/078-v6.3-net-phy-Add-driver-for-Motorcomm-yt8531-gigabit.patch b/target/linux/rockchip/patches-5.15/078-v6.3-net-phy-Add-driver-for-Motorcomm-yt8531-gigabit.patch index 2f2080c40..4efcf784c 100644 --- a/target/linux/rockchip/patches-5.15/078-v6.3-net-phy-Add-driver-for-Motorcomm-yt8531-gigabit.patch +++ b/target/linux/rockchip/patches-5.15/078-v6.3-net-phy-Add-driver-for-Motorcomm-yt8531-gigabit.patch @@ -28,8 +28,6 @@ Signed-off-by: David S. Miller config NATIONAL_PHY tristate "National Semiconductor PHYs" -diff --git a/drivers/net/phy/motorcomm.c b/drivers/net/phy/motorcomm.c -index bdc6a55d59f19..ee7c37dfdca01 100644 --- a/drivers/net/phy/motorcomm.c +++ b/drivers/net/phy/motorcomm.c @@ -1,6 +1,6 @@ @@ -48,7 +46,7 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 #define PHY_ID_YT8531S 0x4f51e91a /* YT8521/YT8531S Register Overview -@@ -517,6 +518,61 @@ static int ytphy_set_wol(struct phy_device *phydev, struct ethtool_wolinfo *wol) +@@ -517,6 +518,61 @@ err_restore_page: return phy_restore_page(phydev, old_page, ret); } @@ -110,7 +108,7 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 static int yt8511_read_page(struct phy_device *phydev) { return __phy_read(phydev, YT8511_PAGE_SELECT); -@@ -767,6 +823,17 @@ static int ytphy_rgmii_clk_delay_config(struct phy_device *phydev) +@@ -767,6 +823,17 @@ static int ytphy_rgmii_clk_delay_config( return ytphy_modify_ext(phydev, YT8521_RGMII_CONFIG1_REG, mask, val); } @@ -128,7 +126,7 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 /** * yt8521_probe() - read chip config then set suitable polling_mode * @phydev: a pointer to a &struct phy_device -@@ -891,6 +958,43 @@ static int yt8521_probe(struct phy_device *phydev) +@@ -891,6 +958,43 @@ static int yt8521_probe(struct phy_devic val); } @@ -172,7 +170,7 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 /** * ytphy_utp_read_lpa() - read LPA then setup lp_advertising for utp * @phydev: a pointer to a &struct phy_device -@@ -1387,6 +1491,94 @@ static int yt8521_config_init(struct phy_device *phydev) +@@ -1387,6 +1491,94 @@ err_restore_page: return phy_restore_page(phydev, old_page, ret); } @@ -267,11 +265,10 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 /** * yt8521_prepare_fiber_features() - A small helper function that setup * fiber's features. -@@ -1969,6 +2161,17 @@ static struct phy_driver motorcomm_phy_drvs[] = { - .suspend = yt8521_suspend, +@@ -1970,6 +2162,17 @@ static struct phy_driver motorcomm_phy_d .resume = yt8521_resume, }, -+ { + { + PHY_ID_MATCH_EXACT(PHY_ID_YT8531), + .name = "YT8531 Gigabit Ethernet", + .probe = yt8531_probe, @@ -282,10 +279,11 @@ index bdc6a55d59f19..ee7c37dfdca01 100644 + .set_wol = yt8531_set_wol, + .link_change_notify = yt8531_link_change_notify, + }, - { ++ { PHY_ID_MATCH_EXACT(PHY_ID_YT8531S), .name = "YT8531S Gigabit Ethernet", -@@ -1990,7 +2193,7 @@ static struct phy_driver motorcomm_phy_drvs[] = { + .get_features = yt8521_get_features, +@@ -1990,7 +2193,7 @@ static struct phy_driver motorcomm_phy_d module_phy_driver(motorcomm_phy_drvs); diff --git a/target/linux/rockchip/patches-5.15/079-v6.3-net-phy-motorcomm-uninitialized-variables-in.patch b/target/linux/rockchip/patches-5.15/079-v6.3-net-phy-motorcomm-uninitialized-variables-in.patch index 16ff9a215..29ae86dbb 100644 --- a/target/linux/rockchip/patches-5.15/079-v6.3-net-phy-motorcomm-uninitialized-variables-in.patch +++ b/target/linux/rockchip/patches-5.15/079-v6.3-net-phy-motorcomm-uninitialized-variables-in.patch @@ -18,7 +18,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/phy/motorcomm.c +++ b/drivers/net/phy/motorcomm.c -@@ -1533,10 +1533,10 @@ static int yt8531_config_init(struct phy_device *phydev) +@@ -1533,10 +1533,10 @@ static int yt8531_config_init(struct phy static void yt8531_link_change_notify(struct phy_device *phydev) { struct device_node *node = phydev->mdio.dev.of_node; diff --git a/target/linux/rockchip/patches-5.15/109-arm64-dts-rockchip-rk356x-Fix-PCIe-register-map.patch b/target/linux/rockchip/patches-5.15/109-arm64-dts-rockchip-rk356x-Fix-PCIe-register-map.patch index 079d6a952..3c6d01197 100644 --- a/target/linux/rockchip/patches-5.15/109-arm64-dts-rockchip-rk356x-Fix-PCIe-register-map.patch +++ b/target/linux/rockchip/patches-5.15/109-arm64-dts-rockchip-rk356x-Fix-PCIe-register-map.patch @@ -17,7 +17,7 @@ Signed-off-by: Andrew Powers-Holmes --- a/arch/arm64/boot/dts/rockchip/rk356x.dtsi +++ b/arch/arm64/boot/dts/rockchip/rk356x.dtsi -@@ -707,7 +707,7 @@ +@@ -708,7 +708,7 @@ compatible = "rockchip,rk3568-pcie"; reg = <0x3 0xc0000000 0x0 0x00400000>, <0x0 0xfe260000 0x0 0x00010000>, @@ -26,7 +26,7 @@ Signed-off-by: Andrew Powers-Holmes reg-names = "dbi", "apb", "config"; interrupts = , , -@@ -736,8 +736,9 @@ +@@ -738,8 +738,9 @@ phys = <&combphy2 PHY_TYPE_PCIE>; phy-names = "pcie-phy"; power-domains = <&power RK3568_PD_PIPE>; diff --git a/target/linux/rockchip/patches-5.15/110-arm64-rk3568-update-gicv3-its-and-pci-msi-map.patch b/target/linux/rockchip/patches-5.15/110-arm64-rk3568-update-gicv3-its-and-pci-msi-map.patch index 48dc44284..fdfb168a7 100644 --- a/target/linux/rockchip/patches-5.15/110-arm64-rk3568-update-gicv3-its-and-pci-msi-map.patch +++ b/target/linux/rockchip/patches-5.15/110-arm64-rk3568-update-gicv3-its-and-pci-msi-map.patch @@ -83,7 +83,7 @@ }; usb_host0_ehci: usb@fd800000 { -@@ -731,7 +738,7 @@ +@@ -733,7 +740,7 @@ num-ib-windows = <6>; num-ob-windows = <2>; max-link-speed = <2>;