linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mathias Nyman <mathias.nyman@linux.intel.com>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: gregkh@linuxfoundation.org, linux-usb@vger.kernel.org,
	linux-media@vger.kernel.org, laurent.pinchart@ideasonboard.com,
	hdegoede@redhat.com, Thinh.Nguyen@synopsys.com,
	Amardeep Rai <amardeep.rai@intel.com>,
	Sakari Ailus <sakari.ailus@linux.intel.com>
Subject: Re: [PATCH 2/3] USB: core: support eUSB2 double bandwidth large isoc URB frames
Date: Mon, 16 Jun 2025 18:36:26 +0300	[thread overview]
Message-ID: <a02dc07c-6d6a-4f3a-af3f-a51ff50b172f@linux.intel.com> (raw)
In-Reply-To: <c82aa592-7904-44c1-b595-ede6eed14ee4@rowland.harvard.edu>


>> @@ -434,7 +435,12 @@ int usb_submit_urb(struct urb *urb, gfp_t mem_flags)
>>   		return -ENODEV;
>>   
>>   	max = usb_endpoint_maxp(&ep->desc);
>> -	if (max <= 0) {
>> +	is_eusb2_isoch_double = dev->speed == USB_SPEED_HIGH &&
>> +				xfertype == USB_ENDPOINT_XFER_ISOC &&
>> +				usb_endpoint_dir_in(&ep->desc) &&
>> +				le16_to_cpu(dev->descriptor.bcdUSB == 0x220) &&
>> +				le16_to_cpu(ep->desc.wMaxPacketSize == 0);
>> +	if (max < 0 || (max == 0 && !is_eusb2_isoch_double)) {
> 
> Minor point: It's impossible to have max < 0 here, because
> usb_endpoint_maxp() always returns a non-negative value (the return
> value is &'ed with 0x07ff).  That part of the test can be removed.
> 
> Alan Stern
> 

Thanks, will fix this for v2
-Mathias

  reply	other threads:[~2025-06-16 15:36 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-16  9:37 [PATCH 0/3] USB: Enable eUSB2 double isochronous bandwidth Mathias Nyman
2025-06-16  9:37 ` [PATCH 1/3] xhci: Add host support for eUSB2 double isochronous bandwidth devices Mathias Nyman
2025-06-16  9:37 ` [PATCH 2/3] USB: core: support eUSB2 double bandwidth large isoc URB frames Mathias Nyman
2025-06-16 14:07   ` Alan Stern
2025-06-16 15:36     ` Mathias Nyman [this message]
2025-06-16  9:37 ` [PATCH 3/3] media: uvcvideo: eUSB2 double isochronous bandwidth support Mathias Nyman
2025-06-16  9:43   ` Laurent Pinchart
2025-06-16 13:05     ` Mathias Nyman
2025-06-16 13:22       ` Laurent Pinchart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a02dc07c-6d6a-4f3a-af3f-a51ff50b172f@linux.intel.com \
    --to=mathias.nyman@linux.intel.com \
    --cc=Thinh.Nguyen@synopsys.com \
    --cc=amardeep.rai@intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=hdegoede@redhat.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-media@vger.kernel.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=sakari.ailus@linux.intel.com \
    --cc=stern@rowland.harvard.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).