]> git.dujemihanovic.xyz Git - u-boot.git/commit
sf: Preserve QE bit when clearing BP# bits for Macronix flash
authorBin Meng <bmeng.cn@gmail.com>
Sun, 23 Jul 2017 14:44:37 +0000 (07:44 -0700)
committerJagan Teki <jagan@amarulasolutions.com>
Wed, 16 Aug 2017 12:51:50 +0000 (18:21 +0530)
commit294f2050c438d1e4ab39fd040d394927772048f2
tree35acc30c4fc837d434bec4f4af040c5493967f03
parent8fc2faefdd8bd950fa6ef615ab63f8ec3b6de7e5
sf: Preserve QE bit when clearing BP# bits for Macronix flash

On some flash (like Macronix), QE (quad enable) bit is in the same
status register as BP# bits, and we need preserve its original value
during a reboot cycle as this is required by some platforms (like
Intel ICH SPI controller working under descriptor mode).

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Jagan Teki <jagan@openedev.com>
[Refined code for readability]
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
drivers/mtd/spi/spi_flash.c