Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1214142
| From | Tillmann Heidsieck <theidsieck@leenox.de> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | Re: [PATCH] s390/jump_label: Use %*ph to print small buffers |
| Date | 2015-08-26 21:10 +0200 |
| Message-ID | <q1Of8-6fF-15@gated-at.bofh.it> (permalink) |
| References | <q1O5s-5Pg-27@gated-at.bofh.it> |
| Organization | leenox.de |
Hi Alexander,
On 2015-08-26 20:49, Alexander Kuleshov wrote:
> printk() supports %*ph format specifier for printing a small buffers,
> let's use it intead of %02x %02x...
noble effort ...
> pr_emerg("Jump label code mismatch at %pS [%p]\n", ipc, ipc);
> - pr_emerg("Found: %02x %02x %02x %02x %02x %02x\n",
> + pr_emerg("Found: %6ph\n",
> ipc[0], ipc[1], ipc[2], ipc[3], ipc[4], ipc[5]);
> - pr_emerg("Expected: %02x %02x %02x %02x %02x %02x\n",
> + pr_emerg("Expected: %6ph\n",
> ipe[0], ipe[1], ipe[2], ipe[3], ipe[4], ipe[5]);
> - pr_emerg("New: %02x %02x %02x %02x %02x %02x\n",
> + pr_emerg("New: %6ph\n",
> ipn[0], ipn[1], ipn[2], ipn[3], ipn[4], ipn[5]);
> panic("Corrupted kernel text");
> }
... but you might want to check our code before submission (e.g. compile
it!)
Cheers
Tillmann
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH] s390/jump_label: Use %*ph to print small buffers Alexander Kuleshov <kuleshovmail@gmail.com> - 2015-08-26 21:00 +0200
Re: [PATCH] s390/jump_label: Use %*ph to print small buffers Tillmann Heidsieck <theidsieck@leenox.de> - 2015-08-26 21:10 +0200
Re: [PATCH] s390/jump_label: Use %*ph to print small buffers Alexander Kuleshov <kuleshovmail@gmail.com> - 2015-08-26 21:20 +0200
csiph-web