[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAJB-X+U7Af3ypru3O0quGTqrsJPMO3b7uoBTNjTLSixrmrvXJw@mail.gmail.com>
Date: Thu, 29 Jun 2023 11:52:33 +0800
From: Koba Ko <koba.ko@...onical.com>
To: "Luck, Tony" <tony.luck@...el.com>
Cc: Borislav Petkov <bp@...en8.de>, James Morse <james.morse@....com>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Robert Richter <rric@...nel.org>,
"linux-edac@...r.kernel.org" <linux-edac@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] EDAC/i10nm: shift exponent is negative
hi Luck,
I agree with your points
is it expected to shift with negative?
Thanks
Koba Ko
On Thu, Jun 29, 2023 at 12:41 AM Luck, Tony <tony.luck@...el.com> wrote:
>
> > ranks = numrank(mtr);
> > rows = numrow(mtr);
> > cols = imc->hbm_mc ? 6 : numcol(mtr);
> > + if (ranks == -EINVAL || rows == -EINVAL || cols == -EINVAL)
> > + return 0;
>
> This seems to be just hiding the real problem that a DIMM was found
> with some number of ranks, rows, or columns that the EDAC driver
> didn't expect to see. Your fix makes the driver skip over this DIMM.
>
> Can you build your kernel with CONFIG_EDAC_DEBUG=y and see
> what messages you get from this code:
>
> static int skx_get_dimm_attr(u32 reg, int lobit, int hibit, int add,
> int minval, int maxval, const char *name)
> {
> u32 val = GET_BITFIELD(reg, lobit, hibit);
>
> if (val < minval || val > maxval) {
> edac_dbg(2, "bad %s = %d (raw=0x%x)\n", name, val, reg);
> return -EINVAL;
> }
>
> -Tony
>
>
Powered by blists - more mailing lists