Commit b2936d3a authored by Christoph Hellwig's avatar Christoph Hellwig

[PATCH] fix rescan warning

The prototype for scsi_rescan_device was missing and once added it's
caller doesn't compile anymore because it expects a return value..
parent d189d057
......@@ -442,6 +442,7 @@ extern void scsi_finish_command(Scsi_Cmnd *);
extern int scsi_retry_command(Scsi_Cmnd *);
extern int scsi_attach_device(struct scsi_device *);
extern void scsi_detach_device(struct scsi_device *);
extern void scsi_rescan_device(struct scsi_device *);
extern int scsi_get_device_flags(unsigned char *vendor, unsigned char *model);
/*
......
......@@ -275,12 +275,8 @@ show_rescan_field (struct device *dev, char *buf)
static ssize_t
store_rescan_field (struct device *dev, const char *buf, size_t count)
{
int ret = ENODEV;
struct scsi_device *sdev;
sdev = to_scsi_device(dev);
if (sdev)
ret = scsi_rescan_device(sdev);
return ret;
scsi_rescan_device(to_scsi_device(dev));
return 0;
}
static DEVICE_ATTR(rescan, S_IRUGO | S_IWUSR, show_rescan_field, store_rescan_field)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment