ChangeSet 1.1474.148.1, 2004/01/23 14:51:29-08:00, greg@kroah.com [PATCH] USB storage: remove info sysfs file as it violates the sysfs 1 value per file rule. drivers/usb/storage/scsiglue.c | 39 --------------------------------------- 1 files changed, 39 deletions(-) diff -Nru a/drivers/usb/storage/scsiglue.c b/drivers/usb/storage/scsiglue.c --- a/drivers/usb/storage/scsiglue.c Tue Jan 27 15:14:56 2004 +++ b/drivers/usb/storage/scsiglue.c Tue Jan 27 15:14:56 2004 @@ -309,44 +309,6 @@ * Sysfs interface ***********************************************************************/ -/* Output routine for the sysfs info file */ -static ssize_t show_info(struct device *dev, char *buffer) -{ - char *pos = buffer; - const int length = PAGE_SIZE; - - struct scsi_device *sdev = to_scsi_device(dev); - struct us_data *us = (struct us_data*)sdev->host->hostdata[0]; - - /* print the controller name */ - SPRINTF(" Host scsi%d: usb-storage\n", sdev->host->host_no); - - /* print product, vendor, and serial number strings */ - SPRINTF(" Vendor: %s\n", us->vendor); - SPRINTF(" Product: %s\n", us->product); - SPRINTF("Serial Number: %s\n", us->serial); - - /* show the protocol and transport */ - SPRINTF(" Protocol: %s\n", us->protocol_name); - SPRINTF(" Transport: %s\n", us->transport_name); - - /* show the device flags */ - if (pos < buffer + length) { - pos += sprintf(pos, " Quirks:"); - - DO_FLAG(SINGLE_LUN); - DO_FLAG(SCM_MULT_TARG); - DO_FLAG(FIX_INQUIRY); - DO_FLAG(FIX_CAPACITY); - - *(pos++) = '\n'; - } - - return (pos - buffer); -} - -static DEVICE_ATTR(info, S_IRUGO, show_info, NULL); - /* Output routine for the sysfs max_sectors file */ static ssize_t show_max_sectors(struct device *dev, char *buf) { @@ -373,7 +335,6 @@ store_max_sectors); static struct device_attribute *sysfs_device_attr_list[] = { - &dev_attr_info, &dev_attr_max_sectors, NULL, };