summaryrefslogtreecommitdiffstats
path: root/external/pflash/test
Commit message (Collapse)AuthorAgeFilesLines
* pflash: Support encoding/decoding ECC'd partitionsStewart Smith2019-02-142-0/+8
| | | | | | | | | | | | | | | | | With the new --ecc option, pflash can add/remove ECC when reading/writing flash partitions protected by ECC. This is *not* flawless with current PNORs out in the wild though, as they do not typically fill the whole partition with valid ECC data, so you have to know how big the valid ECC'd data is and specify the size manually. Note that for some partitions this is pratically impossible without knowing the details of the content of the partition. A future patch is likely to introduce an option to "stop reading data when ECC starts failing and assume everything is okay rather than error out" to support reading the "valid" data from existing PNOR images. Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* pflash: Add --skip option for readingAdriana Kobylak2018-10-252-0/+6
| | | | | | | | | | | | Add a --skip=N option to pflash to skip N number of bytes when reading. This would allow users to print the VERSION partition without the STB header by specifying the --skip=4096 argument, and it's a more generic solution rather than making pflash depend on secure/trusted boot code. Signed-off-by: Adriana Kobylak <anoo@linux.ibm.com> Reviewed-by: Samuel Mendoza-Jonas <sam@mendozajonas.com> [stewart: fix up pflash test] Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* external/ffspart: Use new interfaceCyril Bur2018-04-097-29/+29
| | | | | | | This also updated the pflash tests which use ffspart to generate pnors Signed-off-by: Cyril Bur <cyril.bur@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* external/pflash: Use ffs_entry_user_to_string() to standardise flag stringsCyril Bur2018-04-091-7/+7
| | | | | Signed-off-by: Cyril Bur <cyril.bur@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* libffs: Standardise ffs partition flagsCyril Bur2018-04-092-3/+3
| | | | | | | | | | | | It seems we've developed a character respresentation for ffs partition flags. Currently only pflash really prints them so it hasn't been a problem but now ffspart wants to read them in from user input. It is important that what libffs reads and what pflash prints remain consistent, we should move the code into libffs to avoid problems. Signed-off-by: Cyril Bur <cyril.bur@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
* pflash: Support for clean_on_ecc_error flagAdriana Kobylak2017-12-135-8/+24
| | | | | | | | | | | | Add the misc flag clear_on_ecc_error to libflash/pflash. This was the only missing flag. The generator of the virtual pnor image relies on libflash/pflash to provide the partition information, so all flags are needed to build an accurate virtual pnor partition table. Signed-off-by: Adriana Kobylak <anoo@linux.vnet.ibm.com> Reviewed-by: Cyril Bur <cyril.bur@au1.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* ffspart/pflash: fix tests for new VOLATILE flagStewart Smith2017-11-106-22/+27
| | | | | Fixes: b786e7ba1d34c5a4d8baa6304f4d930539cefac8 Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* pflash: Support for volatile flagAdriana Kobylak2017-11-093-6/+17
| | | | | | | | | The volatile flag was added to the pnor image to indicate partitions that are cleared during a host power off. Display this flag from the pflash command. Signed-off-by: Adriana Kobylak <anoo@us.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* external/pflash: tests: Move the test-miscprint to pflash testsCyril Bur2017-08-014-0/+77
| | | | | | | | | | | | | | New code that is very much pflash functionality was added in commit f2c87a3d2f6 "pflash option to retrieve PNOR partition flags". Unfortunately at the time there wasn't an easy way to test pflash. The previous patch adds pflash infrastructure and plumbs it into `make check` nicely. This commit converts the tests originally added to libflash tests. Signed-off-by: Cyril Bur <cyril.bur@au1.ibm.com> Reviewed-by: Samuel Mendoza-Jonas <sam@mendozajonas.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
* external/pflash: Add testsCyril Bur2017-08-0125-0/+973
Signed-off-by: Cyril Bur <cyril.bur@au1.ibm.com> Reviewed-by: Samuel Mendoza-Jonas <sam@mendozajonas.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
OpenPOWER on IntegriCloud