linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Lorenzo Pieralisi <lorenzo.pieralisi@arm.com>
To: Sinan Kaya <okaya@codeaurora.org>
Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
	Hanjun Guo <hanjun.guo@linaro.org>,
	Tomasz Nowicki <tn@semihalf.com>,
	Nate Watterson <nwatters@codeaurora.org>,
	"Rafael J. Wysocki" <rjw@rjwysocki.net>
Subject: Re: [PATCH] ACPI/IORT: Fix iort_node_get_id() mapping entries indexing
Date: Fri, 6 Jan 2017 09:48:26 +0000	[thread overview]
Message-ID: <20170106094811.GA8587@red-moon> (raw)
In-Reply-To: <8f8816bf-1a29-ca28-79f3-7bc1b9e9fb5c@codeaurora.org>

On Thu, Jan 05, 2017 at 01:37:22PM -0500, Sinan Kaya wrote:
> On 1/5/2017 1:29 PM, Lorenzo Pieralisi wrote:
> > iort_node_get_id() takes an index as input to refer to a specific
> > mapping entry in the mapping array to retrieve the id at a specific
> > index provided the index is below the total mapping count; currently the
> > index is used to retrieve the mapping value from the correct entry but
> > not to dereference the correct entry while retrieving the mapping
> > output_reference (ie IORT parent pointer), which consequently always
> > resolves to the output_reference of the first entry in the mapping
> > array.
> 
> Maybe, irrelevant but I'm going to throw it out.
> 
> Can we somehow break these multiple input and multiple output single
> function into smaller and manageable pieces while we are fixing a bug
> on it?

No. This is a fix for code currently in the kernel that is going
to be released in a few weeks, it is not a clean-up, please let me
know if it works on your platforms.

> These functions seem to do N different things when an input is present
> or not. 
> 
> I got lost in these function when implementing ITS->SMMU->NC use case.

Hanjun is carrying out the clean-up of the mapping functions as part of
its platform MSIs patchset, I followed up on that already to achieve
what you request above.

Thanks,
Lorenzo

  reply	other threads:[~2017-01-06  9:56 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-01-05 18:29 [PATCH] ACPI/IORT: Fix iort_node_get_id() mapping entries indexing Lorenzo Pieralisi
2017-01-05 18:37 ` Sinan Kaya
2017-01-06  9:48   ` Lorenzo Pieralisi [this message]
2017-01-07 21:09 ` Sinan Kaya
2017-01-09  6:34   ` Hanjun Guo
2017-01-09  6:48     ` Hanjun Guo
2017-01-09 11:20     ` okaya
2017-01-09  8:01 ` Hanjun Guo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20170106094811.GA8587@red-moon \
    --to=lorenzo.pieralisi@arm.com \
    --cc=hanjun.guo@linaro.org \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nwatters@codeaurora.org \
    --cc=okaya@codeaurora.org \
    --cc=rjw@rjwysocki.net \
    --cc=tn@semihalf.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).