On Fri, 4 Jan 2002, Petr Nejedly wrote:
Arnd Bergmann wrote:
Am Donnerstag, 3. Januar 2002 22:42 schrieben Sie:
But it sucessfully writes some data before having problems. Well, that part actually _is_ the same with the aha1542 problem, just for a different reason.
I've done some more tests: dd-in exactly 16MB, either in 64kb ok 2kb blocks works perfectly (readback and cmp), but if I try something 64kb unaligned (I was testing dd-in of 260kb), the pktcdvd has problems prereading the rest of the last packet (it shedules reads and then ignores read errors although the medium is perfectly readable using any userland tool). It will then write the data as they are, so if I dd-out 260kb, I'll get written data but the rest of the last packet is empty (zeroes) instead of the original content. The rest of the disk is unchanged.
I have seen some strange problems too on my burner. A read immediately following a write sometimes fails with sense code 70/2/4/8, "LUN not ready, long write in progress". I find this strange since I do not use write caching, so there should be no write in progress after the previous write command has finished. Jens has put in some code in the packet patch to handle this case in scsi_lib.c. The failed command will be retried, and the retry usually works on my drive. Maybe on some drives, this isn't enough to fix the read errors. However, if there are read errors that the module can not fix by retrying, there is no way to avoid data corruption. Either you write the packet and lose the information you couldn't read, or you don't write the packet and lose the information you were going to write.
Is Jens/anybody else actively working on the driver now? (I've seen lots of Jens's work in 2.5.1 so I'm not sure if he still has time to work on pkt layer)
He once wrote that the work in 2.5.1 is required for packet writing to be cleanly implemented (the current approach is more of a hack), but I guess PW is still part of the big picture and will come when the rest has stabilized (a.k.a. not too soon).
So will the 2.5.x effort be ever backported to 2.4?
Probably not. The bio changes broke lots of block device drivers, and backporting all those fixes to 2.4 will be a lot of work.
I think Peter Osterlund is more or less just porting pktcdvd along the kernels but not adding new features.
I am actually working on porting pktcdvd to 2.5. I have a patch for 2.5.2-pre7 which seems to work quite well. There are some things missing, but it is usable at least on my USB writer. The patch is available in this directory: http://w1.894.telia.com/~u89404340/patches/packet/2.5/ If someone wants to try it, please note that the CONFIG_CDROM_PKTCDVD_BUFFERS config option is now being used, and the old default value (256) is much too large to be practical. A better value is probably 4-16. (I will make a real announcement once a few more things have been fixed.) -- Peter Osterlund - petero2@telia.com http://w1.894.telia.com/~u89404340