diff options
author | Martin Peschke <mpeschke@de.ibm.com> | 2016-06-17 15:34:25 +0200 |
---|---|---|
committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2016-07-21 17:52:58 -0400 |
commit | c0053e8a52a447a26fcb81ea97855bd67d49c291 (patch) | |
tree | accbc8e9163d02a9647e00c03d79dfbafd98f6e5 | |
parent | 719abcf4279bae2621a9cbdf534b34a9006292ae (diff) | |
download | talos-hostboot-c0053e8a52a447a26fcb81ea97855bd67d49c291.tar.gz talos-hostboot-c0053e8a52a447a26fcb81ea97855bd67d49c291.zip |
p9_scan_compression: RS4v2 decompression
This adds RS4v2 support to decompression.
Compression was already RS4v2-ready.
Change-Id: I9621b0f72827924734953fd7fd98f861506bd8e0
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/25984
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: Claus M. Olsen <cmolsen@us.ibm.com>
Reviewed-by: Martin Peschke <mpeschke@de.ibm.com>
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/26181
Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
-rw-r--r-- | src/import/chips/p9/utils/imageProcs/p9_scan_compression.H | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/src/import/chips/p9/utils/imageProcs/p9_scan_compression.H b/src/import/chips/p9/utils/imageProcs/p9_scan_compression.H index d60cb9e8b..8bb3156a4 100644 --- a/src/import/chips/p9/utils/imageProcs/p9_scan_compression.H +++ b/src/import/chips/p9/utils/imageProcs/p9_scan_compression.H @@ -256,7 +256,13 @@ rs4_compress(CompressedScanData** o_data, /// the decompressed string, which is the size of the original string in bits /// rounded up to the nearest byte. /// -/// \param[in] i_stringSize The size (in bytes) of \a io_data_str. +/// \param[in,out] io_care_str A caller-supplied data area to contain the +/// decompressed care mask. The \a i_stringSize must be large enough to contain +/// the decompressed care mask, which is the size of the original string in +/// bits rounded up to the nearest byte. +/// +/// \param[in] i_stringSize The size (in bytes) of \a io_data_str and +/// \a io_care_str. /// /// \param[out] o_length The length of the decompressed string in \e bits. /// @@ -270,6 +276,7 @@ rs4_compress(CompressedScanData** o_data, /// \returns See \ref scan_compression_codes int _rs4_decompress(uint8_t* io_data_str, + uint8_t* io_care_str, uint32_t i_stringSize, uint32_t* o_length, const CompressedScanData* i_rs4); @@ -281,9 +288,13 @@ _rs4_decompress(uint8_t* io_data_str, /// decompressed string. After this call the caller owns \a o_data_str and is /// responsible for free()-ing this data area once it is no longer required. /// -/// \param[out] o_length The length of the decompressed string in \e bits. -/// The caller may assume that \a o_data_str contains at least -/// (\a o_length + 7) / 8 \e bytes. +/// \param[out] o_care_str The API malloc()-s this data area to contain the +/// decompressed care mask. After this call the caller owns \a o_care_str and +/// is responsible for free()-ing this data area once it is no longer required. +/// +/// \param[out] o_length The length of the decompressed string and care mask +/// in \e bits. The caller may assume that \a o_data_str and o_care_str each +/// contain at least (\a o_length + 7) / 8 \e bytes. /// /// \param[in] i_rs4 A pointer to the CompressedScanData header + data to be /// decompressed. @@ -291,6 +302,7 @@ _rs4_decompress(uint8_t* io_data_str, /// \returns See \ref scan_compression_codes int rs4_decompress(uint8_t** o_data_str, + uint8_t** o_care_str, uint32_t* o_length, const CompressedScanData* i_rs4); |