Mail Archives: cygwin-developers/1998/09/17/05:45:31
Why not have the /dev file contain the name of the dll?
!<device>dllname major minor type other-parms
Example:
/dev/audio:
!<device>cygaudio.dll 9 0 c dsp-codec 44100 16
All the parameters after the dll name would be passed as argv[]
(paramv[] ?) to the dll "open" function, allowing additional
parameters on a dll-by-dll basis.
This syntax also eliminates the need to search the directory for
matching dll names, and avoids conflicts between, say, foo.1.dll and
bar.1.dll.
For mknod, we'd need to maintain or document a major-to-dll mapping
file, like "majors.txt" or "cygmaj.txt":
1 cygnull.dll
2 djfake.dll
9 cygaudio.dll
Or, we can let mknod scan the dlls and have the dlls include a
function that returns their major numbers.
> The interface is a generalized fhandler class.
Ooo, I like that.
- Raw text -