Received: by 2002:a05:6500:1b8f:b0:1fa:5c73:8e2d with SMTP id df15csp525730lqb; Wed, 29 May 2024 03:06:37 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVLTUPwjxVRctF5m2VzZCvXdRLF4sNZPzqi/10VIf+KPwxi2SExFRnypQ6NBK8nQSMdZhsUh/+GLjMRqxOY4FGCGTskB88fntUIxOh+sw== X-Google-Smtp-Source: AGHT+IG0sizx/XDJ3QsW0omArZ++CXr8RdYTxSFi+MDKzyLSgjmFhywgX5Q0CYkmS6rHlzdFsM+2 X-Received: by 2002:a05:6830:2642:b0:6f0:6170:53da with SMTP id 46e09a7af769-6f8d0a86acbmr17470908a34.19.1716977197679; Wed, 29 May 2024 03:06:37 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1716977197; cv=pass; d=google.com; s=arc-20160816; b=soMHohKtRIZ/JzycEeCl1NBZYELCbtWwaqOTN4n3wvBb+j8bHF3Fvg8cEHhOXfBFw9 CRVLGjEIbxR3dXnZeZXG3KrHimbVyiZ7AOSSNeKI0QQkwZ8XHWMoz4XIQQ7OmuIfsn4h sHXUaJQbrw7LhsyscgNeYy+iLXyBLZjzMWsqYu5IWiKtg/e837kWO9MHMIF2z1rYrOUM GE74Il5x+2wVrepdtHAKrdxXayyr3zRIHobQxyO2a13LwHfQvqzpWjcR7/7MnME75hT+ uH3s6MfXEXoL/78cH9USlrA6H8dZH1AuhVzlsn0y57goBrzqFRRmeksb0HdRzsYpysNn fwaQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:cc:to:subject:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id; bh=wSH0rFdiZDskff4B73r1uwLJE51HvxUln9moOC4D8z4=; fh=Cz5HkxnKU7wdec4CwCGqulLXfaNbYR8t7hxFaTwE8es=; b=qeOnldofO64dktLA2/UCjK7H75/FXm67NXBP7ZJaHaVJMCd7U15XrXDAnjz1u75lcj tZQDlTRPcee4HbXkyrPXwUhVhHQKtgYOjwwc4QPF+9+zhQ7T6AQkAyRNpOVkgoLJ4jPY kO9bNF/KCckn7pinj8XEUu36Rb5eA1GlqT4qJmM3vTIwaK31bUVpuasqQrMo9pvbkbLg oFPDf3uNr6CLKTkC+QzZuWyCWEdIbH96hzK+7UMVfF3Z9fmdaMbZlj+LkRlYiZzIat/x LPByqv5DVR3trnS65rTxfChTKmXc1dFHUIUkcbkSA+rJym2+J/nYHunCkwL4Ee5bFLg5 tvTA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=molgen.mpg.de); spf=pass (google.com: domain of linux-bluetooth+bounces-5023-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-5023-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id d75a77b69052e-43fb17baf52si123636611cf.27.2024.05.29.03.06.37 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 03:06:37 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-bluetooth+bounces-5023-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=molgen.mpg.de); spf=pass (google.com: domain of linux-bluetooth+bounces-5023-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-bluetooth+bounces-5023-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 675AC1C2356D for ; Wed, 29 May 2024 10:06:37 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id AD25817B406; Wed, 29 May 2024 10:06:27 +0000 (UTC) X-Original-To: linux-bluetooth@vger.kernel.org Received: from mx3.molgen.mpg.de (mx3.molgen.mpg.de [141.14.17.11]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 5F4CF31A60; Wed, 29 May 2024 10:06:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=141.14.17.11 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716977187; cv=none; b=jExvA05/sTJWKShe426qj6C9+QZ2O0x+eZZgYmKauFCg2/O36antdn/+AO5UTjJr7pK3mnfkQBT0hBhCqSmbJmNTM7MAuqRfQMOKHVYhcy2Z53IPuqQATgo7jN+c/REXj5dOaTEYCpK/iSsvF10MEBT0v8n2v7j2gN8Qcmo0/GE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1716977187; c=relaxed/simple; bh=G1Rk+7kEkFD09wELNnRj53zJwtqDGrgnZU8T7fnfjek=; h=Message-ID:Date:MIME-Version:Subject:To:Cc:References:From: In-Reply-To:Content-Type; b=KLQdI1tLIJE2JQiMec2wxw0VHutBTF3Yh0jmsoMNqKamK72U+/K2orPm5/A25o4QXcSg/oHCBvjy1FxIPcH23lUD8De6EtNboIidZmkskBwQ1zroQ7uXc5TADuI/9SkFFH58Zw4ciivK1YrS9/jw42UxVhpLgSygWFo/ciX+jG4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=molgen.mpg.de; spf=pass smtp.mailfrom=molgen.mpg.de; arc=none smtp.client-ip=141.14.17.11 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=molgen.mpg.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=molgen.mpg.de Received: from [192.168.0.3] (ip5f5af7f7.dynamic.kabel-deutschland.de [95.90.247.247]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: pmenzel) by mx.molgen.mpg.de (Postfix) with ESMTPSA id ABB5461E5FE01; Wed, 29 May 2024 12:05:43 +0200 (CEST) Message-ID: <52ccf0c1-e5dd-412b-9e47-7829ca0f6ffc@molgen.mpg.de> Date: Wed, 29 May 2024 12:05:42 +0200 Precedence: bulk X-Mailing-List: linux-bluetooth@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v3 2/2] Bluetooth: btnxpuart: Update firmware names To: Neeraj Sanjay Kale Cc: marcel@holtmann.org, luiz.dentz@gmail.com, davem@davemloft.net, edumazet@google.com, kuba@kernel.org, pabeni@redhat.com, robh@kernel.org, krzk+dt@kernel.org, conor+dt@kernel.org, linux-bluetooth@vger.kernel.org, netdev@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, amitkumar.karwar@nxp.com, rohit.fule@nxp.com, sherry.sun@nxp.com, ziniu.wang_1@nxp.com, haibo.chen@nxp.com, LnxRevLi@nxp.com, regressions@lists.linux.dev References: <20240529095347.22186-1-neeraj.sanjaykale@nxp.com> <20240529095347.22186-3-neeraj.sanjaykale@nxp.com> Content-Language: en-US From: Paul Menzel In-Reply-To: <20240529095347.22186-3-neeraj.sanjaykale@nxp.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit [Cc: regressions@] Dear Neeraj, Am 29.05.24 um 11:53 schrieb Neeraj Sanjay Kale: > This updates the firmware names of 3 chipsets: w8987, w8997, w9098. > These changes are been done to standardize chip specific firmware > file names. Can you please describe the new naming schema in the commit message? > To allow user to use older firmware file names, a new device tree > property has been introduced called firmware-name, which will override > the hardcoded firmware names in the driver. So users updating the Linux kernel but not updating the devicetree with the new property are going to see a regression, right? I think this violates Linux’ no regression policy. If so, please implement a way to support old and new names. > Signed-off-by: Neeraj Sanjay Kale > --- > v2: Remove "nxp/" from all firmware name definitions to be inline with > firware file name read from device tree file. (Krzysztof) fir*m*ware > --- > drivers/bluetooth/btnxpuart.c | 28 +++++++++++++++++----------- > 1 file changed, 17 insertions(+), 11 deletions(-) > > diff --git a/drivers/bluetooth/btnxpuart.c b/drivers/bluetooth/btnxpuart.c > index 0b93c2ff29e4..4442d911eba8 100644 > --- a/drivers/bluetooth/btnxpuart.c > +++ b/drivers/bluetooth/btnxpuart.c > @@ -33,16 +33,16 @@ > /* NXP HW err codes */ > #define BTNXPUART_IR_HW_ERR 0xb0 > > -#define FIRMWARE_W8987 "nxp/uartuart8987_bt.bin" > -#define FIRMWARE_W8997 "nxp/uartuart8997_bt_v4.bin" > -#define FIRMWARE_W9098 "nxp/uartuart9098_bt_v1.bin" > -#define FIRMWARE_IW416 "nxp/uartiw416_bt_v0.bin" > -#define FIRMWARE_IW612 "nxp/uartspi_n61x_v1.bin.se" > -#define FIRMWARE_IW624 "nxp/uartiw624_bt.bin" > -#define FIRMWARE_SECURE_IW624 "nxp/uartiw624_bt.bin.se" > -#define FIRMWARE_AW693 "nxp/uartaw693_bt.bin" > -#define FIRMWARE_SECURE_AW693 "nxp/uartaw693_bt.bin.se" > -#define FIRMWARE_HELPER "nxp/helper_uart_3000000.bin" > +#define FIRMWARE_W8987 "uart8987_bt_v0.bin" > +#define FIRMWARE_W8997 "uart8997_bt_v4.bin" > +#define FIRMWARE_W9098 "uart9098_bt_v1.bin" > +#define FIRMWARE_IW416 "uartiw416_bt_v0.bin" > +#define FIRMWARE_IW612 "uartspi_n61x_v1.bin.se" > +#define FIRMWARE_IW624 "uartiw624_bt.bin" > +#define FIRMWARE_SECURE_IW624 "uartiw624_bt.bin.se" > +#define FIRMWARE_AW693 "uartaw693_bt.bin" > +#define FIRMWARE_SECURE_AW693 "uartaw693_bt.bin.se" > +#define FIRMWARE_HELPER "helper_uart_3000000.bin" > > #define CHIP_ID_W9098 0x5c03 > #define CHIP_ID_IW416 0x7201 > @@ -685,13 +685,19 @@ static bool process_boot_signature(struct btnxpuart_dev *nxpdev) > static int nxp_request_firmware(struct hci_dev *hdev, const char *fw_name) > { > struct btnxpuart_dev *nxpdev = hci_get_drvdata(hdev); > + const char *fw_name_dt; > int err = 0; > > if (!fw_name) > return -ENOENT; > > if (!strlen(nxpdev->fw_name)) { > - snprintf(nxpdev->fw_name, MAX_FW_FILE_NAME_LEN, "%s", fw_name); > + if (strcmp(fw_name, FIRMWARE_HELPER) && > + !device_property_read_string(&nxpdev->serdev->dev, > + "firmware-name", > + &fw_name_dt)) > + fw_name = fw_name_dt; > + snprintf(nxpdev->fw_name, MAX_FW_FILE_NAME_LEN, "nxp/%s", fw_name); > > bt_dev_dbg(hdev, "Request Firmware: %s", nxpdev->fw_name); > err = request_firmware(&nxpdev->fw, nxpdev->fw_name, &hdev->dev); Kind regards, Paul