From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.2 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_MUTT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 48BB0C43613 for ; Thu, 20 Jun 2019 12:20:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 163A82080C for ; Thu, 20 Jun 2019 12:20:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1561033221; bh=n0G/+6qb7qw5DGnYI2pT1g29VJVpYzQKudyEs0DE8DI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:List-ID:From; b=HN9yGmpYiyBa/YHdotF5eEIIjQsG+yH8NCS5WmVvFC8X3XT2GS7EhYukkjvFIngHB fDfVthHQLKhgVUj/RI9yLSD4NlcYmzdBDpI6lRybWTyBIlLIYe5oE5o5ltzjwcDPiJ /1JzMdhVQyal6DJ8DyeFWWBtBZRviYHnX39bito4= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731653AbfFTMUQ (ORCPT ); Thu, 20 Jun 2019 08:20:16 -0400 Received: from mail.kernel.org ([198.145.29.99]:44524 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726874AbfFTMUQ (ORCPT ); Thu, 20 Jun 2019 08:20:16 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 0755F2080C; Thu, 20 Jun 2019 12:20:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1561033215; bh=n0G/+6qb7qw5DGnYI2pT1g29VJVpYzQKudyEs0DE8DI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=oWEOibzHy+eUwIi7JgpV2fKCniqoviMJXdixyunQECR1sDvbhoi/xw3z0xMQfQbOP ieFZ03NknkPs4BTWhH8hKZdPEjNu7xo9zi5pNJ8Z9zBcCQNiJEXcI32IXQU0hc2bnf 072dIUUHeoJq4x9eGU1igMCt+OUOdvoGW0fbvgmU= Date: Thu, 20 Jun 2019 14:20:13 +0200 From: Greg Kroah-Hartman To: Vinod Koul Cc: Mathias Nyman , linux-arm-msm@vger.kernel.org, Bjorn Andersson , linux-usb@vger.kernel.org, linux-kernel@vger.kernel.org, Yoshihiro Shimoda , Christian Lamparter Subject: Re: [PATCH 5/5] usb: xhci: allow multiple firmware versions Message-ID: <20190620122013.GE19295@kroah.com> References: <20190620102154.20805-1-vkoul@kernel.org> <20190620102154.20805-6-vkoul@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190620102154.20805-6-vkoul@kernel.org> User-Agent: Mutt/1.12.1 (2019-06-15) Sender: linux-usb-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-usb@vger.kernel.org On Thu, Jun 20, 2019 at 03:51:54PM +0530, Vinod Koul wrote: > Allow multiple firmware file versions in table and load them in > increasing order as we find them in the file system. > > Signed-off-by: Vinod Koul > Cc: Yoshihiro Shimoda > Cc: Christian Lamparter > --- > drivers/usb/host/xhci-pci.c | 39 +++++++++++++++++++++++++++++++++++++ > 1 file changed, 39 insertions(+) > > diff --git a/drivers/usb/host/xhci-pci.c b/drivers/usb/host/xhci-pci.c > index 3574afac44c5..2ee9e6bbabcb 100644 > --- a/drivers/usb/host/xhci-pci.c > +++ b/drivers/usb/host/xhci-pci.c > @@ -333,9 +333,12 @@ static const struct renesas_fw_entry { > * - uPD720201 ES 2.0 sample whose revision ID is 2. > * - uPD720201 ES 2.1 sample & CS sample & Mass product, ID is 3. > * - uPD720202 ES 2.0 sample & CS sample & Mass product, ID is 2. > + * > + * Entry expected_version should be kept in increasing order Why? > */ > { "K2013080.mem", 0x0014, 0x02, 0x2013 }, > { "K2013080.mem", 0x0014, 0x03, 0x2013 }, > + { "K2026090.mem", 0x0014, 0x03, 0x2026 }, > { "K2013080.mem", 0x0015, 0x02, 0x2013 }, Just put a { } entry here at the end and then you don't care about the order at all. Much simpler and easier to maintain over time. thanks, greg k-h