From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751556AbdL1I6F (ORCPT ); Thu, 28 Dec 2017 03:58:05 -0500 Received: from mga05.intel.com ([192.55.52.43]:7483 "EHLO mga05.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751086AbdL1I6E (ORCPT ); Thu, 28 Dec 2017 03:58:04 -0500 X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.45,470,1508828400"; d="scan'208";a="15683379" Message-ID: <1514451118.7000.308.camel@linux.intel.com> Subject: Re: [PATCH v5 2/5] iommu/vt-d: Add debugfs support to show context internals From: Andy Shevchenko To: Sohil Mehta , Joerg Roedel , Alex Williamson Cc: David Woodhouse , Ashok Raj , iommu@lists.linux-foundation.org, linux-kernel@vger.kernel.org, Jacob Pan , Gayatri Kammela , Ravi V Shankar , Lu Baolu , Fenghua Yu Date: Thu, 28 Dec 2017 10:51:58 +0200 In-Reply-To: <1513902760-45605-3-git-send-email-sohil.mehta@intel.com> References: <1513902760-45605-1-git-send-email-sohil.mehta@intel.com> <1513902760-45605-3-git-send-email-sohil.mehta@intel.com> Organization: Intel Finland Oy Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.26.3-1 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2017-12-21 at 16:32 -0800, Sohil Mehta wrote: > From: Gayatri Kammela > > IOMMU internals states such as root and context can be exported to the > userspace. > > Example of such dump in Kabylake: > v5: Change to a SPDX license tag > Fix seq_printf formatting > > > +#define pr_fmt(fmt) "INTEL_IOMMU: " fmt > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include > +#include It might make sense to keep above ordered alphabetically. > +static void root_tbl_entry_show(struct seq_file *m, struct > intel_iommu *iommu, > + u64 rtaddr_reg, bool ext, bool > new_ext) > +{ > + int bus; > + > + seq_printf(m, "\nIOMMU %s: %2s Root Table Addr:%llx\n", > iommu->name, > + ext ? "Extended" : "", rtaddr_reg); Still leading '\n'... -- Andy Shevchenko Intel Finland Oy