media: cec: return -ENODEV instead of -ENXIO if unregistered
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Fri, 23 Feb 2024 09:08:47 +0000 (10:08 +0100)
committerHans Verkuil <hverkuil-cisco@xs4all.nl>
Wed, 24 Apr 2024 11:49:55 +0000 (13:49 +0200)
commitdd05fd125e66932e54da696f33f0cee51d4f8e95
tree35be9fea16ea6f47f14707293850299e3f236bcc
parent1ed4477f2ea4743e7c5e1f9f3722152d14e6eeb1
media: cec: return -ENODEV instead of -ENXIO if unregistered

If the CEC device is unregistered, then an attempt to open
the device node should result in an -ENODEV error instead of
-ENXIO.

Document this as well in cec-func-open.rst.

This is consistent with the error code returned by other
file operations such as ioctl.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Documentation/userspace-api/media/cec/cec-func-open.rst
drivers/media/cec/core/cec-core.c