[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] VT-d: avoid multi-message-MSI check for HPET
- To: Jan Beulich <jbeulich@xxxxxxxx>
- From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Date: Fri, 10 Apr 2026 14:34:58 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector10001; 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=l58eyZBdQYE1wiJggwLEnMNNUGQcCZw7PVZqOmMmsFE=; b=lBmO+Aud8VnTqyY9JkB0nit2mt0rIJwJ+wshaZkl/eXW5oRMiqRtykr4I7/TXoSKNLCcTMTWEUNdh5tvB7/apyVH7lJx9d6ClOf9Dij4wXSEorYRH0H7N+1N0xgHLi+dFI4uVxzQJCNI8cKhI0xrF+7I+5ozHwul4xfV1MlSHVV/4BRHabyNitnU0Z9XekcFKikJLyiQcyHl6EFmSar/kasWcqS1Cg2cbwLL2PpKwOIUfMfv+5Dt11RB0YMHo89U//qoXUheFFJVlvNazvj/hJOW1blfgtytqEhdRDqKr8Y3lAhYSzEMamLZqtEfWt3fkcBI71SGBvBCpSuKh4DXUg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=gBoBSXP8EvoBXlBfevzM1SrZRTI0bk0vIYmbqwlkTgF+yIHkpzrpfYFd5zxtquXlEwRZQgA2vP59MZZE4ZNgMCMXr7F0IJbDVRIFsMflmzqC97OHAC3hk6L198NCBytuoMoNNBRQXYOP9tCCiDAfj/v5GN2zbHghuaow0U55ZZx/1pMBljbgOZKwXh3q4+ZophvULhVVxW3jwUH4KEoH4aBCbqtfTUOSc3t9XF7PuWV42tMc+YIkE0G/RlDCpru7WwQce5SCzMH+pi3SGZJjiAFNJ9pgjZQIF4fC+/14ApzEWlMRZVNGEm5/5EaIx7jWPJnsBX96W1SB0CFGIY6q8g==
- Authentication-results: eu.smtp.expurgate.cloud; dkim=pass header.s=selector1 header.d=citrix.com header.i="@citrix.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck"
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- Delivery-date: Fri, 10 Apr 2026 12:35:25 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Fri, Apr 10, 2026 at 07:51:45AM +0200, Jan Beulich wrote:
> On 09.04.2026 19:36, Roger Pau Monné wrote:
> > On Wed, Apr 01, 2026 at 02:47:48PM +0200, Jan Beulich wrote:
> >> Having this immediately below a PCI-dev vs HPET conditional is (mildly)
> >> confusing. Move that if() into the body of the earlier one.
> >>
> >> Signed-off-by: Jan Beulich <jbeulich@xxxxxxxx>
> >>
> >> --- a/xen/drivers/passthrough/vtd/intremap.c
> >> +++ b/xen/drivers/passthrough/vtd/intremap.c
> >> @@ -513,13 +513,13 @@ static int msi_msg_to_remap_entry(
> >>
> >> if ( rc )
> >> return rc;
> >> +
> >> + if ( msi_desc->msi_attrib.type == PCI_CAP_ID_MSI )
> >> + nr = msi_desc->msi.nvec;
> >> }
> >> else
> >> set_hpet_source_id(msi_desc->hpet_id, &new_ire);
> >>
> >> - if ( msi_desc->msi_attrib.type == PCI_CAP_ID_MSI )
> >> - nr = msi_desc->msi.nvec;
> >> -
> >
> > I'm not fully opposed to this, but maybe it would be good to add a
> > small comment to note that HPET never use multi-vector MSI?
>
> That aspect doesn't change - HPET code simply doesn't (and never should)
> set .type to PCI_CAP_ID_MSI. That field should reflect reality (and HPET,
> iirc, simply leaves it at 0).
Hm, I see, HPET is a very special case which have been "adjusted" to
fit the MSI generation logic.
Acked-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
Thanks, Roger.
|