Attention is currently required from: Nico Huber, Edward O'Callaghan, Angel Pons, Anastasia Klimchuk. Joursoir has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/54890 )
Change subject: programmer: Introduce default shutdown function ......................................................................
Patch Set 6:
(2 comments)
File flashrom.c:
https://review.coreboot.org/c/flashrom/+/54890/comment/df2d8e37_b59bda75 PS5, Line 78: int default_shutdown(void *data)
`static int default_shutdown(void *data)`
The reason why default_shutdown isn't static is because we're going to use it in the API. This helps us explicitly specify which of the shutdowns the programmer is using, e.g:
static const struct spi_master spi_master_programmer = { ... .shutdown = default_shutdown, };
https://review.coreboot.org/c/flashrom/+/54890/comment/111fc397_944d3cb1 PS5, Line 104: function;
Yes, when I mentioned "shutdown function should be required" above, in my mind it was exactly this: […]
Do I right understand that you mean checking in register_*_master() and not in register_shutdown()?
int register_spi_master(const struct spi_master *mst, void *data) { ... if (!mst->write_aai || ... || !mst->shutdown) { return ERROR_FLASHROM_BUG; } ... }