Wouldn't it be natural to
write(fd, <control type>)
write(fd, <control information)
read(fd, reply)
Only one control file for all controls a device understands
>
> Moreover, we have channels that are not tied to a particular device -
> they are for a group of them. Example: setting timings for IDE controller.
> Sure, we can just say "open /dev/hda instead of /dev/hda5", but then we
> are back to the "find related file" problem you tried to avoid.
If the IDE controller is a device we can control, it should have a device
file and a control device file.
Problem solved, AFAICS.
Controlling an IDE controller by writing to a device that's hanging on one
of it's busses is a hack, IMO.
--
................................................................
: jakob@unthought.net : And I see the elder races, :
:.........................: putrid forms of man :
: Jakob Østergaard : See him rise and claim the earth, :
: OZ9ABN : his downfall is at hand. :
:.........................:............{Konkhra}...............:
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/