Skip to content

Commit

Permalink
pstore/ram: Add some more documentation and examples
Browse files Browse the repository at this point in the history
Suggested-by: Shuah Khan <shuahkhan@gmail.com>
Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org>
Acked-by: Kees Cook <keescook@chromium.org>
Acked-by: Colin Cross <ccross@android.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Anton Vorontsov authored and Greg Kroah-Hartman committed Jun 13, 2012
1 parent 602b5be commit 958502d
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions Documentation/ramoops.txt
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,12 @@ corrupt, but usually it is restorable.
Setting the ramoops parameters can be done in 2 different manners:
1. Use the module parameters (which have the names of the variables described
as before).
For quick debugging, you can also reserve parts of memory during boot
and then use the reserved memory for ramoops. For example, assuming a machine
with > 128 MB of memory, the following kernel command line will tell the
kernel to use only the first 128 MB of memory, and place ECC-protected ramoops
region at 128 MB boundary:
"mem=128M ramoops.mem_address=0x8000000 ramoops.ecc=1"
2. Use a platform device and set the platform data. The parameters can then
be set through that platform data. An example of doing that is:

Expand Down Expand Up @@ -70,6 +76,14 @@ if (ret) {
return ret;
}

You can specify either RAM memory or peripheral devices' memory. However, when
specifying RAM, be sure to reserve the memory by issuing memblock_reserve()
very early in the architecture code, e.g.:

#include <linux/memblock.h>

memblock_reserve(ramoops_data.mem_address, ramoops_data.mem_size);

3. Dump format

The data dump begins with a header, currently defined as "====" followed by a
Expand Down

0 comments on commit 958502d

Please sign in to comment.