staging: android: ram_console: split out persistent ram
authorColin Cross <ccross@android.com>
Thu, 8 Mar 2012 01:34:32 +0000 (17:34 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 8 Mar 2012 17:36:08 +0000 (09:36 -0800)
commitc672528aec4a1cf6f3df7a6022e6823a20b20f8e
tree1c90649fc3495d10b17879ce9c232f6c3323adae
parentc5ee1211f249b0897f715aba4647c1f494509cab
staging: android: ram_console: split out persistent ram

Split ram_console into two halves.

persistent_ram is a set of apis that handle a block of memory
that does not get erased across a reboot.  It provides functions
to fill it as a single buffer or a ring buffer, and to extract
the old data after a reboot.  It handles ecc on the data to
correct bit errors introduced during reboot.

ram_console is now a small wrapper around persistent_ram that
feeds console data into the ringbuffer, and exports the old
data to /proc/last_kmsg after a reboot.

[jstultz: Moved persistent_ram.h to staging dir]
CC: Greg KH <gregkh@linuxfoundation.org>
CC: Android Kernel Team <kernel-team@android.com>
Signed-off-by: Colin Cross <ccross@android.com>
Signed-off-by: John Stultz <john.stultz@linaro.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/android/Kconfig
drivers/staging/android/Makefile
drivers/staging/android/persistent_ram.c [new file with mode: 0644]
drivers/staging/android/persistent_ram.h [new file with mode: 0644]
drivers/staging/android/ram_console.c