lkml.org 
[lkml]   [2024]   [Mar]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 01/19] amba: store owner from modules with amba_driver_register()
Hi Krzysztof,

> >> /**
> >> - * amba_driver_register - register an AMBA device driver
> >> + * __amba_driver_register - register an AMBA device driver
> >> * @drv: amba device driver structure
> >> + * @owner: owning module/driver
> >> *
> >> * Register an AMBA device driver with the Linux device model
> >> * core. If devices pre-exist, the drivers probe function will
> >> * be called.
> >> */
> >> -int amba_driver_register(struct amba_driver *drv)
> >> +int __amba_driver_register(struct amba_driver *drv,
> >
> > ...
> >
> >> +/*
> >> + * use a macro to avoid include chaining to get THIS_MODULE
> >> + */
> >
> > Should the documentation be moved here? Well... I don't see any
> > documentation linking this file yet, but in case it comes we want
> > documented amba_driver_register() rather than
> > __amba_driver_register().
> >
>
> That's just a wrapper, not API... why would we care to have kerneldoc
> for it?

Because everyone should use the wrapper while the real function
will be used only once or twice.

I see also that this is a common practice which I don't surely
like.

In any case there is no documentation exported for AMBA so that
this discussion does not bring any tangible benefit.

So that, considering that it's a good improvement,

Reviewed-by: Andi Shyti <andi.shyti@kernel.org>

Andi

\
 
 \ /
  Last update: 2024-05-27 16:13    [W:0.092 / U:2.476 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site