Received: by 2002:a05:6a10:d5a5:0:0:0:0 with SMTP id gn37csp2569295pxb; Fri, 8 Oct 2021 10:21:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy7ZGitrqb9A8bzw4P1TfRZYgkNWZSjVQOUCS4H9u6IVclTN1WaYqpPQZZKgduTPOotDu9X X-Received: by 2002:a63:b204:: with SMTP id x4mr5545051pge.212.1633713671125; Fri, 08 Oct 2021 10:21:11 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1633713671; cv=pass; d=google.com; s=arc-20160816; b=ytXSag1fiJzS5LVUGzRjCO6Wvtjp6czFx11PxjM8Sj3LPBT5CQm5TAwOL528U+tder QfbEYfA1x9r4jljY+o+xbftQ8X4LO/DjFMnFhk283mtNFBIVb72blWZVJLo9v1VMNOs2 mqdoojAB6T2SlCMe4P3EU0vsHj2DJTCKCKFvQB9I0+ENxZyDOmHg3PRyf+pS/bVfXw1n 4btCTRbLKh1UQhGBs5sqxChQlOduvGwV0nSefx5QJ1+dI6rhqIHKpJGMMGczsul0lBQj 1rWsO9tBLrY7pt41R1dcD+DCtf3Hu8BhsfkWAb/iFDOAt8t8qz5BRUtsEnk14e60EB8d hp8w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:content-transfer-encoding :msip_labels:content-language:accept-language:message-id:date :thread-index:thread-topic:subject:cc:to:from:dkim-signature; bh=AIWI9usN7Wtk7PeGlgiXa3+a5hwHulxPebracARxzNk=; b=TkQujQmKfUaVIe6SfxXJlYdodjcdUDE+mnJEuT4Ux9RwVZDfwGyMyiYfNAwbZhz4zp gpi264YHnk4BNrTR19B2faeVhwrm9lg0dmU9uYKwYzitMMql5fIfaNwYzsC7BkzR8EAg 5GP9mCJEHiO5lHtgwJplIiZRk+b4BL6HVnguJ3GRbid0EXvBCeCZM1S6zy041PoPs/ee F37V97+G0IyY/1um3AGKrcrEiEbgJSJe1QqCAGYQoMoYTOUKqU54BhJSFZojK9GrHa+2 9ukWYEyZNPZiWXixO54mcNuCQeJz1zFoiGcmAtZ/JT+j7T8ukuFEBNuCVMaKpAACxnPK fsSQ== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@microsoft.com header.s=selector2 header.b=Y2LqBWk+; arc=pass (i=1 spf=pass spfdomain=microsoft.com dkim=pass dkdomain=microsoft.com dmarc=pass fromdomain=microsoft.com); 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=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z10si3860036pgi.529.2021.10.08.10.20.54; Fri, 08 Oct 2021 10:21:11 -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=@microsoft.com header.s=selector2 header.b=Y2LqBWk+; arc=pass (i=1 spf=pass spfdomain=microsoft.com dkim=pass dkdomain=microsoft.com dmarc=pass fromdomain=microsoft.com); 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=REJECT sp=REJECT dis=NONE) header.from=microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231237AbhJHRVx (ORCPT + 99 others); Fri, 8 Oct 2021 13:21:53 -0400 Received: from mail-oln040093003002.outbound.protection.outlook.com ([40.93.3.2]:19149 "EHLO na01-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S229606AbhJHRVx (ORCPT ); Fri, 8 Oct 2021 13:21:53 -0400 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=CXXIDgByzRHS2odzJ/AtcaAnBsoHxXooRCmbWI4KZTqb2AePfRuOvk0tqO1xc8/obgZ/idmNNSDRf3FMi2WGKjVWjdfeD+Xt2OI+s2/+FnSFEdlkSmR7fvPn++sn/h7Rmhi1uXhOX+Md97RZ9ZoaFZ76SZ6evidSiogG13Cn0Aj9eGC8ju1+jNE8JTaAnYOVyi13aW2cu5PozRqtNBZZR/DGUXfyqD3QSn8Q5g1t1YTsn6aivMjL17oDkmGNyjB/E/gMGgekh27mEtP6FEaB0jKZj7R8XS4OS/u+y3gV9EaK5oAi1HnknxF3msNYvyc4Kj4sv7VVyE1xgzfkGkE0RA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=AIWI9usN7Wtk7PeGlgiXa3+a5hwHulxPebracARxzNk=; b=nG12siMC6DVwDY0yTRIr5b1z5JG+qP3VXhL9UPjq0PS6rjQLVN7czaKhTwBLgJoQk12xKUPYiTA8Py6puCyBUqnD4l7UC0QNxVnY+u8IAG1mXTpA0ZD8dHj5G4xlOpydUOPcDDBLDqpw5N8Nuwe+uryPyk72xFSMjyLwuojPG1cWCPbBHD5w22unr+OzrYqDWL+V5XpR+D9FZ7YmD97g1sQMQQt+cplSdbA70jwCf3GngIeVnO9khFNAagO1lmAYWPzlQH97NuVpVnavZpOv+rl+Yd7OpZPDXdXCTES7m6WsaLl2qMPN9xwlxSjz2OvZ+9zugDyOuKutD4sNlO1hWw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=microsoft.com; dmarc=pass action=none header.from=microsoft.com; dkim=pass header.d=microsoft.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=AIWI9usN7Wtk7PeGlgiXa3+a5hwHulxPebracARxzNk=; b=Y2LqBWk+GP96/WQplWgmBsgmtGnJLoireLzA1+Sl3EH0RytS1lesixv/G4ZBgoUzRVo+y5CsLwKGSJs7lzMAtOHAi2h07McipSmONzz/0l1ABPh10EhO6xuKZ0ue6E1R1gVODh5ehgkXM74N2RunRL8AfN8nFzvbZVRYiVYsBEE= Received: from MW4PR21MB2002.namprd21.prod.outlook.com (2603:10b6:303:68::18) by MW2PR2101MB1851.namprd21.prod.outlook.com (2603:10b6:302:c::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4608.1; Fri, 8 Oct 2021 17:19:53 +0000 Received: from MW4PR21MB2002.namprd21.prod.outlook.com ([fe80::89fe:5bf:5eb2:4c55]) by MW4PR21MB2002.namprd21.prod.outlook.com ([fe80::89fe:5bf:5eb2:4c55%4]) with mapi id 15.20.4608.008; Fri, 8 Oct 2021 17:19:53 +0000 From: Sunil Muthuswamy To: Marc Zyngier , Michael Kelley , Boqun Feng , KY Srinivasan , Haiyang Zhang , Stephen Hemminger , Dexuan Cui , Lorenzo Pieralisi , Rob Herring , =?iso-8859-2?Q?=22Krzysztof_Wilczy=F1ski=22?= , Bjorn Helgaas , Wei Liu CC: Thomas Gleixner , Ingo Molnar , Borislav Petkov , "\"H. Peter Anvin\"" , Arnd Bergmann , "linux-hyperv@vger.kernel.org" , "linux-pci@vger.kernel.org" , "linux-kernel@vger.kernel.org" Subject: [PATCH v2 0/2] PCI: hv: Hyper-V vPCI for ARM64 Thread-Topic: [PATCH v2 0/2] PCI: hv: Hyper-V vPCI for ARM64 Thread-Index: Ade8Z9t+jRUuLsS9S2C/sb8+Gj5obw== Date: Fri, 8 Oct 2021 17:19:53 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_ActionId=0a970baf-4191-44cf-9a6b-38ca92bcc987;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_ContentBits=0;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Enabled=true;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Method=Standard;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_Name=Internal;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SetDate=2021-10-08T17:08:01Z;MSIP_Label_f42aa342-8706-4288-bd11-ebb85995028c_SiteId=72f988bf-86f1-41af-91ab-2d7cd011db47; authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=microsoft.com; x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 39e0218e-c9e7-4d21-d083-08d98a7fd800 x-ms-traffictypediagnostic: MW2PR2101MB1851: x-ms-exchange-transport-forked: True x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:1013; x-ms-exchange-senderadcheck: 1 x-ms-exchange-antispam-relay: 0 x-microsoft-antispam: BCL:0; x-microsoft-antispam-message-info: lYFfeeO4JmkO0F8jD3LYxmSfpTl1vOeVzRbyDmRwIr7GY4EaZ51i3HP/t64l/YxaQbsgy6qcLG4LU2aQBucGWmRdFpR68K/zNwHpIP1+KbOkCaOyi6xTCBj7XlGbGUsJRoh1aHo+pjw/xYJ5099Jn2bcOKJ9T7XjVA8O6Sx7pudfVsjR1TshwIG4zjCJsEGdIp0wIM8W7nOGP3kW4CIkZKMnTUEhLHJsFimJJyfYBC9X6ySzVVNJIm3Qmmq05GZvYB9vIrRBPj+EBLrdsdgUADxJZwSnRzi+qBtFIfDDrwm/bAySllIqHOmncuE0O9FWcJQO7eKhu9GnHe2quo2BQtuvrn7wHOIuR0VGSpcYPInCPxVHnsMC/XTCMgDx3CsYWOM8w+F4qPhW+KxSRvEFSfisYLwkSE/qARMiSwktaZaFLgvEwwUx2nLkSPGaLC6Hl+HRer/ZEbqABdeC72gow/pVyg26pXM8BKunhiLKAccEf2qBqUGECq+N8aBscL38ufKysDuzzFEnb0yUF0z9avRcWPNykaGCYcyYJyecG/UYDSkemVykUCZBw0NrPuHKYEm/D/Ae9JmvaIlRGvb06nH+QKSxBObfAbjLi+yFaeMO9GTchW/fejN3U5RJzO5Z6YitMpUlqNbFS8PMk6t8sLd7UYnEpTDetNW8Vjuczd34NSsMBS8Al+fNYGi+kQeu6GgH8L84Q3xDQNdPPT9t1LJqHChptq9SepwInnB4Rmc= x-forefront-antispam-report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MW4PR21MB2002.namprd21.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(66476007)(64756008)(66446008)(2906002)(8676002)(66556008)(66946007)(82960400001)(71200400001)(33656002)(55016002)(52536014)(122000001)(38100700002)(86362001)(186003)(9686003)(82950400001)(76116006)(8990500004)(921005)(4326008)(38070700005)(110136005)(8936002)(316002)(83380400001)(5660300002)(54906003)(508600001)(10290500003)(7696005)(6506007)(7416002);DIR:OUT;SFP:1102; x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?iso-8859-2?Q?nDaXAsFHdzmW3uR88KefPjKkKaQRPZFIrq5RfpGX9TvDhMdpg2VQutLme4?= =?iso-8859-2?Q?TaCu7nMj5oYRQ9oNnIPCkTlpcGxrUx8r/SKBxCyS//gJBncnJc0wdTrEdR?= =?iso-8859-2?Q?+wYHdzsa4Wb64q7/UMxd/MI/+ctuLoTYxaY+jPAsQuitbS1/8Fxjc92jEr?= =?iso-8859-2?Q?XFjTvH/vzOeAZm78JENG3rbMpFNdewySqREa6wTE6M0unDY75ERAIe4tsw?= =?iso-8859-2?Q?PFTXxvSblY1tBFXd0ER1rZWPbpg+5FHc1xkzX/i34i2EAdS+bD/mNeSlbn?= =?iso-8859-2?Q?QPszqqhOQ95TxPl/UHwnZ0+FhRURcwg3/XhP44FYN8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sGmJkuYsFUpT9VWZETicHU/p1LakXU8UwJLTIRZB2yUuA0XOm?= =?iso-8859-2?Q?AxCIXrkPphXIP/u4bBISwLNTwu+jh+iMY9uj/+Yz6ZTT7EryH+q8VRJbhY?= =?iso-8859-2?Q?HWoRLjmdpGBbH0XAnMfUyEKu2CvX962HRt2+RPzpqmtYgVg/xOphwXSW46?= =?iso-8859-2?Q?Z6+hu4naKWnr8QXsoVopBVoE73G5FxXnRtlBXaPxqwaP2lrKZRTkmvAhus?= =?iso-8859-2?Q?+PvNuwiEJEsKUWpT?= Content-Type: text/plain; charset="iso-8859-2" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-OriginatorOrg: microsoft.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: MW4PR21MB2002.namprd21.prod.outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: 39e0218e-c9e7-4d21-d083-08d98a7fd800 X-MS-Exchange-CrossTenant-originalarrivaltime: 08 Oct 2021 17:19:53.8171 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 72f988bf-86f1-41af-91ab-2d7cd011db47 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: fVQnLlYx7DXZB9UqloRYd5AXro1u7NcZlG8xB2Gfp1dfHYfs/+qj/LkPl5bxwMnYiWpbJVFmW0VDStOM2Yi8bQiQfhQKWk6XiTVVpZbObew= X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW2PR2101MB1851 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Current Hyper-V vPCI code only compiles and works for x64. There are some hardcoded assumptions about the architectural IRQ chip and other arch defines. This patch series adds support for Hyper-V vPCI for ARM64 by first breaking the current hard coded dependency in the vPCI code and making it arch neutral. That is in the first patch. The second patch introduces a Hyper-V vPCI MSI IRQ chip for allocating SPI vectors. changes in v2: - Moved the irqchip implementation to drivers/pci as suggested by Marc Zyngier - Addressed Multi-MSI handling issues identified by Marc Zyngier - Addressed lock/synchronization primitive as suggested by Marc Zyngier - Addressed other code feedback from Marc Zyngier Sunil Muthuswamy (2): PCI: hv: Make the code arch neutral PCI: hv: Support for Hyper-V vPCI for ARM64 MAINTAINERS | 2 + arch/arm64/include/asm/hyperv-tlfs.h | 9 + arch/x86/include/asm/hyperv-tlfs.h | 33 +++ arch/x86/include/asm/mshyperv.h | 7 - drivers/pci/Kconfig | 2 +- drivers/pci/controller/Kconfig | 2 +- drivers/pci/controller/Makefile | 2 +- drivers/pci/controller/pci-hyperv-irqchip.c | 256 ++++++++++++++++++++ drivers/pci/controller/pci-hyperv-irqchip.h | 21 ++ drivers/pci/controller/pci-hyperv.c | 58 +++-- include/asm-generic/hyperv-tlfs.h | 33 --- 11 files changed, 363 insertions(+), 62 deletions(-) create mode 100644 drivers/pci/controller/pci-hyperv-irqchip.c create mode 100644 drivers/pci/controller/pci-hyperv-irqchip.h base-commit: e4e737bb5c170df6135a127739a9e6148ee3da82 --=20 2.25.1