From 41511704b678f7b101a76e58d6c6b7bbe2a9ad70 Mon Sep 17 00:00:00 2001 From: Alan Stern Date: Mon, 15 Nov 2010 16:04:56 -0500 Subject: [SCSI] eliminate an unnecessary local variable from scsi_remove_target() Signed-off-by: Alan Stern Signed-off-by: James Bottomley --- drivers/scsi/scsi_sysfs.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'drivers/scsi/scsi_sysfs.c') diff --git a/drivers/scsi/scsi_sysfs.c b/drivers/scsi/scsi_sysfs.c index 76ee2e784f7..4c68d36f9ac 100644 --- a/drivers/scsi/scsi_sysfs.c +++ b/drivers/scsi/scsi_sysfs.c @@ -993,16 +993,14 @@ static int __remove_child (struct device * dev, void * data) */ void scsi_remove_target(struct device *dev) { - struct device *rdev; - if (scsi_is_target_device(dev)) { __scsi_remove_target(to_scsi_target(dev)); return; } - rdev = get_device(dev); + get_device(dev); device_for_each_child(dev, NULL, __remove_child); - put_device(rdev); + put_device(dev); } EXPORT_SYMBOL(scsi_remove_target); -- cgit v1.2.3-18-g5258