public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: Randy Dunlap <rdunlap@infradead.org>
Cc: linux-kernel@vger.kernel.org, "Rafael J. Wysocki" <rafael@kernel.org>
Subject: Re: [PATCH v2 1/2] driver core: bus.h: document bus notifiers better
Date: Tue, 10 Jan 2023 19:09:11 +0100	[thread overview]
Message-ID: <Y72px6jhwCC1TiQF@kroah.com> (raw)
In-Reply-To: <968101fe-2306-dbef-81f1-6b5864778b7a@infradead.org>

On Tue, Jan 10, 2023 at 09:03:52AM -0800, Randy Dunlap wrote:
> Hi Greg,
> 
> On 1/10/23 06:53, Greg Kroah-Hartman wrote:
> > The bus notifier values are not documented all that well, so clean this
> > up and make a real enumerated type for them and document them much
> > better.  Also change the values from being in hex to just decimal as it
> > didn't make any sense to have them in hex.
> > 
> > Cc: "Rafael J. Wysocki" <rafael@kernel.org>
> > Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
> > ---
> > v2: move the values to decimal from hex as pointed out by Rafael.
> > 
> >  include/linux/device/bus.h | 43 +++++++++++++++++++++++++-------------
> >  1 file changed, 29 insertions(+), 14 deletions(-)
> > 
> > diff --git a/include/linux/device/bus.h b/include/linux/device/bus.h
> > index d529f644e92b..fbec1c7c34c0 100644
> > --- a/include/linux/device/bus.h
> > +++ b/include/linux/device/bus.h
> > @@ -257,21 +257,36 @@ extern int bus_register_notifier(struct bus_type *bus,
> >  extern int bus_unregister_notifier(struct bus_type *bus,
> >  				   struct notifier_block *nb);
> >  
> > -/* All 4 notifers below get called with the target struct device *
> > - * as an argument. Note that those functions are likely to be called
> > - * with the device lock held in the core, so be careful.
> 
> If you want this to be kernel-doc format with no warnings,
> (a) all of the " * BUS_NOTIFY_..." lines should be " * @BUS_NOTIFY_...";
> (b) all of the " * @BUS_NOTIFY_..." lines should be immediately after the
> second ("enum") line. (at [1])
> (c) In the heading "enum" line, s/: / - /, but that's just for consistency
> and to follow kernel-doc documented format; it seems that kernel-doc takes
> that separator either way.
> 
> The patch below (on top of this one) makes all of these changes.

Ah, thank you so much for that, I'll merge your changes into here, and
also drop the explicit values for the enums as that really does not
matter at all.

thanks,

greg k-h

      reply	other threads:[~2023-01-11  9:02 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-01-10 14:53 [PATCH v2 1/2] driver core: bus.h: document bus notifiers better Greg Kroah-Hartman
2023-01-10 14:53 ` [PATCH v2 2/2] driver core: bus: move bus notifier logic into bus.c Greg Kroah-Hartman
2023-01-10 17:03 ` [PATCH v2 1/2] driver core: bus.h: document bus notifiers better Randy Dunlap
2023-01-10 18:09   ` Greg Kroah-Hartman [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Y72px6jhwCC1TiQF@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rafael@kernel.org \
    --cc=rdunlap@infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox