We need a way to identify which registered programmer should be used for a given access. Especially for cases where multiple programmers for the same bus type are registered (e.g. IT87+MCP79 SPI or Dual BIOS solutions), probing has to happen on each programmer. Somehow we have to tell the dispatcher (spi_send_command etc.) this information, and the only way to get the info to the dispatcher is either an ugly global variable which makes dealing with multiple flash chips and multiple bus probing really messy, or we store the info inside struct flashchip. Given that struct flashchip is passed around almost everywhere already, it is the natural location for such information and only very few function prototypes have to be changed to handle this.
I have a prototype patch in the queue, but it's only half ready. If there is any interest, I can send the patch as is to give you an option to shoot it down while it is still unfinished.
Regards, Carl-Daniel