Received: by 2002:a05:6902:102b:0:0:0:0 with SMTP id x11csp3366813ybt; Tue, 30 Jun 2020 00:32:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxhKw4FC1Jx/8BmPlWnnqPDJt+V9dAm1hGAk2UIrSuKIBPP2yX/zQHuwBBZhmaSHGDUpVH2 X-Received: by 2002:a17:906:3c10:: with SMTP id h16mr17065446ejg.87.1593502374148; Tue, 30 Jun 2020 00:32:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593502374; cv=none; d=google.com; s=arc-20160816; b=h1D5KVYzBNcnU92buLF5p0RQTdzVfYRYNAh84Inx4ebdyE/DyGu6+7Tgezl+lJMfRQ dnAggKp1EVrknvMUrzhKmqd4QaNshqp9OLwYpu8qEBsmqv6V5NxIL1guPB58fGsaajYz iewPIO5eK5ngI7AebZrYfY52WzN1TX/WcF86We23gMeWXw0n6uXPW/5fqwMBKGVVy4Om 2KXRP9IMBdwZTgcQ8TZ+R76R4h6Ec9xhBn/kMdJ+NazDgMksk5VzZZy6cKmIZw97O20T PnGb+2XvKc85Iuzzlfz7srksgbGWhLhfpg00krw4YxUCVKo2vpbws6sQRxRHaO5pJN2y C/lQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version; bh=1e90/+4iquf4bsRpUW7KG7qb5zPqy3erpE91QO7pcqc=; b=S8KTs1S0tFQ+ofSMW5d5JKfszn+09G33g0zSJe6J7W3wFvaACVHLOfbcH9r/Z9aj6y FzCArTSry3lPSJSoDUQVuMEPJMbhD1De29DxVejx7cmm6LrTr8bEtJbfv3AmX4BdKZpw M+74M7UgmfPH5ijpEWZGPpiri7jPA62BQNjeOUIOOg9SFedqRGp8RpgoOmvsIlOIQCow a8foSpjpWDnztP6AG+pZffA/jZZ52BrrWITlwOtOFn6jtN8a8T2VFSiJHNeigEurNyom kfP2G8ueWN2wTPdbw6PvE6UZePEW7bDqhZXtcWaXGiyB7Jn+U/feOu6zSon88zK5TnS8 lF8Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id j17si1263277ejg.88.2020.06.30.00.32.30; Tue, 30 Jun 2020 00:32:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=canonical.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730985AbgF3HcH (ORCPT + 99 others); Tue, 30 Jun 2020 03:32:07 -0400 Received: from youngberry.canonical.com ([91.189.89.112]:36447 "EHLO youngberry.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730089AbgF3HcG (ORCPT ); Tue, 30 Jun 2020 03:32:06 -0400 Received: from mail-oi1-f198.google.com ([209.85.167.198]) by youngberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1jqAkO-0003Lf-CH for linux-kernel@vger.kernel.org; Tue, 30 Jun 2020 07:32:04 +0000 Received: by mail-oi1-f198.google.com with SMTP id 18so5483858ois.18 for ; Tue, 30 Jun 2020 00:32:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=1e90/+4iquf4bsRpUW7KG7qb5zPqy3erpE91QO7pcqc=; b=barjiEnx1E2gQbuHSvqICxemKqgw8Sm4vULBU4bWrDnHE8lOOTPIz3rdMnsqm0/RJJ aS+Rrf03CIbJtmpPz0Xfuy0iJdW7+XWmlT/P7GfmjE+H7WWpmfAjLXMqXp5CJbI9Sdzd o6ucyK3rZ4PAaP2VymFhIDTQnAcwY4zT1jwvDIkH7skBz6HLGUCKmV4PcXgmeQwyXAu3 hNCBxljy6g+2nkuLpiLh9xDIy1R0i8DWMNem0F+Sl6r/O7Wf9/SQfr/SwxkdXpvpgPTb /gVQp1Ckvdco/bVxs3TPbd4pdgNxpzqBJcBjrIo51cHyCEJbRB7TTu7UN6K4hS6mWVVB ETHw== X-Gm-Message-State: AOAM533M+NEFqYthRWUOMZK4Gf60STBQX1dDBVImqibu2JaiYIE1AjxY n4pMwuxPZQP913DBoKO1KAtD39CGYbaCEmVkuLc800v2yYt64BHef4GBwGdahY+cj6p9LiYunH/ Wn0n1vQB5dS2AT+gXGaNXgqa6SrQHecLgAPDCeAewb5TgrCADiLRXrRLBXA== X-Received: by 2002:a54:4e1d:: with SMTP id a29mr7387351oiy.139.1593502323394; Tue, 30 Jun 2020 00:32:03 -0700 (PDT) X-Received: by 2002:a54:4e1d:: with SMTP id a29mr7387336oiy.139.1593502323155; Tue, 30 Jun 2020 00:32:03 -0700 (PDT) MIME-Version: 1.0 References: <111dde48-8018-6d74-5df8-1534143f4de6@linux.intel.com> In-Reply-To: <111dde48-8018-6d74-5df8-1534143f4de6@linux.intel.com> From: Koba Ko Date: Tue, 30 Jun 2020 15:31:52 +0800 Message-ID: Subject: Re: [Issue]platform/x86: iommu: System can't shutdown because iommu driver keeps checking the status of DMA_GSTS_TES To: Lu Baolu Cc: David Woodhouse , Joerg Roedel , iommu@lists.linux-foundation.org, Linux Kernel Mailing List , Kai Heng Feng , "Raj, Ashok" , "Sun, Jian" Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 15, 2020 at 3:20 PM Lu Baolu wrote: > > Hi Koba Ko, > > On 2020/6/15 11:19, Koba Ko wrote: > > hi All, > > I have a machine and there's only intel gpu. > > the secureboot and vt-d is enabled in BIOS. > > On the Ubuntu desktop, I do s2idle first and restart the machine. > > The machine can't restart successfully, so I need to press the > > power button to shutdown. > > I tried each of the following and the issue can't be triggered. > > 1. disable secure boot in BIOS. > > 2. intel_iommu=off. > > 3. intel_iomm=igfx_off. > > 4. nomodeset > > 5. i915.modeset=0. > > > > After I investigate further, find inte_iommu keeps checking the status > > of DMA_GSTS_TES. > > During the procedure of restart, the driver would disable iommu > > translation and > > check status of DMA_GSTS_TES until status of DMA_GSTS_TES is 0. > > > > If you need more information, I can provide it. > > Do you mind telling what platform is it? > > Best regards, > baolu Hi Baolu, Sorry, i missed your email. I'm running on TGL. My colleague has reported this on bugzilla. Have tested your patch and it works fine. https://bugzilla.kernel.org/show_bug.cgi?id=208363 Could you explain more about these patches!? Why do we need a flag for active iommu!? Koba Ko