Add support for LKM operation.
Change M_NOWAIT on buffer memory allocation to M_WAIT in hopes we'll be
able to get ourselves a nice fat buffer from the kernel if we suspend.
Note: The LKM support looks kinda screwy in two areas, where I found
problems with the kernel proper. First, calling dev_attach()
at module load time will cause a panic. I haven't investigated.
Secondly, I had to manually call qcam_drvinit() to register the
device softc structure by hand at module load time. This seems
bogus, it should be called as a core part of the module load
process for character/block device drivers.
- split driver into FreeBSD specific and camera specific portions
(qcamio.c can run in user mode, with a Linux "driver top" etc,
and qcam.c should be trivial to port to NetBSD and BSDI.)
- support for 4bppand bidirectional transfers working better
- start of interleaved data-transfers byte-stream decodes (some of this
stuff has been pulled out for the moment to make it easier to debug)
At this point, anyone who wants to port it to other platforms should feel
free to do so. Please feed changes directly back to me so that I can produce
a unified distribution.