diff mbox

double_buffer_not_ok compile error

Message ID 4D6261C8.1090605@matrix-vision.de (mailing list archive)
State New, archived
Headers show

Commit Message

Michael Jones Feb. 21, 2011, 12:59 p.m. UTC
None
diff mbox

Patch

diff --git a/drivers/usb/musb/musb_host.c b/drivers/usb/musb/musb_host.c
index 0f523d7..809965f 100644
--- a/drivers/usb/musb/musb_host.c
+++ b/drivers/usb/musb/musb_host.c
@@ -609,9 +609,11 @@  musb_rx_reinit(struct musb *musb, struct musb_qh *qh, struct musb_hw_ep *ep)
 	/* Set RXMAXP with the FIFO size of the endpoint
 	 * to disable double buffer mode.
 	 */
+#ifdef CONFIG_USB_GADGET_MUSB_HDRC
 	if (musb->double_buffer_not_ok)
 		musb_writew(ep->regs, MUSB_RXMAXP, ep->max_packet_sz_rx);
 	else
+#endif
 		musb_writew(ep->regs, MUSB_RXMAXP,
 				qh->maxpacket | ((qh->hb_mult - 1) << 11));
 
@@ -784,10 +786,12 @@  static void musb_ep_program(struct musb *musb, u8 epnum,
 		/* protocol/endpoint/interval/NAKlimit */
 		if (epnum) {
 			musb_writeb(epio, MUSB_TXTYPE, qh->type_reg);
+#ifdef CONFIG_USB_GADGET_MUSB_HDRC
 			if (musb->double_buffer_not_ok)
 				musb_writew(epio, MUSB_TXMAXP,
 						hw_ep->max_packet_sz_tx);
 			else
+#endif
 				musb_writew(epio, MUSB_TXMAXP,
 						qh->maxpacket |
 						((qh->hb_mult - 1) << 11));