Add code for the unlocking (erasing/writing) of Winbond W39V040FB chips, enabling erasing/writing this type of chip.<br><br>Signed-off-by: Idwer Vollering <<a href="mailto:vidwer@gmail.com">vidwer@gmail.com</a>><br><br>
Index: w39.c<br>===================================================================<br>--- w39.c       (revision 1246)<br>+++ w39.c       (working copy)<br>@@ -244,6 +244,16 @@<br>        return -1;<br> }<br><br>+int unlock_w39v040fb(struct flashchip *flash)<br>
+{<br>+       if (unlock_w39_fwh(flash))<br>+               return -1;<br>+       if (printlock_w39_common(flash, 0x7fff2))<br>+               return -1;<br>+<br>+       return 0;<br>+}<br>+<br> int unlock_w39v080fa(struct flashchip *flash)<br>
 {<br>        if (unlock_w39_fwh(flash))<br>Index: flashchips.c<br>===================================================================<br>--- flashchips.c        (revision 1246)<br>+++ flashchips.c        (working copy)<br>
@@ -7694,7 +7694,7 @@<br>                .feature_bits   = FEATURE_REGISTERMAP | FEATURE_EITHER_RESET,<br>                .tested         = TEST_OK_PRE,<br>                .probe          = probe_jedec,<br>-               .probe_timing   = 10,<br>
+               .probe_timing   = 10,<br>                .block_erasers  =<br>                {<br>                        {<br>@@ -7706,6 +7706,7 @@<br>                        }<br>                },<br>                .printlock      = printlock_w39v040fb,<br>
+               .unlock         = unlock_w39v040fb,<br>                .write          = write_jedec_1,<br>                .read           = read_memmapped,<br>        },<br>Index: chipdrivers.h<br>===================================================================<br>
--- chipdrivers.h       (revision 1246)<br>+++ chipdrivers.h       (working copy)<br>@@ -119,6 +119,7 @@<br> int printlock_w39v080a(struct flashchip *flash);<br> int printlock_w39v080fa(struct flashchip *flash);<br> int printlock_w39v080fa_dual(struct flashchip *flash);<br>
+int unlock_w39v040fb(struct flashchip *flash);<br> int unlock_w39v080fa(struct flashchip *flash);<br><br> /* w29ee011.c */<br>