Shiyu Sun has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/48662 )
Change subject: realtek_mst_i2c_spi.c: Add ISP mode check ......................................................................
Patch Set 3:
(2 comments)
https://review.coreboot.org/c/flashrom/+/48662/1/realtek_mst_i2c_spi.c File realtek_mst_i2c_spi.c:
https://review.coreboot.org/c/flashrom/+/48662/1/realtek_mst_i2c_spi.c@133 PS1, Line 133: /* wait for isp enter */ : int retry = 10; : while (retry-- > 0) { : if (realtek_mst_i2c_spi_in_isp_mode(fd) == 1) : break; : struct timespec wait_200ms = { 0, (unsigned)2e8 }; : nanosleep(&wait_200ms, NULL); : } : : if (retry < 0) : return SPI_GENERIC_ERROR;
I think this is re-implementing, […]
Done
https://review.coreboot.org/c/flashrom/+/48662/1/realtek_mst_i2c_spi.c@163 PS1, Line 163: if (realtek_mst_i2c_spi_in_isp_mode(fd) == 0) { : msg_perr("%s: MST not in ISP mode, reset will not happen.\n", __func__); : return SPI_GENERIC_ERROR; : }
just inline this, […]
I was thinking use the return value as True/False to present whether the device is in the ISP mode. But probably that should be a parameter instead of return value.