From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 30BDEC433DF for ; Wed, 3 Jun 2020 14:54:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 0F32F20738 for ; Wed, 3 Jun 2020 14:54:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726046AbgFCOyz (ORCPT ); Wed, 3 Jun 2020 10:54:55 -0400 Received: from mga05.intel.com ([192.55.52.43]:13341 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725985AbgFCOyy (ORCPT ); Wed, 3 Jun 2020 10:54:54 -0400 IronPort-SDR: yYEa+ODQTv4e0MaGzm3NmUrLxnLvbUAs6C8zJ75bo7lt2mMdw1uKVsfb3EpsIU0qMb2djOl399 3ytsxGIq4Emw== X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga105.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 03 Jun 2020 07:54:54 -0700 IronPort-SDR: Na/zi5dWpOxM01SPF1+rbTUPlBzY0vjHthSG6Ni6xBFD3i9x1SJi0Ajc5fM/USa4TUtX5uaSRy xDQzcNFyX0iA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.73,467,1583222400"; d="scan'208";a="378127274" Received: from lahna.fi.intel.com (HELO lahna) ([10.237.72.163]) by fmsmga001.fm.intel.com with SMTP; 03 Jun 2020 07:54:49 -0700 Received: by lahna (sSMTP sendmail emulation); Wed, 03 Jun 2020 17:54:48 +0300 Date: Wed, 3 Jun 2020 17:54:48 +0300 From: Mika Westerberg To: Rajat Jain Cc: David Woodhouse , Lu Baolu , Joerg Roedel , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Ashok Raj , lalithambika.krishnakumar@intel.com, rajatxjain@gmail.com, pmalani@google.com, bleung@google.com, levinale@google.com, zsm@google.com, mnissler@google.com, tbroch@google.com Subject: Re: [PATCH v4] iommu/vt-d: Don't apply gfx quirks to untrusted devices Message-ID: <20200603145448.GU247495@lahna.fi.intel.com> References: <20200603130317.94672-1-rajatja@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200603130317.94672-1-rajatja@google.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 03, 2020 at 06:03:17AM -0700, Rajat Jain wrote: > Currently, an external malicious PCI device can masquerade the VID:PID > of faulty gfx devices, and thus apply iommu quirks to effectively > disable the IOMMU restrictions for itself. > > Thus we need to ensure that the device we are applying quirks to, is > indeed an internal trusted device. > > Signed-off-by: Rajat Jain > Acked-by: Lu Baolu > Reviewed-by: Ashok Raj Looks good now, thanks! Reviewed-by: Mika Westerberg