Bug fix: ATA and SATA drives under sg did not register their SCSI address tuple
This commit is contained in:
parent
6fb158b56d
commit
a63fa82724
@ -1 +1 @@
|
||||
#define Cdrskin_timestamP "2024.04.27.162735"
|
||||
#define Cdrskin_timestamP "2024.09.15.141244"
|
||||
|
@ -1367,11 +1367,18 @@ static int fname_enumerate(char *fname, int flag)
|
||||
is_ata = is_ata_drive(fname, fd);
|
||||
if (is_ata < 0)
|
||||
{ret = -1; goto ex;}
|
||||
if (!is_ata)
|
||||
if (is_ata) {
|
||||
/* In most cases Linux returns SCSI bus,...,lun even for
|
||||
ATA and SATA drives
|
||||
*/
|
||||
sg_obtain_scsi_adr_fd(fname, fd, &bus_no, &host_no,
|
||||
&channel_no, &target_no, &lun_no);
|
||||
} else {
|
||||
is_scsi = is_scsi_drive(fname, fd, &bus_no, &host_no,
|
||||
&channel_no, &target_no, &lun_no);
|
||||
if (is_scsi < 0)
|
||||
{ret = -1; goto ex;}
|
||||
if (is_scsi < 0)
|
||||
{ret = -1; goto ex;}
|
||||
}
|
||||
if (is_ata == 0 && is_scsi == 0)
|
||||
{ret = 0; goto ex;}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user