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]
Date:   Mon, 2 Oct 2023 10:16:05 +0000
From:   Biju Das <biju.das.jz@...renesas.com>
To:     Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
CC:     Jonathan Cameron <Jonathan.Cameron@...wei.com>,
        André Apitzsch <git@...tzsch.eu>,
        Jonathan Cameron <jic23@...nel.org>,
        Lars-Peter Clausen <lars@...afoo.de>,
        "linux-iio@...r.kernel.org" <linux-iio@...r.kernel.org>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH] iio: magnetometer: ak8975: Fix 'Unexpected device' error



> -----Original Message-----
> From: Biju Das
> Sent: Monday, October 2, 2023 10:57 AM
> To: Andy Shevchenko <andriy.shevchenko@...ux.intel.com>
> Cc: Jonathan Cameron <Jonathan.Cameron@...wei.com>; André Apitzsch
> <git@...tzsch.eu>; Jonathan Cameron <jic23@...nel.org>; Lars-Peter Clausen
> <lars@...afoo.de>; linux-iio@...r.kernel.org; linux-kernel@...r.kernel.org
> Subject: RE: [PATCH] iio: magnetometer: ak8975: Fix 'Unexpected device'
> error
> 
> > Subject: Re: [PATCH] iio: magnetometer: ak8975: Fix 'Unexpected device'
> > error
> >
> > On Mon, Oct 02, 2023 at 09:38:17AM +0000, Biju Das wrote:
> > > > On Mon, Oct 02, 2023 at 10:27:45AM +0100, Jonathan Cameron wrote:
> > > > > On Sun, 1 Oct 2023 18:09:56 +0200 André Apitzsch
> > > > > <git@...tzsch.eu> wrote:
> > > >
> > > > > > Fixes: 4f9ea93afde1 ("iio: magnetometer: ak8975: Convert
> > > > > > enum->pointer for data in the match tables")
> > > >
> > > > ^^^ (1)
> >
> > ...
> >
> > > > > So we need the spacer until someone converts this driver to use
> > > > > pointers instead for both of and ACPI tables.
> > > >
> > > > Isn't it done by (1) which is in your tree?
> > >
> > > How (1) can trigger 'Unexpected device' error??
> > > It returns match_data, and match_data has correct device type.
> >
> > How? The enum starts from 0 with a AKXXXX and ak_def_array starts from
> > 0 indexing, it's classical off-by-one, you got the driver data for a
> > wrong chip.
> 
> Got it. I was about to reply. It just needs mapping as Andre did here.

Or split this array into device specific individual variable
to avoid any mapping.

Cheers,
Biju

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ