|
From: | Robert Kausch |
Subject: | Re: [Libcdio-devel] problems with libcdio on openbsd (and probably netbsd too) |
Date: | Sun, 27 May 2018 15:17:10 +0200 |
User-agent: | Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.0 |
Am 27.05.2018 um 14:52 schrieb Thomas Schmitt:
Is there documentation about what a raw partition can do which the others cannot ?
I don't know, sorry. I'm not a NetBSD developer. Just ported fre:ac to the BSDs back then and most of my knowledge is from trying it out and/or reading the source code.
libburn tries with 'c' and 'd' : fd = open(path, O_RDWR | O_NDELAY); ... ret = ioctl(fd, SCIOCIDENTIFY, &addr); and wants to see after successful ioctl(): addr.type == TYPE_SCSIFrom then on, the drive is regarded as usable for SCSI transactionsvia ioctl(SCIOCCOMMAND). Is this too daring ?
I *think* this should work, but it would probably be better to use 'a' + RAW_PART. Two reasons:
1. Future architectures might define RAW_PART to 4 or something else, so you'd suddenly get devices like /dev/rcd0e on such systems. 2. Not sure if it's actually possible, but on architectures with RAW_PART == 3 there might still be a /dev/rcd0c device in some cases, but with a different meaning. Treating it like a raw disc device could possibly cause bad things to happen.
---- Robert Kausch address@hidden
[Prev in Thread] | Current Thread | [Next in Thread] |