[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
map_domain_pirq(): pirq already mapped?
- To: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- From: Jason Andryuk <jason.andryuk@xxxxxxx>
- Date: Wed, 13 May 2026 21:18:46 -0400
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=lists.xenproject.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0)
- 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=9vMMdgFpCCx7rZUbpem9G3SNarBzXP9jMrSI85xD/z8=; b=krg3ygcli8gHfMF9fBUVgtYFNTRxpWGYoRU1Btfjeklg5//G0TSut4kVeLano9+FF4iLqphJUJ7VYliEq7xie9VIc3YIRkIIrsLV4HfITWZ9mDh6fURPOl2hi69iWE22bXhDhdq+cL/rskdHCmkYQqd8ue4c7y3Q6pv0I2FLXoZ93GisYNebomhGVmpF17FKBiZ58Tm2/gLgcqf8lnkSWc8+8bMjDs2U/iWDaMZkZEsQnKTNbBESC5J2fTlUMjbr+Z8fkDsSrVphuZ4uVYQzX1swCqGveONAToSzDwfx2EX85tPmkUeKHyYMfHzILK1k2R9ra/T34eZyDxdUQ9M8qg==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector10001; d=microsoft.com; cv=none; b=Mhu9FUR8iHeR+Q9nfyEMyNdN2mVabyzAf0/PH+ePpRFFJ2zJQLTQWnv6oFYoDDTwLq6mUCOG4K+jX9eYK7GxlZc5gO6l/47qNCfSPZpxumyX+F/PA8YaCJcbJmE4vQ2+f7Z940NzMjqQCFYI33tWrqoQGvruNcTOnqnKCH9y1EQcYy1ypp50S0dfSesyptwhQTD6t5hbpYxQr2Z6ZgtIah5hCmwGzPG9lw6W44ucKg4f8FT2UIBYLZ8+FI88z4Da1ZRmpCw+qwZ4plyc7oRobioSMiOOcwQFAsaItgrh83/rP0fgmLOI86WwmU0EUCvv1Mf2OFqyHvmJyKkobUd8UA==
- Authentication-results: eu.smtp.expurgate.cloud; dkim=pass header.s=selector1 header.d=amd.com header.i="@amd.com" header.h="From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck"
- Delivery-date: Thu, 14 May 2026 01:24:00 +0000
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Hi,
Early in map_domain_pirq(), we have this block:
old_irq = domain_pirq_to_irq(d, pirq);
old_pirq = domain_irq_to_pirq(d, irq);
if ( (old_irq > 0 && (old_irq != irq) ) ||
(old_pirq && (old_pirq != pirq)) )
{
dprintk(XENLOG_G_WARNING,
"dom%d: pirq %d or irq %d already mapped (%d,%d)\n",
d->domain_id, pirq, irq, old_pirq, old_irq);
return 0;
}
Why do we return 0 instead of -EEXIST? Since the pirq is not updated,
the caller doesn't know that pirq won't fire - only old_pirq. For
allocate_and_map_gsi_pirq(), the new pirq is still returned to the
caller. I would expect old_pirq to be returned so the caller knows what
to use. Am I missing something?
Thanks,
Jason
|