From: Karel Janda <karel1@tutanota.com>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Linux Media <linux-media@vger.kernel.org>,
Ricardo Ribalda <ribalda@chromium.org>
Subject: Re: [PATCH] media: uvcvideo: Pick first best alternate setting insteed of last
Date: Fri, 20 Oct 2023 16:09:34 +0200 (CEST) [thread overview]
Message-ID: <NhCPsL5--7-9@tutanota.com> (raw)
In-Reply-To: <20231019222430.17043-1-laurent.pinchart@ideasonboard.com>
Hi Laurent,
you pleased me very much, also for your quick reply.
1)
The patch is exactly the same as final state of my debugging.
I just succesfully probe it against uvc_video.c <https://elixir.bootlin.com/linux/v6.6-rc6/source/drivers/media/usb/uvc/uvc_video.c> source on my PC running
Linux HP-Pro-A-MT 6.5.0-9-generic #9-Ubuntu SMP PREEMPT_DYNAMIC
Sat Oct 7 01:35:40 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
with Newmine camera.
/The patch also doesn't hurt my other UVC 1.0 camera, Genius Qcam 6000./
All my 6.5.0 uvc*.c files in uvc directory are clean of any other changes I used for tests before,
only the path of one single line in one file is there now.
Now I also carefully compare 6.5.0 uvc_video.c <https://elixir.bootlin.com/linux/v6.6-rc6/source/drivers/media/usb/uvc/uvc_video.c> original (before the patch) with currect Linux sources at
https://elixir.bootlin.com/linux/v6.6-rc6/source/drivers/media/usb/uvc/uvc_video.c
and also at
https://github.com/torvalds/linux/blob/master/drivers/media/usb/uvc/uvc_video.c
These are different only in few blank characters :)).
I am not able to run last git 6.6 kernel just now, but I hope that my verification by 6.5.0 will be enough.
If is necessery - let me now, I will try compile last kernel on different, dedicated computer.
(I never work with such a big git project. I sometimes used other's ppa results.)
2)
You can mention my name in linux git history, I will be glad.
best regards
Karel Janda
20. 10. 2023 0:24 od laurent.pinchart@ideasonboard.com:
> ---
> Karel, could you please test this patch ? Please also let me know if you
> are fine having your name recorded in the kernel git history with the
> Reported-by and Suggested-by tags above. If not, I will drop them.
> ---
> drivers/media/usb/uvc/uvc_video.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/media/usb/uvc/uvc_video.c b/drivers/media/usb/uvc/uvc_video.c
> index 28dde08ec6c5..7cbf4692bd87 100644
> --- a/drivers/media/usb/uvc/uvc_video.c
> +++ b/drivers/media/usb/uvc/uvc_video.c
> @@ -1954,7 +1954,7 @@ static int uvc_video_start_transfer(struct uvc_streaming *stream,
>
> /* Check if the bandwidth is high enough. */
> psize = uvc_endpoint_max_bpi(stream->dev->udev, ep);
> - if (psize >= bandwidth && psize <= best_psize) {
> + if (psize >= bandwidth && psize < best_psize) {
> altsetting = alts->desc.bAlternateSetting;
> best_psize = psize;
> best_ep = ep;
> --
>
next prev parent reply other threads:[~2023-10-20 14:09 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-19 22:24 [PATCH] media: uvcvideo: Pick first best alternate setting insteed of last Laurent Pinchart
2023-10-20 14:09 ` Karel Janda [this message]
2023-10-20 16:16 ` Karel Janda
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=NhCPsL5--7-9@tutanota.com \
--to=karel1@tutanota.com \
--cc=laurent.pinchart@ideasonboard.com \
--cc=linux-media@vger.kernel.org \
--cc=ribalda@chromium.org \
/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