Commit d36fef6f authored by Bartlomiej Zolnierkiewicz's avatar Bartlomiej Zolnierkiewicz
Browse files

[PATCH] ide-disk: flush cache after calling del_gendisk()


Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
parent 8f29e650
...@@ -1034,12 +1034,12 @@ static int ide_disk_remove(struct device *dev) ...@@ -1034,12 +1034,12 @@ static int ide_disk_remove(struct device *dev)
struct ide_disk_obj *idkp = drive->driver_data; struct ide_disk_obj *idkp = drive->driver_data;
struct gendisk *g = idkp->disk; struct gendisk *g = idkp->disk;
ide_cacheflush_p(drive);
ide_unregister_subdriver(drive, idkp->driver); ide_unregister_subdriver(drive, idkp->driver);
del_gendisk(g); del_gendisk(g);
ide_cacheflush_p(drive);
ide_disk_put(idkp); ide_disk_put(idkp);
return 0; return 0;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment