[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAHp75VdmtFJe5k_6biofS0HtgqC7HQuNzrM=9cMhM1uz1p5Eng@mail.gmail.com>
Date: Mon, 20 Jun 2022 10:00:31 +0200
From: Andy Shevchenko <andy.shevchenko@...il.com>
To: Marcin Wojtas <mw@...ihalf.com>
Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>,
"open list:SERIAL DRIVERS" <linux-serial@...r.kernel.org>,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Jiri Slaby <jirislaby@...nel.org>,
Miquel Raynal <miquel.raynal@...tlin.com>,
Grzegorz Jaszczyk <jaz@...ihalf.com>, upstream@...ihalf.com
Subject: Re: [PATCH] serial: 8250: dw: enable using pdata with ACPI
On Sun, Jun 19, 2022 at 9:43 AM Marcin Wojtas <mw@...ihalf.com> wrote:
>
> Commit 3242fe805b52 ("serial: 8250: dw: Move the USR register to pdata")
> caused NULL-pointer dereference when booting with ACPI by unconditional
> usage of the recently added pdata.
>
> In order to fix that and prevent similar issues in future, hook the
> default version of this structure in dw8250_acpi_match table.
Thanks for the report and fix! One proposal below.
...
> static const struct acpi_device_id dw8250_acpi_match[] = {
> - { "INT33C4", 0 },
> - { "INT33C5", 0 },
> - { "INT3434", 0 },
> - { "INT3435", 0 },
> - { "80860F0A", 0 },
> - { "8086228A", 0 },
> - { "APMC0D08", 0},
> - { "AMD0020", 0 },
> - { "AMDI0020", 0 },
> - { "AMDI0022", 0 },
> - { "BRCM2032", 0 },
> - { "HISI0031", 0 },
> + { "INT33C4", (kernel_ulong_t)&dw8250_dw_apb },
> + { "INT33C5", (kernel_ulong_t)&dw8250_dw_apb },
> + { "INT3434", (kernel_ulong_t)&dw8250_dw_apb },
> + { "INT3435", (kernel_ulong_t)&dw8250_dw_apb },
> + { "80860F0A", (kernel_ulong_t)&dw8250_dw_apb },
> + { "8086228A", (kernel_ulong_t)&dw8250_dw_apb },
> + { "APMC0D08", (kernel_ulong_t)&dw8250_dw_apb},
> + { "AMD0020", (kernel_ulong_t)&dw8250_dw_apb },
> + { "AMDI0020", (kernel_ulong_t)&dw8250_dw_apb },
> + { "AMDI0022", (kernel_ulong_t)&dw8250_dw_apb },
> + { "BRCM2032", (kernel_ulong_t)&dw8250_dw_apb },
> + { "HISI0031", (kernel_ulong_t)&dw8250_dw_apb },
Since you are touching all of them, please keep the order
alphanumerically sorted by the HID.
> { },
> };
--
With Best Regards,
Andy Shevchenko
Powered by blists - more mailing lists