diff options
Diffstat (limited to 'drivers/usb/storage/scsiglue.c')
-rw-r--r-- | drivers/usb/storage/scsiglue.c | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/drivers/usb/storage/scsiglue.c b/drivers/usb/storage/scsiglue.c index 92b05d95ec5e..94d75edef77f 100644 --- a/drivers/usb/storage/scsiglue.c +++ b/drivers/usb/storage/scsiglue.c | |||
@@ -496,7 +496,7 @@ US_DO_ALL_FLAGS | |||
496 | ***********************************************************************/ | 496 | ***********************************************************************/ |
497 | 497 | ||
498 | /* Output routine for the sysfs max_sectors file */ | 498 | /* Output routine for the sysfs max_sectors file */ |
499 | static ssize_t show_max_sectors(struct device *dev, struct device_attribute *attr, char *buf) | 499 | static ssize_t max_sectors_show(struct device *dev, struct device_attribute *attr, char *buf) |
500 | { | 500 | { |
501 | struct scsi_device *sdev = to_scsi_device(dev); | 501 | struct scsi_device *sdev = to_scsi_device(dev); |
502 | 502 | ||
@@ -504,7 +504,7 @@ static ssize_t show_max_sectors(struct device *dev, struct device_attribute *att | |||
504 | } | 504 | } |
505 | 505 | ||
506 | /* Input routine for the sysfs max_sectors file */ | 506 | /* Input routine for the sysfs max_sectors file */ |
507 | static ssize_t store_max_sectors(struct device *dev, struct device_attribute *attr, const char *buf, | 507 | static ssize_t max_sectors_store(struct device *dev, struct device_attribute *attr, const char *buf, |
508 | size_t count) | 508 | size_t count) |
509 | { | 509 | { |
510 | struct scsi_device *sdev = to_scsi_device(dev); | 510 | struct scsi_device *sdev = to_scsi_device(dev); |
@@ -514,16 +514,14 @@ static ssize_t store_max_sectors(struct device *dev, struct device_attribute *at | |||
514 | blk_queue_max_hw_sectors(sdev->request_queue, ms); | 514 | blk_queue_max_hw_sectors(sdev->request_queue, ms); |
515 | return count; | 515 | return count; |
516 | } | 516 | } |
517 | return -EINVAL; | 517 | return -EINVAL; |
518 | } | 518 | } |
519 | 519 | static DEVICE_ATTR_RW(max_sectors); | |
520 | static DEVICE_ATTR(max_sectors, S_IRUGO | S_IWUSR, show_max_sectors, | ||
521 | store_max_sectors); | ||
522 | 520 | ||
523 | static struct device_attribute *sysfs_device_attr_list[] = { | 521 | static struct device_attribute *sysfs_device_attr_list[] = { |
524 | &dev_attr_max_sectors, | 522 | &dev_attr_max_sectors, |
525 | NULL, | 523 | NULL, |
526 | }; | 524 | }; |
527 | 525 | ||
528 | /* | 526 | /* |
529 | * this defines our host template, with which we'll allocate hosts | 527 | * this defines our host template, with which we'll allocate hosts |