diff options
author | Michael Sevakis <jethead71@rockbox.org> | 2011-01-18 14:10:06 +0000 |
---|---|---|
committer | Michael Sevakis <jethead71@rockbox.org> | 2011-01-18 14:10:06 +0000 |
commit | 453550a6877afcda342ac2477cf05028fff053f9 (patch) | |
tree | 0c1da0af945d93a6c4af2da5eb359f737e6a7f53 /firmware/export | |
parent | 980225c3e20b3102382c910da6e1406cc8c7f1b5 (diff) |
Try to get some control over #ifdef hell in usb.c by refactoring and inline function use. SYS_USB_DISCONNECTED_ACK hasn't been doing anything useful for the USB thread; remove it. USB thread simply ignores that value. Observe only valid usb_state transitions.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29084 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/export')
-rw-r--r-- | firmware/export/kernel.h | 1 | ||||
-rw-r--r-- | firmware/export/usb.h | 5 |
2 files changed, 1 insertions, 5 deletions
diff --git a/firmware/export/kernel.h b/firmware/export/kernel.h index cfc7a232ac..20743c554b 100644 --- a/firmware/export/kernel.h +++ b/firmware/export/kernel.h @@ -64,7 +64,6 @@ #define SYS_USB_CONNECTED MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 0) #define SYS_USB_CONNECTED_ACK MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 1) #define SYS_USB_DISCONNECTED MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 2) -#define SYS_USB_DISCONNECTED_ACK MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 3) #define SYS_USB_LUN_LOCKED MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 4) #define SYS_USB_READ_DATA MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 5) #define SYS_USB_WRITE_DATA MAKE_SYS_EVENT(SYS_EVENT_CLS_USB, 6) diff --git a/firmware/export/usb.h b/firmware/export/usb.h index aceecb55ae..a3425dae2f 100644 --- a/firmware/export/usb.h +++ b/firmware/export/usb.h @@ -33,10 +33,7 @@ enum { USB_EXTRACTED = 0, /* Event+State */ USB_INSERTED, /* Event+State */ -#if defined(HAVE_USB_POWER) || defined(USB_DETECT_BY_DRV) || \ - defined(USB_DETECT_BY_CORE) - USB_POWERED, /* Event+State */ -#endif + USB_POWERED, /* Event+State - transitional indicator if no power */ #if defined(USB_DETECT_BY_DRV) || defined(USB_DETECT_BY_CORE) USB_UNPOWERED, /* Event */ #endif |