From c31ad081e8734aab3fb45d2f32e9969994dd076e Mon Sep 17 00:00:00 2001 From: Arve Hjønnevåg Date: Tue, 22 May 2012 16:33:23 -0700 Subject: pstore/ram: Allow specifying ecc parameters in platform data Allow specifying ecc parameters in platform data Signed-off-by: Arve Hjønnevåg [jstultz: Tweaked commit subject & add commit message] Signed-off-by: John Stultz Acked-by: Kees Cook Signed-off-by: Anton Vorontsov --- include/linux/pstore_ram.h | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'include') diff --git a/include/linux/pstore_ram.h b/include/linux/pstore_ram.h index cb6ab5feab67..9974975d40db 100644 --- a/include/linux/pstore_ram.h +++ b/include/linux/pstore_ram.h @@ -26,6 +26,13 @@ struct persistent_ram_buffer; struct rs_control; +struct persistent_ram_ecc_info { + int block_size; + int ecc_size; + int symsize; + int poly; +}; + struct persistent_ram_zone { phys_addr_t paddr; size_t size; @@ -39,15 +46,14 @@ struct persistent_ram_zone { struct rs_control *rs_decoder; int corrected_bytes; int bad_blocks; - int ecc_block_size; - int ecc_size; + struct persistent_ram_ecc_info ecc_info; char *old_log; size_t old_log_size; }; struct persistent_ram_zone *persistent_ram_new(phys_addr_t start, size_t size, - u32 sig, int ecc_size); + u32 sig, struct persistent_ram_ecc_info *ecc_info); void persistent_ram_free(struct persistent_ram_zone *prz); void persistent_ram_zap(struct persistent_ram_zone *prz); @@ -74,7 +80,7 @@ struct ramoops_platform_data { unsigned long console_size; unsigned long ftrace_size; int dump_oops; - int ecc_size; + struct persistent_ram_ecc_info ecc_info; }; #endif -- cgit v1.2.3