From nobody Sun Nov 24 21:59:23 2024 Delivered-To: importer@patchew.org Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; arc=pass (i=1 dmarc=pass fromdomain=outlook.jp); dmarc=pass(p=none dis=none) header.from=outlook.jp ARC-Seal: i=2; a=rsa-sha256; t=1720150434; cv=pass; d=zohomail.com; s=zohoarc; b=XQGz47y46gOT76paAA+eQZ38FyTosVkOBC/VTae/iYCQhA/X4LfFsznv7ZzGrvSN+IPPZ7VAoj6Jp2fYVkC6nlv9XmE0rBf8Y9Aj6VtMcp0AIJZrmrc9sc5vMfaWBQi+cFCQBoTpocS2pN6m2IfB99ww+0+1OFc4fUSwzjU5ycc= ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1720150434; h=Content-Type:Cc:Cc:Date:Date:From:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:Subject:To:To:Message-Id:Reply-To; bh=X/YIvRofYO0R16YIMpAlHEXp6ljGp8JFJhITXZtB0uI=; b=dj48G+JazU1WrZr7f0UZ6nYQPFYE4QYw9eY8Qp8Lz5VkjD687aeSVk+GC2jFz23fE2aJCdHrJBx6m6+QTBtj2w/MHSaoCWSWVEFKeHXVNHbOkfMUmjEZKY5M6uChljsm63P41vmNoD+bIKlzB1w99XUB0W+22POkf233t4IzZJg= ARC-Authentication-Results: i=2; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org; arc=pass (i=1 dmarc=pass fromdomain=outlook.jp); dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mx.zohomail.com with SMTPS id 1720150434183678.9518785450227; Thu, 4 Jul 2024 20:33:54 -0700 (PDT) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sPZhg-00056e-Ip; Thu, 04 Jul 2024 23:33:45 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPZha-000564-Rd for qemu-devel@nongnu.org; Thu, 04 Jul 2024 23:33:39 -0400 Received: from mail-sgaapc01acsn2080b.outbound.protection.outlook.com ([2a01:111:f400:feab::80b] helo=APC01-SG2-obe.outbound.protection.outlook.com) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPZhX-0003mS-CH for qemu-devel@nongnu.org; Thu, 04 Jul 2024 23:33:38 -0400 Received: from SEZPR01MB4301.apcprd01.prod.exchangelabs.com (2603:1096:101:4f::5) by KL1PR01MB5736.apcprd01.prod.exchangelabs.com (2603:1096:820:10e::8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7719.33; Fri, 5 Jul 2024 03:33:28 +0000 Received: from SEZPR01MB4301.apcprd01.prod.exchangelabs.com ([fe80::40ec:96e8:ebc2:2872]) by SEZPR01MB4301.apcprd01.prod.exchangelabs.com ([fe80::40ec:96e8:ebc2:2872%6]) with mapi id 15.20.7741.027; Fri, 5 Jul 2024 03:33:27 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Cpiv61YzzfDlzJuXEPj8jZNT1EOSiYPmpFrTlcBpTw0N8ChqYsmQFBwER4gNM8TTcp+2rxhok5G20UdCkQKtQaBEiG5akQ207lL2Jkd6zORGrVLbkxrwSPJO94rBd7U0BxUPHGayGgXQvac8k5tZMcx6GYXT58PppxlmMXattOF3hXRT2APqMMbJaVx73f0WHIOj2IYntz1w5bIiDidBdM+9XdzjxxDY4qBfA/EzpFXRuJLMxgDzqTqJ6ncRoUrOiGJFKRdLol1IfS4dciWV9FV3bxi5/sQLuzlMcvtuiFqmRzU+rglGqz29dy0S6l/tjEqfsni6rZ0gHNIrmzA1WA== 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=X/YIvRofYO0R16YIMpAlHEXp6ljGp8JFJhITXZtB0uI=; b=nK3N+wUZDXGQ7qK/Of6xg5EJbiF8kZuk5mRmzCd7pUfwqhOrJxWPfitIomU+IS727Dk4l45AGljOMtuF1+5s8/CogNUoe70Rxq4fgFUBmSA6gOGaqKZw+Eo598IKqfEV6uXQbn3iixxWp2CDUeGh6tmVBH6dsqN6WLzrqBNreQM9WbcZRTIPl5KEjalq5ra/YzvzIkDVG1SF5grsEMAlh3xgrD6LZD4Rn8a7A41vrH5HXP+YWUHaf+uz8GxpoYuPOvnjb4BatsUF8Hx9LlSp+Up0rV95tpI6ibNK+XObD2KerVCkR4copByzj8zcZojYsSP3g3eOZH0vge4egRZTXA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=OUTLOOK.JP; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=X/YIvRofYO0R16YIMpAlHEXp6ljGp8JFJhITXZtB0uI=; b=liCMFQJNCh+IgzWkelZHvGQZUfQE3Nd2c4Yvyvi832o+xQoe8s4/4pIBT2SYOWf/TkiQ+Cu8Pgh8IYYITMijxhyYcdzLbfXgwVgUXK4mikoof5uxGrERAbrFPAIPpiUsznJJaxy04t7IDw4PLYSiI2zQYE1OIc9s9j8OZERyDtaAEPU0cDF9Oyciyw8nlvguiB2G9EQUCkFlu3R2dy2brOwi9wnbwMioAn7JvTAVJFyfaBjAXhVXRKN92ZAUPwsEEOLvAUsG8jg9JfyxsWKQO32BXFhWRidh6nut9p0+XKyhqVADiQdbQvXHAx1EiRtAFDWty1/qeCXzpmCazBNbZA== From: =?iso-2022-jp?B?GyRCMEtGIxsoQiAbJEJCQEA2GyhC?= To: "qemu-devel@nongnu.org" CC: "pbonzini@redhat.com" , "mst@redhat.com" Subject: [PING][PATCH] hw/intc/ioapic: Delete a wrong IRQ redirection on I/O APIC Thread-Topic: [PING][PATCH] hw/intc/ioapic: Delete a wrong IRQ redirection on I/O APIC Thread-Index: AQHaxvexsisMgUUJlkSRN/8Sl71JD7HniWYq Date: Fri, 5 Jul 2024 03:33:27 +0000 Message-ID: References: In-Reply-To: Accept-Language: ja-JP, en-US Content-Language: ja-JP X-MS-Has-Attach: X-MS-TNEF-Correlator: msip_labels: x-tmn: [mxv7y7BQ00ZdnUnobWr054exya4/XMvI] x-ms-publictraffictype: Email x-ms-traffictypediagnostic: SEZPR01MB4301:EE_|KL1PR01MB5736:EE_ x-ms-office365-filtering-correlation-id: 4df030d4-de01-4933-94dd-08dc9ca33b86 x-microsoft-antispam: BCL:0; ARA:14566002|9400799024|8060799006|19110799003|461199028|102099032|440099028|3412199025; x-microsoft-antispam-message-info: G8Jt6RtRL48xms4UnsDg4Vcjs1elDSmiRRX5jCOMrGg9PKzMn90n0xn47y1HxhyPsjP+IJqkKfv/E/u9VlrYW7e9prX6i6g6YZ5JJsXVZz5ld9AZS16vjGY6VDW8I1InP/+vNlHeYyh+hqQUaTAM3fKSKiKGfNW/hLFJsFkscGi7BbyqoqQydjxsrggvURVwb3Xz0M+pxzodRVND+mpwHhsl+y8X6O3MjTgith6JIJcWOXF6pHImLSwHt2nPYVhc3r0B3g09R0UogHy71S+WGZobGVuCD2B/lrWgRVT4QgcHoMVVjCXSb+KVYsx2nNHTmUgwiREPyABX1WzdzpPPtWXYWOUzy01zXTvOutUsta5V77GiQIctmZ21NLW/xttPIv+AIALXgiyIYeVd1s2XB/wdgD934CmTzWfhh+Lm6YlJI0AjJnW8lR1wABpivuLlaREHUVA7/ytEVOWd3+cjNWyUCGtkcnCOaNTlHdT8I5pJGYtCe6b+QMw0fVJrM2z+JlxkoAcuCtjEsQODseNVELxLO6EVZn9IurjWWvZb4MZc9HSiOejRCH1qS4Mlj6N0eYNzrez3TFTOiad/iXtHOhxw0M2t8Wn5hdB3nkb1VBu0J8cLIz81qXMhX6Bft9ZqsRo3YDagaYdrmkBH09hnYA6fscbpw+d5MAdNmTjBi+HBJqEdkd7XQPwkWluTHKtRz3tkuafmWi46D/ElwGu7YLjHaMlyXc0Nm4VYadtiywA= x-ms-exchange-antispam-messagedata-chunkcount: 1 x-ms-exchange-antispam-messagedata-0: =?iso-2022-jp?B?SHE3bDU4c01iOUZCNDg0Zzc5Tlp0NWM5ajdDMkk5ZWhXa05janBWend4?= =?iso-2022-jp?B?U0lMQ21wcmdMWm5TUHU3cVplYm8xbTBKRkh2dHVDb1ZCRkU0eEF2Ymdj?= =?iso-2022-jp?B?TzUzcTRQUmNOTVNYVWVuZCttRGhlRDJ3NnJHSUo3ZzJZZ3FGYWFJQnFC?= =?iso-2022-jp?B?WGU0bEtOU0hOR1p3bkkvU1BXMDYyN05DaG9tRHJkR0hYeW93TmlsWDMr?= =?iso-2022-jp?B?d09pWVdGWittaTQ4QWdEZmcvSXU5MUZUZW9ub2kxaFB0WWlya1NZZEpn?= =?iso-2022-jp?B?YlE3dG1LZ2hFZVl6dXpMUmlLMHVteGVoNDVucWxQUnRneVZKbFVnMitq?= =?iso-2022-jp?B?Yk9zQVpnOTRCS0V6U0pMTGl5akRNQ0w4UFRkWUlMREpXenJGSWhvUWc5?= =?iso-2022-jp?B?K2JXSEJtbDQzN3RJNW1JVzdHSHJVMWRCMW5xLzVVaUJncVpmck5DT3lY?= =?iso-2022-j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bHFqeStrVUFI?= =?iso-2022-jp?B?MTRjS3lCRllTblZqdHVJMGdPTVNUTXhUK3BES2hnSW00Ui9rSEFHOWVw?= =?iso-2022-jp?B?R3p5WFM5NFlUb0VPRGY1bUU4YlltWnFORTBHY0hZejNQT05mQitrbWxa?= =?iso-2022-jp?B?MHhsU1Y4VU00dVhxeVhaaU0yay9hYUVLVTlJUGZrUnppc2thZVYzS3Ar?= =?iso-2022-jp?B?WWMvS1BnU3cxTUFJdXcxelc1OFQwazlTWXpmWjBsSmZaSklKKzhtemlU?= =?iso-2022-jp?B?SnJacm92VDBRYWVjWHZWaU1reVJBWFNnMm5UNVF6V1ExRFgyWlEveXYr?= =?iso-2022-jp?B?N1ZQeEQ3aGFEWWlLVXVudE1UMFFVbFMxQUhVNFBFWmhZN1M2K0VMT0RK?= =?iso-2022-jp?B?RUZBeE1qUS9PbkVhSjhpQlE2c2xtd3lRdkNycEpDYzZnWmdHSGFnNWs9?= Content-Type: multipart/alternative; boundary="_000_SEZPR01MB43019C6C7D242A7A18B9C0B6A4DF2SEZPR01MB4301apcp_" MIME-Version: 1.0 X-OriginatorOrg: sct-15-20-7719-20-msonline-outlook-b4c57.templateTenant X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-AuthSource: SEZPR01MB4301.apcprd01.prod.exchangelabs.com X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-CrossTenant-Network-Message-Id: 4df030d4-de01-4933-94dd-08dc9ca33b86 X-MS-Exchange-CrossTenant-originalarrivaltime: 05 Jul 2024 03:33:27.1680 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-rms-persistedconsumerorg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: KL1PR01MB5736 Received-SPF: pass (zohomail.com: domain of gnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Received-SPF: pass client-ip=2a01:111:f400:feab::80b; envelope-from=taisei1212@outlook.jp; helo=APC01-SG2-obe.outbound.protection.outlook.com X-Spam_score_int: 14 X-Spam_score: 1.4 X-Spam_bar: + X-Spam_report: (1.4 / 5.0 requ) BAYES_00=-1.9, CHARSET_FARAWAY_HEADER=3.2, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: qemu-devel-bounces+importer=patchew.org@nongnu.org X-ZohoMail-DKIM: pass (identity @OUTLOOK.JP) X-ZM-MESSAGEID: 1720150434960100005 --_000_SEZPR01MB43019C6C7D242A7A18B9C0B6A4DF2SEZPR01MB4301apcp_ Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" This is a ping to the patch below. https://lore.kernel.org/qemu-devel/TY0PR0101MB42850337F8917D1F514107FBA4D52= @TY0PR0101MB4285.apcprd01.prod.exchangelabs.com/ ________________________________ =E5=B7=AE=E5=87=BA=E4=BA=BA: TaiseiIto =E9=80=81=E4=BF=A1=E6=97=A5=E6=99=82: 2024=E5=B9=B46=E6=9C=8825=E6=97=A5 21= :03 =E5=AE=9B=E5=85=88: qemu-devel@nongnu.org CC: pbonzini@redhat.com ; mst@redhat.com ; TaiseiIto =E4=BB=B6=E5=90=8D: [PATCH] hw/intc/ioapic: Delete a wrong IRQ redirection = on I/O APIC Before this commit, interruptions from i8254 which should be sent to IRQ0 were sent to IRQ2. After this commit, these are correctly sent to IRQ0. When I had an HPET timer generate interruptions once per second to test an HPET driver in my operating system on QEMU, I observed more frequent interruptions than I configured on the HPET timer. I investigated the cause and found that not only interruptions from HPET but also interruptions from i8254 were sent to IRQ2 because of a redirection from IRQ0 to IRQ2. This redirection is added in hw/apic.c at commit 16b29ae1807b024bd5052301550f5d47dae958a2 but this redirection caused wrong interruptions. So I deleted the redirection. Finally, I confirmed there is no problem on 'make check' results and that interruptions from i8254 and interruptions from HPET are correclty sent to IRQ0 and IRQ2 respectively. Signed-off-by: TaiseiIto --- hw/intc/ioapic.c | 7 ------- 1 file changed, 7 deletions(-) diff --git a/hw/intc/ioapic.c b/hw/intc/ioapic.c index 716ffc8bbb..6b630b45ca 100644 --- a/hw/intc/ioapic.c +++ b/hw/intc/ioapic.c @@ -154,15 +154,8 @@ static void ioapic_set_irq(void *opaque, int vector, i= nt level) { IOAPICCommonState *s =3D opaque; - /* ISA IRQs map to GSI 1-1 except for IRQ0 which maps - * to GSI 2. GSI maps to ioapic 1-1. This is not - * the cleanest way of doing it but it should work. */ - trace_ioapic_set_irq(vector, level); ioapic_stat_update_irq(s, vector, level); - if (vector =3D=3D 0) { - vector =3D 2; - } if (vector < IOAPIC_NUM_PINS) { uint32_t mask =3D 1 << vector; uint64_t entry =3D s->ioredtbl[vector]; -- 2.34.1 --_000_SEZPR01MB43019C6C7D242A7A18B9C0B6A4DF2SEZPR01MB4301apcp_ Content-Type: text/html; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable
This is a ping to the patch below.


=1B$B:9=3DP?M=1B(B: TaiseiIto <taisei1212@outlook.jp>
=1B$BAw?.F|;~=1B(B: 2024=1B$BG/=1B(B6=1B$B7n=1B(B25=1B$BF|=1B(B= 21:03
=1B$B08@h=1B(B: qemu-devel@nongnu.org <qemu-devel@nongnu.org= >
CC: pbonzini@redhat.com <pbonzini@redhat.com>; mst@redhat= .com <mst@redhat.com>; TaiseiIto <taisei1212@outlook.jp>
=1B$B7oL>=1B(B: [PATCH] hw/intc/ioapic: Delete a wrong IRQ redi= rection on I/O APIC
 
Before this commit, interruptions from i825= 4 which should be sent to IRQ0
were sent to IRQ2. After this commit, these are correctly sent to IRQ0. Whe= n
I had an HPET timer generate interruptions once per second to test an HPET<= br> driver in my operating system on QEMU, I observed more frequent
interruptions than I configured on the HPET timer. I investigated the cause=
and found that not only interruptions from HPET but also interruptions from=
i8254 were sent to IRQ2 because of a redirection from IRQ0 to IRQ2. This redirection is added in hw/apic.c at commit
16b29ae1807b024bd5052301550f5d47dae958a2 but this redirection caused wrong<= br> interruptions. So I deleted the redirection. Finally, I confirmed there is<= br> no problem on 'make check' results and that interruptions from i8254 and interruptions from HPET are correclty sent to IRQ0 and IRQ2 respectively.
Signed-off-by: TaiseiIto <taisei1212@outlook.jp>
---
 hw/intc/ioapic.c | 7 -------
 1 file changed, 7 deletions(-)

diff --git a/hw/intc/ioapic.c b/hw/intc/ioapic.c
index 716ffc8bbb..6b630b45ca 100644
--- a/hw/intc/ioapic.c
+++ b/hw/intc/ioapic.c
@@ -154,15 +154,8 @@ static void ioapic_set_irq(void *opaque, int vector, i= nt level)
 {
     IOAPICCommonState *s =3D opaque;
 
-    /* ISA IRQs map to GSI 1-1 except for IRQ0 which maps -     * to GSI 2.  GSI maps to ioapic 1-1.  T= his is not
-     * the cleanest way of doing it but it should work= . */
-
     trace_ioapic_set_irq(vector, level);
     ioapic_stat_update_irq(s, vector, level);
-    if (vector =3D=3D 0) {
-        vector =3D 2;
-    }
     if (vector < IOAPIC_NUM_PINS) {
         uint32_t mask =3D 1 <&l= t; vector;
         uint64_t entry =3D s->i= oredtbl[vector];
--
2.34.1

--_000_SEZPR01MB43019C6C7D242A7A18B9C0B6A4DF2SEZPR01MB4301apcp_--