Attention is currently required from: Edward O'Callaghan, Alexander Goncharov.
Anastasia Klimchuk has posted comments on this change. ( https://review.coreboot.org/c/flashrom/+/72807 )
Change subject: ch341a_spi: Refactor singleton states into reentrant pattern ......................................................................
Patch Set 3:
(2 comments)
File ch341a_spi.c:
https://review.coreboot.org/c/flashrom/+/72807/comment/a5cae2ad_fd65947a PS3, Line 80: struct libusb_transfer *transfer_out; : struct libusb_transfer *transfer_ins[USB_IN_TRANSFERS]; : : /* Accumulate delays to be plucked between CS deassertion and CS assertions. */ : unsigned int stored_delay_us; : : struct libusb_device_handle *handle; Will default values for these be the same as before? If not, they should be set in init function. Although 0s and NULLs are probably default initialisation anyway?
https://review.coreboot.org/c/flashrom/+/72807/comment/480477a4_b99f4a94 PS3, Line 461: msg_pwarn("Cannot detach the existing USB driver. Claiming the interface may fail. %s\n", : libusb_error_name(ret)); Is this an error branch? It should `goto free_data` then. Or maybe `goto close_handle` ?