Attention is currently required from: Nicholas Chin, ZhiYuanNJ.
Anastasia Klimchuk has posted comments on this change by ZhiYuanNJ. ( https://review.coreboot.org/c/flashrom/+/82776?usp=email )
Change subject: ch347_spi: Add spi clock frequency selection ......................................................................
Patch Set 13:
(1 comment)
File ch347_spi.c:
https://review.coreboot.org/c/flashrom/+/82776/comment/163c8bd0_3a8f8b02?usp... : PS13, Line 291: int speed_index = 2;
Hi, Change here.
Yes, I see you changed speed_index, thank you! But have you seen my previous comment, I had one more idea: to remove `int divisor`
Which means:
remove line 287 remove line 360 line 370 will be: `ch347_spi_config(ch347_data, spispeeds[speed_index].divisor)`
The main advantage: you have only one variable to maintain: speed_index. And then later if you need to change the default, you only need to change speed_index.
Do you agree? If you don't like the idea for some reasons, please tell me!