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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Wed, 2 Feb 2022 14:36:47 +0100
From:   Geert Uytterhoeven <geert@...ux-m68k.org>
To:     Biju Das <biju.das.jz@...renesas.com>
Cc:     Prabhakar Mahadev Lad <prabhakar.mahadev-lad.rj@...renesas.com>,
        Magnus Damm <magnus.damm@...il.com>,
        Linux-Renesas <linux-renesas-soc@...r.kernel.org>,
        Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
        Prabhakar <prabhakar.csengg@...il.com>
Subject: Re: [PATCH v2] soc: renesas: Add support for reading product revision
 for RZ/G2L family

Hi Biju,

On Wed, Feb 2, 2022 at 12:20 PM Biju Das <biju.das.jz@...renesas.com> wrote:
> > Subject: Re: [PATCH v2] soc: renesas: Add support for reading product
> > revision for RZ/G2L family
> > On Wed, Feb 2, 2022 at 10:51 AM Biju Das <biju.das.jz@...renesas.com>
> > wrote:
> > > > Subject: Re: [PATCH v2] soc: renesas: Add support for reading
> > > > product revision for RZ/G2L family On Fri, Jan 21, 2022 at 2:41 AM
> > > > Lad Prabhakar <prabhakar.mahadev- lad.rj@...renesas.com> wrote:
> > > > > From: Biju Das <biju.das.jz@...renesas.com> As per RZ/G2L HW
> > > > > manual (Rev.1.00 Sep, 2021) DEV_ID [31:28] indicates product
> > > > > revision. Use this information to populate the revision info for
> > > > > RZ/G2L family.
> > > > >
> > > > > Signed-off-by: Biju Das <biju.das.jz@...renesas.com>
> > > > > Signed-off-by: Lad Prabhakar
> > > > > <prabhakar.mahadev-lad.rj@...renesas.com>
> >
> > > > > --- a/drivers/soc/renesas/renesas-soc.c
> > > > > +++ b/drivers/soc/renesas/renesas-soc.c
> > > > > @@ -405,41 +417,38 @@ static int __init renesas_soc_init(void)
> > > > >
> > > > >                         eshi = ((product >> 4) & 0x0f) + 1;
> > > > >                         eslo = product & 0xf;
> > > > > +                       soc_dev_attr->revision =
> > > > > + kasprintf(GFP_KERNEL,
> > > > "ES%u.%u",
> > > > > +                                                          eshi,
> > eslo);
> > > > > +               }  else if (id == &id_rzg2l) {
> > > > > +                       eshi =  ((product >> 28) & 0x0f);
> > > > > +                       soc_dev_attr->revision =
> > > > > + kasprintf(GFP_KERNEL,
> > > > "Rev %u",
> > > > > +                                                          eshi);
> > > >
> > > > Would you mind if I would drop the "Rev " while applying?
> > >
> > > Kernel reports the below message after dropping Rev. Is it OK?
> > >
> > > [    0.018297] Detected Renesas RZ/G2L r9a07g044 1
> >
> > That's indeed not so nice...
> >
> > Either we have to add it back, or do something like:
>
> This is much better.
>
> [    0.003427] Detected Renesas RZ/G2L r9a07g044 Rev 1
> root@...rc-rzg2l:~# for i in machine family soc_id revision; do echo -n "$i: ";cat /sys/devices/soc0/$i; done
> machine: Renesas SMARC EVK based on r9a07g044l2
> family: RZ/G2L
> soc_id: r9a07g044
> revision: 1
> root@...rc-rzg2l:~#
>
> >
> > -       pr_info("Detected Renesas %s %s %s\n", soc_dev_attr->family,
> > -               soc_dev_attr->soc_id, soc_dev_attr->revision ?: "");
> > +       pr_info("Detected Renesas %s %s%s%s\n", soc_dev_attr->family,
> > +               soc_dev_attr->soc_id, soc_dev_attr->revision ? " Rev " :
> > "",
> > +               soc_dev_attr->revision ?: "");
> >
>
> Will you post this change or Do you want me to send the patch?
>
> Please let me know.

I'll send a patch, to be folded in to the original.

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@...ux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ