linux: Fix spi handling with more than one spi device

Reported by @opensource-alt.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
This commit is contained in:
Kevin O'Connor 2020-10-25 10:14:15 -04:00
parent c2c79ff98d
commit ed5ce9cb37
1 changed files with 1 additions and 0 deletions

View File

@ -57,6 +57,7 @@ spi_open(uint32_t bus, uint32_t dev)
devices[devices_count].bus = bus; devices[devices_count].bus = bus;
devices[devices_count].dev = dev; devices[devices_count].dev = dev;
devices[devices_count].fd = fd; devices[devices_count].fd = fd;
devices_count++;
return fd; return fd;
} }