lkml.org 
[lkml]   [2003]   [Oct]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: PROBLEM: Impossible to read files from a CD-Rom
Hi,

Le ven 12 sep 2003 11:58:25 GMT, Samuel Thibault a tapoté sur son clavier :
> Le ven 12 sep 2003 08:51:16 GMT, Jens Axboe a tapoté sur son clavier :
>
> > This basically boils down to a typical problem with CDROM/DVD drives -
> > some specific structure may vary a little in size depending on when in
> > the spec cycle they were implemented. Some drives barf if you try and
> > read to much, some when you read too little. So the approach that
> > typically works the best is to just read the very first of the
> > structure, check the length, and issue a read for the complete data.
>
> This is fine. Another solution would be that cdrom_get_track_info returns
> the actual amount of data that was read, so that the caller may check
> that the field it needs was really filled up.

I tested this and it worked fine.

> > I'd be more interested in fixing the real bug: why does your drive
> > return zero length, and only sporadically?

Not sporadically, it always returns the same amount of data, but this
amount is not sufficient to give the size, so that an arbitrary size is
taken. The function should see that and report an error instead, which
will fix the problem we had by trigging another size discovery mean.

Regards,
Samuel Thibault
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:49    [W:0.123 / U:0.832 seconds]
©2003-2014 Jasper Spaans. Advertise on this site