Scsi tape write protect status question
Sorry to bother you all with such an easy thing. I can't figure out how the kernel knows I have a write protected tape in a drive that I open via
open("/dev/st0", O_RDWR, cf_flg, 0666)
Using the sgio interface I can only sense a write protect status after attempting to to a write.
How can one know this before doing a write op?
Thanks in advance
Mark
Quoted 5 lines · Mark Hounschell
Sorry to bother you all with such an easy thing. I can't figure out how the
kernel knows I have a write protected tape in a drive that I open via
open("/dev/st0", O_RDWR, cf_flg, 0666)
Sorry for the typo
open("/dev/st0", O_RDWR, 0666)
Quoted 12 lines
Using the sgio interface I can only sense a write protect status after attempting to to a write.
How can one know this before doing a write op?Thanks in advance
Mark
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 5 lines · Mark Hounschell
Quoted 4 lines · Mark Hounschell
Sorry to bother you all with such an easy thing. I can't figure out how the
kernel knows I have a write protected tape in a drive that I open via
Quoted 10 lines
Quoted 1 line
open("/dev/st0", O_RDWR, cf_flg, 0666)Sorry for the typo
open("/dev/st0", O_RDWR, 0666)Quoted 4 lines
Using the sgio interface I can only sense a write protect status after attempting to to a write.
How can one know this before doing a write op?
Never mind, it's in the mode-sense data.
Mark