aboutsummaryrefslogtreecommitdiffstats
path: root/os/hal/src
diff options
context:
space:
mode:
authorgdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-06-10 16:31:03 +0000
committergdisirio <gdisirio@35acf78f-673a-0410-8e92-d51de3d6d3f4>2012-06-10 16:31:03 +0000
commitc762926b68f6a6c7f1e71b8acf9b1dd29d6e481f (patch)
tree595000cdeb9dd88826192dcf82d47381de9cb03e /os/hal/src
parent1d023ea90143296fe13176df8be2aa91d88e702d (diff)
downloadChibiOS-c762926b68f6a6c7f1e71b8acf9b1dd29d6e481f.tar.gz
ChibiOS-c762926b68f6a6c7f1e71b8acf9b1dd29d6e481f.tar.bz2
ChibiOS-c762926b68f6a6c7f1e71b8acf9b1dd29d6e481f.zip
git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@4265 35acf78f-673a-0410-8e92-d51de3d6d3f4
Diffstat (limited to 'os/hal/src')
-rw-r--r--os/hal/src/serial_usb.c8
-rw-r--r--os/hal/src/usb.c4
2 files changed, 10 insertions, 2 deletions
diff --git a/os/hal/src/serial_usb.c b/os/hal/src/serial_usb.c
index 2c7a37b4d..7f1658812 100644
--- a/os/hal/src/serial_usb.c
+++ b/os/hal/src/serial_usb.c
@@ -119,6 +119,7 @@ static const struct SerialUSBDriverVMT vmt = {
static void inotify(GenericQueue *qp) {
SerialUSBDriver *sdup = (SerialUSBDriver *)qp->q_wrptr;
+#if 0
/* Writes to the input queue can only happen when the queue has been
emptied, then a whole packet is loaded in the queue.*/
if (!usbGetReceiveStatusI(sdup->config->usbp, USB_CDC_DATA_AVAILABLE_EP) &&
@@ -139,6 +140,7 @@ static void inotify(GenericQueue *qp) {
while (notempty(&sdup->iqueue.q_waiting))
chSchReadyI(fifo_remove(&sdup->iqueue.q_waiting))->p_u.rdymsg = Q_OK;
}
+#endif
}
/**
@@ -148,6 +150,7 @@ static void onotify(GenericQueue *qp) {
SerialUSBDriver *sdup = (SerialUSBDriver *)qp->q_rdptr;
size_t n;
+#if 0
/* If there is any data in the output queue then it is sent within a
single packet and the queue is emptied.*/
n = chOQGetFullI(&sdup->oqueue);
@@ -166,6 +169,7 @@ static void onotify(GenericQueue *qp) {
while (notempty(&sdup->oqueue.q_waiting))
chSchReadyI(fifo_remove(&sdup->oqueue.q_waiting))->p_u.rdymsg = Q_OK;
}
+#endif
}
/*===========================================================================*/
@@ -298,6 +302,7 @@ void sduDataTransmitted(USBDriver *usbp, usbep_t ep) {
SerialUSBDriver *sdup = usbp->param;
size_t n;
+#if 0
chSysLockFromIsr();
/* If there is any data in the output queue then it is sent within a
single packet and the queue is emptied.*/
@@ -319,6 +324,7 @@ void sduDataTransmitted(USBDriver *usbp, usbep_t ep) {
chSchReadyI(fifo_remove(&sdup->oqueue.q_waiting))->p_u.rdymsg = Q_OK;
}
chSysUnlockFromIsr();
+#endif
}
/**
@@ -332,6 +338,7 @@ void sduDataTransmitted(USBDriver *usbp, usbep_t ep) {
void sduDataReceived(USBDriver *usbp, usbep_t ep) {
SerialUSBDriver *sdup = usbp->param;
+#if 0
chSysLockFromIsr();
/* Writes to the input queue can only happen when the queue has been
emptied, then a whole packet is loaded in the queue.*/
@@ -355,6 +362,7 @@ void sduDataReceived(USBDriver *usbp, usbep_t ep) {
chSchReadyI(fifo_remove(&sdup->iqueue.q_waiting))->p_u.rdymsg = Q_OK;
}
chSysUnlockFromIsr();
+#endif
}
/**
diff --git a/os/hal/src/usb.c b/os/hal/src/usb.c
index 1927581f1..ceae24770 100644
--- a/os/hal/src/usb.c
+++ b/os/hal/src/usb.c
@@ -313,10 +313,10 @@ void usbInitEndpointI(USBDriver *usbp, usbep_t ep,
"usbEnableEndpointI(), #2", "already initialized");
/* Logically enabling the endpoint in the USBDriver structure.*/
- if (!(epcp->ep_mode & USB_EP_MODE_PACKET)) {
+// if (!(epcp->ep_mode & USB_EP_MODE_PACKET)) {
memset(epcp->in_state, 0, sizeof(USBInEndpointState));
memset(epcp->out_state, 0, sizeof(USBOutEndpointState));
- }
+// }
usbp->epc[ep] = epcp;
/* Low level endpoint activation.*/