Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 634C3C433F5 for ; Mon, 29 Nov 2021 23:47:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232993AbhK2XvC (ORCPT ); Mon, 29 Nov 2021 18:51:02 -0500 Received: from gate.crashing.org ([63.228.1.57]:34567 "EHLO gate.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229841AbhK2XvB (ORCPT ); Mon, 29 Nov 2021 18:51:01 -0500 Received: from ip6-localhost (localhost.localdomain [127.0.0.1]) by gate.crashing.org (8.14.1/8.14.1) with ESMTP id 1ATNf0UG024811; Mon, 29 Nov 2021 17:41:01 -0600 Message-ID: <84b2d2c6b530d0a3a9b86b0ffcbfa70935bdb0a9.camel@kernel.crashing.org> Subject: Re: [PATCH 1/3] usb: aspeed-vhub: add qualifier descriptor From: Benjamin Herrenschmidt To: Neal Liu , Felipe Balbi , Greg Kroah-Hartman , Joel Stanley , Andrew Jeffery , Cai Huoqing , Tao Ren , Julia Lawall , kernel test robot , Sasha Levin , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-aspeed@lists.ozlabs.org Cc: BMC-SW@aspeedtech.com Date: Tue, 30 Nov 2021 10:40:59 +1100 In-Reply-To: <20211126110954.2677627-2-neal_liu@aspeedtech.com> References: <20211126110954.2677627-1-neal_liu@aspeedtech.com> <20211126110954.2677627-2-neal_liu@aspeedtech.com> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.5-0ubuntu1 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2021-11-26 at 19:09 +0800, Neal Liu wrote: > > @@ -417,10 +435,9 @@ enum std_req_rc ast_vhub_std_hub_request(struct ast_vhub_ep *ep, > > /* GET/SET_CONFIGURATION */ > case DeviceRequest | USB_REQ_GET_CONFIGURATION: > - return ast_vhub_simple_reply(ep, 1); > + return ast_vhub_simple_reply(ep, vhub->current_config); > case DeviceOutRequest | USB_REQ_SET_CONFIGURATION: > - if (wValue != 1) > - return std_req_stall; > + vhub->current_config = wValue; > return std_req_complete; This is odd.. why should we support arbitrary SET_CONFIGURATION for configs we don't support ? Otherwise looks good. Cheers, Ben.