Re: [PATCH 059/100] usb: musb: gadget: fix compile warning

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello.

On 26-02-2013 13:34, Felipe Balbi wrote:

Fix the following compile warning:

drivers/usb/musb/musb_gadget.c: In function ‘rxstate’:
drivers/usb/musb/musb_gadget.c:714:22: warning: comparison of distinct pointer types lacks a cast [enabled by default]

Signed-off-by: Felipe Balbi <balbi@xxxxxx>
---
  drivers/usb/musb/musb_gadget.c | 13 ++++++++-----
  1 file changed, 8 insertions(+), 5 deletions(-)

diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c
index 296698b..1fcd987 100644
--- a/drivers/usb/musb/musb_gadget.c
+++ b/drivers/usb/musb/musb_gadget.c
@@ -580,7 +580,7 @@ static void rxstate(struct musb *musb, struct musb_request *req)
  			struct dma_controller	*c;
  			struct dma_channel	*channel;
  			int			use_dma = 0;
-			int transfer_size;
+				unsigned int transfer_size;

   You've iserted one tab too many, it seems...

@@ -622,7 +622,8 @@ static void rxstate(struct musb *musb, struct musb_request *req)
  						csr | MUSB_RXCSR_DMAMODE);
  				musb_writew(epio, MUSB_RXCSR, csr);

-				transfer_size = min(request->length - request->actual,
+					transfer_size = min_t(unsigned int,
+							request->length - request->actual,

   Same here.

WBR, Sergei

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux