Attention is currently required from: Felix Singer, Angel Pons, Michael Niewöhner. Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/57809 )
Change subject: ft2232_spi: prevent use of reserved pins on some programmers ......................................................................
Patch Set 3: Code-Review+2
(1 comment)
File ft2232_spi.c:
https://review.coreboot.org/c/flashrom/+/57809/comment/abb1ad2c_b625aa75 PS2, Line 417: /* Flyswatter and Flyswatter-2 require GPIO bits 0x80 : * and 0x40 to be driven low to enable output buffers */ : pindir = 0xcb; :
Done
IMHO, a good argument not to add a redundant variable. Isn't this
pindir & 0xf0 == rsv_bits
always true after detecting the specific programmer? If we can use that as a rule to write a patch, we can also just write it into code to avoid human errors. One could still do it with an additional variable, e.g. at the right spot:
const uint8_t rsv_bits = pindir & 0xf0;