[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH RFC 0/6] x86/ioapic: fix edge triggered interrupt migration
- To: xen-devel@xxxxxxxxxxxxxxxxxxxx
- From: Roger Pau Monne <roger.pau@xxxxxxxxxx>
- Date: Thu, 21 Apr 2022 15:21:08 +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=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=p0eLGIcM3P4X+NUpoJY3mSiSpRD256XuFHD/XZ8SoOc=; b=HEPg8uSPqP49OiWpOlhol7Xz3T1HznCLw+kzPbVo8wh5+p9/A/Aequr4eu6QMj5ej6OR87prOpTa3lHRPyjdzJuRw/gK/JqFx9Z5FMkww+CexBy94NiKiqxm8fDAo4DJsGxIM8TFo46/fL4R8KCFgC553uXL7rLwsLBNqNXT5LEJcd5hGsetR/SbZRu3QQkRwnokZGN4RJddPGDuW/szxzzarRZ3K7cWijRQe1slkYDbuvZ/8C3CpiU2h8218wCDKnrfTSkU9+M9qvcBexZr/YishGA1qUyi0+xR6Hz490Lcbr649Q1SU8YcJjOp5wJyt8bwszpf16ixjtF4ujkBnw==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=EaH5qi5fFEkyBpCF6gUewO3xE1DhH0OoypZ9uf0xjk6nCvD34JgjS3jdXKfU3nNkI561Xv0FdOrsTBkTmvOQrKr/jXeQKss8WNvg1H4AcyEoVzmEWNF/9lvfj9m8nrU6MmysrCWa5gkxglWixuidufAJh+mMT6ebtHj2sVMtWS9AMp4MDyyGeeBsAd/C7WN8KYkSbY4y6EVlVzUbQ/Y256JPF3O1sY9a1S05+J57urOKNsdRFy1hhYh5FAL4RE921Wc4SE2i7Fvl3cDr2DLxJVCOeq/nLaHCVoSaHe8ugV3Mv/DjL+WSlcrk5oIxyXzuGQX9Swby2lMCk/4WZLz70w==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: Roger Pau Monne <roger.pau@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Kevin Tian <kevin.tian@xxxxxxxxx>, Paul Durrant <paul@xxxxxxx>
- Delivery-date: Thu, 21 Apr 2022 13:22:02 +0000
- Ironport-data: A9a23:Wi78SKOr1hOd+qXvrR21lsFynXyQoLVcMsEvi/4bfWQNrUpz3zACz GtNUWrSbqmNMGekKYt3a9njpE0C6JaAyNdhHAto+SlhQUwRpJueD7x1DKtR0wB+jCHnZBg6h ynLQoCYdKjYdleF+lH1dOKJQUBUjclkfJKlYAL/En03FFcMpBsJ00o5wbZl2Ncw2LBVPivW0 T/Mi5yHULOa82Yc3lI8s8pvfzs24ZweEBtB1rAPTagjUG32zhH5P7pGTU2FFFPqQ5E8IwKPb 72rIIdVXI/u10xF5tuNyt4Xe6CRK1LYFVDmZnF+A8BOjvXez8CbP2lS2Pc0MC9qZzu1c99Z2 O9dqpqqSFoTMoaQnuEmaEd5FSpMBPgTkFPHCSDXXc276WTjKiGp6dM+SUY8MMsf5/p9BnxI+ boAMjcRYxufhuWwhrWmVu1rgcdlJ87uVG8dkig4kXeFUrB7HNaaHP+iCdxwhV/cguhUGvnTf YwBYCdHZxXceRxffFwQDfrSmc/21yelI2QE8zp5o4IXuHH0kE8y0oLoMYX7IYy6Y5QLhnmx8 zeuE2PRR0ty2Mak4SqI9Degi/HCmQv/WZkOD/uo+/hymlqRy2cPThoMWjOTo/O0l0q/UNJ3M FEP92wlqq1a3FOvZsnwWVu/unHslh0RRdtWVfE74Qely6zI7gLfDW8BJhZZYcEinN87Q3otz FDhoj/yLTlmsbnQQ3TN8L6R9Gm2IXJMcjVEYjIYRwwY5dWluJs0kh/EUtdkFuiyk8HxHjbzh TuNqUDSmokusCLC7I3jlXivvt5mjsGhotIdjukPYl+Y0w==
- Ironport-hdrordr: A9a23:qqV5lqOFaG8lVcBcT1z155DYdb4zR+YMi2TDiHoddfUFSKalfp 6V98jztSWatN/eYgBDpTnmAtj5fZq8z+8N3WB1B9uftWbdyQ+Vxe1ZjbcKoAeQZhEWiNQtsp uIGpIWYLOQMbETt7eB3ODSKadE/DDoytHKuQ+IpE0dNj2CJpsQmTuQTW2gYzxLbTgDIaB8OI uX58JBqTblUXMLbv6jDn1Ae+TYvdXEmL/vfBZDXnccmUGzpALtzIS/PwmT3x8YXT8K6bA+8V Ldmwi8wqm4qfm0xjLVymeWxZVLn9nKzMdFGaW3+4EoAwSprjztSJVqWrWEsjxwiOaz6GwymN 2JmBskN9Qb0QKlQkiF5T/WnyXw2jcn7HHvjXWCh2H4nMD/TDUmT+JcmINwaHLimgYdleA59J gO83OStpJRAx+Ftj/6/cL0WxZjkVfxiWY+kNQUk2dUXeIlGfJsRLQkjQ1o+ao7bWPHANhNKp gvMCic3ocdTbqiVQGXgoE1q+bcHUjaHX+9Mzo/U4KuonprdUtCvjQlLfwk7ws9Ha0GOud5Dp z/Q8JVfZF1P7srhPFGdZA8qfXeMB28fTv8dESvHH/AKIYrf1rwlr+f2sRH2AjtQu1C8KcP
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
Hello,
Following series attempts to solve the issue with IO-APIC edge triggered
interrupts seeing an inconsistent RTE or IRTE when injected while being
migrated.
It's currently RFC because some patches have post commit message notes,
and because I'm not sure if patch 1 is really needed. I originally had
the idea of suggesting to only backport patch 1 in order to fix the
issue in older releases, while leaving the more complex (and thus
error prone) IOMMU changes in unstable. Note however that patch 1 is
just a workaround to prevent interrupts seeing inconsistent entries
while being updated, masking the entry just makes the warning go away,
but the interrupt will be lost.
Thanks, Roger.
Roger Pau Monne (6):
x86/ioapic: set disable hook for masking edge interrupts
x86/ioapic: add a raw field to RTE struct
x86/ioapic: RTE modifications must use ioapic_write_entry
x86/iommu: pass full IO-APIC RTE for remapping table update
amd/iommu: atomically update remapping entries when possible
x86/ioapic: mask entry while updating
xen/arch/x86/include/asm/io_apic.h | 72 ++++++-------
xen/arch/x86/include/asm/iommu.h | 3 +-
xen/arch/x86/io_apic.c | 81 ++++++++++-----
xen/drivers/passthrough/amd/iommu.h | 2 +-
xen/drivers/passthrough/amd/iommu_intr.c | 115 +++++++--------------
xen/drivers/passthrough/vtd/extern.h | 2 +-
xen/drivers/passthrough/vtd/intremap.c | 125 +++++++++++------------
xen/drivers/passthrough/x86/iommu.c | 4 +-
xen/include/xen/iommu.h | 3 +-
9 files changed, 195 insertions(+), 212 deletions(-)
--
2.35.1
|