Shawn Nematbakhsh d95b9fc18c npcx: flash: Fix SR reg reads during UMA lock
If UMA is locked, read and write access to SR* regs will fail, and we'll
be unable to determine or change our write protect state. Save our SR
regs before enabling UMA lock, and bring down UMA lock for a brief
period when writing SR regs.

BUG=chrome-os-partner:60029
BRANCH=gru
TEST=Manual on kevin with SW sync enabled.
flashrom -p ec --wp-enable -> verify success, check flags:
Flags:   wp_gpio_asserted ro_at_boot ro_now

Reboot host, check flags:
Flags:   wp_gpio_asserted ro_at_boot ro_now all_now

Verify flashrom -p ec --wp-status shows protected, and flashrom -p ec
--wp-disable fails.

Also verify same state after EC reset.

Boot into recovery mode, check flags:
Flags:   wp_gpio_asserted ro_at_boot ro_now

Remove WP screw, reboot EC, check flags:
Flags:   ro_at_boot ro_now

Verify flashrom WP status shows protected, and flashrom WP disable
succeeds and clears all flags.

Signed-off-by: Shawn Nematbakhsh <shawnn@chromium.org>
Change-Id: I17e32f7305600183e7fcb87f69a3feb88978f94e
Reviewed-on: https://chromium-review.googlesource.com/412977
(cherry picked from commit 6cfc0d0dd030b8b0334f99e99950a52fcf8267af)
Reviewed-on: https://chromium-review.googlesource.com/415497
Commit-Ready: Shawn N <shawnn@chromium.org>
Tested-by: Shawn N <shawnn@chromium.org>
Reviewed-by: Shawn N <shawnn@chromium.org>
2016-12-01 19:59:07 -08:00
2016-12-01 19:59:06 -08:00
2016-11-10 21:28:33 -08:00
2016-12-01 19:58:56 -08:00
2016-11-20 00:24:27 -08:00
2016-09-09 19:20:12 -07:00
2012-05-11 09:11:52 -07:00
2016-10-14 16:05:49 -07:00
2014-04-02 19:58:53 +00:00
2015-12-08 20:05:05 -08:00

For an overview of the Embedded Controller firmware, refer to

http://www.chromium.org/chromium-os/2014-firmware-summit

For instructions on building from source, refer to

http://www.chromium.org/chromium-os/ec-development/getting-started-building-ec-images-quickly
Description
No description provided
Readme 1.4 GiB
Languages
C 64.7%
Lasso 20.7%
ASL 3.6%
JavaScript 3.2%
C# 2.9%
Other 4.6%