Received: by 2002:ab2:68c1:0:b0:1fd:9a81:d0e4 with SMTP id e1csp392542lqp; Sun, 9 Jun 2024 00:33:23 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUWlv69ATwceo1foBqy0w0SP2zV132xpMP2Uz++Ey7WoIrauY+YyyDWoKzxaITWUzQekLh9yK9YzWaf5+DbZQHNkgNzxT0j9RclA0ABog== X-Google-Smtp-Source: AGHT+IFqRCmr6t0qupHHuhtBu5ygvccm2vNKIXs8Pr48fmn+CBufUM2rkeo9zD8/C2aXdMzd81hv X-Received: by 2002:a05:620a:29d0:b0:792:bf9b:3dab with SMTP id af79cd13be357-7953c434d39mr818534985a.39.1717918403691; Sun, 09 Jun 2024 00:33:23 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717918403; cv=pass; d=google.com; s=arc-20160816; b=ppIg3hZatWmslmjm4plton7f1fHCSf0SiWXPVK5xsLkKGN6jQHwyBnMNPCQrGZ2qoV S01OFtbneIASueS4YJ3c9ySnwaIRNtO0LebvQpDIIlPX1Y94vHponTdBDXgpOtSxBLcE QAk+OBgm1bvF51T9I24YH8T056UETWr1rYJlEiB27gQTfbzdPLupvPaEdlEDwLGLnyO9 ljfYE8pcLUXt2vWsmkoJI9r6V0FUB6frtX9YVjPi0/qlADlCmXSHddUI4FX7vQ+fzlaW grkGNXiyR9tyRvtK9bchLpIpReT5iaZ38WOn0z6PiEco2kCk0wGIJ7o+/aLMkJsFzQf7 YDMA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:in-reply-to:from:content-language :references:to:subject:cc:user-agent:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:date:message-id:dkim-signature; bh=WDb7tLPdmYPPxl5gmrzL8h47NWUHGzgy7P49zl/Zdos=; fh=mxKfdGA1jddtH7BjHWkjPpZMn4JeKdsSiZe3BjuqDbE=; b=sl7Vm16f/MmHjNTT+Gr5oEcyIQ8Neh+T3opLQOPqe1axvtpcPtS2P4mRgrce7d/LHo KxTVAebAQY01I/WVvJcr1YQknAoHiCQnM8/LvDdqX1ztkLLDEN8ZPR+IK7j6wVQpDBHV stnCQjk09D4nlnmGWr3x6pLO75FnyoTvSjJXK1MvhmMj703YymtQw4uSaMM2lmu06EmO xk+c461+AztEobOq/6Hzxt0klryUk2ys5fJL/xiezuoYHnIq9SdMkUtp/7bx428CmtRj SA2EgeWTLOyGTT1rpI2eHoBLooLNcINjJoS/wh+Hq++ZR/UydWVGDIqtiUPsUhXODkJL 9fvA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=hbPZ96fn; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-207269-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-207269-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [2604:1380:45d1:ec00::1]) by mx.google.com with ESMTPS id af79cd13be357-795485276a9si462506185a.170.2024.06.09.00.33.23 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 09 Jun 2024 00:33:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-207269-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) client-ip=2604:1380:45d1:ec00::1; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b=hbPZ96fn; arc=pass (i=1 dkim=pass dkdomain=intel.com dmarc=pass fromdomain=linux.intel.com); spf=pass (google.com: domain of linux-kernel+bounces-207269-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45d1:ec00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-207269-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 8F8EA1C2119B for ; Sun, 9 Jun 2024 07:33:18 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id F416F1BF47; Sun, 9 Jun 2024 07:33:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b="hbPZ96fn" Received: from mgamail.intel.com (mgamail.intel.com [192.198.163.8]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 7719BD29E for ; Sun, 9 Jun 2024 07:33:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=192.198.163.8 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717918391; cv=none; b=g2WRes5GIJQ/scuo2xLflcUcssy1fmK2xAp0JCjEZFJRn52g1rMIMOMhO5yBdjis/RVaLFC6kJ5gCTTNiZKM3CjsV1SxnPxJt/F+O1U7D3Q0kKgtZwldRL/3XSyiIIzupSpVgye7J5qfT3MPMNB5RA2C22hsVoFrXiaiACcWqLQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717918391; c=relaxed/simple; bh=6aFJQCU4PfS3rcXKKlQlz+ML8ImSC4rh3Wu5S/El4Fc=; h=Message-ID:Date:MIME-Version:Cc:Subject:To:References:From: In-Reply-To:Content-Type; b=UW22QH6yi8d4hfbhNoAOP5PI3QnJUCQONdYc+ihCkyv5WsODDWTQyS2BXn9cLpQkoNCLUTPBo8seQ4tx7t/UjG4QAdiFa1ujPAH/R0bQWmW7Is6fxeQxzf91nEP3h56InOc5dWHMhjTbwr+yqKZJaOd3TSJedCdPDyLEQH4AEmg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com; spf=none smtp.mailfrom=linux.intel.com; dkim=pass (2048-bit key) header.d=intel.com header.i=@intel.com header.b=hbPZ96fn; arc=none smtp.client-ip=192.198.163.8 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=linux.intel.com Authentication-Results: smtp.subspace.kernel.org; spf=none smtp.mailfrom=linux.intel.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1717918389; x=1749454389; h=message-id:date:mime-version:cc:subject:to:references: from:in-reply-to:content-transfer-encoding; bh=6aFJQCU4PfS3rcXKKlQlz+ML8ImSC4rh3Wu5S/El4Fc=; b=hbPZ96fn2Wn4Nlkt3fgqIQfG4AhC/7djuC7biRQOock8K7gkRCh1aGB1 qs4AVnrVLFD4ZWjYmj0h1QRNNUbmckg2w2L2GnPW2PGct7IvkjJKeglOr 2vqBW0G6l5vasmo9ewnMPoe7XJ7FM60GT0VDzjNQAQ2JW2P0yuxXdoWzs hD1LBdKpQ0d1smVf+4Rip5ewuZ70/1k1qoPJ5M5pSeNoOmS/mbfD2afRl uNyb7ZneBF0TxKu8t1SHwFdBx5gQE33eNPthUtB4ErAdBjDSebxGT6vxf RDKYXTD9F0ll1q/OUsml00sMuyvzRltx3JrcTsPjpYrl/t3sm1fg6ergM A==; X-CSE-ConnectionGUID: xrE+4DFiQLKbj60eRCdHAQ== X-CSE-MsgGUID: XyncmmDTRwKV146mWXWAJA== X-IronPort-AV: E=McAfee;i="6600,9927,11097"; a="32136876" X-IronPort-AV: E=Sophos;i="6.08,225,1712646000"; d="scan'208";a="32136876" Received: from orviesa010.jf.intel.com ([10.64.159.150]) by fmvoesa102.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Jun 2024 00:33:08 -0700 X-CSE-ConnectionGUID: OqQdNhqdTm2j4Rinc57ReA== X-CSE-MsgGUID: 7lHAV04gRzmAkgMx9TKYcA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="6.08,225,1712646000"; d="scan'208";a="38678785" Received: from unknown (HELO [10.239.159.127]) ([10.239.159.127]) by orviesa010.jf.intel.com with ESMTP; 09 Jun 2024 00:33:07 -0700 Message-ID: Date: Sun, 9 Jun 2024 15:30:53 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Cc: baolu.lu@linux.intel.com, =?UTF-8?B?SsO2cmcgUsO2ZGVs?= , Will Deacon , iommu@lists.linux.dev, linux-kernel@vger.kernel.org Subject: Re: DMAR-IR: IRQ remapping was enabled on dmar6 but we are not in kdump mode To: Paul Menzel References: <5517f76a-94ad-452c-bae6-34ecc0ec4831@molgen.mpg.de> <433452d0-589a-49c8-8044-dcc93d5be90a@linux.intel.com> <24bf9a11-6abd-4ccf-9ca1-3cf75c45d374@molgen.mpg.de> <42b53bff-4027-4cb6-a457-e26fd62895e5@linux.intel.com> <61ce93c7-e89c-4217-8095-dde9fb01763c@molgen.mpg.de> <7eb01b85-9233-4f21-865e-6d128f39fb46@linux.intel.com> <754664f9-ac5b-406e-99bd-1b179ea8333b@molgen.mpg.de> Content-Language: en-US From: Baolu Lu In-Reply-To: <754664f9-ac5b-406e-99bd-1b179ea8333b@molgen.mpg.de> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 6/8/24 7:07 PM, Paul Menzel wrote: > Dear Linux folks, > > > Am 15.05.24 um 08:02 schrieb Paul Menzel: > >> Am 15.05.24 um 04:13 schrieb Baolu Lu: >>> On 5/15/24 3:46 AM, Paul Menzel wrote: >>>> Am 23.01.24 um 01:55 schrieb Baolu Lu: >>>>> On 2024/1/22 22:53, Paul Menzel wrote: >>>>>> Am 22.01.24 um 13:38 schrieb Baolu Lu: >>>>>>> On 2024/1/19 22:45, Paul Menzel wrote: >>>>>>>> >>>>>>>> On a Dell PowerEdge T640, Linux 5.9 and 6.6.12 warn about kdump: >>>>>>>> >>>>>>>>      [    2.728445] DMAR-IR: IRQ remapping was enabled on dmar6 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.736544] DMAR-IR: IRQ remapping was enabled on dmar5 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.744620] DMAR-IR: IRQ remapping was enabled on dmar4 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.752695] DMAR-IR: IRQ remapping was enabled on dmar3 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.760774] DMAR-IR: IRQ remapping was enabled on dmar2 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.768847] DMAR-IR: IRQ remapping was enabled on dmar1 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.776922] DMAR-IR: IRQ remapping was enabled on dmar0 >>>>>>>> but we are not in kdump mode >>>>>>>>      [    2.784999] DMAR-IR: IRQ remapping was enabled on dmar7 >>>>>>>> but we are not in kdump mode >>>>>>>> >>>>>>>> Looking through the logs, this only happens when using kexec to >>>>>>>> restart the system. >>>>>>> >>>>>>> The code that warned this is, >>>>>>> >>>>>>>   599         if (ir_pre_enabled(iommu)) { >>>>>>>   600                 if (!is_kdump_kernel()) { >>>>>>>   601                         pr_warn("IRQ remapping was enabled >>>>>>> on %s but we are not in kdump mode\n", >>>>>>>   602                                 iommu->name); >>>>>>>   603                         clear_ir_pre_enabled(iommu); >>>>>>>   604                         iommu_disable_irq_remapping(iommu); >>>>>>>   605                 } >>>>>>> >>>>>>> The VT-d interrupt remapping is enabled during boot, but this is >>>>>>> not a >>>>>>> kdump kernel. >>>>>>> >>>>>>> Do you mind checking whether the disable interrupt remapping >>>>>>> callback >>>>>>> was called during kexec reboot? >>>>>>> >>>>>>> 1121 struct irq_remap_ops intel_irq_remap_ops = { >>>>>>> 1122         .prepare                = intel_prepare_irq_remapping, >>>>>>> 1123         .enable                 = intel_enable_irq_remapping, >>>>>>> 1124         .disable                = disable_irq_remapping, >>>>>>> 1125         .reenable               = reenable_irq_remapping, >>>>>>> 1126         .enable_faulting        = enable_drhd_fault_handling, >>>>>>> 1127 }; >>>>>> >>>>>> Is there a way to check this without rebuilding the Linux kernel? >>>>> >>>>> I am not sure, but you can check whether any messages are dumped in >>>>> the >>>>> path of .disable callback? or try to use ftrace? >>>> >>>> With >>>> >>>> ``` >>>> diff --git a/drivers/iommu/intel/irq_remapping.c >>>> b/drivers/iommu/intel/irq_remapping.c >>>> index 712ebfc9870c6..146f19ae5b5f1 100644 >>>> --- a/drivers/iommu/intel/irq_remapping.c >>>> +++ b/drivers/iommu/intel/irq_remapping.c >>>> @@ -1030,6 +1030,7 @@ static void disable_irq_remapping(void) >>>>       struct dmar_drhd_unit *drhd; >>>>       struct intel_iommu *iommu = NULL; >>>> >>>> +     pr_warn("XXX: Called %s\n", __func__); >>>>       /* >>>>        * Disable Interrupt-remapping for all the DRHD's now. >>>>        */ >>>> ``` >>>> >>>> I can’t see anything in the logs, so it does not seem to be called. >>>> >>>> Can you reproduce the issue? >>> >>> How did you reproduce this? >> >> On a “server” (with Intel Xeon?), in my case Dell PowerEdge T640 and >> Dell PowerEdge R930 (Intel E7-8891 v3), run >> >>      kexec /boot/bzImage --initrd=/boot/grub/initramfs.igz >> --reuse-cmdline > > Were you able to fit some cycles into reproducing/analyzing this issue? Yeah! I can reproduce this issue with my local development machine. But I haven't had time to analyze it yet. Perhaps we can remove this message, or make sure the .disable callback should be called? Best regards, baolu