From nobody Fri Oct 31 03:48:31 2025 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) client-ip=192.237.175.120; envelope-from=xen-devel-bounces@lists.xenproject.org; helo=lists.xenproject.org; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass(p=none dis=none) header.from=gmail.com ARC-Seal: i=1; a=rsa-sha256; t=1752737532; cv=none; d=zohomail.com; s=zohoarc; b=R+EUk6JfeizUWkXYiySqSC4J1M/yU9xXTpzTGR5td9EOcel7SWHmED6Vtbo1XCRi9G5OS+RltlIgUpmJCQUknknkHb1mERjoLGWJNvDktt4nQkobkkCsKjPscy1U2XxI5uXMhsP3EXfpVqrXcklYinMe63b9H62RBBndGg0Lm28= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1752737532; h=Content-Transfer-Encoding:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=Qmq/Nsl0M7ErOrqCpTVnTzy11DB2G6jqpravhzisJJo=; b=B08L+w9wtlDTQpkRf18babVbG6K+Yg1uxHhJzv7K+Kbx50FL5olkGRyDBcGrcTawX8u9k5nh4wE9g2Pr3AoPrTrwGy+1EGNYJEAgQBoLt35uiGa4DlpIoxsgyCQZViQdEjz6stJPYERDBoB1WFUSrEMzfPMJaa0R1uDzpYw2J/I= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of lists.xenproject.org designates 192.237.175.120 as permitted sender) smtp.mailfrom=xen-devel-bounces@lists.xenproject.org; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) by mx.zohomail.com with SMTPS id 1752737532129224.26297508774678; Thu, 17 Jul 2025 00:32:12 -0700 (PDT) Received: from list by lists.xenproject.org with outflank-mailman.1046276.1416607 (Exim 4.92) (envelope-from ) id 1ucJ5y-0004gS-IS; Thu, 17 Jul 2025 07:31:58 +0000 Received: by outflank-mailman (output) from mailman id 1046276.1416607; Thu, 17 Jul 2025 07:31:58 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ucJ5y-0004gJ-F5; Thu, 17 Jul 2025 07:31:58 +0000 Received: by outflank-mailman (input) for mailman id 1046276; Thu, 17 Jul 2025 07:31:57 +0000 Received: from se1-gles-flk1-in.inumbo.com ([94.247.172.50] helo=se1-gles-flk1.inumbo.com) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1ucJ5x-0004NF-3A for xen-devel@lists.xenproject.org; Thu, 17 Jul 2025 07:31:57 +0000 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [2a00:1450:4864:20::336]) by se1-gles-flk1.inumbo.com (Halon) with ESMTPS id 1d10fa46-62e0-11f0-b894-0df219b8e170; Thu, 17 Jul 2025 09:31:55 +0200 (CEST) Received: by mail-wm1-x336.google.com with SMTP id 5b1f17b1804b1-451dbe494d6so6247745e9.1 for ; Thu, 17 Jul 2025 00:31:55 -0700 (PDT) Received: from pc (cpc92320-cmbg19-2-0-cust1786.5-4.cable.virginm.net. [82.13.70.251]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-3b5e8dc201asm19792460f8f.22.2025.07.17.00.31.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 17 Jul 2025 00:31:52 -0700 (PDT) X-Outflank-Mailman: Message body and most headers restored to incoming version X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" X-Inumbo-ID: 1d10fa46-62e0-11f0-b894-0df219b8e170 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1752737514; x=1753342314; darn=lists.xenproject.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Qmq/Nsl0M7ErOrqCpTVnTzy11DB2G6jqpravhzisJJo=; b=UjQXXaISBGBtxv5Dzfl1m0GZ3dR/nz8BO4SScOsQYv9MKQaRdjd9DUs3Ecvzjm9Ait OzYUPlnBgodr+mowq8KHySLo9zXbrKHzjzqZ7JSIcu7+hdKkDIDCpnea0tkatZviENXr SxAwFlxkj3IneESnWqdULurM1fLne64N9DKDf80cRYnXfo6mQk3V1gU2gK1Q3P0gdUhm 4sVUvpL05Ecrks27iK4qkZL8aw50MFW+EJWbhBiePjfoHqXk2WQjed/cNMlgqTHkuHLL dFrtaJPno3c19v5x0JGxA/lxdPNP9aKc5q1W7DIvVw7N73wAxVg2IV4j/8RFoJG3rqY9 4qnA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1752737514; x=1753342314; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Qmq/Nsl0M7ErOrqCpTVnTzy11DB2G6jqpravhzisJJo=; b=G9GHpb/xa3y9ik41ke2TyvmlSAMjwZqC2amM654Lf8F9FMlBIFIzqdbLTLEYB+oBNo MSAAqrBLguIhQ8EPzX1+5HnxXWoSnYaLu88d4DwjVoEpgS9aOc7ddl6ZdxZEbLfb52iy EkjHkSCO+ori5hjVoYqW5uTf+U8wa/y62aV5DqRErzxAx1httqrcwD0Ourp8+l5Fq3ZN MiE3JGV2dtmNHAjVBC+iFmgv/DL/tH4Wqk5C5fhD83wVhFqTkiUbT3AuCOoJ9QXvr/L7 K4/8umqkp0wx/DhCowFXw6fniZEkIbNEcXG9IJbs+db9c3W6r1p96f+vJ/JtPOcGVRg+ 7Swg== X-Gm-Message-State: AOJu0YxbmfHTYQ8yJWCSOuPD4jGKSnC2v3QDdh5K/y8tu3NgCiE6edFy BTQlJSRk14720384J1TUCvRRoH6630fmGumBc2Izvig6UmTqZQnDZRTpSdLa/oYr X-Gm-Gg: ASbGncsLnl31kDww9xgu+EiBKyu1uUibXCs0c0IKiX2hH72kY8KIfrrMDKqsmzmeoJ5 yXVxagtXGpHRHwidA/vRsMOd7cgM9e1DZk/a+/8b5wHjPTjNn7Jj0od4DPPyxb0gwpDZaM2Cd9X 1Rev+cM7RLgMOSFpNqsuTS48ZRpjzk7/IJKzeFRxV4VlwNJENqz5r5gb3H1AEvMkhmsPjS0UduE CgggN7R7QCxznK2W+sddS33Cr3FAPqJT9MDT2tyMFbnLCY1XqAZTpcb9F4s3NHlk2nh0UDUhyDc 49VmXmtX86ZWmWeSEND9X1n0Com7AQ3pGzHD3FEphqCOfYP6uVarKvC5hF1UD+wBV9+lmlxVGCw Vpqb2ldj2QCux1x4sH+EqhrP41Xw7pSfCEje3vnhkGx7qi2XBRkmWEntP4thtrjYXBWKAZY5X X-Google-Smtp-Source: AGHT+IFerTBt+a2FRLEgXUDPZ4Z7PoLIzaMrvURSIR9xXAlQjAMwHEqbeJYQRDO6gcgdpvfg/zPmtQ== X-Received: by 2002:a05:600c:19cb:b0:43c:ee3f:2c3 with SMTP id 5b1f17b1804b1-4562e37a0ecmr42772215e9.7.1752737513849; Thu, 17 Jul 2025 00:31:53 -0700 (PDT) From: Andrii Sultanov To: xen-devel@lists.xenproject.org Cc: Andrii Sultanov , Jan Beulich , Andrew Cooper , =?UTF-8?q?Roger=20Pau=20Monn=C3=A9?= Subject: [PATCH v5 3/3] drivers: Make ioapic_sbdf and hpet_sbdf contain pci_sbdf_t Date: Thu, 17 Jul 2025 08:31:27 +0100 Message-ID: <94d8b7537021337a6b54d8950294702f5bbd2590.1752736989.git.andriy.sultanov@vates.tech> X-Mailer: git-send-email 2.50.1 In-Reply-To: References: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @gmail.com) X-ZM-MESSAGEID: 1752737533000116600 Content-Type: text/plain; charset="utf-8" Following a similar change to amd_iommu struct, make two more structs take pci_sbdf_t directly instead of seg and bdf separately. This lets us drop several conversions from the latter to the former and simplifies several comparisons and assignments. Bloat-o-meter reports: add/remove: 0/0 grow/shrink: 1/10 up/down: 256/-320 (-64) Function old new delta _einittext 22092 22348 +256 parse_ivrs_hpet 248 245 -3 amd_iommu_detect_one_acpi 876 868 -8 iov_supports_xt 275 264 -11 amd_iommu_read_ioapic_from_ire 344 332 -12 amd_setup_hpet_msi 237 224 -13 amd_iommu_ioapic_update_ire 575 555 -20 reserve_unity_map_for_device 453 424 -29 _hvm_dpci_msi_eoi 160 128 -32 amd_iommu_get_supported_ivhd_type 86 30 -56 parse_ivrs_table 3966 3830 -136 Signed-off-by: Andrii Sultanov Reviewed-by: Jan Beulich --- Changes in V5: * Dropped PCI_BDF usage inside PCI_SBDF macros * Joined separate seg and bdf comparisons into a single sbdf one in parse_ivrs_table * Dropped unnecessary bdf in parse_ivhd_device_special, using sbdf.bdf instead * Reverted print formatting change in amd_iommu_ioapic_update_ire Changes in V4: * Folded several separate seg+bdf comparisons and assignments into one with sbdf_t * With reshuffling in the prior commits, this commit is no longer neutral in terms of code size Changes in V3: * Dropped aliasing of seg and bdf, renamed users. Changes in V2: * Split single commit into several patches * Change the format specifier to %pp in amd_iommu_ioapic_update_ire --- xen/drivers/passthrough/amd/iommu.h | 5 +-- xen/drivers/passthrough/amd/iommu_acpi.c | 40 ++++++++++------------ xen/drivers/passthrough/amd/iommu_intr.c | 43 ++++++++++++------------ 3 files changed, 41 insertions(+), 47 deletions(-) diff --git a/xen/drivers/passthrough/amd/iommu.h b/xen/drivers/passthrough/= amd/iommu.h index 2599800e6a..52f748310b 100644 --- a/xen/drivers/passthrough/amd/iommu.h +++ b/xen/drivers/passthrough/amd/iommu.h @@ -262,7 +262,7 @@ int cf_check amd_setup_hpet_msi(struct msi_desc *msi_de= sc); void cf_check amd_iommu_dump_intremap_tables(unsigned char key); =20 extern struct ioapic_sbdf { - u16 bdf, seg; + pci_sbdf_t sbdf; u8 id; bool cmdline; u16 *pin_2_idx; @@ -273,7 +273,8 @@ unsigned int ioapic_id_to_index(unsigned int apic_id); unsigned int get_next_ioapic_sbdf_index(void); =20 extern struct hpet_sbdf { - u16 bdf, seg, id; + pci_sbdf_t sbdf; + uint16_t id; enum { HPET_NONE, HPET_CMDL, diff --git a/xen/drivers/passthrough/amd/iommu_acpi.c b/xen/drivers/passthr= ough/amd/iommu_acpi.c index a9c5432e86..c007a427f2 100644 --- a/xen/drivers/passthrough/amd/iommu_acpi.c +++ b/xen/drivers/passthrough/amd/iommu_acpi.c @@ -707,8 +707,7 @@ static int __init cf_check parse_ivrs_ioapic(const char= *str) } } =20 - ioapic_sbdf[idx].bdf =3D PCI_BDF(bus, dev, func); - ioapic_sbdf[idx].seg =3D seg; + ioapic_sbdf[idx].sbdf =3D PCI_SBDF(seg, bus, dev, func); ioapic_sbdf[idx].id =3D id; ioapic_sbdf[idx].cmdline =3D true; =20 @@ -734,8 +733,7 @@ static int __init cf_check parse_ivrs_hpet(const char *= str) return -EINVAL; =20 hpet_sbdf.id =3D id; - hpet_sbdf.bdf =3D PCI_BDF(bus, dev, func); - hpet_sbdf.seg =3D seg; + hpet_sbdf.sbdf =3D PCI_SBDF(seg, bus, dev, func); hpet_sbdf.init =3D HPET_CMDL; =20 return 0; @@ -746,8 +744,9 @@ static u16 __init parse_ivhd_device_special( const struct acpi_ivrs_device8c *special, u16 seg, u16 header_length, u16 block_length, struct amd_iommu *iommu) { - u16 dev_length, bdf; + u16 dev_length; unsigned int apic, idx; + pci_sbdf_t sbdf; =20 dev_length =3D sizeof(*special); if ( header_length < (block_length + dev_length) ) @@ -756,16 +755,16 @@ static u16 __init parse_ivhd_device_special( return 0; } =20 - bdf =3D special->used_id; - if ( bdf >=3D ivrs_bdf_entries ) + sbdf =3D PCI_SBDF(seg, special->used_id); + if ( sbdf.bdf >=3D ivrs_bdf_entries ) { - AMD_IOMMU_ERROR("IVHD: invalid Device_Entry Dev_Id %#x\n", bdf); + AMD_IOMMU_ERROR("IVHD: invalid Device_Entry Dev_Id %#x\n", sbdf.bd= f); return 0; } =20 AMD_IOMMU_DEBUG("IVHD Special: %pp variety %#x handle %#x\n", - &PCI_SBDF(seg, bdf), special->variety, special->handle= ); - add_ivrs_mapping_entry(bdf, bdf, special->header.data_setting, 0, true, + &sbdf, special->variety, special->handle); + add_ivrs_mapping_entry(sbdf.bdf, sbdf.bdf, special->header.data_settin= g, 0, true, iommu); =20 switch ( special->variety ) @@ -780,8 +779,7 @@ static u16 __init parse_ivhd_device_special( */ for ( idx =3D 0; idx < nr_ioapic_sbdf; idx++ ) { - if ( ioapic_sbdf[idx].bdf =3D=3D bdf && - ioapic_sbdf[idx].seg =3D=3D seg && + if ( ioapic_sbdf[idx].sbdf.sbdf =3D=3D sbdf.sbdf && ioapic_sbdf[idx].cmdline ) break; } @@ -790,7 +788,7 @@ static u16 __init parse_ivhd_device_special( AMD_IOMMU_DEBUG("IVHD: Command line override present for IO-AP= IC %#x" "(IVRS: %#x devID %pp)\n", ioapic_sbdf[idx].id, special->handle, - &PCI_SBDF(seg, bdf)); + &sbdf); break; } =20 @@ -805,8 +803,7 @@ static u16 __init parse_ivhd_device_special( special->handle); else if ( idx !=3D MAX_IO_APICS && ioapic_sbdf[idx].pin_2_idx ) { - if ( ioapic_sbdf[idx].bdf =3D=3D bdf && - ioapic_sbdf[idx].seg =3D=3D seg ) + if ( ioapic_sbdf[idx].sbdf.sbdf =3D=3D sbdf.sbdf ) AMD_IOMMU_WARN("IVHD: duplicate IO-APIC %#x entries\n", special->handle); else @@ -827,8 +824,7 @@ static u16 __init parse_ivhd_device_special( } =20 /* set device id of ioapic */ - ioapic_sbdf[idx].bdf =3D bdf; - ioapic_sbdf[idx].seg =3D seg; + ioapic_sbdf[idx].sbdf =3D sbdf; ioapic_sbdf[idx].id =3D special->handle; =20 ioapic_sbdf[idx].pin_2_idx =3D xmalloc_array( @@ -862,13 +858,12 @@ static u16 __init parse_ivhd_device_special( AMD_IOMMU_DEBUG("IVHD: Command line override present for HPET = %#x " "(IVRS: %#x devID %pp)\n", hpet_sbdf.id, special->handle, - &PCI_SBDF(seg, bdf)); + &sbdf); break; case HPET_NONE: /* set device id of hpet */ hpet_sbdf.id =3D special->handle; - hpet_sbdf.bdf =3D bdf; - hpet_sbdf.seg =3D seg; + hpet_sbdf.sbdf =3D sbdf; hpet_sbdf.init =3D HPET_IVHD; break; default: @@ -1139,9 +1134,8 @@ static int __init cf_check parse_ivrs_table(struct ac= pi_table_header *table) return -ENXIO; } =20 - if ( !ioapic_sbdf[idx].seg && - /* SB IO-APIC is always on this device in AMD systems. */ - ioapic_sbdf[idx].bdf =3D=3D PCI_BDF(0, 0x14, 0) ) + /* SB IO-APIC is always on this device in AMD systems. */ + if ( ioapic_sbdf[idx].sbdf.sbdf =3D=3D PCI_SBDF(0, 0, 0x14, 0).sbd= f ) sb_ioapic =3D 1; =20 if ( ioapic_sbdf[idx].pin_2_idx ) diff --git a/xen/drivers/passthrough/amd/iommu_intr.c b/xen/drivers/passthr= ough/amd/iommu_intr.c index 25bf25904e..7dae89bcc0 100644 --- a/xen/drivers/passthrough/amd/iommu_intr.c +++ b/xen/drivers/passthrough/amd/iommu_intr.c @@ -323,7 +323,8 @@ void cf_check amd_iommu_ioapic_update_ire( unsigned int apic, unsigned int pin, uint64_t rte) { struct IO_APIC_route_entry new_rte; - int seg, bdf, rc; + pci_sbdf_t sbdf; + int rc; struct amd_iommu *iommu; unsigned int idx; =20 @@ -335,20 +336,19 @@ void cf_check amd_iommu_ioapic_update_ire( new_rte.raw =3D rte; =20 /* get device id of ioapic devices */ - bdf =3D ioapic_sbdf[idx].bdf; - seg =3D ioapic_sbdf[idx].seg; - iommu =3D find_iommu_for_device(PCI_SBDF(seg, bdf)); + sbdf =3D ioapic_sbdf[idx].sbdf; + iommu =3D find_iommu_for_device(sbdf); if ( !iommu ) { AMD_IOMMU_WARN("failed to find IOMMU for IO-APIC @ %04x:%04x\n", - seg, bdf); + sbdf.seg, sbdf.bdf); __ioapic_write_entry(apic, pin, true, new_rte); return; } =20 /* Update interrupt remapping entry */ rc =3D update_intremap_entry_from_ioapic( - bdf, iommu, &new_rte, + sbdf.bdf, iommu, &new_rte, &ioapic_sbdf[idx].pin_2_idx[pin]); =20 if ( rc ) @@ -369,7 +369,8 @@ unsigned int cf_check amd_iommu_read_ioapic_from_ire( unsigned int offset; unsigned int val =3D __io_apic_read(apic, reg); unsigned int pin =3D (reg - 0x10) / 2; - uint16_t seg, bdf, req_id; + pci_sbdf_t sbdf; + uint16_t req_id; const struct amd_iommu *iommu; union irte_ptr entry; =20 @@ -381,12 +382,11 @@ unsigned int cf_check amd_iommu_read_ioapic_from_ire( if ( offset >=3D INTREMAP_MAX_ENTRIES ) return val; =20 - seg =3D ioapic_sbdf[idx].seg; - bdf =3D ioapic_sbdf[idx].bdf; - iommu =3D find_iommu_for_device(PCI_SBDF(seg, bdf)); + sbdf =3D ioapic_sbdf[idx].sbdf; + iommu =3D find_iommu_for_device(sbdf); if ( !iommu ) return val; - req_id =3D get_intremap_requestor_id(seg, bdf); + req_id =3D get_intremap_requestor_id(sbdf.seg, sbdf.bdf); entry =3D get_intremap_entry(iommu, req_id, offset); =20 if ( !(reg & 1) ) @@ -515,15 +515,15 @@ int cf_check amd_iommu_msi_msg_update_ire( struct msi_desc *msi_desc, struct msi_msg *msg) { struct pci_dev *pdev =3D msi_desc->dev; - int bdf, seg, rc; + pci_sbdf_t sbdf; + int rc; struct amd_iommu *iommu; unsigned int i, nr =3D 1; u32 data; =20 - bdf =3D pdev ? pdev->sbdf.bdf : hpet_sbdf.bdf; - seg =3D pdev ? pdev->seg : hpet_sbdf.seg; + sbdf =3D pdev ? pdev->sbdf : hpet_sbdf.sbdf; =20 - iommu =3D _find_iommu_for_device(PCI_SBDF(seg, bdf)); + iommu =3D _find_iommu_for_device(sbdf); if ( IS_ERR_OR_NULL(iommu) ) return PTR_ERR(iommu); =20 @@ -532,7 +532,7 @@ int cf_check amd_iommu_msi_msg_update_ire( =20 if ( msi_desc->remap_index >=3D 0 && !msg ) { - update_intremap_entry_from_msi_msg(iommu, bdf, nr, + update_intremap_entry_from_msi_msg(iommu, sbdf.bdf, nr, &msi_desc->remap_index, NULL, NULL); =20 @@ -543,7 +543,7 @@ int cf_check amd_iommu_msi_msg_update_ire( if ( !msg ) return 0; =20 - rc =3D update_intremap_entry_from_msi_msg(iommu, bdf, nr, + rc =3D update_intremap_entry_from_msi_msg(iommu, sbdf.bdf, nr, &msi_desc->remap_index, msg, &data); if ( rc >=3D 0 ) @@ -660,8 +660,7 @@ bool __init cf_check iov_supports_xt(void) if ( idx =3D=3D MAX_IO_APICS ) return false; =20 - if ( !find_iommu_for_device(PCI_SBDF(ioapic_sbdf[idx].seg, - ioapic_sbdf[idx].bdf)) ) + if ( !find_iommu_for_device(ioapic_sbdf[idx].sbdf) ) { AMD_IOMMU_WARN("no IOMMU for IO-APIC %#x (ID %x)\n", apic, IO_APIC_ID(apic)); @@ -690,14 +689,14 @@ int __init cf_check amd_setup_hpet_msi(struct msi_des= c *msi_desc) return -ENODEV; } =20 - iommu =3D find_iommu_for_device(PCI_SBDF(hpet_sbdf.seg, hpet_sbdf.bdf)= ); + iommu =3D find_iommu_for_device(hpet_sbdf.sbdf); if ( !iommu ) return -ENXIO; =20 - lock =3D get_intremap_lock(hpet_sbdf.seg, hpet_sbdf.bdf); + lock =3D get_intremap_lock(hpet_sbdf.sbdf.seg, hpet_sbdf.sbdf.bdf); spin_lock_irqsave(lock, flags); =20 - msi_desc->remap_index =3D alloc_intremap_entry(iommu, hpet_sbdf.bdf, 1= ); + msi_desc->remap_index =3D alloc_intremap_entry(iommu, hpet_sbdf.sbdf.b= df, 1); if ( msi_desc->remap_index >=3D INTREMAP_MAX_ENTRIES ) { msi_desc->remap_index =3D -1; --=20 2.49.0