Attention is currently required from: Nico Huber, Edward O'Callaghan, Anastasia Klimchuk, Eric Lai.
4 comments:
Commit Message:
Patch Set #1, Line 9: CB:35480
please use commit hash.
Done
Patch Set #1, Line 15: Coreboot issue
Ticket […]
Done
Patch Set #1, Line 19: FT2232H
This programmer also supports native 4BA commands which are probably […]
Ok interesting, I wrote a little test case:
```
static void print_sr(struct flashctx *flash)
{
uint8_t value;
int ret = spi_read_register(flash, STATUS1, &value);
printf("SR1=0x%02x ret=%d\n", value, ret);
ret = spi_read_register(flash, STATUS2, &value);
printf("SR2=0x%02x ret=%d\n", value, ret);
ret = spi_read_register(flash, STATUS3, &value);
printf("SR3=0x%02x ret=%d\n\n", value, ret);
}
static void test(struct flashctx *flash)
{
printf("Power-up state:\n");
print_sr(flash);
int ret = spi_enter_exit_4ba(flash, false);
printf("Exit 4BA ret=%d\n", ret);
print_sr(flash);
ret = spi_enter_exit_4ba(flash, true);
printf("Enter 4BA ret=%d\n", ret);
print_sr(flash);
ret = spi_enter_exit_4ba(flash, false);
printf("Exit 4BA ret=%d\n", ret);
print_sr(flash);
}
```
Here are the results:
```
# FEATURE_4BA:
Power-up state:
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
Exit 4BA ret=0
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
Enter 4BA ret=0
SR1=0x00 ret=0
SR2=0x01 ret=0
SR3=0x20 ret=0
Exit 4BA ret=0
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
```
```
# FEATURE_4BA_WREN:
Power-up state:
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
Exit 4BA ret=0
SR1=0x02 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
Enter 4BA ret=0
SR1=0x02 ret=0
SR2=0x01 ret=0
SR3=0x20 ret=0
Exit 4BA ret=0
SR1=0x02 ret=0
SR2=0x00 ret=0
SR3=0x20 ret=0
```
So it is able to set the ADS bit with or without WREN. The bit that's always set in SR3 is DRV0, which defaults to 1 according to the datasheet. Just to be sure I set it to 0 (i.e. `spi_write_register(flash, STATUS3, 0)` and reran the test:
```
# FEATURE_4BA, DRV0 cleared:
Power-up state:
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x00 ret=0
Exit 4BA ret=0
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x00 ret=0
Enter 4BA ret=0
SR1=0x00 ret=0
SR2=0x01 ret=0
SR3=0x00 ret=0
Exit 4BA ret=0
SR1=0x00 ret=0
SR2=0x00 ret=0
SR3=0x00 ret=0
```
Patchset:
You forgot to add the topic! I am marking this unresolved so that the comment is more visible.
Done
To view, visit change 70342. To unsubscribe, or for help writing mail filters, visit settings.