Re: BMI160 accelerometer on AyaNeo tablet

From: Jonathan Cameron
Date: Mon Oct 18 2021 - 11:17:43 EST


On Mon, 18 Oct 2021 10:40:33 +0300
Andy Shevchenko <andy.shevchenko@xxxxxxxxx> wrote:

> +Cc: Hans
>
> On Mon, Oct 18, 2021 at 6:41 AM Jonathan Cameron <jic23@xxxxxxxxxx> wrote:
> >
> > On Sat, 16 Oct 2021 19:27:50 +0300
> > Maxim Levitsky <maximlevitsky@xxxxxxxxx> wrote:
> >
> > > BMI160: AYA NEA accelometer ID
>
> accelerometer
>
> > > On AYA NEO, the accelerometer is BMI160 but it is exposed
> > > via ACPI as 10EC5280
> > >
> > > Signed-off-by: Maxim Levitsky <mlevitsk@xxxxxxxxxx>
> >
> > I guess it is hopelessly optimistic to hope that we could let someone
> > at the supplier know that's a totally invalid ACPI id and that they
> > should clean up their act.
> >
> > Curiously it looks like a valid PCI ID pair though for a realtek device.
> >
> > Ah well. Applied to the iio-togreg branch of iio.git and pushed out
> > as testing to see if 0-day can find any issues with it.
>
> NAK. And I explain below why and how to make progress with it.
>
> The commit message should contain at least the link to the DSDT and
> official technical description of the platform. Besides that, it
> should have a corresponding comment near to the ID in the code.
>
> On top of that, in particular to this case, the ID is very valid from
> the ACPI specification point of view, but in this case it's a
> representation of the PCI ID 10ec:5280 which is Realtek owned. So, we
> need to hear (okay in reasonable time) from Realtek (I believe they
> are active in the Linux kernel) and that OEM.
>
> I hardly believe that Realtek has issued a special ID from the range
> where mostly PCIe ports or so are allocated, although it's possible.
> We need proof.
>
> What I believe is the case here is that OEMs are just quite diletants
> in ACPI and firmware and they messed up with BIOS somehow that it
> issued the ID for the device.
> There are also two other possibilities: OEM stole the ID (deliberately
> or accidentally), or the device is not just gyro, but something which
> contains gyro.
>
> As to the last paragraph, see above, we must see DSDT. Without it I
> have a strong NAK.
>
> P.S. Jonathan, please do not be so fast next time with ACPI IDs.

No problem. Will pull this one once I'm back on correct PC.

Jonathan

>