diff mbox

[4/6] staging: android: persistent_ram: Move to fs/pstore/ram_core.c

Message ID 20120517005014.GA333@lizard
State New
Headers show

Commit Message

Anton Vorontsov May 17, 2012, 12:50 a.m. UTC
On Wed, May 16, 2012 at 08:05:50AM -0700, Greg Kroah-Hartman wrote:
[...]
> After applying this patch, and building things, I get the following
> errors:
> 
> drivers/built-in.o: In function `ram_console_write':
> ram_console.c:(.text+0x1690b9): undefined reference to `persistent_ram_write'
> drivers/built-in.o: In function `ram_console_read_old':
> ram_console.c:(.text+0x1690f7): undefined reference to `persistent_ram_old_size'
> ram_console.c:(.text+0x169103): undefined reference to `persistent_ram_old'
> ram_console.c:(.text+0x169136): undefined reference to `persistent_ram_ecc_string'
> ram_console.c:(.text+0x169177): undefined reference to `persistent_ram_ecc_string'
> drivers/built-in.o: In function `ram_console_probe':
> ram_console.c:(.init.text+0xc9ea): undefined reference to `persistent_ram_init_ringbuffer'
> drivers/built-in.o: In function `ram_console_late_init':
> ram_console.c:(.init.text+0xca6c): undefined reference to `persistent_ram_old_size'
> ram_console.c:(.init.text+0xcaa2): undefined reference to `persistent_ram_free_old'
> ram_console.c:(.init.text+0xcab4): undefined reference to `persistent_ram_old_size'
> ram_console.c:(.init.text+0xcac3): undefined reference to `persistent_ram_ecc_string'
> make: *** [.tmp_vmlinux1] Error 1
> 
> What went wrong?

I believe that error caused by two missing bytes: '=' and 'y'. :-)
RAM_CONSOLE is a bool, so it should be enabled only when PSTORE_RAM
is also =y. (For some reason I keep foregetting that bool's 'depends on'
may be satisfied by tristates' =m option, which easily lead to the
errors above.)

Thanks for catching this!

I've applied the following hunk to this patch and will resend the left
over patches soon:
diff mbox

Patch

diff --git a/drivers/staging/android/Kconfig b/drivers/staging/android/Kconfig
index 4bfcceb..0e16b59 100644
--- a/drivers/staging/android/Kconfig
+++ b/drivers/staging/android/Kconfig
@@ -27,7 +27,7 @@  config ANDROID_LOGGER
 
 config ANDROID_RAM_CONSOLE
 	bool "Android RAM buffer console"
-	depends on !S390 && !UML && HAVE_MEMBLOCK && PSTORE_RAM
+	depends on !S390 && !UML && HAVE_MEMBLOCK && PSTORE_RAM=y
 	default n
 
 config ANDROID_TIMED_OUTPUT