On Thu, Jan 03, 2019 at 03:54:26PM +0800, Anand Jain wrote:
> > I think this should reflect the status of the operation. The ioctl
> > caller has no information about success/error. Eg. an invalid device
> > path passed could return -ENOENT, 0 if it was released and 1 if not.
> > 
> > In case of all devices, it's probably ok to return 0.
> 
> OK. v13 will return error if the given device is not found,
> and I find ENXIO is more suitable (instead of ENOENT).
> If you disagree pls can you make the changes as in [1]
> when integrating. I have tested with both.

ENXIO refers to device nodes, however for paths it should be ok to use
ENOENT, same what would eg. stat return on the given device path.

The ENXIO is used for lseek and is documented as such, I'd rather stick
to semantics of 'file' even though it's a path to a device.

Reply via email to