Corrected the format constant (its 0010b) and set the msf bit to 1. MMC Specs say it shall not have an effect on the result, but it also states that the time bit shall be set to 1.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@14483 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Michael Lotz 2005-10-23 23:24:10 +00:00
parent 106d748c45
commit d9c69ef133
2 changed files with 4 additions and 5 deletions

View File

@ -818,7 +818,6 @@ static
void
dump_full_table_of_contents(uchar *data, uint16 data_length)
{
return;
cdrom_table_of_contents_header *header;
cdrom_full_table_of_contents_entry *entries;
int i, count;
@ -888,8 +887,8 @@ read_table_of_contents(int deviceFD, uint32 first_session, uchar *buffer,
// Init the scsi command and copy it into the BeOS "raw scsi command" ioctl struct
memset(raw_command.command, 0, 16);
scsi_command.command = 0x43;
scsi_command.msf = 0;
scsi_command.format = 2;
scsi_command.msf = 1;
scsi_command.format = kFullTableOfContentsFormat;
scsi_command.number = first_session;
scsi_command.length = B_HOST_TO_BENDIAN_INT16(buffer_length);
scsi_command.control = 0;

View File

@ -70,7 +70,7 @@ typedef struct {
// Some of the possible "READ TOC/PMA/ATIP" formats
const uint8 kTableOfContentsFormat = 0x00;
const uint8 kSessionFormat = 0x01;
const uint8 kFullTableOfContentsFormat = 0x10; //!< "READ TOC/PMA/ATIP" format of interest
const uint8 kFullTableOfContentsFormat = 0x02; //!< "READ TOC/PMA/ATIP" format of interest
/*! \brief Minutes:Seconds:Frames format address
@ -138,7 +138,7 @@ typedef struct {
} cdrom_table_of_contents_entry;
/*! \brief Type of entries returned by "READ TOC/PMA/ATIP" when called with format
\c kFullTableOfContentsFormat == 0x10
\c kFullTableOfContentsFormat == 0x02
*/
typedef struct {
uint8 session;