lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <51c9408e-45e7-4ce7-9e95-6e0a45bcc8fa@dujemihanovic.xyz>
Date: Fri, 28 Nov 2025 22:30:55 +0100
From: Duje Mihanović <duje@...emihanovic.xyz>
To: Karel Balej <balejk@...fyz.cz>, Ulf Hansson <ulf.hansson@...aro.org>,
 Rob Herring <robh@...nel.org>, Krzysztof Kozlowski <krzk+dt@...nel.org>,
 Conor Dooley <conor+dt@...nel.org>, linux-arm-kernel@...ts.infradead.org,
 linux-pm@...r.kernel.org, linux-kernel@...r.kernel.org,
 devicetree@...r.kernel.org
Cc: ~postmarketos/upstreaming@...ts.sr.ht, phone-devel@...r.kernel.org
Subject: Re: [PATCH 2/2] pmdomain: add audio power island for Marvell PXA1908
 SoC

On 11/27/2025 8:02 PM, Karel Balej wrote:
> Define power domain which needs to be enabled in order for audio to work
> on the PXA1908-based samsung,coreprimevelte smartphone. In the
> downstream code, this power-on method is marked as specific to the ulcx
> series which is likely some variant of the board or some part of it. No
> other audio components needed for sound to work on this phone are
> currently available mainline but some successful testing was performed
> with the vendor variants of the respective drivers and with the domain
> forced always-on.

>From what I know, ULCx is actually meant to be some SoC codename. ULC1
happens to be PXA1908, but I couldn't find any such codename for the rest.

Other than that, just a few nits:

> diff --git a/drivers/pmdomain/marvell/pxa1908-power-controller.c b/drivers/pmdomain/marvell/pxa1908-power-controller.c
> index ff5e6e82d3f8..e32eb227f235 100644
> --- a/drivers/pmdomain/marvell/pxa1908-power-controller.c
> +++ b/drivers/pmdomain/marvell/pxa1908-power-controller.c
> @@ -29,7 +29,10 @@
>  #define POWER_POLL_TIMEOUT_US	(25 * USEC_PER_MSEC)
>  #define POWER_POLL_SLEEP_US	6
>  
> -#define NR_DOMAINS	5
> +#define APMU_AUD_CLK		0x80
> +#define AUDIO_ULCX_ENABLE	0x0d

I would group these with the other register definitions.

Also, it's probably better to be more consistent with the naming, so I'd
prefer APMU_AUDIO_CLK.

> @@ -59,9 +62,13 @@ static inline bool pxa1908_pd_is_on(struct pxa1908_pd *pd)
>  {
>  	struct pxa1908_pd_ctrl *ctrl = pd->ctrl;
>  
> -	return pd->data.id != PXA1908_POWER_DOMAIN_DSI
> -		? regmap_test_bits(ctrl->base, APMU_PWR_STATUS_REG, pd->data.pwr_state)
> -		: regmap_test_bits(ctrl->base, APMU_DEBUG, DSI_PHY_DVM_MASK);
> +	switch (pd->data.id) {
> +	case PXA1908_POWER_DOMAIN_AUDIO:
> +		return regmap_test_bits(ctrl->base, APMU_AUD_CLK, AUDIO_ULCX_ENABLE);
> +	case PXA1908_POWER_DOMAIN_DSI:
> +		return regmap_test_bits(ctrl->base, APMU_DEBUG, DSI_PHY_DVM_MASK);
> +	}
> +	return regmap_test_bits(ctrl->base, APMU_PWR_STATUS_REG, pd->data.pwr_state);

Perhaps this should go into the switch?

Regards,
--
Duje

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ