Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp199165yba; Fri, 12 Apr 2019 01:37:35 -0700 (PDT) X-Google-Smtp-Source: APXvYqwj64doRWxULIRmob2H0DpCiprWkObrMaZi55FqxqTYU+AgFo9EbBi9GyI7GLnHd4AT4QPe X-Received: by 2002:a17:902:d24:: with SMTP id 33mr56965361plu.246.1555058255634; Fri, 12 Apr 2019 01:37:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555058255; cv=none; d=google.com; s=arc-20160816; b=nDE7oE6qK6MLkwLXy3AWDbTZ/jiIk/V2Q4KfTHgytW4Y8MJHaO55p6M5aIYGdNZ+Nd zGOL1xINnh5+pabwkUPjPnzdpNhDTvZn282VP/zNW3U49sVc1TaF9bA2fwV1GUdFlA0X OxbVilbPSa2PyF7Wk6QDZcucAp2V2U6HaPT+OI5BFyRuScH6h0vWCCogGBW6gYDLH7Cn bugp80lofuZ10LgOBEizrsjLplGOw0WjR9BKdWzLMQI6UbpjeLg8eir1CDFPW40m/Jgw vd9oqP6NiwDfls9K48yK0o+Q/whCoqRB3shOOjzyosMUkYcospmVEf9zHsUg/4wm6aO0 Cp6g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=gp9YtnB4iUaVXUZLhRjAvu+m7Z2jChTox4X626rKerQ=; b=dhAvUZYpMFRyF3amIfclLpVaJOzV/OnG4LCMkJBvm3wZHDorBc2VPhtVhNlrJL0WEI UtsLNnHGUbjLNr3pOKFDnrTdW2qPsvtmyLSQf5UZhNwtglkZPZdQ/LYaFH09vHsy2xlM pEsK0MbwF9Yiro03ZlZ7aouEcXi7RZ6aTqeQG2T5q+mI8g30Jqi6hGZIx9b/wxvSKhkm RQrbEN65LwScqoz3xfWkmsJbC/vGDepHXiETLvrRaPP0OO/2tNg8yZqu8QE3YNoV6mJq w2qfFLgsOuIZmRlASjLGMkhZb8SawKdiYKynZ6mhJnFrJTbBROKIUDW+ezoW/OXyGstV VRcQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nxp.com header.s=selector1 header.b=eu53ifXi; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t3si13418302plr.71.2019.04.12.01.37.19; Fri, 12 Apr 2019 01:37:35 -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; dkim=pass header.i=@nxp.com header.s=selector1 header.b=eu53ifXi; 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=pass (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727722AbfDLIgQ (ORCPT + 99 others); Fri, 12 Apr 2019 04:36:16 -0400 Received: from mail-eopbgr80053.outbound.protection.outlook.com ([40.107.8.53]:4153 "EHLO EUR04-VI1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726875AbfDLIgP (ORCPT ); Fri, 12 Apr 2019 04:36:15 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=gp9YtnB4iUaVXUZLhRjAvu+m7Z2jChTox4X626rKerQ=; b=eu53ifXisaS6+MazwSJN6oKjl2KMN1dHoQmq1JVOmeTfuugFsjwkGr7bFQaDMiYhK3iIEbHWBsi2Y1kUpxET15n3CNH3GAHlaYwBuY4oAv373HMmDFJ7drrV2FJ/BRW63x+aDqMz4Aov1WZ30eJ54EGCEi3LsAMiJ8XijKmogf8= Received: from AM6PR04MB5781.eurprd04.prod.outlook.com (20.179.3.19) by AM6PR04MB5846.eurprd04.prod.outlook.com (20.179.3.26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1792.18; Fri, 12 Apr 2019 08:36:06 +0000 Received: from AM6PR04MB5781.eurprd04.prod.outlook.com ([fe80::f9db:ed86:614e:460]) by AM6PR04MB5781.eurprd04.prod.outlook.com ([fe80::f9db:ed86:614e:460%4]) with mapi id 15.20.1792.009; Fri, 12 Apr 2019 08:36:06 +0000 From: "Z.q. Hou" To: "linux-pci@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "bhelgaas@google.com" , "robh+dt@kernel.org" , "mark.rutland@arm.com" , "l.subrahmanya@mobiveil.co.in" , "shawnguo@kernel.org" , Leo Li , "lorenzo.pieralisi@arm.com" , "catalin.marinas@arm.com" , "will.deacon@arm.com" CC: Mingkai Hu , "M.h. Lian" , Xiaowei Bao , "Z.q. Hou" Subject: [PATCHv5 09/20] PCI: mobiveil: Correct inbound/outbound window setup routines Thread-Topic: [PATCHv5 09/20] PCI: mobiveil: Correct inbound/outbound window setup routines Thread-Index: AQHU8QrFfxj3itSLU0yAx2so+j68jQ== Date: Fri, 12 Apr 2019 08:36:06 +0000 Message-ID: <20190412083635.33626-10-Zhiqiang.Hou@nxp.com> References: <20190412083635.33626-1-Zhiqiang.Hou@nxp.com> In-Reply-To: <20190412083635.33626-1-Zhiqiang.Hou@nxp.com> Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-clientproxiedby: HK2PR06CA0011.apcprd06.prod.outlook.com (2603:1096:202:2e::23) To AM6PR04MB5781.eurprd04.prod.outlook.com (2603:10a6:20b:ad::19) authentication-results: spf=none (sender IP is ) smtp.mailfrom=zhiqiang.hou@nxp.com; x-ms-exchange-messagesentrepresentingtype: 1 x-mailer: git-send-email 2.17.1 x-originating-ip: [119.31.174.73] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 92de0ac2-1796-437a-bbf9-08d6bf21e7bc x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: BCL:0;PCL:0;RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(4627221)(201703031133081)(201702281549075)(8990200)(5600139)(711020)(4605104)(4618075)(2017052603328)(7193020);SRVR:AM6PR04MB5846; x-ms-traffictypediagnostic: AM6PR04MB5846: x-microsoft-antispam-prvs: x-forefront-prvs: 0005B05917 x-forefront-antispam-report: SFV:NSPM;SFS:(10009020)(39860400002)(366004)(376002)(396003)(346002)(136003)(189003)(199004)(54534003)(486006)(478600001)(2616005)(476003)(316002)(446003)(11346002)(305945005)(7736002)(81166006)(25786009)(81156014)(256004)(14454004)(8676002)(7416002)(4326008)(186003)(50226002)(26005)(8936002)(68736007)(2906002)(53936002)(102836004)(6512007)(66066001)(86362001)(99286004)(106356001)(6116002)(3846002)(6436002)(97736004)(1076003)(6506007)(386003)(52116002)(2201001)(105586002)(6486002)(36756003)(71200400001)(110136005)(54906003)(5660300002)(2501003)(71190400001)(76176011)(921003)(1121003);DIR:OUT;SFP:1101;SCL:1;SRVR:AM6PR04MB5846;H:AM6PR04MB5781.eurprd04.prod.outlook.com;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;MX:1;A:1; received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: rDOr7VCltQ0PRoI4+XQuPlX/rrvxifIDa3HIDUR+hWb/U7it84KolGUpwZHRjWr0piHXOmDC+8E9kAgmKSsoswTBhS8bFAGHpfMHK/H1cB89+W8cBc1BFYJnszHhTqpOQPqw6Jn9gRZKQv/sUeOlQPv2z7DCFRtxgMe8Qx6KV7REwthq8IPG5/i4pMIoqQyNXDBf9aWX7V76RKG+vKTVkGDWpSJAxrFOMm9pz/LH/+GQcHRsqClVI0iz7M3gicDbCScrIAgqHMVyreki8TGvj8IiUvnmcWqD+PexbOMMuM43VT/suZ6bvEUkuxr73VNSyWzz43kASZsSz5pgmTfRYE0iQAlvhTLD/5y/w+5GrMOA5fCkgNBMPhaR8SKOoBypFAu+9MiSHLtX312nEq085T7rQDnZ2GXp0qBhbr8aDL8= Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: 92de0ac2-1796-437a-bbf9-08d6bf21e7bc X-MS-Exchange-CrossTenant-originalarrivaltime: 12 Apr 2019 08:36:06.6618 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR04MB5846 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org RnJvbTogSG91IFpoaXFpYW5nIDxaaGlxaWFuZy5Ib3VAbnhwLmNvbT4NCg0KT3V0Ym91bmQgd2lu ZG93IHJvdXRpbmU6DQogLSBSZW1vdmUgdW51c2VkIHZhciBkZWZpbml0aW9ucyBhbmQgcmVnaXN0 ZXIgcmVhZCBvcGVyYXRpb25zLg0KIC0gQWRkIHRoZSB1cHBlciAzMi1iaXQgY3B1IGFkZHJlc3Mg c2V0dXAgb2YgdGhlIHdpbmRvdy4NCiAtIEluc3RlYWQgb2YgYmxpbmRseSB3cml0ZSwgb25seSBj aGFuZ2UgdGhlIGZpZWxkcyBzcGVjaWZpZWQuDQogLSBNYXNrIHRoZSBsb3d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