Re: [PATCH 3/5] smbios: Use SMBIOS 3.0 to support an address above 4GB

2023-10-17 Thread Caleb Connolly
Hi Both, [...] >>> >>> @@ -513,13 +517,23 @@ ulong write_smbios_table(ulong addr) >>>*/ >>> table_addr = (ulong)map_sysmem(tables, 0); >>> if (sizeof(table_addr) > sizeof(u32) && table_addr > (ulong)UINT_MAX) >>> { >> >> You have to check the end address of the table not the s

Re: [PATCH 3/5] smbios: Use SMBIOS 3.0 to support an address above 4GB

2023-10-18 Thread Caleb Connolly
On 18/10/2023 04:33, Simon Glass wrote: > Hi Caleb, > > On Tue, 17 Oct 2023 at 11:59, Caleb Connolly > wrote: >> >> Hi Both, >> >> [...] >>>>> >>>>> @@ -513,13 +517,23 @@ ulong write_smbios_table(ulong addr) &g

Re: [PATCH] smbios: arm64: Allow table to be written at a fixed addr

2023-10-21 Thread Caleb Connolly
Hi Simon, On 21/10/2023 01:45, Simon Glass wrote: U-Boot typically sets up its malloc() pool near the top of memory. On ARM64 systems this can result in an SMBIOS table above 4GB which is not supported by SMBIOSv2. Work around this problem by providing a new option to choose an address just bel

Re: [PATCH] smbios: arm64: Allow table to be written at a fixed addr

2023-10-23 Thread Caleb Connolly
On 23/10/2023 08:04, Simon Glass wrote: > Hi Caleb, > > On Sat, 21 Oct 2023 at 01:43, Caleb Connolly > wrote: >> >> Hi Simon, >> >> On 21/10/2023 01:45, Simon Glass wrote: >>> U-Boot typically sets up its malloc() pool near the top of memory. On &

[PATCH] arm: init: add an option to use FDT from previous bootloader

2023-10-24 Thread Caleb Connolly
instead determine it dynamically at runtime. Signed-off-by: Caleb Connolly --- This patch will improve generic support for Qualcomm boards by enabling us to configure the memory map at runtime rather than having hardcoded maps on a per-device basis. I've gone for this approach initially to tr

[PATCH v2] arm: init: add an option to use FDT from previous bootloader

2023-10-24 Thread Caleb Connolly
instead determine it dynamically at runtime. Signed-off-by: Caleb Connolly --- This patch will improve generic support for Qualcomm boards by enabling us to configure the memory map at runtime rather than having hardcoded maps on a per-device basis. I've gone for this approach initially to tr

Re: [PATCH] arm: init: add an option to use FDT from previous bootloader

2023-10-24 Thread Caleb Connolly
On 24/10/2023 19:03, Simon Glass wrote: > Hi Caleb, > > On Tue, 24 Oct 2023 at 04:32, Caleb Connolly > wrote: >> >> Add a new config option to allow u-boot to reuse the FDT provided by the > > U-Boot (please fix throughout) Will do! > >> previous st

Re: [PATCH] arm: init: add an option to use FDT from previous bootloader

2023-10-24 Thread Caleb Connolly
On 24/10/2023 20:25, Tom Rini wrote: > On Tue, Oct 24, 2023 at 12:32:35PM +0100, Caleb Connolly wrote: > >> Add a new config option to allow u-boot to reuse the FDT provided by the >> previous stage bootloader when available. >> >> On some boards the previous

[PATCH 0/8] arm: mach-snapdragon: Qualcomm clock driver cleanup

2023-10-24 Thread Caleb Connolly
to resend this initial support pending acceptance of this series and several other cleanups. [1]: https://lore.kernel.org/u-boot/20230324080418.3856409-1-bhupesh.sha...@linaro.org/ --- Caleb Connolly (7): clk/qcom: move from mach-snapdragon clk/qcom: add per-platform configs

[PATCH 1/8] clk/qcom: move from mach-snapdragon

2023-10-24 Thread Caleb Connolly
Clock drivers don't belong here, move them to the right place and declutter mach-snapdragon a bit. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/Makefile| 5 - drivers/clk/Makefile | 1 + driver

[PATCH 3/8] clk/qcom: move ipq4019 driver from mach-ipq40xx

2023-10-24 Thread Caleb Connolly
This driver is just a stub, but it's necessary to support the upcoming reset driver changes. Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-ipq40xx/Makefile | 1 - drivers/clk/qcom/Kc

[PATCH 2/8] clk/qcom: add per-platform configs

2023-10-24 Thread Caleb Connolly
Decouple the clock drivers from the mach-snapdragon TARGET configs by introducing CONFIG_CLK_QCOM and associated options to build each SoC. This will make future cleanup easier as we move towards a generic Qualcomm target. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/Kconfig | 4

[PATCH 4/8] clk/qcom: handle resets and clocks in one device

2023-10-24 Thread Caleb Connolly
m' and drop unused compatibles. Heavily inspired by Renesas code for a similar hw block. Signed-off-by: Konrad Dybcio [caleb: moved drivers to clk/qcom, added reset driver and adjusted bind logic] Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/dts/qcom

[PATCH 5/8] clk/qcom: sdm845: add register map for simple gate clocks

2023-10-24 Thread Caleb Connolly
Many gate clocks can be enabled with a single register write, add support for defining these simple gate clocks and add the ones found on SDM845. While we're here, inline clk_init_uart() into msm_set_rate(). Signed-off-by: Caleb Connolly --- .../mach-snapdragon/include/mach/sysmap-sdm

[PATCH 7/8] clk/qcom: add mnd_width to clk_rcg_set_rate_mnd()

2023-10-24 Thread Caleb Connolly
This property is needed on some platforms to ensure that only the relevant bits are set in the M/N/D registers. Signed-off-by: Caleb Connolly --- drivers/clk/qcom/clock-apq8016.c | 4 ++-- drivers/clk/qcom/clock-apq8096.c | 4 ++-- drivers/clk/qcom/clock-qcom.c| 11 +++ drivers

[PATCH 6/8] clk/qcom: use function pointers for enable and set_rate

2023-10-24 Thread Caleb Connolly
mon.h to include the board specific sysmap header, include those explicitly to further reduce the dependency between the clock driver and a particular target configuration. Signed-off-by: Caleb Connolly --- drivers/clk/qcom/clock-apq8016.c | 12 ++-- drivers/clk/qcom/clock-apq8096.c

[PATCH 8/8] clk/qcom: fix rcg divider value

2023-10-24 Thread Caleb Connolly
: Caleb Connolly --- drivers/clk/qcom/clock-apq8016.c | 2 +- drivers/clk/qcom/clock-apq8096.c | 2 +- drivers/clk/qcom/clock-qcom.c| 40 drivers/clk/qcom/clock-qcom.h| 11 +++ drivers/clk/qcom/clock-qcs404.c | 16 drivers/clk

Re: [PATCH 0/8] arm: mach-snapdragon: Qualcomm clock driver cleanup

2023-10-25 Thread Caleb Connolly
Hi Sumit, On 25/10/2023 13:10, Sumit Garg wrote: > Hi Caleb, > > On Wed, 25 Oct 2023 at 01:54, Caleb Connolly > wrote: >> >> This series begins making some headway towards cleaning up Qualcomm >> platform support in u-boot. The following is a rough overview of th

Re: [PATCH 8/8] clk/qcom: fix rcg divider value

2023-10-25 Thread Caleb Connolly
On 24/10/2023 21:23, Caleb Connolly wrote: > The RCG divider field takes a value of (2*h - 1) where h is the divisor. > This allows fractional dividers to be supported by calculating them at > compile time using a macro. > > However, the clk_rcg_set_rate_mnd() function was also

Re: [PATCH 8/8] clk/qcom: fix rcg divider value

2023-10-27 Thread Caleb Connolly
On 27/10/2023 13:18, Sumit Garg wrote: > On Wed, 25 Oct 2023 at 19:14, Caleb Connolly > wrote: >> >> >> >> On 24/10/2023 21:23, Caleb Connolly wrote: >>> The RCG divider field takes a value of (2*h - 1) where h is the divisor. >>> This allows fr

Re: [PATCH 3/8] clk/qcom: move ipq4019 driver from mach-ipq40xx

2023-10-27 Thread Caleb Connolly
[...] >> diff --git a/arch/arm/mach-ipq40xx/clock-ipq4019.c >> b/drivers/clk/qcom/clock-ipq4019.c >> similarity index 56% >> rename from arch/arm/mach-ipq40xx/clock-ipq4019.c >> rename to drivers/clk/qcom/clock-ipq4019.c >> index c1d5c4ecdd81..04c99964df15 100644 >> --- a/arch/arm/mach-ipq40xx/c

Re: [PATCH 3/8] clk/qcom: move ipq4019 driver from mach-ipq40xx

2023-10-27 Thread Caleb Connolly
On 27/10/2023 14:03, Sumit Garg wrote: > On Fri, 27 Oct 2023 at 18:27, Caleb Connolly > wrote: >> >> >> [...] >>>> diff --git a/arch/arm/mach-ipq40xx/clock-ipq4019.c >>>> b/drivers/clk/qcom/clock-ipq4019.c >>>> similarity inde

[PATCH v2 2/7] clk/qcom: move ipq4019 driver from mach-ipq40xx

2023-10-30 Thread Caleb Connolly
This driver is just a stub, but it's necessary to support the upcoming reset driver changes. Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-ipq40xx/Makefile | 1 - drivers/clk/qcom/Kc

[PATCH v2 0/7] arm: mach-snapdragon: Qualcomm clock driver cleanup

2023-10-30 Thread Caleb Connolly
y add relevant gate_clks for sdm845 * Link to v1: https://lore.kernel.org/r/20231024-b4-qcom-clk-v1-0-9d96359b9...@linaro.org --- Caleb Connolly (6): clk/qcom: move from mach-snapdragon clk/qcom: move ipq4019 driver from mach-ipq40xx clk/qcom: sdm845: add register map for sim

[PATCH v2 1/7] clk/qcom: move from mach-snapdragon

2023-10-30 Thread Caleb Connolly
default for the respective targets. This will make future work easier as we move towards a generic Qualcomm target. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/Kconfig | 4 ++ arch/arm/mach-snapdragon/Makefile | 5 --- driv

[PATCH v2 4/7] clk/qcom: sdm845: add register map for simple gate clocks

2023-10-30 Thread Caleb Connolly
Many gate clocks can be enabled with a single register write, add support for defining these simple gate clocks and add the ones found on SDM845. While we're here, inline clk_init_uart() into msm_set_rate(). Signed-off-by: Caleb Connolly --- .../mach-snapdragon/include/mach/sysmap-sdm

[PATCH v2 3/7] clk/qcom: handle resets and clocks in one device

2023-10-30 Thread Caleb Connolly
rs to clk/qcom, added reset driver and adjusted bind logic. Imported qcom,gcc-ipq4019.h from Linux] Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/dts/qcom-ipq4019.dtsi | 14 +- arch/arm/dts/qcs404-ev

[PATCH v2 5/7] clk/qcom: use function pointers for enable and set_rate

2023-10-30 Thread Caleb Connolly
e are also inlined. Signed-off-by: Caleb Connolly --- .../mach-snapdragon/include/mach/sysmap-apq8016.h | 39 -- .../mach-snapdragon/include/mach/sysmap-apq8096.h | 37 - .../mach-snapdragon/include/mach/sysmap-qcs404.h | 88 -- .../mach-snapdragon/include

[PATCH v2 6/7] clk/qcom: add mnd_width to clk_rcg_set_rate_mnd()

2023-10-30 Thread Caleb Connolly
This property is needed on some platforms to ensure that only the relevant bits are set in the M/N/D registers. Signed-off-by: Caleb Connolly Reviewed-by: Sumit Garg --- drivers/clk/qcom/clock-apq8016.c | 4 ++-- drivers/clk/qcom/clock-apq8096.c | 4 ++-- drivers/clk/qcom/clock-qcom.c

[PATCH v2 7/7] clk/qcom: fix rcg divider value

2023-10-30 Thread Caleb Connolly
: Caleb Connolly --- drivers/clk/qcom/clock-apq8016.c | 2 +- drivers/clk/qcom/clock-apq8096.c | 2 +- drivers/clk/qcom/clock-qcom.c| 66 +--- drivers/clk/qcom/clock-qcom.h| 11 +++ drivers/clk/qcom/clock-qcs404.c | 16 +- drivers/clk/qcom/clock

[PATCH 0/6] arm: mach-snapdragon: Qualcomm pinctrl driver cleanup

2023-10-31 Thread Caleb Connolly
series loosely depends on the associated clock driver cleanup which can be found here (Makefile and perhaps DTS conflicts): https://lore.kernel.org/u-boot/20231024-b4-qcom-clk-v1-0-9d96359b9...@linaro.org/ --- Caleb Connolly (6): pinctrl: qcom: move out of mach-snapdragon pinctrl: qcom:

[PATCH 2/6] pinctrl: qcom: make compatible with linux DTs

2023-10-31 Thread Caleb Connolly
Adjust the GPIO driver to handle these too, and finally enable support for all pins with the same numbering as used in Linux. Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard845c-uboot.dtsi | 2 +- arch/arm/dts/sdm845.dtsi| 16 +++- arch/arm/dts/starqltechn-uboo

[PATCH 1/6] pinctrl: qcom: move out of mach-snapdragon

2023-10-31 Thread Caleb Connolly
Move the Qualcomm pinctrl drivers out of mach-snapdragon and over to the rest of the pinctrl drivers, adjust the drivers so that support for each platform can be enabled/disabled individually and introduce platform specific configuration options. Signed-off-by: Caleb Connolly --- arch/arm/mach

[PATCH 3/6] pinctrl: qcom: handle reserved ranges

2023-10-31 Thread Caleb Connolly
ry to interact with these pins. Signed-off-by: Caleb Connolly --- drivers/gpio/msm_gpio.c | 15 + drivers/pinctrl/qcom/pinctrl-qcom.c | 64 + include/qcom-gpio.h | 15 + 3 files changed, 94 insertions(+) diff --git a/dr

[PATCH 4/6] msm_qcom: use unsigned int

2023-10-31 Thread Caleb Connolly
Replaces the uses of "unsigned" with "unsigned int". Signed-off-by: Caleb Connolly --- drivers/gpio/msm_gpio.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/msm_gpio.c b/drivers/gpio/msm_gpio.c index 7a09abdafb2e..7d01fecf46f2 10064

[PATCH 5/6] pinctrl: qcom: move ipq4019 driver from mach-ipq40xx

2023-10-31 Thread Caleb Connolly
Drop the duplicated pinctrl-snapdragon driver from mach-ipq40xx and add it to drivers/pinctrl/qcom. Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-ipq40xx/Makefile | 8 - arch/arm/mach-ipq40xx/pinctrl

[PATCH 6/6] pinctrl: qcom: rename msm -> qcom

2023-10-31 Thread Caleb Connolly
The "MSM" naming hasn't been correct for quite a while now, in line with Linux lets rename all these msm_* functions to qcom_* as well as ensure namespacing is consistent across the pinctrl and GPIO drivers. Signed-off-by: Caleb Connolly --- configs/dragonboard410c_defcon

[PATCH] MAINTAINERS: update Qualcomm maintainer

2023-10-31 Thread Caleb Connolly
As Ramon has been inactive for some time now, add myself and Neil Armstrong to maintain Qualcomm efforts going forwards. Signed-off-by: Caleb Connolly --- I greatly appreciate the work done by Ramon Fried in keeping Qualcomm support alive in U-Boot the last few years. However it's clear th

Re: [PATCH] MAINTAINERS: update Qualcomm maintainer

2023-11-03 Thread Caleb Connolly
On 02/11/2023 11:49, Sumit Garg wrote: > On Tue, 31 Oct 2023 at 20:49, Caleb Connolly > wrote: >> >> As Ramon has been inactive for some time now, add myself and Neil >> Armstrong to maintain Qualcomm efforts going forwards. >> >> Signed-off-by: Caleb Conn

Please pull qcom-next-20231103

2023-11-03 Thread Caleb Connolly
1-03 13:17:50 +0000) Caleb Connolly (1): MAINTAINERS: update Qualcomm maintainer MAINTAINERS | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) Thanks, -- // Caleb (they/them)

Re: [PATCH v2 7/7] clk/qcom: fix rcg divider value

2023-11-03 Thread Caleb Connolly
On 02/11/2023 08:24, Sumit Garg wrote: > On Tue, 31 Oct 2023 at 03:54, Caleb Connolly > wrote: >> >> The RCG divider field takes a value of (2*h - 1) where h is the divisor. >> This allows fractional dividers to be supported by calculating them at >> compile tim

[PATCH v3 0/7] arm: mach-snapdragon: Qualcomm clock driver cleanup

2023-11-03 Thread Caleb Connolly
om-clk-v1-0-9d96359b9...@linaro.org [1]: https://source.denx.de/u-boot/custodians/u-boot-snapdragon --- Caleb Connolly (6): clk/qcom: move from mach-snapdragon clk/qcom: move ipq4019 driver from mach-ipq40xx clk/qcom: sdm845: add register map for simple gate clocks clk/qco

[PATCH v3 1/7] clk/qcom: move from mach-snapdragon

2023-11-03 Thread Caleb Connolly
default for the respective targets. This will make future work easier as we move towards a generic Qualcomm target. Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- MAINTAINERS| 1 + arch/arm/mach-snapdragon/Kconfig | 4 ++ arch/arm/

[PATCH v3 2/7] clk/qcom: move ipq4019 driver from mach-ipq40xx

2023-11-03 Thread Caleb Connolly
This driver is just a stub, but it's necessary to support the upcoming reset driver changes. Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-ipq40xx/Makefile | 1 - drivers/clk/qcom/Kc

[PATCH v3 4/7] clk/qcom: sdm845: add register map for simple gate clocks

2023-11-03 Thread Caleb Connolly
Many gate clocks can be enabled with a single register write, add support for defining these simple gate clocks and add the ones found on SDM845. While we're here, inline clk_init_uart() into msm_set_rate(). Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- drivers/clk/qcom/

[PATCH v3 5/7] clk/qcom: use function pointers for enable and set_rate

2023-11-03 Thread Caleb Connolly
e are also inlined. Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- .../mach-snapdragon/include/mach/sysmap-apq8016.h | 39 -- .../mach-snapdragon/include/mach/sysmap-apq8096.h | 37 - .../mach-snapdragon/include/mach/sysmap-qcs404.h | 88 -- ...

[PATCH v3 3/7] clk/qcom: handle resets and clocks in one device

2023-11-03 Thread Caleb Connolly
river and adjusted bind logic. Imported qcom,gcc-ipq4019.h from Linux] Signed-off-by: Konrad Dybcio Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/dts/qcom-ipq4019.dtsi | 14 +- arch/arm/dts/q

[PATCH v3 6/7] clk/qcom: add mnd_width to clk_rcg_set_rate_mnd()

2023-11-03 Thread Caleb Connolly
This property is needed on some platforms to ensure that only the relevant bits are set in the M/N/D registers. Signed-off-by: Caleb Connolly Reviewed-by: Sumit Garg --- drivers/clk/qcom/clock-apq8016.c | 4 ++-- drivers/clk/qcom/clock-apq8096.c | 4 ++-- drivers/clk/qcom/clock-qcom.c

[PATCH v3 7/7] clk/qcom: fix rcg divider value

2023-11-03 Thread Caleb Connolly
: Caleb Connolly --- drivers/clk/qcom/clock-apq8016.c | 2 +- drivers/clk/qcom/clock-apq8096.c | 2 +- drivers/clk/qcom/clock-qcom.c| 64 +--- drivers/clk/qcom/clock-qcom.h| 11 +++ drivers/clk/qcom/clock-qcs404.c | 16 +- drivers/clk/qcom/clock

Re: [PATCH v3 6/7] clk/qcom: add mnd_width to clk_rcg_set_rate_mnd()

2023-11-06 Thread Caleb Connolly
On 06/11/2023 07:06, Sumit Garg wrote: > On Fri, 3 Nov 2023 at 21:09, Caleb Connolly wrote: >> >> This property is needed on some platforms to ensure that only the >> relevant bits are set in the M/N/D registers. > > This commit broke qcs404 platform which is fixed

[PATCH v2 0/5] arm: mach-snapdragon: Qualcomm pinctrl driver cleanup

2023-11-06 Thread Caleb Connolly
-qcom-pinctrl-v1-0-9123d6a21...@linaro.org --- Caleb Connolly (5): pinctrl: qcom: move out of mach-snapdragon pinctrl: qcom: move ipq4019 driver from mach-ipq40xx pinctrl: qcom: make compatible with linux DTs msm_gpio: use unsigned int fixup! pinctrl: qcom: ma

[PATCH v2 2/5] pinctrl: qcom: move ipq4019 driver from mach-ipq40xx

2023-11-06 Thread Caleb Connolly
Drop the duplicated pinctrl-snapdragon driver from mach-ipq40xx and add it to drivers/pinctrl/qcom. Acked-by: Sumit Garg Signed-off-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-ipq40xx/Makefile | 8 - arch/arm/mach

[PATCH v2 1/5] pinctrl: qcom: move out of mach-snapdragon

2023-11-06 Thread Caleb Connolly
Move the Qualcomm pinctrl drivers out of mach-snapdragon and over to the rest of the pinctrl drivers, adjust the drivers so that support for each platform can be enabled/disabled individually and introduce platform specific configuration options. Reviewed-by: Sumit Garg Signed-off-by: Caleb

[PATCH v2 3/5] pinctrl: qcom: make compatible with linux DTs

2023-11-06 Thread Caleb Connolly
Adjust the GPIO driver to handle these too, and finally enable support for all pins with the same numbering as used in Linux. Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard845c-uboot.dtsi | 2 +- arch/arm/dts/sdm845.dtsi | 16 ++ arch/arm/dts/starqlt

[PATCH v2 5/5] fixup! pinctrl: qcom: make compatible with linux DTs

2023-11-06 Thread Caleb Connolly
--- drivers/gpio/msm_gpio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpio/msm_gpio.c b/drivers/gpio/msm_gpio.c index 3e4a0194b10a..80cd28bb231f 100644 --- a/drivers/gpio/msm_gpio.c +++ b/drivers/gpio/msm_gpio.c @@ -11,7 +11,7 @@ #include #include #include -

[PATCH v2 4/5] msm_gpio: use unsigned int

2023-11-06 Thread Caleb Connolly
Replaces the uses of "unsigned" with "unsigned int". Reviewed-by: Sumit Garg Signed-off-by: Caleb Connolly --- drivers/gpio/msm_gpio.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/msm_gpio.c b/drivers/gpio/msm_gpio.c index 7d

Re: [PATCH 0/2] serial: msm-geni: rework oversampling and fix clk API bug

2023-12-04 Thread Caleb Connolly
On Tue, 14 Nov 2023 12:51:10 +, Caleb Connolly wrote: > These patches improve GENI UART support during init by implementing the > parent property read directly rather than via a misc device, and fixing > the error path when the clock can't be found. > > In my testing, th

Re: [PATCH 00/21] Qualcomm generic board support

2023-12-05 Thread Caleb Connolly
On 05/12/2023 07:44, Sumit Garg wrote: > Hi Simon, > > On Tue, 5 Dec 2023 at 06:22, Simon Glass wrote: >> >> Hi Sumit, >> >> On Tue, 21 Nov 2023 at 23:21, Sumit Garg wrote: >>> >>> Hi Caleb, >>> >>> On Tue, 21 No

[PATCH v6 0/9] Qualcomm PMIC fixes

2023-12-05 Thread Caleb Connolly
; properties for buttons * Add missing sdm845 DTS parts * Put button driver in drivers/button * Link to v1: https://lore.kernel.org/r/20231106-b4-qcom-dt-compat-v1-0-0ccbb7841...@linaro.org --- Caleb Connolly (9): gpio: qcom_pmic: fix silent dev_read_addr downcast button: qcom-pmi

[PATCH v6 1/9] gpio: qcom_pmic: fix silent dev_read_addr downcast

2023-12-05 Thread Caleb Connolly
-by: Caleb Connolly --- drivers/gpio/qcom_pmic_gpio.c | 14 ++ 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/gpio/qcom_pmic_gpio.c b/drivers/gpio/qcom_pmic_gpio.c index 65feb453ebc3..e5841f502953 100644 --- a/drivers/gpio/qcom_pmic_gpio.c +++ b/drivers/g

[PATCH v6 2/9] button: qcom-pmic: introduce Qualcomm PMIC button driver

2023-12-05 Thread Caleb Connolly
d-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off-by: Caleb Connolly --- MAINTAINERS | 1 + drivers/button/Kconfig| 9 +++ drivers/button/Makefile | 1 + drivers/button/button-qcom-pmic.c | 165 +++

[PATCH v6 3/9] mach-snapdragon: switch to PMIC button driver

2023-12-05 Thread Caleb Connolly
Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard410c-uboot.dtsi | 11 -- arch/arm/dts/dragonboard410c.dts | 22 +--- arch/arm/dts/dragonboard820c-uboot.dtsi | 12 --- arch/arm/dts/dragonboard820c.dts | 23

[PATCH v6 4/9] gpio: qcom_pmic: drop pon GPIO driver

2023-12-05 Thread Caleb Connolly
Remove the (now unused) GPIO driver for the power and resin buttons on the PMIC. Reviewed-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off-by: Caleb Connolly --- drivers/gpio/Kconfig | 5 +- drivers/gpio/qcom_pmic_gpio.c | 104

[PATCH v6 5/9] gpio: qcom_pmic: support upstream DT

2023-12-05 Thread Caleb Connolly
Garg Signed-off-by: Caleb Connolly --- drivers/gpio/qcom_pmic_gpio.c | 31 --- 1 file changed, 28 insertions(+), 3 deletions(-) diff --git a/drivers/gpio/qcom_pmic_gpio.c b/drivers/gpio/qcom_pmic_gpio.c index 7b83c67fa464..5221bd27825e 100644 --- a/drivers

[PATCH v6 6/9] dts: qcom: adjust pmic gpio to use upstream bindings

2023-12-05 Thread Caleb Connolly
Use the upstream gpio-ranges property instead of gpio-count, and drop the bank-name property for Qualcomm boards. Reviewed-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard410c.dts | 3 +-- arch/arm/dts

[PATCH v6 7/9] gpio: qcom_pmic: drop gpio-count property

2023-12-05 Thread Caleb Connolly
This property is not part of the dt bindings and all boards use the new gpio-ranges property instead. Drop support for this. Reviewed-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off-by: Caleb Connolly --- doc/device-tree-bindings/gpio/pm8916_gpio.txt | 48

[PATCH v6 8/9] spmi: msm: fix register range names

2023-12-05 Thread Caleb Connolly
The core and chnl register ranges were swapped on SDM845. Fix it, and fetch the register ranges by name instead of by index. Drop the cosmetic "version" variable and clean up the debug logging. Reviewed-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off

[PATCH v6 9/9] pmic: qcom: dont use dev_read_addr to get USID

2023-12-05 Thread Caleb Connolly
er doesn't have support for GSID handling, so just ignore the second value for now. Reviewed-by: Neil Armstrong Reviewed-by: Sumit Garg Tested-by: Sumit Garg Signed-off-by: Caleb Connolly --- doc/device-tree-bindings/pmic/qcom,spmi-pmic.txt | 94 drivers/power/p

Re: [PATCH v6 6/9] dts: qcom: adjust pmic gpio to use upstream bindings

2023-12-06 Thread Caleb Connolly
Hi Simon, On 06/12/2023 03:54, Simon Glass wrote: > Hi Caleb, > > On Tue, 5 Dec 2023 at 06:48, Caleb Connolly wrote: >> >> Use the upstream gpio-ranges property instead of gpio-count, and drop >> the bank-name property for Qualcomm boards. >> >> Revi

Re: [PATCH 00/21] Qualcomm generic board support

2023-12-06 Thread Caleb Connolly
ed, Nov 22, 2023 at 11:51:29AM +0530, Sumit Garg wrote: >>>>> Hi Caleb, >>>>> >>>>> On Tue, 21 Nov 2023 at 22:39, Caleb Connolly >>>>> wrote: >>>> [snip] >>>>>> == DT loading == >>>>>> >&g

Re: [PATCH 00/21] Qualcomm generic board support

2023-12-06 Thread Caleb Connolly
Hi Simon, - gzip u-boot:: gzip u-boot-nodtb.bin - Append dtb to gzipped u-boot:: cat u-boot-nodtb.bin.gz /arch/arm64/boot/dts/qcom/your-board.dtb > u-boot-nodtb.bin.gz-dtb >>> >>> What is this?? Who or what uses a gzipped image with a sin

Re: [PATCH 18/21] dts: msm8916: import DT from Linux

2023-12-07 Thread Caleb Connolly
On 21/11/2023 19:21, Stephan Gerhold wrote: > On Tue, Nov 21, 2023 at 05:09:41PM +0000, Caleb Connolly wrote: >> Import the msm8916 devicetree from Linux and adjust the dragonboard410c >> devicetree to use it. >> > > Can you add a note here from which Linux versi

[PATCH 0/3] Qualcomm quirky SMMU support

2023-12-11 Thread Caleb Connolly
it is required for upcoming USB support on SDM845 and future Qualcomm platforms. --- Caleb Connolly (3): iommu: fix compilation when CONFIG_PCI disabled iommu: add a connect op iommu: add qcom-hyp-smmu drivers/iommu/Kconfig | 16 ++ drivers/iommu/Makefile| 1

[PATCH 1/3] iommu: fix compilation when CONFIG_PCI disabled

2023-12-11 Thread Caleb Connolly
The dev_pci_iommu_enable() function is only available when CONFIG_PCI is enabled, replace the runtime check with a preprocessor one to fix compilation with pci disabled. Signed-off-by: Caleb Connolly --- drivers/iommu/iommu-uclass.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions

[PATCH 2/3] iommu: add a connect op

2023-12-11 Thread Caleb Connolly
Add an optional iommu callback to be invoked before a device probes. This can be used to configure the IOMMU in preparation for the device (e.g. by allocating a context bank) Signed-off-by: Caleb Connolly --- drivers/iommu/iommu-uclass.c | 11 +++ include/iommu.h | 9

[PATCH 3/3] iommu: add qcom-hyp-smmu

2023-12-11 Thread Caleb Connolly
m ids that aren't already configured. This driver is necessary to support peripherals that perform DMA which weren't configured by the previous stage bootloader (for example USB). It works by allocating a context bank using identity mapping (as U-Boot doesn't use virtual addresses).

Re: [PATCH 1/3] iommu: fix compilation when CONFIG_PCI disabled

2023-12-11 Thread Caleb Connolly
On 11/12/2023 19:17, Tom Rini wrote: > On Mon, Dec 11, 2023 at 08:08:32PM +0100, Dragan Simic wrote: >> On 2023-12-11 19:41, Caleb Connolly wrote: >>> The dev_pci_iommu_enable() function is only available when CONFIG_PCI is >>> enabled, replace the runtime check wit

Re: [PATCH v6 6/9] dts: qcom: adjust pmic gpio to use upstream bindings

2023-12-18 Thread Caleb Connolly
On 06/12/2023 11:39, Caleb Connolly wrote: > Hi Simon, > > On 06/12/2023 03:54, Simon Glass wrote: >> Hi Caleb, >> >> On Tue, 5 Dec 2023 at 06:48, Caleb Connolly >> wrote: >>> >>> Use the upstream gpio-ranges property instead of gpio-coun

[PATCH v2 01/32] arm: init: export prev_bl_fdt_addr

2023-12-19 Thread Caleb Connolly
the FDT addr so that boards can use it over the built-in FDT. Don't check is_addr_accessible() here because we might not yet have a valid mem_map if it's going to be populated from the FDT, let the board do their own validation instead. Reviewed-by: Tom Rini Signed-off-by: Cale

[PATCH v2 00/32] Qualcomm generic board support

2023-12-19 Thread Caleb Connolly
To: Neil Armstrong To: Sumit Garg To: Ramon Fried Cc: Marek Vasut To: Dzmitry Sankouski To: Caleb Connolly To: Peng Fan To: Jaehoon Chung To: Rayagonda Kokatanur To: Lukasz Majewski To: Sean Anderson To: Jorge Ramirez-Ortiz To: Stephan Gerhold Cc: --- Caleb Connolly (32): arm

[PATCH v2 03/32] mmc: msm_sdhci: use modern clock handling

2023-12-19 Thread Caleb Connolly
Use the clk_* helper functions and the correct property name for clocks. Signed-off-by: Caleb Connolly --- drivers/mmc/msm_sdhci.c | 69 - 1 file changed, 46 insertions(+), 23 deletions(-) diff --git a/drivers/mmc/msm_sdhci.c b/drivers/mmc

[PATCH v2 02/32] usb: dwc3-generic: support external vbus regulator

2023-12-19 Thread Caleb Connolly
Add support for a vbus-supply regulator specified in devicetree. This provides generic support to avoid hardcoded GPIO configuration in board init code. Signed-off-by: Caleb Connolly --- This patch has no dependencies Cc: Marek Vasut --- drivers/usb/dwc3/dwc3-generic.c | 12 1

[PATCH v2 04/32] dt-bindings: drop msm_sdhci binding

2023-12-19 Thread Caleb Connolly
The upstream DT is supported here, so drop the U-Boot specific binding docs. Signed-off-by: Caleb Connolly --- doc/device-tree-bindings/mmc/msm_sdhci.txt | 25 - 1 file changed, 25 deletions(-) diff --git a/doc/device-tree-bindings/mmc/msm_sdhci.txt b/doc/device-tree

[PATCH v2 05/32] clk/qcom: use upstream compatible properties

2023-12-19 Thread Caleb Connolly
Adjust the apq8016 and apq8096 drivers to use the upstream compatible properties, and adjust the associated dts files in U-Boot. Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard410c.dts | 2 +- drivers/clk/qcom/clock-apq8016.c | 2 +- drivers/clk/qcom/clock-apq8096.c | 2 +- 3 files

[PATCH v2 06/32] serial: msm: add debug UART

2023-12-19 Thread Caleb Connolly
Introduce support for early debugging. Signed-off-by: Caleb Connolly --- drivers/serial/Kconfig | 8 drivers/serial/serial_msm.c | 32 2 files changed, 40 insertions(+) diff --git a/drivers/serial/Kconfig b/drivers/serial/Kconfig index

[PATCH v2 07/32] serial: msm: fix clock handling

2023-12-19 Thread Caleb Connolly
Use the modern helpers to fetch the clock and use the correct property ("clocks" instead of "clock") Signed-off-by: Caleb Connolly --- arch/arm/dts/dragonboard410c.dts | 3 ++- arch/arm/dts/dragonboard820c.dts | 3 ++- drivers/serial/serial_msm.c | 24 +

[PATCH v2 08/32] gpio: qcom_pmic: 1-based GPIOs

2023-12-19 Thread Caleb Connolly
Qualcomm PMICs number their GPIOs starting from 1, implement a custom .xlate method to handle this. Signed-off-by: Caleb Connolly --- drivers/gpio/qcom_pmic_gpio.c | 22 ++ 1 file changed, 22 insertions(+) diff --git a/drivers/gpio/qcom_pmic_gpio.c b/drivers/gpio

[PATCH v2 09/32] gpio: qcom_pmic: add a quirk to skip GPIO configuration

2023-12-19 Thread Caleb Connolly
). Signed-off-by: Caleb Connolly --- drivers/gpio/qcom_pmic_gpio.c | 18 -- 1 file changed, 16 insertions(+), 2 deletions(-) diff --git a/drivers/gpio/qcom_pmic_gpio.c b/drivers/gpio/qcom_pmic_gpio.c index 2a4fef8d28cb..198cd84bc31e 100644 --- a/drivers/gpio/qcom_pmic_gpio.c +++ b

[PATCH v2 10/32] gpio: qcom_pmic: add pinctrl driver

2023-12-19 Thread Caleb Connolly
r now. Signed-off-by: Caleb Connolly --- drivers/gpio/qcom_pmic_gpio.c | 204 -- 1 file changed, 177 insertions(+), 27 deletions(-) diff --git a/drivers/gpio/qcom_pmic_gpio.c b/drivers/gpio/qcom_pmic_gpio.c index 198cd84bc31e..647b5dc1e6f6 100644 --- a/drivers

[PATCH v2 11/32] board: dragonboard410c: add chainloaded config fragment

2023-12-19 Thread Caleb Connolly
Add a config fragment for building U-Boot such that it can be chainloaded by aboot/LK rather than being flashed directly to the aboot partition. Signed-off-by: Caleb Connolly --- board/qualcomm/dragonboard410c/configs/chainloaded.config | 7 +++ 1 file changed, 7 insertions(+) diff --git a

[PATCH v2 14/32] board: dragonboard820c: use LINUX_KERNEL_IMAGE_HEADER

2023-12-19 Thread Caleb Connolly
db820c predated support for prepending the kernel image header automatically, drop it's custom linker script and head.S in favour of this generic support. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/Kconfig | 1 + board/qualcomm/dragonboard820c/Makefile

[PATCH v2 12/32] board: dragonboard410c: upstream DT compat

2023-12-19 Thread Caleb Connolly
ned-off-by: Caleb Connolly --- arch/arm/dts/dragonboard410c.dts | 25 +++- board/qualcomm/dragonboard410c/dragonboard410c.c | 93 +++- doc/device-tree-bindings/usb/ehci-msm.txt| 10 -- drivers/clk/qcom/clock-apq8016.c | 7 +- drivers/phy/qcom/ms

[PATCH v2 13/32] board: dragonboard410c: import board code from mach-snapdragon

2023-12-19 Thread Caleb Connolly
. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/Makefile | 2 - arch/arm/mach-snapdragon/include/mach/dram.h | 12 - arch/arm/mach-snapdragon/misc.c| 55 -- board/qualcomm/dragonboard410c/Makefile| 3 +- board

[PATCH v2 16/32] mach-snapdragon: dynamic load addresses

2023-12-19 Thread Caleb Connolly
ff-by: Caleb Connolly --- arch/arm/Kconfig | 1 + arch/arm/mach-snapdragon/board.c | 35 board/qualcomm/dragonboard410c/dragonboard410c.c | 2 +- 3 files changed, 37 insertions(+), 1 deletion(-) diff --git a/arch/arm/Kcon

[PATCH v2 15/32] mach-snapdragon: generalise board support

2023-12-19 Thread Caleb Connolly
onfig files for the Dragonboard 845c, Galaxy S9, and QCS404 EVB. For now the db410c and 820c are excluded as they still have some board code left. Similarly, the config headers for db845c, starqltechn, and qcs404-evb are replaced by a single qcom header. Signed-off-by: Caleb Connolly --- arc

[PATCH v2 17/32] mach-snapdragon: generate fdtfile automatically

2023-12-19 Thread Caleb Connolly
supported platforms, and lets us avoid having a big lookup table. Signed-off-by: Caleb Connolly --- arch/arm/mach-snapdragon/board.c | 101 +++ 1 file changed, 101 insertions(+) diff --git a/arch/arm/mach-snapdragon/board.c b/arch/arm/mach-snapdragon/board.c

[PATCH v2 19/32] dt-bindings: import headers for SDM845

2023-12-19 Thread Caleb Connolly
Import the DT bindings headers that are used by SDM845 from Linux 6.7-rc3 Signed-off-by: Caleb Connolly --- include/dt-bindings/clock/qcom,camcc-sdm845.h | 116 ++ include/dt-bindings/clock/qcom,dispcc-sdm845.h | 56 +++ include/dt-bindings/clock/qcom,gpucc-sdm845.h | 24

[PATCH v2 22/32] dt-bindings: import headers for MSM8916

2023-12-19 Thread Caleb Connolly
Import the dt-bindings headers in preparation for switching to upstream DTS for MSM8916. Signed-off-by: Caleb Connolly --- include/dt-bindings/arm/coresight-cti-dt.h | 37 + include/dt-bindings/clock/qcom,rpmcc.h | 174 include/dt-bindings

[PATCH v2 23/32] dts: msm8916: import PMIC dtsi files

2023-12-19 Thread Caleb Connolly
Import the supporting pm8916.dtsi and msm8916-pm8916.dtsi files from upstream in preparation for switching boards over. Signed-off-by: Caleb Connolly --- arch/arm/dts/msm8916-pm8916.dtsi | 157 ++ arch/arm/dts/pm8916.dtsi | 178

[PATCH v2 20/32] dts: sdm845: import supporting dtsi files

2023-12-19 Thread Caleb Connolly
Import the PM8998 and PMI8998 PMIC DTSI files from Linux 6.7-rc3 as well as the common audio codec in preperation for replacing board DTS files with upstream. Signed-off-by: Caleb Connolly --- arch/arm/dts/pm8998.dtsi | 130 +++ arch/arm/dts/pmi8998

  1   2   3   4   5   6   7   8   9   10   >