On Wed, 31 Jan 2007, Oliver Neukum wrote: > Hi, > > could you please test this with your storage device. It tries to implement > a heuristics which will work with both versions of the firmware. > > Regards > Oliver
If some other device ends up needing this in the future, what makes you think the heuristic you have chosen will be appropriate? > + /* Some devices have version which report the correct sizes > + * and others which do not. We guess size according toa heuristic > + * and err on the side of lowering the capacity. */ > + if (sdp->guess_capacity) The patch doesn't define sdp->guess_capacity anywhere. > + if (sdkp->capacity % 63 || sdkp->capacity % 255) > + --sdkp->capacity; This is a strange computation. You avoid decrementing the capacity iff it is already divisible both by 63 and by 255. Maybe you really want to use && rather than || ? The idea being, I presume, that the last partition will extend only as far as a pseudo-cylinder boundary. Alan Stern ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys - and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ [email protected] To unsubscribe, use the last form field at: https://lists.sourceforge.net/lists/listinfo/linux-usb-devel
