2023-08-07 05:21:48

by Bhaskar Chowdhury

[permalink] [raw]
Subject: [PATCH]upi:media: Added rest of the Generic Error Codes to the existing list

Added rest of the Generic Error Codes to the existing list of codes.

cc: [email protected]
cc: [email protected]
cc: [email protected]
cc: [email protected]
cc: [email protected]

Signed-off-by: Bhaskar Chowdhury <[email protected]>
---
There is a "moreutils" package across the Linux distribution, if you
installed it and that package has a binary name "errno",if you run it with
"-l" or "--list" option, it will show all the error codes.In my system, while
running it shows me precisely, 134 of such codes.YMMV

.../userspace-api/media/gen-errors.rst | 479 ++++++++++++++++++
1 file changed, 479 insertions(+)

diff --git a/Documentation/userspace-api/media/gen-errors.rst b/Documentation/userspace-api/media/gen-errors.rst
index e595d0bea109..2d5dd8f7faea 100644
--- a/Documentation/userspace-api/media/gen-errors.rst
+++ b/Documentation/userspace-api/media/gen-errors.rst
@@ -85,6 +85,485 @@ Generic Error Codes
- No device corresponding to this device special file exists.


+ - - ``ENOENT``
+
+ - No such file or directory.
+
+ - - ``ESRCH``
+
+ - No such process.
+
+ - - ``EIO``
+
+ - Input/output error.
+
+ - - ``E2BIG``
+
+ - Argument list too long.
+
+ - - ``ENOEXEC``
+
+ - Exec format error.
+
+ - - ``ECHILD``
+
+ - No child processes.
+
+ - - ``EACCES``
+
+ - Permission denied.
+
+ - - ``ENOTBLK``
+
+ - Block device required.
+
+ - - ``EEXIST``
+
+ - File Exists.
+
+ - - ``EXDEV``
+
+ - Invalid cross device link.
+
+ - - ``ENOTDIR``
+
+ - Not a directory.
+
+ - - ``EISDIR``
+
+ - Is a directory.
+
+ - - ``ENFILE``
+
+ - Too many open files in system.
+
+ - - ``EMFILE``
+
+ - Too many open files.
+
+ - - ``ETXTBSY``
+
+ - Text file busy.
+
+ - - ``EFBIG``
+
+ - File too large.
+
+ - - ``ESPIPE``
+
+ - Illegal seek.
+
+ - - ``EROFS``
+
+ - Read-only file system.
+
+ - - ``EMLINK``
+
+ - Too many links.
+
+ - - ``EPIPE``
+
+ - Broken pipe.
+
+ - - ``EDOM``
+
+ - Numerical argument out of domain.
+
+ - - ``ERANGE``
+
+ - Numerical result out of range.
+
+ - - ``EDEADLK``
+
+ - Resourse deadlock avoided.
+
+ - - ``ENAMETOOLONG``
+
+ - File name too long.
+
+ - - ``ENOLCK``
+
+ - No locks available.
+
+ - - ``ENOSYS``
+
+ - Function not implemented.
+
+ - - ``ENOTEMPTY``
+
+ - Directory not empty.
+
+ - - ``ELOOP``
+
+ - Too many levels of symbolic links.
+
+ - - ``ENOMSG``
+
+ - No message of desired type.
+
+ - - ``EIDRM``
+
+ - Identifier removed.
+
+ - - ``ECHRNG``
+
+ - Channel number out of range.
+
+ - - ``EL2NSYNC``
+
+ - Level 2 not syncronized.
+
+ - - ``EL3HLT``
+
+ - Level 3 halted.
+
+ - - ``EL3RST``
+
+ - Level 3 reset.
+
+ - - ``ELNRNG``
+
+ - Link number out of range.
+
+ - - ``EUNATCH``
+
+ - Protocol driver not attached.
+
+ - - ``ENOCSI``
+
+ - No CSI structure available.
+
+ - - ``EL2HLT``
+
+ - Level 2 halted.
+
+ - - ``EBADE``
+
+ - Invalid exchnage.
+
+ - - ``EBDR``
+
+ - Invalid request descriptor.
+
+ - - ``EXFULL``
+
+ - Exchange full.
+
+ - - ``ENOANO``
+
+ - No anode.
+
+ - - ``EBADRQC``
+
+ - Invalid request code.
+
+ - - ``EBADSLT``
+
+ - Invalid slot.
+
+ - - ``EBFONT``
+
+ - Bad font file format.
+
+ - - ``ENOSTR``
+
+ - Device not a stream.
+
+ - - ``ENODATA``
+
+ - No data available.
+
+ - - ``ETIME``
+
+ - Time expired.
+
+ - - ``ENOSR``
+
+ - Out of stream resources.
+
+ - - ``ENONET``
+
+ - Machine is not on the network.
+
+ - - ``ENOPKG``
+
+ - Package not installed.
+
+ - - ``EREMOTE``
+
+ - Object is remote.
+
+ - - ``ENOLINK``
+
+ - Link has been severed.
+
+ - - ``EADV``
+
+ - Advertise error.
+
+ - - ``ESRMNT``
+
+ - Srmount error.
+
+ - - ``ECOMM``
+
+ - Communication error on send.
+
+ - - ``EPROTO``
+
+ - Protocol error.
+
+ - - ``EMULTIHOP``
+
+ - Multihop attempted.
+
+ - - ``EDOTDOT``
+
+ - RFS specific error.
+
+ - - ``EBADMSG``
+
+ - Bad message.
+
+ - - ``EOVERFLOW``
+
+ - Value too large for defined data type.
+
+ - - ``ENOTUNIQ``
+
+ - Name not uniq on network.
+
+ - - ``EBADFD``
+
+ - File descriptor in bad state.
+
+ - - ``EREMCHG``
+
+ - Remote address changed.
+
+ - - ``ELIBACC``
+
+ - Can not access a needed shared library.
+
+ - - ``ELIBBAD``
+
+ - Accessing a corrupted shared library.
+
+ - - ``ELIBSCN``
+
+ - .lib section in a.out corrupted.
+
+ - - ``ELIBMAX``
+
+ - Attempting to link in too many shared libraries.
+
+ - - ``ELIBEXEC``
+
+ - Can not exec a shared library directly.
+
+ - - ``ELIBSEQ``
+
+ - Invalid or incomplete multibyte or wide character.
+
+ - - ``ERESTART``
+
+ - Interrupted system call should be restarted.
+
+ - - ``ESTRPIPE``
+
+ - Stream pipe error.
+
+ - - ``EUSERS``
+
+ - Too many users.
+
+ - - ``ENOTSOCK``
+
+ - Socker operation on non-socket.
+
+ - - ``EDESTADDREQ``
+
+ - Destination address required.
+
+ - - ``EMSGSIZE``
+
+ - Message too long.
+
+ - - ``EPROTOTYPE``
+
+ - protocol wrong type for socket.
+
+ - - ``ENOPROTOOPT``
+
+ - Protocol not available.
+
+ - - ``EPROTNOSUPPORT``
+
+ - Protocol not supported.
+
+ - - ``ESOCKTNOSUPPORT``
+
+ - Socket type not supported.
+
+ - - ``EOPNOTSUPP``
+
+ - Operation not supported.
+
+ - - ``EPFNOSUPPORT``
+
+ - Protocol family not supported.
+
+ - - ``EAFNOSUPPORT``
+
+ - Address family not supported by protocol.
+
+ - - ``EADDRINUSE``
+
+ - Address already in use.
+
+ - - ``EADDRNOTAVAIL``
+
+ - Cannot assign requested address.
+
+ - - ``ENETDOWN``
+
+ - Network is down.
+
+ - - ``ENETUNREACH``
+
+ - Network is unreachable.
+
+ - - ``ENETRESET``
+
+ - Network dropped connection on reset.
+
+ - - ``ECONNABORTED``
+
+ - Software caused connection abort.
+
+ - - ``ECONNRESET``
+
+ - Connection reset by peer.
+
+ - - ``ENOBUFS``
+
+ - No buffer space available.
+
+ - - ``EISCONN``
+
+ - Transport endpoint is already connected.
+
+ - - ``ENOTCONN``
+
+ - Transport endpoint is not connected.
+
+ - - ``ESHUTDOWN``
+
+ - Cannot send after transport endpoint shutdown.
+
+ - - ``ETOOMANYREFS``
+
+ - Too many references: cannot splice.
+
+ - - ``ETIMEDOUT``
+
+ - Connection timed out.
+
+ - - ``ECONNREFUSED``
+
+ - Connection refused.
+
+ - - ``EHOSTDOWN``
+
+ - Host is down.
+
+ - - ``EHOSTUNREACH``
+
+ - No route to host.
+
+ - - ``EALREADY``
+
+ - Operation already in progress.
+
+ - - ``EINPROGRESS``
+
+ - Operation now in progress.
+
+ - - ``ESTALE``
+
+ - Stale file handle.
+
+ - - ``EUCLEAN``
+
+ - Structure needs cleaning.
+
+ - - ``ENOTNAM``
+
+ - Not a XENIX named type file.
+
+ - - ``ENAVAIL``
+
+ - No XENIX semaphores available.
+
+ - - ``EISNAM``
+
+ - Is a named type file.
+
+ - - ``EREMOTEIO``
+
+ - Remote I/O error.
+
+ - - ``EDQUOT``
+
+ - Disk quota exceeded.
+
+ - - ``ENOMEDIUM``
+
+ - No medium found.
+
+ - - ``EMEDIUMTYPE``
+
+ - Wrong medium type.
+
+ - - ``ECANCELED``
+
+ - Operation canceled.
+
+ - - ``ENOKEY``
+
+ - Required key not available.
+
+ - - ``EKEYEXPIRED``
+
+ - Key has expired.
+
+ - - ``EKEYREVOKED``
+
+ - Key has been revoked.
+
+ - - ``EKEYREJECTED``
+
+ - Key was rejected by service.
+
+ - - ``EOWNERDEAD``
+
+ - Owner died.
+
+ - - ``ENOTRECOVERABLE``
+
+ - State not recoverable.
+
+ - - ``ERFKILL``
+
+ - Operation not possible due to RF-kill.
+
+ - - ``EHWPOISON``
+
+ - Memory page has hardware error.
+
+ - - ``ENOTSUP``
+
+ - Operation not supported.
.. note::

#. This list is not exhaustive; ioctls may return other error codes.
--
2.41.0



2023-08-07 19:36:24

by Jonathan Corbet

[permalink] [raw]
Subject: Re: [PATCH]upi:media: Added rest of the Generic Error Codes to the existing list

Bhaskar Chowdhury <[email protected]> writes:

> Added rest of the Generic Error Codes to the existing list of codes.
>
> cc: [email protected]
> cc: [email protected]
> cc: [email protected]
> cc: [email protected]
> cc: [email protected]
>
> Signed-off-by: Bhaskar Chowdhury <[email protected]>
> ---
> There is a "moreutils" package across the Linux distribution, if you
> installed it and that package has a binary name "errno",if you run it with
> "-l" or "--list" option, it will show all the error codes.In my system, while
> running it shows me precisely, 134 of such codes.YMMV
>
> .../userspace-api/media/gen-errors.rst | 479 ++++++++++++++++++
> 1 file changed, 479 insertions(+)

This document is a list of errors that can be returned by media drivers,
with a focus on what those errors mean in the media context. What is
the point of stuffing it full of error numbers that media drivers will
never return, along with generic, one-line descriptions? I'll defer to
the media folks on this, but I don't think this helps their users.

Thanks,

jon

2023-08-20 11:11:01

by Hans Verkuil

[permalink] [raw]
Subject: Re: [PATCH]upi:media: Added rest of the Generic Error Codes to the existing list

On 07/08/2023 20:12, Jonathan Corbet wrote:
> Bhaskar Chowdhury <[email protected]> writes:
>
>> Added rest of the Generic Error Codes to the existing list of codes.
>>
>> cc: [email protected]
>> cc: [email protected]
>> cc: [email protected]
>> cc: [email protected]
>> cc: [email protected]
>>
>> Signed-off-by: Bhaskar Chowdhury <[email protected]>
>> ---
>> There is a "moreutils" package across the Linux distribution, if you
>> installed it and that package has a binary name "errno",if you run it with
>> "-l" or "--list" option, it will show all the error codes.In my system, while
>> running it shows me precisely, 134 of such codes.YMMV
>>
>> .../userspace-api/media/gen-errors.rst | 479 ++++++++++++++++++
>> 1 file changed, 479 insertions(+)
>
> This document is a list of errors that can be returned by media drivers,
> with a focus on what those errors mean in the media context. What is
> the point of stuffing it full of error numbers that media drivers will
> never return, along with generic, one-line descriptions? I'll defer to
> the media folks on this, but I don't think this helps their users.

Indeed, this documents just the media-specific errors, there is no point
in listing all errors here.

Regards,

Hans