[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: CVS commit: src/sys/dev/ic/dp8390.c
On Sun, Feb 24, 2008 at 04:33:58PM +0100, Christoph Badura wrote:
> On Sat, Feb 23, 2008 at 02:26:53AM +0000, David Young wrote:
> > Modified Files:
> > src/sys/dev/ic: dp8390.c
> > Log Message:
> > ENODEV and ENOTTY are appropriate error codes for indicating
> > unsupported ioctls, but EINVAL is definitely not! If an operation
> > is not supported, return ENODEV instead of EINVAL.
> ENOTTY is the standard error code to return when the device doesn't support
> an ioctl. Shouldn't you return that?
I think that it depends. According to my interpretation, we should
return ENOTTY if an ioctl is not supported by this ethernet or any other
ethernet, and ENODEV if this particular ethernet does not support the
ioctl, but some ethernet may. I.e., if I call DIOCGPART on an ethernet,
then ENOTTY. If I call SIOCSIFMTU on an ethernet that does not support
it, then ENODEV. Make sense?
I will be revisiting this issue as I work some more on the interface
ioctls. I have read a lot of ioctl routines by now, and they are very,
David Young OJC Technologies
dyoung%ojctech.com@localhost Urbana, IL * (217) 278-3933 ext 24
Main Index |
Thread Index |