Devicetree
 help / color / mirror / Atom feed
From: sashiko-bot@kernel.org
To: "Michal Wilczynski" <m.wilczynski@samsung.com>
Cc: devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org,
	robh@kernel.org, conor+dt@kernel.org
Subject: Re: [PATCH v8 17/18] riscv: dts: starfive: jh7110: Update DT for display subsystem
Date: Tue, 24 Nov 2026 16:12:38 +0000	[thread overview]
Message-ID: <sashiko-outbox-231537@kernel.org> (raw)
In-Reply-To: <20261124-jh7110-clean-send-v8-17-de92635dd857@samsung.com>

Thank you for your contribution! Sashiko AI review found 2 potential
issues to consider:
- [High] riscv: dts: starfive: CMA alloc-ranges in jh7110-common.dtsi
  breaks 1 GiB RAM
- [Low] riscv: dts: starfive: duplicate 24 MHz xin24m clock node in
  jh7110.dtsi
--

commit 7ebd6a4c9bd05a6b380264edfb6e56553f4653a0
Author: Michal Wilczynski <m.wilczynski@samsung.com>

riscv: dts: starfive: jh7110: Update DT for display subsystem

This commit adds the JH7110 video output display subsystem, DC8200 display
controller, HDMI subsystem, and default CMA pool nodes to the StarFive
JH7110 device trees.

> diff --git a/arch/riscv/boot/dts/starfive/jh7110-common.dtsi b/arch/riscv/boot/dts/starfive/jh7110-common.dtsi
> index 64de468f2c317..3eadb5732b011 100644
> --- a/arch/riscv/boot/dts/starfive/jh7110-common.dtsi
> +++ b/arch/riscv/boot/dts/starfive/jh7110-common.dtsi
> @@ -33,6 +33,27 @@ memory@40000000 {
>  		bootph-pre-ram;
>  	};
>  
> +	reserved-memory {
> +		#address-cells = <2>;
> +		#size-cells = <2>;
> +		ranges;
> +
> +		/*
> +		 * The display controller allocates its framebuffers from CMA,
> +		 * and the default pool is too small for them. Keep the pool
> +		 * inside the range the controller can address; it fits in the
> +		 * memory every VisionFive 2 variant has.
> +		 */
> +		linux,cma {
> +			compatible = "shared-dma-pool";
> +			reusable;
> +			size = <0x0 0x20000000>;
> +			alignment = <0x0 0x1000>;
> +			alloc-ranges = <0x0 0x70000000 0x0 0x20000000>;
> +			linux,cma-default;
> +		};
> +	};

[Severity: High]
Does pinning alloc-ranges to 0x70000000..0x90000000 break CMA reservation on
1 GiB JH7110 boards?

jh7110-common.dtsi is also included by boards that ship in 1 GiB RAM
configurations (such as Milk-V Mars and Mars CM), where DRAM starts at
0x40000000 and ends at 0x80000000.  With only 256 MiB of RAM falling inside
alloc-ranges, __reserved_mem_alloc_in_range() fails to reserve the 512 MiB
pool with -ENOMEM, leaving the system without its default CMA pool and
causing DC8200 framebuffer allocations to fail.

Even on boards with 2 GiB or more of RAM, matching the 512 MiB alloc-ranges
window to the exact 512 MiB pool size leaves no placement slack, so any
earlier memblock reservation (such as an initrd) overlapping
0x70000000..0x90000000 also causes the CMA reservation to fail.  Since
vs_dc_probe() sets DMA_BIT_MASK(32), can alloc-ranges cover the 32-bit
addressable DRAM window (for example <0x0 0x40000000 0x0 0xc0000000>) or a
smaller size that fits within 1 GiB configurations?

[ ... ]

> diff --git a/arch/riscv/boot/dts/starfive/jh7110.dtsi b/arch/riscv/boot/dts/starfive/jh7110.dtsi
> index 82ea63f715b0e..4c3ef68c16bb6 100644
> --- a/arch/riscv/boot/dts/starfive/jh7110.dtsi
> +++ b/arch/riscv/boot/dts/starfive/jh7110.dtsi
> @@ -352,6 +346,13 @@ tdm_ext: tdm-ext-clock {
>  		#clock-cells = <0>;
>  	};
>  
> +	xin24m: xin24m-clock {
> +		compatible = "fixed-clock";
> +		#clock-cells = <0>;
> +		clock-frequency = <24000000>;
> +		clock-output-names = "xin24m";
> +	};

[Severity: Low]
Does xin24m duplicate the existing osc: oscillator node in jh7110.dtsi?

The SoC 24 MHz reference crystal is already modelled as &osc (with its
24 MHz frequency set in jh7110-common.dtsi), and starfive_hdmi_phy_probe()
acquires its unnamed reference clock at index 0 and queries its parent name
dynamically via __clk_get_name(), so hdmi_phy can take clocks = <&osc>
directly without adding a second 24 MHz root clock.

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20261124-jh7110-clean-send-v8-0-de92635dd857@samsung.com?part=17

  reply	other threads:[~2026-11-24 16:12 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <CGME20261124155359eucas1p2f7d4e5137f38415561ce77fd55023466@eucas1p2.samsung.com>
2026-11-24 15:52 ` [PATCH v8 00/18] drm: starfive: jh7110: Enable display subsystem Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 01/18] drm/bridge: inno-hdmi: fix swapped HSYNC and VSYNC polarity Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 02/18] drm/bridge: inno-hdmi: Report hotplug through drm_bridge_hpd_notify() Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 03/18] dt-bindings: display: bridge: Add starfive,jh7110-inno-hdmi-controller Michal Wilczynski
2026-11-24 16:01     ` sashiko-bot
2026-11-24 15:52   ` [PATCH v8 04/18] dt-bindings: display: starfive: Add starfive,jh7110-hdmi-subsystem Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 05/18] dt-bindings: soc: starfive: Add starfive,jh7110-vout-syscon Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 06/18] dt-bindings: display: starfive: Add starfive,jh7110-vout-subsystem Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 07/18] drm/bridge: inno-hdmi: Split probe out of bind Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 08/18] drm/bridge: inno-hdmi: Use a regmap for register access Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 09/18] drm/bridge: inno-hdmi: Add .disable platform operation Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 10/18] drm/bridge: inno-hdmi: Add .mode_valid " Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 11/18] drm/bridge: inno-hdmi: Make the PHY configuration table optional Michal Wilczynski
2026-11-24 16:05     ` sashiko-bot
2026-11-24 15:52   ` [PATCH v8 12/18] drm/bridge: inno-hdmi: Make the register clock source selectable Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 13/18] drm/bridge: inno-hdmi: Make the supported HDMI version selectable Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 14/18] soc: starfive: Add jh7110-hdmi-subsystem driver Michal Wilczynski
2026-11-24 16:09     ` sashiko-bot
2026-11-24 15:52   ` [PATCH v8 15/18] soc: starfive: Add jh7110-vout-subsystem driver Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 16/18] drm/bridge: starfive: Add JH7110 HDMI controller driver Michal Wilczynski
2026-11-24 15:52   ` [PATCH v8 17/18] riscv: dts: starfive: jh7110: Update DT for display subsystem Michal Wilczynski
2026-11-24 16:12     ` sashiko-bot [this message]
2026-11-24 15:52   ` [PATCH v8 18/18] MAINTAINERS: Add StarFive JH7110 display subsystem entry Michal Wilczynski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=sashiko-outbox-231537@kernel.org \
    --to=sashiko-bot@kernel.org \
    --cc=conor+dt@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=m.wilczynski@samsung.com \
    --cc=robh@kernel.org \
    --cc=sashiko-reviews@lists.linux.dev \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox