Skip to contentSkip to conversation

lib: errno: sync error codes

PATCH New Heinrich Schuchardt 2 participants 2 messages Oct 6, 2019 – Nov 1, 2019 Library code

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 lib: errno: sync error codes

Macro ERRNO_MSG() ignores the error number but we should still use the same constants as in include/linux/errno.h.

---
 lib/errno_str.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
lib/errno_str.c +2 -2
index 0ba950e970..fbe56395d1 100644
@@ -13,7 +13,7 @@
 static const char * const errno_message[] = {
 	ERRNO_MSG(0, "Success"),
 	ERRNO_MSG(EPERM, "Operation not permitted"),
-	ERRNO_MSG(ENOEN, "No such file or directory"),
+	ERRNO_MSG(ENOENT, "No such file or directory"),
 	ERRNO_MSG(ESRCH, "No such process"),
 	ERRNO_MSG(EINTR, "Interrupted system call"),
 	ERRNO_MSG(EIO, "I/O error"),
@@ -26,7 +26,7 @@ static const char * const errno_message[] = {
 	ERRNO_MSG(ENOMEM, "Out of memory"),
 	ERRNO_MSG(EACCES, "Permission denied"),
 	ERRNO_MSG(EFAULT, "Bad address"),
-	ERRNO_MSG(ENOTBL, "Block device required"),
+	ERRNO_MSG(ENOTBLK, "Block device required"),
 	ERRNO_MSG(EBUSY, "Device or resource busy"),
 	ERRNO_MSG(EEXIST, "File exists"),
 	ERRNO_MSG(EXDEV, "Cross-device link"),

--
2.23.0

#1 lore raw

PATCH 1/1 lib: errno: sync error codes

Quoted 4 lines · Heinrich Schuchardt

Macro ERRNO_MSG() ignores the error number but we should still use the same constants as in include/linux/errno.h.

Applied to u-boot/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20191101/d09d8adc/attachment.sig>