Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp2374465pxf; Sat, 13 Mar 2021 18:42:10 -0800 (PST) X-Google-Smtp-Source: ABdhPJy/fDnS/r1p+gWcE7yCWJzwyEkV941bG3aZlN+K75Gd2qpkgKwa7uumKin06EEAGBGMoI5U X-Received: by 2002:aa7:c941:: with SMTP id h1mr22599804edt.85.1615689729855; Sat, 13 Mar 2021 18:42:09 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615689729; cv=none; d=google.com; s=arc-20160816; b=Hk45zsDch/FGoqCFjJiXnSjnBaqxdE7m1eFN15fOCZLdfybW95ipYtQVV4DbnZwl+E xC5ogMiSNab0hbAEEnJidXkPbZSNdd1btmrdeGpjestGWMy2VsADXHDh7j0Gbck+DtNU 9TO+6y4sHFDT7MQEdmrHvKcpSQQAuDnmeDpuR4uwbMYKsQ7O5cyVAWQqDfc6ai7lrGEd ANF61oXlGxTXmPmWda1SI3p4ATzOh1lT7/6dks67D6JxyjOJnx6Ai6MShXZEk+crqlRw MsbIPViiIoS40tlGBDJqyOd9w47rL2uYqmk46hLzWne407WKc0TsvBL4S0AckN7HM6XA g6Yg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=WiLmnQQDQ+QmRoWDVaNyDAWg7uxFsnSo0uMgzVcTILY=; b=h4gkxul8CRcOlmTxa/A5cFA3gMuExqYAbZQWfMz4yg3j6CG7BGxiRyAsuyd5fvanAw kqpo7y796nomU2sQ99bhrNhZGbMlq4QDNwlTR/XuJ+lby8nCvj/m8kSqRbSzcXxXRILl btGgqKULcqq/ol62VwKv9nI5V1ncZaoO3aLk/ezVgVVg8g5AzEML1ydOTMyLVQUEPWnh KMWHJm2p80JXpF8NY8jfMhR6RR2uF2BFiFdZ8vb4FdgVJgAGXxF8r6IF2CTxA7cKrIqr YJxMqZ49RjoCJH/thVWuZoJPRD+X5FX6Yaxjx2h5g0/BaLpjEwgjIh/z/vRboduNAEjD Mybg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=iDKnyLBy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id p3si8026482ejd.319.2021.03.13.18.41.29; Sat, 13 Mar 2021 18:42:09 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass (test mode) header.i=@ideasonboard.com header.s=mail header.b=iDKnyLBy; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233868AbhCNCaz (ORCPT + 99 others); Sat, 13 Mar 2021 21:30:55 -0500 Received: from perceval.ideasonboard.com ([213.167.242.64]:45256 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233441AbhCNCan (ORCPT ); Sat, 13 Mar 2021 21:30:43 -0500 Received: from pendragon.ideasonboard.com (62-78-145-57.bb.dnainternet.fi [62.78.145.57]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id 02C1A55C; Sun, 14 Mar 2021 03:30:41 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ideasonboard.com; s=mail; t=1615689042; bh=ibheVfpzm+JE73D5nVjhfA/XFmhnMvmRbtXmyfTRNJk=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=iDKnyLByxnc+cu3aOpqUV3Jdvti1BSI1I7mvH/zau/rooHUY+NeSQLF+SQYgElm9p yOeWXK3alybNmqHy3DipT033C5gL9yy13SovOnpdbzDK/035eSvAWF7QWVet+UvUO0 TBB0rfZOD7YXure8ouUFaAuHrjhZ78xBLzpuZbUQ= Date: Sun, 14 Mar 2021 04:30:06 +0200 From: Laurent Pinchart To: Pawel Laszczak Cc: balbi@kernel.org, gregkh@linuxfoundation.org, linux-api@vger.kernel.org, linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, peter.chen@kernel.org, kurahul@cadence.com Subject: Re: [PATCH 2/2] usb: webcam: Invalid size of Processing Unit Descriptor Message-ID: References: <20210308102735.9251-1-pawell@gli-login.cadence.com> <20210308102735.9251-2-pawell@gli-login.cadence.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20210308102735.9251-2-pawell@gli-login.cadence.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Pawel, Thank you for the patch. On Mon, Mar 08, 2021 at 11:27:35AM +0100, Pawel Laszczak wrote: > From: Pawel Laszczak > > According with USB Device Class Definition for Video Device the > Processing Unit Descriptor bLength should be 12 (10 + bmControlSize), > but it has 11. > > Invalid length caused that Processing Unit Descriptor Test Video form > CV tool failed. To fix this issue patch adds bmVideoStandards into > uvc_processing_unit_descriptor structure. The bmVideoStandards field was added in UVC 1.1, it wasn't part of UVC 1.0a. The commit message should explain this. This change looks good to me, but could you also update drivers/usb/gadget/legacy/webcam.c and drivers/usb/gadget/function/f_uvc.c to explicitly set this field to 0 ? With that, Reviewed-by: Laurent Pinchart > Signed-off-by: Pawel Laszczak > --- > include/uapi/linux/usb/video.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/uapi/linux/usb/video.h b/include/uapi/linux/usb/video.h > index d854cb19c42c..2a54e8fdd341 100644 > --- a/include/uapi/linux/usb/video.h > +++ b/include/uapi/linux/usb/video.h > @@ -302,6 +302,7 @@ struct uvc_processing_unit_descriptor { > __u8 bControlSize; > __u8 bmControls[2]; > __u8 iProcessing; > + __u8 bmVideoStandards; > } __attribute__((__packed__)); > > #define UVC_DT_PROCESSING_UNIT_SIZE(n) (9+(n)) -- Regards, Laurent Pinchart