diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2012-02-08 14:03:14 -0500 |
---|---|---|
committer | Jens Axboe <axboe@kernel.dk> | 2012-02-08 14:03:14 -0500 |
commit | cdccaa9467b982d57b139818d15e1e994feca372 (patch) | |
tree | 573e6aa79bce8105b3a2508a462d03368ac5214c /include/linux/cdrom.h | |
parent | 37b40adf2d1b4a5e51323be73ccf8ddcf3f15dd3 (diff) |
cdrom: move shared static to cdrom_device_info
The keeplocked variable in the cdrom driver is shared across multiple
drives, but set in per-device ioctls. Move it to the per-device struct,
avoiding that the setting on one drive affects the driver's behavior
when closing another.
[ Impact: limit udev's confusion to one drive when a CD burning program
unlocks the CD door at the end of burning. ]
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/linux/cdrom.h')
-rw-r--r-- | include/linux/cdrom.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/include/linux/cdrom.h b/include/linux/cdrom.h index 35eae4b67503..7c48029dffe6 100644 --- a/include/linux/cdrom.h +++ b/include/linux/cdrom.h | |||
@@ -952,7 +952,8 @@ struct cdrom_device_info { | |||
952 | char name[20]; /* name of the device type */ | 952 | char name[20]; /* name of the device type */ |
953 | /* per-device flags */ | 953 | /* per-device flags */ |
954 | __u8 sanyo_slot : 2; /* Sanyo 3 CD changer support */ | 954 | __u8 sanyo_slot : 2; /* Sanyo 3 CD changer support */ |
955 | __u8 reserved : 6; /* not used yet */ | 955 | __u8 keeplocked : 1; /* CDROM_LOCKDOOR status */ |
956 | __u8 reserved : 5; /* not used yet */ | ||
956 | int cdda_method; /* see flags */ | 957 | int cdda_method; /* see flags */ |
957 | __u8 last_sense; | 958 | __u8 last_sense; |
958 | __u8 media_written; /* dirty flag, DVD+RW bookkeeping */ | 959 | __u8 media_written; /* dirty flag, DVD+RW bookkeeping */ |