Received: by 10.223.185.116 with SMTP id b49csp3671644wrg; Tue, 13 Feb 2018 06:04:17 -0800 (PST) X-Google-Smtp-Source: AH8x225ME/5QbwPs9bdTuuA/mqBp8D8GEbKU6MLcT2tC6gi68p73kvhzHPRiBqM0w6aHjq4AG0TH X-Received: by 10.98.215.12 with SMTP id b12mr1342641pfh.149.1518530657797; Tue, 13 Feb 2018 06:04:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1518530657; cv=none; d=google.com; s=arc-20160816; b=BGTgB6704T23FQ1bT19aq7SlC9685ZC3vhnc8/geg88B2cXyM7sPScfvPMyZWHXGJm 4AyU7sK6J2euj7XOqoSgp/AMg9R5bv1c43BarIqGhQbav/3PHL3MH0Z2+jWyvS7XKaCa OSDklUCzIV/P4WW6Ja/OpjMN8Q510PQ9ZCloa58ZWduQYsqDdRHMUKaOHOm7vmP6Hy7h VHpris1qf+AdskqEiAKw76egVNIvV6kdDwmdGfiFFzQYFHaCP3clY98WI14rfwH3c0SR Q5ryPAydOxOAou9OKce+Sof3/knUZ95YjWhZT+TwdvvOvhxUhkpfnWnRjY25Rh2aJq/y Q3Zg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:arc-authentication-results; bh=usE/6//KY00I3rkwn3olkqS7+1Bl7UjF0NxY0YljhLo=; b=lIMAKh8KJt7QEng0BtAFs5BQ3Svib63HR4BW/Y2oNFFArixFvLz/IClj9ECUOg9VKq U9e3kOxbWykNbGPENgncQHRQgBYbEzOWjJGUg+D4a/OK7Cyt+HOy40/C3JToDq1LkHXC HM3ujTuIXnqTOzRQNnhDPSpfsrZmfVoTyJGVVEzrTVrLbG3ZyYrC4U6VOMeEmJTnqQBX b+uHXfxCQYhHKJdIapDdqpb5D1KfiaJ8+WrGEjURbQ4c3+xN3jHnokIfV2fc+sZXcuUS VjMqqlGli6tNIkGKj7OgoPsEuCFP2IqAAJJgll3mR/KdKqs/o05/AQZAh8mqWpMbgL1J Ir4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail (test mode) header.i=@8bytes.org header.s=mail-1 header.b=FEqxDPmk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g33-v6si1509171plb.251.2018.02.13.06.04.02; Tue, 13 Feb 2018 06:04:17 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail (test mode) header.i=@8bytes.org header.s=mail-1 header.b=FEqxDPmk; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=8bytes.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S965058AbeBMODH (ORCPT + 99 others); Tue, 13 Feb 2018 09:03:07 -0500 Received: from 8bytes.org ([81.169.241.247]:38208 "EHLO theia.8bytes.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964879AbeBMODF (ORCPT ); Tue, 13 Feb 2018 09:03:05 -0500 Received: by theia.8bytes.org (Postfix, from userid 1000) id F3E3E242; Tue, 13 Feb 2018 15:03:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=8bytes.org; s=mail-1; t=1518530584; bh=pKvKlkYq4kIyQTj3qFrw/6FODavuVa/rJ7FqTjwfVfI=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=FEqxDPmkboGjC1rphuAGj/EjKjMX/RhJmCvq5zLxWan9PG/iA+dbeOmQVW70CmCep VOFEGjTyc/0cZv5Ep/ZZnPkewC8bIhpH1IGJYJuXdMf+Gu94vT+UPEXaOs28BHNEnS NGSM791/wSMZWTAhcbG8LxHs+mqhX6hYqt25prcivxFK8a5HCKlQsv8USlyq07GzGY Nx94m4TmzfCc1Ps/Bl5HbHIFpC3smaeRJ9IYLoJKeALSpO/uioZoh7fq5T2E3hvhwB L0XIjhJyaN3nVtX7+0sVGvywz0tTOgcFs25LYuIe+Kvyw14U7H4zuJmQ58DazPehhl BxZex8OK4syPw== Date: Tue, 13 Feb 2018 15:03:03 +0100 From: Joerg Roedel To: Sohil Mehta Cc: Alex Williamson , Ashok Raj , David Woodhouse , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Jacob Pan , Gayatri Kammela , Ravi V Shankar , Andy Shevchenko , Lu Baolu , Fenghua Yu Subject: Re: [PATCH v7 0/5] Add Intel IOMMU debugfs support Message-ID: <20180213140303.42mbzfxpypljy37l@8bytes.org> References: <1517619001-148586-1-git-send-email-sohil.mehta@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1517619001-148586-1-git-send-email-sohil.mehta@intel.com> User-Agent: NeoMutt/20170421 (1.8.2) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 02, 2018 at 04:49:56PM -0800, Sohil Mehta wrote: > This series aims to add debugfs support for Intel IOMMU. It exposes IOMMU > registers, internal context and dumps individual table entries to help debug > Intel IOMMUs. > > The first patch does the ground work for the following patches by reorganizing > some Intel IOMMU data structures. The following patches create a new Kconfig > option - INTEL_IOMMU_DEBUG and add debugfs support for IOMMU context internals, > register contents, PASID internals, and Interrupt remapping in that order. The > information can be accessed in sysfs at '/sys/kernel/debug/intel_iommu/'. This looks like it only presents data from the iommu-hardware (register state) or from in-memory data structures used by the hardware. Can't all this be read out from user-space with libpci and /dev/mem access? Things are different for kernel-defined data structures, as they might change between releases and can be presented to user-space via debugfs is needed, but the data structures used by the hardware should be pretty stable. Joerg