mirror of
https://github.com/torvalds/linux.git
synced 2024-11-11 14:42:24 +00:00
SCSI: improve two error messages
This trivial patch (as1338) makes two uninformative error messages in scsi_sysfs_add_sdev() more explicit. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
This commit is contained in:
parent
db6857c6e7
commit
73d8c34f3d
@ -864,13 +864,15 @@ int scsi_sysfs_add_sdev(struct scsi_device *sdev)
|
||||
|
||||
error = device_add(&sdev->sdev_gendev);
|
||||
if (error) {
|
||||
printk(KERN_INFO "error 1\n");
|
||||
sdev_printk(KERN_INFO, sdev,
|
||||
"failed to add device: %d\n", error);
|
||||
return error;
|
||||
}
|
||||
device_enable_async_suspend(&sdev->sdev_dev);
|
||||
error = device_add(&sdev->sdev_dev);
|
||||
if (error) {
|
||||
printk(KERN_INFO "error 2\n");
|
||||
sdev_printk(KERN_INFO, sdev,
|
||||
"failed to add class device: %d\n", error);
|
||||
device_del(&sdev->sdev_gendev);
|
||||
return error;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user