mirror of
git://projects.qi-hardware.com/ben-wpan.git
synced 2025-04-21 12:27:27 +03:00
tools/lib: added USB-SPI driver for ATUSB
- atusb-spi.c: ATUSB driver that uses the ATUSB_SPI_* functions instead
of ATUSB_{REG,BUF,SRAM}_*
- driver.h, atrf.c (drivers, atrf_usb_handle): added atusb_spi_driver
- Makefile (OBJS): added atusb-spi.o
This commit is contained in:
@@ -35,6 +35,7 @@ static const struct atrf_driver *drivers[] = {
|
||||
#endif
|
||||
#ifdef HAVE_USB
|
||||
&atusb_driver,
|
||||
&atusb_spi_driver,
|
||||
#endif
|
||||
&atnet_driver,
|
||||
NULL
|
||||
@@ -44,7 +45,7 @@ static const struct atrf_driver *drivers[] = {
|
||||
void *atrf_usb_handle(struct atrf_dsc *dsc)
|
||||
{
|
||||
#ifdef HAVE_USB
|
||||
if (dsc->driver == &atusb_driver)
|
||||
if (dsc->driver == &atusb_driver || dsc->driver == &atusb_spi_driver)
|
||||
return atusb_dev_handle(dsc->handle);
|
||||
#endif
|
||||
return NULL;
|
||||
|
||||
Reference in New Issue
Block a user