scsi: remove DRIVER_ATTR() usage
It's better to use the DRIVER_ATTR_RW() and DRIVER_ATTR_RO() macros to explicitly show that this is a read/write or read/only sysfs file. So convert the remaining SCSI drivers that use the old style to use the newer macros. Bonus is that this removes some checkpatch.pl warnings :) This is part of a series to drop DRIVER_ATTR() from the tree entirely. Cc: "James E.J. Bottomley" <jejb@linux.vnet.ibm.com> Cc: "Martin K. Petersen" <martin.petersen@oracle.com> Cc: Kashyap Desai <kashyap.desai@broadcom.com> Cc: Sumit Saxena <sumit.saxena@broadcom.com> Cc: Shivasharan S <shivasharan.srikanteshwara@broadcom.com> Cc: Willem Riede <osst@riede.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Reviewed-by: Bart Van Assche <bart.vanassche@wdc.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
This commit is contained in:

committed by
Martin K. Petersen

부모
22fe5670ce
커밋
e14a396772
@@ -5667,12 +5667,12 @@ static struct osst_support_data support_list[] = {
|
||||
* sysfs support for osst driver parameter information
|
||||
*/
|
||||
|
||||
static ssize_t osst_version_show(struct device_driver *ddd, char *buf)
|
||||
static ssize_t version_show(struct device_driver *ddd, char *buf)
|
||||
{
|
||||
return snprintf(buf, PAGE_SIZE, "%s\n", osst_version);
|
||||
}
|
||||
|
||||
static DRIVER_ATTR(version, S_IRUGO, osst_version_show, NULL);
|
||||
static DRIVER_ATTR_RO(version);
|
||||
|
||||
static int osst_create_sysfs_files(struct device_driver *sysfs)
|
||||
{
|
||||
|
Reference in New Issue
Block a user