lkml.org 
[lkml]   [2023]   [Oct]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH v9 05/15] irqchip/sifive-plic: Convert PLIC driver into a platform driver
On Fri, Sep 29, 2023 at 6:02 PM Marc Zyngier <maz@kernel.org> wrote:
>
> On Thu, 28 Sep 2023 07:11:57 +0100,
> Anup Patel <apatel@ventanamicro.com> wrote:
> >
> > The PLIC driver does not require very early initialization so let
> > us convert it into a platform driver.
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> >
> > As part of the conversion, the PLIC probing undergoes the following
> > changes:
> > 1. Use dev_info(), dev_err() and dev_warn() instead of pr_info(),
> > pr_err() and pr_warn()
> > 2. Use devm_xyz() APIs wherever applicable
> > 3. PLIC is now probed after CPUs are brought-up so we have to
> > setup cpuhp state after context handler of all online CPUs
> > are initialized otherwise we see crash on multi-socket systems
> >
> > Signed-off-by: Anup Patel <apatel@ventanamicro.com>
> > ---
> > drivers/irqchip/irq-sifive-plic.c | 242 +++++++++++++++++++-----------
> > 1 file changed, 154 insertions(+), 88 deletions(-)
> >
>
> [...]
>
> > +core_initcall(plic_init);
>
> Or not. There are only two choices: either you absolutely require
> early init, and you stick with the current situation, or you don't,
> and you can rely on dependencies.
>
> I'm not prepared to have a third option.

This is not required for DT based platform driver probing so
I will use builtin_platform_driver() over here and in APLIC
as well as IMSIC platform drivers.

Regards,
Anup

>
> M.
>
> --
> Without deviation from the norm, progress is not possible.

\
 
 \ /
  Last update: 2023-10-02 17:19    [W:0.205 / U:0.548 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site