mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: James Bottomley <jejb@linux.ibm.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org
Cc: Johannes Thumshirn <jth@kernel.org>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	linux-scsi <linux-scsi@vger.kernel.org>
Subject: Re: [PATCH 03/10] SCSI: fcoe: convert to use BUS_ATTR_WO
Date: Fri, 28 Dec 2018 13:50:53 +0100	[thread overview]
Message-ID: <5691ac07-ec5d-893f-09e4-ff1acd889abd@suse.de> (raw)
In-Reply-To: <1545406185.2765.8.camel@linux.ibm.com>

On 12/21/18 4:29 PM, James Bottomley wrote:
> [scsi list cc added]
> On Fri, 2018-12-21 at 08:54 +0100, Greg Kroah-Hartman wrote:
>> We are trying to get rid of BUS_ATTR() and the usage of that in the
>> fcoe driver can be trivially converted to use BUS_ATTR_WO(), so use
>> that instead.
>>
>> At the same time remove a unneeded EXPORT_SYMBOL() marking for the
>> sysfs callback function we are renaming, no idea of how that got into
>> the tree...
> 
> The EXPORT_SYMBOL removal is fine, but
> 
> [...]
>> --- a/include/scsi/libfcoe.h
>> +++ b/include/scsi/libfcoe.h
>> @@ -405,10 +405,8 @@ int fcoe_transport_attach(struct fcoe_transport
>> *ft);
>>   int fcoe_transport_detach(struct fcoe_transport *ft);
>>
>>   /* sysfs store handler for ctrl_control interface */
>> -ssize_t fcoe_ctlr_create_store(struct bus_type *bus,
>> -			       const char *buf, size_t count);
>> -ssize_t fcoe_ctlr_destroy_store(struct bus_type *bus,
>> -				const char *buf, size_t count);
>> +ssize_t ctlr_create_store(struct bus_type *bus, const char *buf,
>> size_t count);
>> +ssize_t ctlr_destroy_store(struct bus_type *bus, const char *buf,
>> size_t count);
> 
> You're really damaging our prefix namespace here.  It looks like the
> ctlr_ name is a farly recent addition for sysfs (only myra/b) use it in
> SCSI but it's inviting symbol clashes.
> 
Hmm. I was under the impression that all sysfs functions from myrb/myrs 
are local, hence I would not need to prefix them.
If this isn't the case I definitely will be fixing them.

But in any case, if possible any sysfs function should be local to the 
driver; no-one else should ever attempt to use them.
And we should be making it so if that's not the case.

Cheers,

Hannes

  reply	other threads:[~2018-12-28 12:50 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-21  7:54 [PATCH 00/10] Driver core: remove BUS_ATTR() Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 01/10] PCI: pci.c: convert to use BUS_ATTR_RW Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 02/10] PCI: pci-sysfs.c: convert to use BUS_ATTR_WO Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 03/10] SCSI: fcoe: " Greg Kroah-Hartman
2018-12-21  8:00   ` Johannes Thumshirn
2018-12-21 15:29   ` James Bottomley
2018-12-28 12:50     ` Hannes Reinecke [this message]
2019-01-22 14:22       ` Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 04/10] pseries: ibmebus.c: " Greg Kroah-Hartman
2018-12-27  5:27   ` Michael Ellerman
2018-12-21  7:54 ` [PATCH 05/10] rapidio: rio-sysfs.c: " Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 06/10] block: rbd: convert to use BUS_ATTR_WO and RO Greg Kroah-Hartman
2018-12-21  9:28   ` Ilya Dryomov
2018-12-21  7:54 ` [PATCH 07/10] driver core: bus: convert to use BUS_ATTR_WO and RW Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 08/10] Documentation: driver core: remove use of BUS_ATTR Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 09/10] driver core: drop use of BUS_ATTR() Greg Kroah-Hartman
2018-12-21  7:54 ` [PATCH 10/10] driver core: remove BUS_ATTR() Greg Kroah-Hartman

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=5691ac07-ec5d-893f-09e4-ff1acd889abd@suse.de \
    --to=hare@suse.de \
    --cc=gregkh@linuxfoundation.org \
    --cc=jejb@linux.ibm.com \
    --cc=jth@kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    /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

all inboxes | Powered by JetHome®