瀏覽代碼

usb: r8a66597-udc: Fixed bufnum of Bulk

Signed-off-by: Yusuke Goda <yusuke.goda.sx@renesas.com>
Acked-by: Yoshihiro Shimoda <yoshihiro.shimoda.uh@renesas.com>
Cc: Paul Mundt <lethal@linux-sh.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Yusuke Goda 14 年之前
父節點
當前提交
6d86d52a33
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/usb/gadget/r8a66597-udc.c

+ 1 - 1
drivers/usb/gadget/r8a66597-udc.c

@@ -258,7 +258,7 @@ static int pipe_buffer_setting(struct r8a66597 *r8a66597,
 		break;
 		break;
 	case R8A66597_BULK:
 	case R8A66597_BULK:
 		/* isochronous pipes may be used as bulk pipes */
 		/* isochronous pipes may be used as bulk pipes */
-		if (info->pipe > R8A66597_BASE_PIPENUM_BULK)
+		if (info->pipe >= R8A66597_BASE_PIPENUM_BULK)
 			bufnum = info->pipe - R8A66597_BASE_PIPENUM_BULK;
 			bufnum = info->pipe - R8A66597_BASE_PIPENUM_BULK;
 		else
 		else
 			bufnum = info->pipe - R8A66597_BASE_PIPENUM_ISOC;
 			bufnum = info->pipe - R8A66597_BASE_PIPENUM_ISOC;