aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManuel Odendahl <wesen@ruinwesen.com>2012-11-26 17:20:27 +0100
committerManuel Odendahl <wesen@ruinwesen.com>2013-01-17 20:52:25 +0100
commit5fb5900ab6f483ea587154a00b1d1de90357570b (patch)
tree3f880f628d90ecf232abadb4e2770d181ada3927
parent207281a869e04229c275cd2a3c447456c77309f2 (diff)
downloadlibrambutan-5fb5900ab6f483ea587154a00b1d1de90357570b.tar.gz
librambutan-5fb5900ab6f483ea587154a00b1d1de90357570b.zip
Rename USB_EP_EP_KIND to USB_EP_EP_KIND_DBL_BUF
Signed-off-by: Manuel Odendahl <wesen@ruinwesen.com>
-rw-r--r--libmaple/usb/stm32f1/usb_reg_map.h10
1 files changed, 5 insertions, 5 deletions
diff --git a/libmaple/usb/stm32f1/usb_reg_map.h b/libmaple/usb/stm32f1/usb_reg_map.h
index 607b03b..412a741 100644
--- a/libmaple/usb/stm32f1/usb_reg_map.h
+++ b/libmaple/usb/stm32f1/usb_reg_map.h
@@ -70,7 +70,7 @@ typedef struct usb_reg_map {
#define USB_EP_CTR_RX_BIT 15
#define USB_EP_DTOG_RX_BIT 14
#define USB_EP_SETUP_BIT 11
-#define USB_EP_EP_KIND_BIT 8
+#define USB_EP_EP_KIND_DBL_BUF_BIT 8
#define USB_EP_CTR_TX_BIT 7
#define USB_EP_DTOG_TX_BIT 6
@@ -87,8 +87,8 @@ typedef struct usb_reg_map {
#define USB_EP_EP_TYPE_CONTROL (0x1 << 9)
#define USB_EP_EP_TYPE_ISO (0x2 << 9)
#define USB_EP_EP_TYPE_INTERRUPT (0x3 << 9)
-#define USB_EP_EP_KIND BIT(USB_EP_EP_KIND_BIT)
-#define USB_EP_EP_DBL_BUF USB_EP_EP_KIND
+#define USB_EP_EP_KIND_DBL_BUF BIT(USB_EP_EP_KIND_DBL_BUF_BIT)
+#define USB_EP_EP_DBL_BUF USB_EP_EP_KIND_DBL_BUF
#define USB_EP_CTR_TX BIT(USB_EP_CTR_TX_BIT)
#define USB_EP_DTOG_TX BIT(USB_EP_DTOG_TX_BIT)
#define USB_EP_STAT_TX (0x3 << 4)
@@ -193,7 +193,7 @@ typedef struct usb_reg_map {
#define __EP_CTR_NOP (USB_EP_CTR_RX | USB_EP_CTR_TX)
#define __EP_NONTOGGLE (USB_EP_CTR_RX | USB_EP_SETUP | \
- USB_EP_EP_TYPE | USB_EP_EP_KIND | \
+ USB_EP_EP_TYPE | USB_EP_EP_KIND_DBL_BUF | \
USB_EP_CTR_TX | USB_EP_EA)
static inline void usb_clear_ctr_rx(uint8 ep) {
@@ -311,7 +311,7 @@ static inline void usb_set_ep_type(uint8 ep, uint32 type) {
static inline void usb_set_ep_kind(uint8 ep, uint32 kind) {
uint32 epr = USB_BASE->EP[ep];
- epr &= ~USB_EP_EP_KIND & __EP_NONTOGGLE;
+ epr &= ~USB_EP_EP_KIND_DBL_BUF & __EP_NONTOGGLE;
epr |= kind;
USB_BASE->EP[ep] = epr;
}