Attention is currently required from: Nikolai Artemiev, Sergii Dmytruk.
Nikolai Artemiev uploaded patch set #5 to this change.
writeprotect: Add function to get register values and WP bit masks
Add a new wp_cfg_to_reg_values() function that takes a generic wp_cfg
instance and returns the chip-specific values that need to be written to
the chip's registers to enable the specified protection range/mode.
The function returns three values for each chip register:
- reg_values[reg] - Value writeprotect will write to reg
- bit_masks[reg] - Bit mask for WP-related bits in reg
- write_masks[reg] - Bit mask for writable WP-related bits in reg
(i.e. the ones writeprotect will try to write)
BUG=b:260019525,b:259013033
BRANCH=none
TEST=ninja test
Change-Id: Ib2a47153b230c9f82bb4eca357c335f2abbacc20
Signed-off-by: Nikolai Artemiev <nartemiev@google.com>
---
M include/writeprotect.h
M tests/chip_wp.c
M tests/tests.c
M tests/tests.h
M writeprotect.c
5 files changed, 128 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/flashrom refs/changes/47/69847/5
To view, visit change 69847. To unsubscribe, or for help writing mail filters, visit settings.