[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <eae0d1c49fcd4b41b700e8fd86af1b3e@cqplus1.com>
Date: Fri, 1 Apr 2022 09:19:31 +0000
From: qinjian[覃健] <qinjian@...lus1.com>
To: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
CC: "robh+dt@...nel.org" <robh+dt@...nel.org>,
"mturquette@...libre.com" <mturquette@...libre.com>,
"sboyd@...nel.org" <sboyd@...nel.org>,
"tglx@...utronix.de" <tglx@...utronix.de>,
"maz@...nel.org" <maz@...nel.org>,
"p.zabel@...gutronix.de" <p.zabel@...gutronix.de>,
"linux@...linux.org.uk" <linux@...linux.org.uk>,
"arnd@...db.de" <arnd@...db.de>,
"linux-arm-kernel@...ts.infradead.org"
<linux-arm-kernel@...ts.infradead.org>,
"devicetree@...r.kernel.org" <devicetree@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"linux-clk@...r.kernel.org" <linux-clk@...r.kernel.org>
Subject: RE: [PATCH v12 4/9] dt-bindings: clock: Add bindings for SP7021 clock
driver
> > diff --git a/include/dt-bindings/clock/sp-sp7021.h b/include/dt-bindings/clock/sp-sp7021.h
> > new file mode 100644
> > index 000000000..45dac6de8
> > --- /dev/null
> > +++ b/include/dt-bindings/clock/sp-sp7021.h
> > @@ -0,0 +1,112 @@
> > +/* SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) */
> > +/*
> > + * Copyright (C) Sunplus Technology Co., Ltd.
> > + * All rights reserved.
> > + */
> > +#ifndef _DT_BINDINGS_CLOCK_SUNPLUS_SP7021_H
> > +#define _DT_BINDINGS_CLOCK_SUNPLUS_SP7021_H
> > +
> > +#define XTAL 27000000
> > +
> > +/* plls */
> > +#define PLL_A 0
> > +#define PLL_E 1
> > +#define PLL_E_2P5 2
> > +#define PLL_E_25 3
> > +#define PLL_E_112P5 4
> > +#define PLL_F 5
> > +#define PLL_TV 6
> > +#define PLL_TV_A 7
> > +#define PLL_SYS 8
> > +
> > +/* gates: mo_clken0 ~ mo_clken9 */
> > +#define CLK_SYSTEM 0x10
> > +#define CLK_RTC 0x12
>
> YAML looks ok, but here comment from Arnd also applies. These should be
> regular decimal numbers incremented by one.
>
> Best regards,
> Krzysztof
Yes, same as reset driver, these defines also mapping the hardware.
But different from reset driver, clk driver also used these defines.
If I removed this defines, I must write the proper hardware number twice in dt & driver.
It's meaningless & hard to check.
Powered by blists - more mailing lists