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: <20251231020951-GYA2019108@gentoo.org>
Date: Wed, 31 Dec 2025 10:09:51 +0800
From: Yixun Lan <dlan@...too.org>
To: Alex Elder <elder@...cstar.com>
Cc: Stephen Boyd <sboyd@...nel.org>,
	Michael Turquette <mturquette@...libre.com>,
	Philipp Zabel <p.zabel@...gutronix.de>,
	Guodong Xu <guodong@...cstar.com>,
	Inochi Amaoto <inochiama@...il.com>, linux-kernel@...r.kernel.org,
	linux-clk@...r.kernel.org, linux-riscv@...ts.infradead.org,
	spacemit@...ts.linux.dev
Subject: Re: [PATCH v2 3/3] reset: spacemit: fix auxiliary device id

Hi Alex,

On 18:50 Mon 29 Dec     , Alex Elder wrote:
> On 12/26/25 12:55 AM, Yixun Lan wrote:
> > Due to the auxiliary register procedure moved to ccu common module,
> > the auxiliary device id need to be adjusted, otherwise reset driver
> > will fail to probe.
> > 
> > Signed-off-by: Yixun Lan <dlan@...too.org>
> > ---
> >   drivers/reset/reset-spacemit.c | 2 +-
> >   1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/reset/reset-spacemit.c b/drivers/reset/reset-spacemit.c
> > index e1272aff28f7..8922e14fa836 100644
> > --- a/drivers/reset/reset-spacemit.c
> > +++ b/drivers/reset/reset-spacemit.c
> > @@ -278,7 +278,7 @@ static int spacemit_reset_probe(struct auxiliary_device *adev,
> >   
> >   #define K1_AUX_DEV_ID(_unit) \
> >   	{ \
> > -		.name = "spacemit_ccu_k1." #_unit "-reset", \
> > +		.name = "spacemit_ccu." _K_RST(_unit), \
> >   		.driver_data = (kernel_ulong_t)&k1_ ## _unit ## _reset_data, \
> >   	}
> 
> The above macro is named K1_AUX_DEV_ID().  Why don't you
> define K3_AUX_DEV_ID(), which could use "k3" in its name?
> 
that should also works, the idea of using same macro '_K_RST()' here
is trying to explictly tell users the clock and reset shares same name

> Anyway, if you go this route I suggest you drop "K1_" from the
> name of this macro.
> 
or could further refactor the code, to make K1/K3 drivers share same macro

anyway I don't want to change this patch, my goal here is tring to fix
reset driver after clock common driver refactored plus the modularization 
introduced, it's more proper to leave those refactor work up to Guodong,
since he did a lot adjustment to add reset support for K3 SoC

-- 
Yixun Lan (dlan)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ