]> git.neil.brown.name Git - history.git/commitdiff
[PATCH] ide: fix PM with ide-default driver
authorBartlomiej Zolnierkiewicz <b.zolnierkiewicz@elka.pw.edu.pl>
Thu, 4 Sep 2003 03:11:42 +0000 (20:11 -0700)
committerLinus Torvalds <torvalds@home.osdl.org>
Thu, 4 Sep 2003 03:11:42 +0000 (20:11 -0700)
From Benjamin Herrenschmidt <benh@kernel.crashing.org>

drivers/ide/ide.c

index 8ff22ad3f648e155a1065349b377999f21792bce..dfb03f9a423f4d0dcaf3b511f4aa262f126420b5 100644 (file)
@@ -2406,6 +2406,13 @@ static ide_startstop_t default_abort (ide_drive_t *drive, const char *msg)
        return ide_abort(drive, msg);
 }
 
+static ide_startstop_t default_start_power_step(ide_drive_t *drive,
+                                               struct request *rq)
+{
+       rq->pm->pm_step = ide_pm_state_completed;
+       return ide_stopped;
+}
+
 static void setup_driver_defaults (ide_driver_t *d)
 {
        if (d->cleanup == NULL)         d->cleanup = default_cleanup;
@@ -2420,6 +2427,8 @@ static void setup_driver_defaults (ide_driver_t *d)
        if (d->capacity == NULL)        d->capacity = default_capacity;
        if (d->special == NULL)         d->special = default_special;
        if (d->attach == NULL)          d->attach = default_attach;
+       if (d->start_power_step == NULL)
+               d->start_power_step = default_start_power_step;
 }
 
 int ide_register_subdriver (ide_drive_t *drive, ide_driver_t *driver, int version)