block: move policy from disk to part0
Move disk->policy to part0->policy. Implement and use get_disk_ro(). Signed-off-by: Tejun Heo <tj@kernel.org> Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
This commit is contained in:
@ -1113,7 +1113,7 @@ static ide_startstop_t cdrom_start_rw(ide_drive_t *drive, struct request *rq)
|
||||
|
||||
if (write) {
|
||||
/* disk has become write protected */
|
||||
if (cd->disk->policy) {
|
||||
if (get_disk_ro(cd->disk)) {
|
||||
cdrom_end_request(drive, 0);
|
||||
return ide_stopped;
|
||||
}
|
||||
|
Reference in New Issue
Block a user