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 D2E0BC433EF for ; Wed, 5 Jan 2022 17:52:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242563AbiAERwM (ORCPT ); Wed, 5 Jan 2022 12:52:12 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60392 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S242576AbiAERvv (ORCPT ); Wed, 5 Jan 2022 12:51:51 -0500 Received: from mail-pf1-x432.google.com (mail-pf1-x432.google.com [IPv6:2607:f8b0:4864:20::432]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BF963C061212 for ; Wed, 5 Jan 2022 09:51:51 -0800 (PST) Received: by mail-pf1-x432.google.com with SMTP id t187so2127pfb.11 for ; Wed, 05 Jan 2022 09:51:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=message-id:date:mime-version:user-agent:subject:to:cc:references :from:in-reply-to; bh=rOF/qbE54zTKxEB1bZkK4jaLuVaDTfmNrTYKMUlEh1s=; b=Q+4ikBePayoQ8Mo4iBS91PhvHSrUshJPUNu/1CPBdCkxZe+7OuUdE74rh8dW9ZgGPk XU1dO17Wrb4M+35WuLF07PCSnCn5XaXaZDkgl2VShVu43SumkETloQCagk/k7EjFZHLc /ywC5A4dXZEK7swvD49S3gjX7i1FTUzXydrEM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:message-id:date:mime-version:user-agent:subject :to:cc:references:from:in-reply-to; bh=rOF/qbE54zTKxEB1bZkK4jaLuVaDTfmNrTYKMUlEh1s=; b=Tf7iJ/m5nb//ZM/iOV40xrdLFSGuzBTkXzPfu9zjugl9FWkRNnsWM/phDpGfGGSoSw kvLfQXECRSC3BuiOru6BrVH6T4Rvv+MpGxgQuIazBEyfWALqVXFFWac7kvVn2xsH5ojQ gM/LX80zxUoZUl9HoV0xy6VLWLu9Ac6TrvtBsecvhCquvYee9SYbZotCWhMIwvStpqqG ULjzpeFVvijyiHsR1DFHnuQbJ8zcgFXNoowzT/ewqAvsluuS6BYlVAcWeq/IZ9EIDYKB F0rdvU8ae9ElDrszpSy23BTY7A1pZQvVtBtknNRJciz+H8hGJAi8dcnvmJX3wIAe26kH 7UOg== X-Gm-Message-State: AOAM530xR4eiSePMy4Y3XNylZnZkZejvryvrR6V8nWA/6TjH5PtvTJxe gxbRY/VTeOMVCAIlKtpqmiC7DvYmR0o6F6kF X-Google-Smtp-Source: ABdhPJzvqmaNg04iaat24IpzZUcCEXAy7LYSrvSFIDZQFdBydqSFyOFhqEsKSR5+viH9EOJBMdUzXQ== X-Received: by 2002:a63:3e41:: with SMTP id l62mr44763809pga.139.1641405111077; Wed, 05 Jan 2022 09:51:51 -0800 (PST) Received: from [10.136.8.222] ([192.19.228.250]) by smtp.gmail.com with ESMTPSA id y37sm36824101pga.78.2022.01.05.09.51.49 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 05 Jan 2022 09:51:50 -0800 (PST) Message-ID: <244e74d9-1b46-2abc-6c2a-c089fa5b68b4@broadcom.com> Date: Wed, 5 Jan 2022 09:51:48 -0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.4.1 Subject: Re: [PATCH] PCI: iproc: Set all 24 bits of PCI class code To: =?UTF-8?Q?Pali_Roh=c3=a1r?= , Roman Bacik , Lorenzo Pieralisi , Rob Herring , =?UTF-8?Q?Krzysztof_Wilczy=c5=84ski?= , Bjorn Helgaas Cc: bcm-kernel-feedback-list@broadcom.com, linux-pci@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org References: <20220105093552.27542-1-pali@kernel.org> From: Ray Jui In-Reply-To: <20220105093552.27542-1-pali@kernel.org> Content-Type: multipart/signed; protocol="application/pkcs7-signature"; micalg=sha-256; boundary="0000000000009ad43d05d4d96851" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --0000000000009ad43d05d4d96851 Content-Language: en-US Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Hi Pali, On 1/5/2022 1:35 AM, Pali Rohár wrote: > Register 0x43c in its low 24 bits contains PCI class code. > > Update code to set all 24 bits of PCI class code and not only upper 16 bits > of PCI class code. > > Use a new macro PCI_CLASS_BRIDGE_PCI_NORMAL which represents whole 24 bits > of normal PCI bridge class. > > Signed-off-by: Pali Rohár > > --- > Roman helped me with this change and confirmed that class code is stored > really in bits [23:0] of custom register 0x43c (normally class code is > stored in bits [31:8] of pci register 0x08). > > This patch depends on patch which adds PCI_CLASS_BRIDGE_PCI_NORMAL macro: > https://lore.kernel.org/linux-pci/20211220145140.31898-1-pali@kernel.org/ > --- > drivers/pci/controller/pcie-iproc.c | 9 ++++----- > 1 file changed, 4 insertions(+), 5 deletions(-) > > diff --git a/drivers/pci/controller/pcie-iproc.c b/drivers/pci/controller/pcie-iproc.c > index 3df4ab209253..2519201b0e51 100644 > --- a/drivers/pci/controller/pcie-iproc.c > +++ b/drivers/pci/controller/pcie-iproc.c > @@ -789,14 +789,13 @@ static int iproc_pcie_check_link(struct iproc_pcie *pcie) > return -EFAULT; > } > > - /* force class to PCI_CLASS_BRIDGE_PCI (0x0604) */ > + /* force class to PCI_CLASS_BRIDGE_PCI_NORMAL (0x060400) */ > #define PCI_BRIDGE_CTRL_REG_OFFSET 0x43c > -#define PCI_CLASS_BRIDGE_MASK 0xffff00 > -#define PCI_CLASS_BRIDGE_SHIFT 8 > +#define PCI_BRIDGE_CTRL_REG_CLASS_MASK 0xffffff > iproc_pci_raw_config_read32(pcie, 0, PCI_BRIDGE_CTRL_REG_OFFSET, > 4, &class); > - class &= ~PCI_CLASS_BRIDGE_MASK; > - class |= (PCI_CLASS_BRIDGE_PCI << PCI_CLASS_BRIDGE_SHIFT); > + class &= ~PCI_BRIDGE_CTRL_REG_CLASS_MASK; > + class |= PCI_CLASS_BRIDGE_PCI_NORMAL; > iproc_pci_raw_config_write32(pcie, 0, PCI_BRIDGE_CTRL_REG_OFFSET, > 4, class); > I have two comments: 1. You do not seem to generate the email list using the get_maintainer.pl script, so the two maintainers for Broadcom ARM architecture (Ray Jui and Scott Branden) are left out. 2. I suppose 'PCI_CLASS_BRIDGE_PCI_NORMAL' is defined in some common PCI header in a separate patch as described in the commit message. Then how come these patches are not constructed with a patch series? Other than, the change itself is exactly what I sent to Roman and looks good to me. Thanks. Acked-by: Ray Jui --0000000000009ad43d05d4d96851 Content-Type: application/pkcs7-signature; name="smime.p7s" Content-Transfer-Encoding: base64 Content-Disposition: attachment; filename="smime.p7s" Content-Description: S/MIME Cryptographic Signature MIIQXgYJKoZIhvcNAQcCoIIQTzCCEEsCAQExDzANBglghkgBZQMEAgEFADALBgkqhkiG9w0BBwGg gg21MIIFDTCCA/WgAwIBAgIQeEqpED+lv77edQixNJMdADANBgkqhkiG9w0BAQsFADBMMSAwHgYD VQQLExdHbG9iYWxTaWduIFJvb3QgQ0EgLSBSMzETMBEGA1UEChMKR2xvYmFsU2lnbjETMBEGA1UE AxMKR2xvYmFsU2lnbjAeFw0yMDA5MTYwMDAwMDBaFw0yODA5MTYwMDAwMDBaMFsxCzAJBgNVBAYT AkJFMRkwFwYDVQQKExBHbG9iYWxTaWduIG52LXNhMTEwLwYDVQQDEyhHbG9iYWxTaWduIEdDQyBS MyBQZXJzb25hbFNpZ24gMiBDQSAyMDIwMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA vbCmXCcsbZ/a0fRIQMBxp4gJnnyeneFYpEtNydrZZ+GeKSMdHiDgXD1UnRSIudKo+moQ6YlCOu4t r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