usb dont spawn worker process, because only one USB controller is supported
This commit is contained in:
23
usb/usb.c
23
usb/usb.c
@@ -8,17 +8,7 @@
|
||||
#include <string.h>
|
||||
#include <system.h>
|
||||
|
||||
static void usb_poll_driver_proc (void* arg) {
|
||||
struct device_info* info = arg;
|
||||
|
||||
mprintf ("Polling device %s\n", info->key);
|
||||
|
||||
for (;;) {
|
||||
device_do (info->key, XUSBCTRL_POLL_DRIVER, NULL, NULL, NULL, NULL);
|
||||
|
||||
sched ();
|
||||
}
|
||||
}
|
||||
static void usb_poll_driver_proc (void* arg) { struct device_info* info = arg; }
|
||||
|
||||
void app_main (void) {
|
||||
libprocess_self_init ();
|
||||
@@ -44,13 +34,14 @@ void app_main (void) {
|
||||
continue;
|
||||
}
|
||||
|
||||
struct process_data* pdata = process_spawn (&usb_poll_driver_proc, info);
|
||||
mprintf ("Polling device %s\n", info->key);
|
||||
|
||||
mprintf ("Started USB poller process: PID %d\n", pdata->pid);
|
||||
for (;;) {
|
||||
device_do (info->key, XUSBCTRL_POLL_DRIVER, NULL, NULL, NULL, NULL);
|
||||
|
||||
sched ();
|
||||
}
|
||||
}
|
||||
|
||||
for (;;)
|
||||
;
|
||||
} else {
|
||||
mprintf ("ERROR unknown command %s\n", commandbuf);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user