Received: by 10.213.65.68 with SMTP id h4csp1161869imn; Wed, 14 Mar 2018 11:24:06 -0700 (PDT) X-Google-Smtp-Source: AG47ELvCP6h3X9oG/82xz+f9Xs5Rli2dYi4HCIkPDZ19/ShS6H3DJlLSFGDvajmazaRuENXBDnLY X-Received: by 10.99.147.72 with SMTP id w8mr4584735pgm.208.1521051846616; Wed, 14 Mar 2018 11:24:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521051846; cv=none; d=google.com; s=arc-20160816; b=gM8ccfud8RVCayhhfrM8fH57Sun1HxhnYHwwJVLr/gWBo2lC1YLN3jgFUG5MMDrZ3f OYdctek8TY+FfqBibcAsgjZkmias9LNZY+SXidxwrZ2eGlfTNWgp4VwaKREoVfNBOAZJ dmuHFmqRziSGaFO7EM46Oxjmj970g0olJ1b74PCUjp37yhk6RkEP9VgJXUP5lOnQO8wV Pcg9KrWQYVCegFeqYmfw+c2wszSpC1ixJjr6KxrmQcbg6zqm8NoVxoXo5ywWc5a/XxJl QaX/YHMj3ofKrX42GznDGviPgK2DbCHdmeF1mSaNGVJ7HqfgaDAyxlExhLc+VNqtwFxO 9tLQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date:from :references:cc:to:subject:arc-authentication-results; bh=ro1PZIUfSmP/QQMHe+yoKG3P41nwTTBgRTNTAwLBpPo=; b=bJvGIgmObZUyZddfiqMbe728lDU8hActx5SnyPsWxqUMmrMMLfqcSPm9YqvxB5b1o2 EzOuEM7hstvChIKyNuBtLBtJJbYhdyjA0vOpU58nB/Q0XByxK8JGJz8Fk8Byh2BVf7M+ PKv5HEyeGLn+LCywoSlQssxpm7/p2Ubn7XjiWlYBosXds5x8/Unhym6woC5ywqkDDrph Tc3Yuf/Bs1JobF17AFDUkP7mt9Oh7Kt+T1BjCRJJ0vfW7TVVA7Oxa9HTP5ct7/iAJ+0N RoLw9e/v6FqAEweWShW6/tfWRNEysfjWuZ/1B6LD3bWzLUTPDrleoZwkeE68LAFlbJZv OsVQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i12-v6si2339533plk.508.2018.03.14.11.23.51; Wed, 14 Mar 2018 11:24:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751727AbeCNSW4 (ORCPT + 99 others); Wed, 14 Mar 2018 14:22:56 -0400 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:60616 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751279AbeCNSWy (ORCPT ); Wed, 14 Mar 2018 14:22:54 -0400 Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id w2EIKsbo141100 for ; Wed, 14 Mar 2018 14:22:54 -0400 Received: from e11.ny.us.ibm.com (e11.ny.us.ibm.com [129.33.205.201]) by mx0a-001b2d01.pphosted.com with ESMTP id 2gq5b8anev-1 (version=TLSv1.2 cipher=AES256-SHA256 bits=256 verify=NOT) for ; Wed, 14 Mar 2018 14:22:54 -0400 Received: from localhost by e11.ny.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Wed, 14 Mar 2018 14:22:52 -0400 Received: from b01cxnp23033.gho.pok.ibm.com (9.57.198.28) by e11.ny.us.ibm.com (146.89.104.198) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Wed, 14 Mar 2018 14:22:48 -0400 Received: from b01ledav004.gho.pok.ibm.com (b01ledav004.gho.pok.ibm.com [9.57.199.109]) by b01cxnp23033.gho.pok.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id w2EIMlsn50724958; Wed, 14 Mar 2018 18:22:47 GMT Received: from b01ledav004.gho.pok.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id D6D1E112047; Wed, 14 Mar 2018 14:21:24 -0400 (EDT) Received: from [9.85.181.236] (unknown [9.85.181.236]) by b01ledav004.gho.pok.ibm.com (Postfix) with ESMTP id 92A19112034; Wed, 14 Mar 2018 14:21:22 -0400 (EDT) Subject: Re: [PATCH 1/2, pci] pci: Addition of PCI_DEV_FLAGS_QUIET_PCI_REALIGN attribute to the PCI subsystem To: Bjorn Helgaas Cc: linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, bhelgaas@google.com, benh@kernel.crashing.org, paulus@samba.org, mpe@ellerman.id.au, ruscur@russell.cc, aik@ozlabs.ru, david@gibson.dropbear.id.au, fbarrat@linux.vnet.ibm.com, brking@linux.vnet.ibm.com References: <20180314163455.15854-1-desnesn@linux.vnet.ibm.com> <20180314163455.15854-2-desnesn@linux.vnet.ibm.com> <20180314180642.GC179719@bhelgaas-glaptop.roam.corp.google.com> From: =?UTF-8?Q?Desnes_Augusto_Nunes_do_Ros=c3=a1rio?= Date: Wed, 14 Mar 2018 15:22:44 -0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.2 MIME-Version: 1.0 In-Reply-To: <20180314180642.GC179719@bhelgaas-glaptop.roam.corp.google.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-TM-AS-GCONF: 00 x-cbid: 18031418-2213-0000-0000-0000027F8090 X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00008674; HX=3.00000241; KW=3.00000007; PH=3.00000004; SC=3.00000254; SDB=6.01003024; UDB=6.00510423; IPR=6.00782354; MB=3.00020035; MTD=3.00000008; XFM=3.00000015; UTC=2018-03-14 18:22:51 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18031418-2214-0000-0000-00005969C94D Message-Id: <30c63477-620b-3f8b-82df-fd1e34cd99b8@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:,, definitions=2018-03-14_09:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1709140000 definitions=main-1803140201 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello Bjorn, On 03/14/2018 03:06 PM, Bjorn Helgaas wrote: > On Wed, Mar 14, 2018 at 01:34:54PM -0300, Desnes A. Nunes do Rosario wrote: >> Add PCI_DEV_FLAGS_QUIET_PCI_REALIGN to pci_dev_flags and use it to >> silent PCI realignment messages if the flag is turned on by a driver. >> >> Signed-off-by: Desnes A. Nunes do Rosario >> --- >> drivers/pci/pci.c | 3 ++- >> drivers/pci/setup-res.c | 3 ++- >> include/linux/pci.h | 2 ++ >> 3 files changed, 6 insertions(+), 2 deletions(-) >> >> diff --git a/drivers/pci/pci.c b/drivers/pci/pci.c >> index 8c71d1a66cdd..be197c944e5f 100644 >> --- a/drivers/pci/pci.c >> +++ b/drivers/pci/pci.c >> @@ -5505,7 +5505,8 @@ void pci_reassigndev_resource_alignment(struct pci_dev *dev) >> return; >> } >> >> - pci_info(dev, "Disabling memory decoding and releasing memory resources\n"); >> + if (!(dev->dev_flags & PCI_DEV_FLAGS_QUIET_PCI_REALIGN)) >> + pci_info(dev, "Disabling memory decoding and releasing memory resources\n"); >> pci_read_config_word(dev, PCI_COMMAND, &command); >> command &= ~PCI_COMMAND_MEMORY; >> pci_write_config_word(dev, PCI_COMMAND, command); >> diff --git a/drivers/pci/setup-res.c b/drivers/pci/setup-res.c >> index 369d48d6c6f1..00a538def763 100644 >> --- a/drivers/pci/setup-res.c >> +++ b/drivers/pci/setup-res.c >> @@ -172,7 +172,8 @@ EXPORT_SYMBOL(pci_claim_resource); >> >> void pci_disable_bridge_window(struct pci_dev *dev) >> { >> - pci_info(dev, "disabling bridge mem windows\n"); >> + if (!(dev->dev_flags & PCI_DEV_FLAGS_QUIET_PCI_REALIGN)) >> + pci_info(dev, "disabling bridge mem windows\n"); > > As far as I'm concerned, we can just remove these messages completely. > I don't think there's any real value there. After I found out that this was happening to all PCI devices on powerpc due to the __weak pcibios_default_alignment() interface (necessary for VFIO passthrough and performance), I confess that this was my first approach to this matter; however I couldn't vouch the need of these messages on other architectures. If there are no further concerns, I definitely prefer sending a second version of this patch only eliminating these messages and attesting the reason why. Thank you very much for your review Bjorn, -- Desnes A. Nunes do Rosário