diff options
author | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-24 18:22:41 -0400 |
---|---|---|
committer | Bartlomiej Zolnierkiewicz <bzolnier@gmail.com> | 2009-03-24 18:22:41 -0400 |
commit | 7ed5b157d9dff55bf477b4c8b4708d5d45476677 (patch) | |
tree | cbfd113108efd3b4d0b634f02ca8f09e99b7fdc7 /drivers/ide/ide-iops.c | |
parent | 8cd3c605624035b7f57deb8894e17c5ba6d05b2e (diff) |
ide: add ide_for_each_present_dev() iterator
* Add ide_for_each_present_dev() iterator and convert IDE code to use it.
* Do some drive-by CodingStyle fixups in ide-acpi.c while at it.
There should be no functional changes caused by this patch.
Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
Diffstat (limited to 'drivers/ide/ide-iops.c')
-rw-r--r-- | drivers/ide/ide-iops.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/ide/ide-iops.c b/drivers/ide/ide-iops.c index b1892bd95c6f..02fed32a4047 100644 --- a/drivers/ide/ide-iops.c +++ b/drivers/ide/ide-iops.c | |||
@@ -1103,9 +1103,8 @@ static ide_startstop_t do_reset1 (ide_drive_t *drive, int do_not_try_atapi) | |||
1103 | 1103 | ||
1104 | prepare_to_wait(&ide_park_wq, &wait, TASK_UNINTERRUPTIBLE); | 1104 | prepare_to_wait(&ide_park_wq, &wait, TASK_UNINTERRUPTIBLE); |
1105 | timeout = jiffies; | 1105 | timeout = jiffies; |
1106 | ide_port_for_each_dev(i, tdrive, hwif) { | 1106 | ide_port_for_each_present_dev(i, tdrive, hwif) { |
1107 | if (tdrive->dev_flags & IDE_DFLAG_PRESENT && | 1107 | if ((tdrive->dev_flags & IDE_DFLAG_PARKED) && |
1108 | tdrive->dev_flags & IDE_DFLAG_PARKED && | ||
1109 | time_after(tdrive->sleep, timeout)) | 1108 | time_after(tdrive->sleep, timeout)) |
1110 | timeout = tdrive->sleep; | 1109 | timeout = tdrive->sleep; |
1111 | } | 1110 | } |