Date: Wed, 2 Mar 2022 11:23:11 +0700 From: Eugene Grosbein <eugen@grosbein.net> To: Wojciech Puchar <wojtek@puchar.net>, freebsd-hackers@freebsd.org Subject: Re: problem with USB-CD drive Message-ID: <21050393-470a-8539-1324-3482d64c4870@grosbein.net> In-Reply-To: <197d435-6c4b-a60-4e6f-ea4ee515b8f4@puchar.net> References: <197d435-6c4b-a60-4e6f-ea4ee515b8f4@puchar.net>
next in thread | previous in thread | raw e-mail | index | archive | help
21.02.2022 17:44, Wojciech Puchar wrote: > i can read sectors by dd, by single (bs=2k) or multiple. > Other communication (vendor specific SCSI commands - used to configure/control the device with our software) - works properly. > If i make an image (first 34 sectors, device presents itself as 16MB > to prevent problems with some OSes but everything later are zeros) - it is good - did cmp with original image file. > > i can do mdconfig, mount_cd9660 on this file and everything is fine. > > > BUT > > mount_cd9660 /dev/cd1 /mnt > > results in: > > mount_cd9660: /dev/cd1: Invalid argument > > There is no kernel messages. > > How could i find out what is exactly a problem? It looks like the device or driver do not like size of reading request, f.e. short read. It should be possible to verify that using several ways: 1) run "ktrace -i mount_cd9660 ..." then study ouput of kdump; 2) enable debug logs at GEOM level, use sysctl kern.geom.debugflags=255 (beware of large amount of logs) then run mount_cd9660 3) use gcache(8) that is capable of limiting minimum request size by caching "extra" data, but try using only single gcache(8) instance per system because of known instability in the gcache code when you create multiple geom_cache's.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?21050393-470a-8539-1324-3482d64c4870>