History

Merge tag 'printk-for-6.3' of git://git.kernel.org/pub/scm/linux/kernel/git/printk/linux

Pull printk updates from Petr Mladek: - Refactor printk code for formatting messages that are shown on consoles. This is a preparatory step for introducing atomic consoles which could not share the global buffers - Prevent memory leak when removing printk index in debugfs - Dump also the newest printk message by the sample gdbmacro - Fix a compiler warning * tag 'printk-for-6.3' of git://git.kernel.org/pub/scm/linux/kernel/git/printk/linux: printf: fix errname.c list kernel/printk/index.c: fix memory leak with using debugfs_lookup() printk: Use scnprintf() to print the message about the dropped messages on a console printk: adjust string limit macros printk: use printk_buffers for devkmsg printk: introduce console_prepend_dropped() for dropped messages printk: introduce printk_get_next_message() and printk_message printk: introduce struct printk_buffers console: Document struct console console: Use BIT() macros for @flags values printk: move size limit macros into internal.h docs: gdbmacros: print newest record

Linus Torvalds committed 3 years ago

Commit d8763152 parents cd43b50 392143c7 files · +313 −168Browse files

Showing the changes to lib (1 of 7 files). Show all

Unified · Split

lib/errname.c+14−8
@@ -21,6 +21,7 @@ static const char *names_0[] = { · 20 unmodified lines
2121 E(EADDRNOTAVAIL),
2222 E(EADV),
2323 E(EAFNOSUPPORT),
24+ E(EAGAIN), /* EWOULDBLOCK */
2425 E(EALREADY),
2526 E(EBADE),
2627 E(EBADF),
@@ -31,15 +32,17 @@ static const char *names_0[] = { · 4 unmodified lines
3132 E(EBADSLT),
3233 E(EBFONT),
3334 E(EBUSY),
34−#ifdef ECANCELLED
35− E(ECANCELLED),
36−#endif
35+ E(ECANCELED), /* ECANCELLED */
3736 E(ECHILD),
3837 E(ECHRNG),
3938 E(ECOMM),
4039 E(ECONNABORTED),
40+ E(ECONNREFUSED), /* EREFUSED */
4141 E(ECONNRESET),
42+ E(EDEADLK), /* EDEADLOCK */
43+#if EDEADLK != EDEADLOCK /* mips, sparc, powerpc */
4244 E(EDEADLOCK),
45+#endif
4346 E(EDESTADDRREQ),
4447 E(EDOM),
4548 E(EDOTDOT),
@@ -166,14 +169,17 @@ static const char *names_0[] = { · 120 unmodified lines
166169 E(EUSERS),
167170 E(EXDEV),
168171 E(EXFULL),
169−
170− E(ECANCELED), /* ECANCELLED */
171− E(EAGAIN), /* EWOULDBLOCK */
172− E(ECONNREFUSED), /* EREFUSED */
173− E(EDEADLK), /* EDEADLOCK */
174172 };
175173 #undef E
176174
175+#ifdef EREFUSED /* parisc */
176+static_assert(EREFUSED == ECONNREFUSED);
177+#endif
178+#ifdef ECANCELLED /* parisc */
179+static_assert(ECANCELLED == ECANCELED);
180+#endif
181+static_assert(EAGAIN == EWOULDBLOCK); /* everywhere */
182+
177183 #define E(err) [err - 512 + BUILD_BUG_ON_ZERO(err < 512 || err > 550)] = "-" #err
178184 static const char *names_512[] = {
179185 E(ERESTARTSYS),

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t