[PATCH v1 2/2] ath79: D-Link DAP-2xxx (QCA953x): convert ath9k caldata to nvmem
Sander Vanheule
sander at svanheule.net
Sat Jun 11 06:12:48 PDT 2022
Hi Christian,
On Sat, 2022-06-11 at 15:01 +0200, Christian Lamparter wrote:
> On 11/06/2022 14:05, Sander Vanheule wrote:
> > Convert the calibration data reference for the ath9k radio to an
> > nvmem-cell, replacing the downstream mtd-cal-data property.
> >
> > Cc: Sebastian Schaper <openwrt at sebastianschaper.net>
> > Signed-off-by: Sander Vanheule <sander at svanheule.net>
> > ---
> > target/linux/ath79/dts/qca953x_dlink_dap-2xxx.dtsi | 13 ++++++++++++-
> > 1 file changed, 12 insertions(+), 1 deletion(-)
> >
> > diff --git a/target/linux/ath79/dts/qca953x_dlink_dap-2xxx.dtsi
> > b/target/linux/ath79/dts/qca953x_dlink_dap-2xxx.dtsi
> > index 59c09dbe1b62..1bce67c871b7 100644
> > --- a/target/linux/ath79/dts/qca953x_dlink_dap-2xxx.dtsi
> > +++ b/target/linux/ath79/dts/qca953x_dlink_dap-2xxx.dtsi
> > @@ -54,5 +54,16 @@
> > &wmac {
> > status = "okay";
> >
> > - mtd-cal-data = <&art 0x1000>;
> > + nvmem-cells = <&cal_ath9k>;
> > + nvmem-cell-names = "calibration";
> > +};
> > +
> > +&art {
> > + compatible = "nvmem-cells";
> > + #address-cells = <1>;
> > + #size-cells = <1>;
> > +
> > + cal_ath9k: calibration at 1000 {
> > + reg = <0x1000 0x440>;
> > + };
> > };
>
> you could merge the content of the &art { compatible = "nvmem-cells" ... }
> right into the "new" "partition at ff000 { label = "art" ... }" from your first
> patch of this series.
>
> This would likely make the extra art-label redundant too.
> (Personally, I think it is better to keep the information together,
> if it's all in the same file anyway.)
I've heard different opinions about this, perhaps because you end up nesting quite deep. In this
case everything can indeed be contained to the (unlabeled) ART partition. The latter is also how I
would prefer it actually, but these are the first changes of this type I've submitted. I'll update
in v2.
Best,
Sander
More information about the openwrt-devel
mailing list