diff options
author | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-06-15 20:34:34 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-06-15 20:34:34 -0400 |
commit | de7f928ca460005086a8296be07c217aac4b625d (patch) | |
tree | db7ae7a5a536d2cd6b686b69759092eb237e252f /drivers/ide/ide.c | |
parent | fa04a008a16ac633a55f41baf9e84b551e613e7e (diff) | |
parent | d1be0a8225f2cb1cdc356ebb0ae6800f023ce67d (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/bart/ide-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/bart/ide-2.6:
ide-scsi: fix OOPS in idescsi_expiry()
Resume from RAM on HPC nx6325 broken
Diffstat (limited to 'drivers/ide/ide.c')
-rw-r--r-- | drivers/ide/ide.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c index 0af0d1614f75..0cd76bf66833 100644 --- a/drivers/ide/ide.c +++ b/drivers/ide/ide.c | |||
@@ -1010,7 +1010,6 @@ static int generic_ide_resume(struct device *dev) | |||
1010 | { | 1010 | { |
1011 | ide_drive_t *drive = dev->driver_data; | 1011 | ide_drive_t *drive = dev->driver_data; |
1012 | ide_hwif_t *hwif = HWIF(drive); | 1012 | ide_hwif_t *hwif = HWIF(drive); |
1013 | ide_driver_t *drv = to_ide_driver(dev->driver); | ||
1014 | struct request rq; | 1013 | struct request rq; |
1015 | struct request_pm_state rqpm; | 1014 | struct request_pm_state rqpm; |
1016 | ide_task_t args; | 1015 | ide_task_t args; |
@@ -1033,8 +1032,12 @@ static int generic_ide_resume(struct device *dev) | |||
1033 | 1032 | ||
1034 | err = ide_do_drive_cmd(drive, &rq, ide_head_wait); | 1033 | err = ide_do_drive_cmd(drive, &rq, ide_head_wait); |
1035 | 1034 | ||
1036 | if (err == 0 && drv && drv->resume) | 1035 | if (err == 0 && dev->driver) { |
1037 | drv->resume(drive); | 1036 | ide_driver_t *drv = to_ide_driver(dev->driver); |
1037 | |||
1038 | if (drv->resume) | ||
1039 | drv->resume(drive); | ||
1040 | } | ||
1038 | 1041 | ||
1039 | return err; | 1042 | return err; |
1040 | } | 1043 | } |