Implement flash region permissions check in hardware sequencing.

This patch adds support for checking flash fd permissions
before performing read/write/erase and verify. This prevents
flashrom from accessing locked/disabled regions.

BUG=chrome-os-partner:37711
TEST=flashrom -p host -w <path_to_image.bin>

flashrom -p host --wp-status
flashrom -p host -r <filename>
flashrom -p host -E

Change-Id: Iace2d11d6304a29b95e38e6f9c9e7655247934ba
Signed-off-by: Ramya Vijaykumar <ramya.vijaykumar@intel.com>
Reviewed-on: https://chromium-review.googlesource.com/304980
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
1 file changed