Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp958107pxu; Wed, 7 Oct 2020 22:35:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyhdNeMsOJXzSCwbO1RfhSaGPk/g5//YMFhbK3n+4cuJB3udMQebErF0DIJZDo77oRa8YYR X-Received: by 2002:a17:906:1e15:: with SMTP id g21mr6620246ejj.131.1602135321907; Wed, 07 Oct 2020 22:35:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602135321; cv=none; d=google.com; s=arc-20160816; b=UgpxpuldYjCM0E1MLojYdxffQwQhx6vHV8xZhkGWwTamKhmKKEziJj5+P93k0rUQGy tFnOWJnJiKtgHfoZHqF4I38FCUNmm1iNQVXkEOvouuLqv3YwwzbhRAUIPHHbIG+Xh7d4 m//0wuAm2XfuttaTxqSNuEoTPOaQUKmphlG9N+xlJ8V9v8/t1CniH09Sf+ZBX9rpwojZ ZTOrCVuJD6a92LnSJ4DcRnkb3IV1KaaYdqH6K8Y4qWDF2dYruhQmTX3RO8cNvVfGOlrj 7Et0F8wPNz1+LleXBetbVbsuKvAN7spFjyvx5C+NQ4FCdcdyM94IHyYhj7/tE1oQutEn J2rw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:dkim-signature:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=J4CEG7z41t4fftMpaxkaa5Era9zth5z8jjZg7k+ZCts=; b=FHDw2pj8+oaS1wqOhp07vjOUZ+JjN8syt1sn8GDX48RA0pB/cLkvQzGQGnvmj18jr1 ZnzgnHm0fxUCRnHKATYWeytE6TYfO44Bo1TecqhnfAOZsJIiMiJmo9ubgEEeMhqsAD2N BzehlWCThMXEHAeCVFkeiUGGKXu/hsRTCMzMWwQWMaTy7ZJGvPB9yJxkQinxtRB7Tc07 JjXw4K4aiwtzbUPrfy/aeNWv6457ujSld2GwwE/6HLRsVC9iNZniFYTFnoJjHNsifrRt WeSmWO1+J/H29GXjv/xov1BT87/9kcEmfiret7D7h2UnS9nlR1GXDkZqg8tx14jqpr4I Pffg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=gGiVTnDK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cf8si1879418ejb.203.2020.10.07.22.34.58; Wed, 07 Oct 2020 22:35:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=gGiVTnDK; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728132AbgJHFdW (ORCPT + 99 others); Thu, 8 Oct 2020 01:33:22 -0400 Received: from hqnvemgate25.nvidia.com ([216.228.121.64]:12999 "EHLO hqnvemgate25.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726148AbgJHFdW (ORCPT ); Thu, 8 Oct 2020 01:33:22 -0400 Received: from hqmail.nvidia.com (Not Verified[216.228.121.13]) by hqnvemgate25.nvidia.com (using TLS: TLSv1.2, AES256-SHA) id ; Wed, 07 Oct 2020 22:32:23 -0700 Received: from [10.25.74.27] (172.20.13.39) by HQMAIL107.nvidia.com (172.20.187.13) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Thu, 8 Oct 2020 05:32:58 +0000 Subject: Re: [PATCH v2 0/5] PCI: dwc: improve msi handling To: Jisheng Zhang CC: Kishon Vijay Abraham I , Lorenzo Pieralisi , Rob Herring , Bjorn Helgaas , Jingoo Han , Kukjin Kim , Krzysztof Kozlowski , Richard Zhu , Lucas Stach , Shawn Guo , Sascha Hauer , "Pengutronix Kernel Team" , Fabio Estevam , "NXP Linux Team" , Yue Wang , "Kevin Hilman" , Neil Armstrong , Jerome Brunet , Martin Blumenstingl , Jesper Nilsson , Gustavo Pimentel , Xiaowei Song , Binghui Wang , Andy Gross , Bjorn Andersson , Stanimir Varbanov , Pratyush Anand , Thierry Reding , Jonathan Hunter , "Kunihiko Hayashi" , Masahiro Yamada , "linux-omap@vger.kernel.org" , "linux-pci@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , "linux-samsung-soc@vger.kernel.org" , "linux-amlogic@lists.infradead.org" , "linux-arm-kernel@axis.com" , "linux-arm-msm@vger.kernel.org" , "linux-tegra@vger.kernel.org" References: <20200924190421.549cb8fc@xhacker.debian> <20201006143647.3f989340@xhacker.debian> From: Vidya Sagar Message-ID: <435c8cf8-8f4a-c491-4aca-3ec5b7abe49a@nvidia.com> Date: Thu, 8 Oct 2020 11:02:54 +0530 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.2.1 MIME-Version: 1.0 In-Reply-To: <20201006143647.3f989340@xhacker.debian> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [172.20.13.39] X-ClientProxiedBy: HQMAIL107.nvidia.com (172.20.187.13) To HQMAIL107.nvidia.com (172.20.187.13) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1602135143; bh=J4CEG7z41t4fftMpaxkaa5Era9zth5z8jjZg7k+ZCts=; h=Subject:To:CC:References:From:Message-ID:Date:User-Agent: MIME-Version:In-Reply-To:Content-Type:Content-Language: Content-Transfer-Encoding:X-Originating-IP:X-ClientProxiedBy; b=gGiVTnDKnvH3IW3q8erfoIHhPlDmnbH2thdoY4rptWoPCwmwQxfo0RIcd6vK7za+a qgXLjiuv+uk3BJx5tDpmSQbDqUWKoQT3pRifw4gmZgEkA3RCj+BkqAEyGD6U4bOMRW 7YyxCLCtjO6qbXeESHYlP9z93kG3O82AA69UQ3ntIr7k056NtyNn++sDetOOUG9on9 TLtrQofmOFFUqspaxJYSK34woIeLsROw+yztJ5/3W8Z0lg/zdHFQ7f3LuLDNI6K7bW 8eHbfb3P1ff5T55KfN3H8s00wH7Fd2T5ZOlcWCQii/0bU80nfxDTNlQkTNzGgPp5vF Rmin14uLeUy0A== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 10/6/2020 12:06 PM, Jisheng Zhang wrote: > External email: Use caution opening links or attachments > > > On Tue, 6 Oct 2020 11:56:34 +0530 Vidya Sagar wrote: > >> >> >> Hi, > > Hi, > >> I would like to verify this series along with the other series "PCI: >> dwc: fix two MSI issues" on Tegra194. I tried to apply these series on >> both linux-next and Lorenzo's pci/dwc branches but there seem to be non >> trivial conflicts. Could you please tell me which branch I can use and >> apply these series cleanly? > > This is a fix, so I thought the series would be picked up in v5.9, so the > series is patched against v5.9-rcN > > could you please try v5 https://lkml.org/lkml/2020/9/29/2511 on v5.9-rc7? I tried this series on top of v5.9-rc7 and it worked as expected on Tegra194 platform. Also, I couldn't cleanly apply the other series 'PCI: dwc: fix two MSI issues' on top. Could you please rebase them? Thanks, Vidya Sagar > > > Thanks > >> FWIW, I acknowledge that the existing code does leak MSI target page >> every time system goes through suspend-resume sequence on Tegra194. >> >> Thanks, >> Vidya Sagar >> >> On 9/24/2020 4:35 PM, Jisheng Zhang wrote: >>> External email: Use caution opening links or attachments >>> >>> >>> Improve the msi code: >>> 1. Add proper error handling. >>> 2. Move dw_pcie_msi_init() from each users to designware host to solve >>> msi page leakage in resume path. >>> >>> Since v1: >>> - add proper error handling patches. >>> - solve the msi page leakage by moving dw_pcie_msi_init() from each >>> users to designware host >>> >>> >>> Jisheng Zhang (5): >>> PCI: dwc: Call dma_unmap_page() before freeing the msi page >>> PCI: dwc: Check alloc_page() return value >>> PCI: dwc: Rename dw_pcie_free_msi to dw_pcie_msi_deinit >>> PCI: dwc: Skip PCIE_MSI_INTR0* programming if MSI is disabled >>> PCI: dwc: Move dw_pcie_msi_init() from each users to designware host >>> >>> drivers/pci/controller/dwc/pci-dra7xx.c | 1 + >>> drivers/pci/controller/dwc/pci-exynos.c | 2 - >>> drivers/pci/controller/dwc/pci-imx6.c | 3 -- >>> drivers/pci/controller/dwc/pci-meson.c | 8 ---- >>> drivers/pci/controller/dwc/pcie-artpec6.c | 10 ----- >>> .../pci/controller/dwc/pcie-designware-host.c | 43 +++++++++++++------ >>> .../pci/controller/dwc/pcie-designware-plat.c | 3 -- >>> drivers/pci/controller/dwc/pcie-designware.h | 9 +++- >>> drivers/pci/controller/dwc/pcie-histb.c | 3 -- >>> drivers/pci/controller/dwc/pcie-kirin.c | 3 -- >>> drivers/pci/controller/dwc/pcie-qcom.c | 3 -- >>> drivers/pci/controller/dwc/pcie-spear13xx.c | 1 - >>> drivers/pci/controller/dwc/pcie-tegra194.c | 2 - >>> drivers/pci/controller/dwc/pcie-uniphier.c | 9 +--- >>> 14 files changed, 38 insertions(+), 62 deletions(-) >>> >>> -- >>> 2.28.0 >>> >