summaryrefslogtreecommitdiffstats
path: root/fs
diff options
context:
space:
mode:
authorAhmad Fatoum <a.fatoum@pengutronix.de>2019-11-26 11:56:59 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2019-11-27 14:39:33 +0100
commitbafb8da8e48716810331ecbd78dee7e2912d1c3e (patch)
tree9622ebfe081083c2ef0bb17a2f29d551ca44a524 /fs
parentc7ec778bbe2527254c2a05f990bb632c72d94563 (diff)
downloadbarebox-bafb8da8e48716810331ecbd78dee7e2912d1c3e.tar.gz
barebox-bafb8da8e48716810331ecbd78dee7e2912d1c3e.tar.xz
pstore: fix build by re-resolving botched merge conflict
297ac7288 ("pstore: Only capture log messages") removed the pstore console. v3 of the eventually merged 75a74b5c ("console: fix out-of-bounds read in dputc(/dev/*, ...)") reinstated part of this code, which broke the pstore build because the now removed bufsize member had a user reintroduced in the patch. Fix this by reverting the offending patch's changes to the pstore code. It wasn't applicable to begin with. Fixes: 75a74b5c ("console: fix out-of-bounds read in dputc(/dev/*, ...)") Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'fs')
-rw-r--r--fs/pstore/platform.c29
1 files changed, 0 insertions, 29 deletions
diff --git a/fs/pstore/platform.c b/fs/pstore/platform.c
index 15c0174b1f..0a6fa38edc 100644
--- a/fs/pstore/platform.c
+++ b/fs/pstore/platform.c
@@ -46,35 +46,6 @@ void pstore_set_kmsg_bytes(int bytes)
static int pstore_ready;
-static void pstore_console_write(const char *s, unsigned c)
-{
- const char *e = s + c;
-
- while (s < e) {
- struct pstore_record record = {
- .type = PSTORE_TYPE_CONSOLE,
- .psi = psinfo,
- };
-
- if (c > psinfo->bufsize)
- c = psinfo->bufsize;
-
- record.buf = (char *)s;
- record.size = c;
- psinfo->write_buf(PSTORE_TYPE_CONSOLE, 0, &record.id, 0,
- record.buf, 0, record.size, psinfo);
- s += c;
- c = e - s;
- }
-}
-
-static int pstore_console_puts(struct console_device *cdev, const char *s,
- size_t nbytes)
-{
- pstore_console_write(s, nbytes);
- return nbytes;
-}
-
void pstore_log(const char *str)
{
uint64_t id;