All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andreas Herrmann <herrmann.der.user@googlemail.com>
To: Julien Grall <julien.grall@linaro.org>
Cc: Ian Campbell <Ian.Campbell@citrix.com>,
	Stefano Stabellini <stefano.stabellini@eu.citrix.com>,
	tim@xen.org, stefano.stabellini@citrix.com,
	Andreas Herrmann <andreas.herrmann@calxeda.com>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH v2 10/12] xen/iommu: smmu: Check for duplicate stream IDs when registering master devices
Date: Tue, 27 Jan 2015 21:54:29 +0100	[thread overview]
Message-ID: <20150127205429.GA24135@alberich> (raw)
In-Reply-To: <54C7D038.4010808@linaro.org>

FYI, I am not actively working on the SMMU driver anymore.


Andreas

--
Pawns in the Game (W.G. Carr).

Think twice: People addicted to media (all?) who believe w/o
questioning all personalized information presented to them, are
massively manipulable via social media and designed plots might become
self-fulfilling prophecies.

--

On Tue, Jan 27, 2015 at 05:51:52PM +0000, Julien Grall wrote:
> On 27/01/15 17:44, Ian Campbell wrote:
> > On Tue, 2015-01-27 at 17:33 +0000, Julien Grall wrote:
> >> On 27/01/15 17:02, Stefano Stabellini wrote:
> >>> On Tue, 27 Jan 2015, Julien Grall wrote:
> >>>> On 27/01/15 16:30, Stefano Stabellini wrote:
> >>>>> On Fri, 16 Jan 2015, Julien Grall wrote:
> >>>>>> From: Andreas Herrmann <andreas.herrmann@calxeda.com>
> >>>>>>
> >>>>>> If DT information lists one stream ID twice for the master devices of
> >>>>>> an SMMU this can cause a multi match when stream ID matching is used.
> >>>>>> For stream ID indexing this might trigger an overwrite of an S2CR that
> >>>>>> is already in use.
> >>>>>>
> >>>>>> So better check for duplicates when DT information is parsed.
> >>>>>>
> >>>>>> Taken from the linux ML:
> >>>>>> http://lists.infradead.org/pipermail/linux-arm-kernel/2014-January/226099.html
> >>>>>>
> >>>>>> Cc: Andreas Herrmann <herrmann.der.user@googlemail.com>
> >>>>>> Signed-off-by: Andreas Herrmann <andreas.herrmann@calxeda.com>
> >>>>>> Signed-off-by: Julien Grall <julien.grall@linaro.org>
> >>>>>
> >>>>> Why didn't you just take a more recent version of the Linux smmu driver?
> >>>>
> >>>> The SMMU driver very is recent (see commit in the previous patch)...
> >>>> Just this patch has never reached upstream.
> >>>
> >>> That is not good. It might be worth to wait for it to go upstream.
> >>
> >> The patch was sent one year ago. Just before Calxeda was shutdown.
> >>
> >> This is a requirement for the following patch. Do you think the other
> >> patch should be upstream to Linux before?
> > 
> > In general we should be reluctant to diverge over these things, since it
> > just ends up making things harder for us in the future (e.g. the next
> > resync or the one after).
> > 
> > Is the issue being fixed here specific to Calxeda? e.g. is duplicate
> > stream ids a h/w bug which has yet to be observed elsewhere or is it a
> > valid configuration per the h/w specs which it just happens only Calxeda
> > implemented?
> 
> It's for catching possible error in the device tree. If the ID is
> duplicated the multi match algo in the following patch may not work
> correctly.
> 
> > 
> > Unless it's a h/w bug I don't see why it couldn't go upstream first.
> > Even if it is it might still stand a chance.
> 
> Because nobody take care to upstream it (see why below).
> 
> >> If so, Calxeda server won't be able to use properly SMMU.
> >>
> >> Even though the server will never be used, I do all my SMMU development
> >> on it.
> > 
> > The fact that Calxeda are no longer around doesn't in itself preclude
> > getting these patches upstreamed. After all, no one is deleting CX
> > support and some people do have them (not just us). It's hardly the most
> > obscure platform supported by Linux...
> 
> By default Linux is by-passing the stream ID and the device is not using
> the SMMU.
> 
> You will have to use either passthrough or manually said : "I want to
> enforce this device". And then you will see the error. So by default
> both patches are not necessary.
> 
> On Xen, we can't by-pass the SMMU by default. At least it's not the way
> it should work.
> 
> Regards,
> 
> -- 
> Julien Grall

  reply	other threads:[~2015-01-27 20:54 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-16 14:23 [PATCH v2 00/12] xen/arm: Resync the SMMU driver with the Linux one Julien Grall
2015-01-16 14:23 ` [PATCH v2 01/12] xen/arm: gic-v2: Change the device name in DT_DEVICE_START Julien Grall
2015-01-27 15:52   ` Stefano Stabellini
2015-01-16 14:23 ` [PATCH v2 02/12] xen/arm: vgic: Drop unecessary include asm/device.h Julien Grall
2015-01-27 15:53   ` Stefano Stabellini
2015-01-16 14:23 ` [PATCH v2 03/12] xen/dt: Extend dt_device_match to possibly store data Julien Grall
2015-01-27 15:57   ` Stefano Stabellini
2015-01-27 16:07     ` Julien Grall
2015-01-27 16:10       ` Stefano Stabellini
2015-01-27 16:35         ` Julien Grall
2015-01-27 16:46           ` Stefano Stabellini
2015-01-27 16:49             ` Julien Grall
2015-01-16 14:23 ` [PATCH v2 04/12] xen/arm: device: Rename device_type into device_match Julien Grall
2015-01-27 16:05   ` Stefano Stabellini
2015-01-27 16:09     ` Julien Grall
2015-01-27 16:13       ` Stefano Stabellini
2015-01-27 22:26         ` Julien Grall
2015-01-16 14:24 ` [PATCH v2 05/12] xen/iommu: arm: Remove temporary the SMMU driver Julien Grall
2015-01-27 16:05   ` Stefano Stabellini
2015-01-16 14:24 ` [PATCH v2 06/12] xen/arm: Introduce a generic way to describe device Julien Grall
2015-01-16 14:59   ` Jan Beulich
2015-01-16 15:01     ` Julien Grall
2015-01-27 16:13   ` Stefano Stabellini
2015-01-16 14:24 ` [PATCH v2 07/12] xen/iommu: Consolidate device assignment ops into a single set Julien Grall
2015-01-16 15:03   ` Jan Beulich
2015-01-27 16:16   ` Stefano Stabellini
2015-01-16 14:24 ` [PATCH v2 08/12] xen/arm: Describe device supported by a driver with dt_match_node Julien Grall
2015-01-27 16:28   ` Stefano Stabellini
2015-01-16 14:24 ` [PATCH v2 09/12] xen/iommu: arm: Import the SMMU driver from Linux Julien Grall
2015-01-27 16:28   ` Stefano Stabellini
2015-01-27 16:51     ` Julien Grall
2015-01-16 14:24 ` [PATCH v2 10/12] xen/iommu: smmu: Check for duplicate stream IDs when registering master devices Julien Grall
2015-01-27 16:30   ` Stefano Stabellini
2015-01-27 16:52     ` Julien Grall
2015-01-27 17:02       ` Stefano Stabellini
2015-01-27 17:33         ` Julien Grall
2015-01-27 17:36           ` Stefano Stabellini
2015-01-27 17:44           ` Ian Campbell
2015-01-27 17:51             ` Julien Grall
2015-01-27 20:54               ` Andreas Herrmann [this message]
2015-01-28 10:38               ` Ian Campbell
2015-01-28 11:39                 ` Julien Grall
2015-01-16 14:24 ` [PATCH v2 11/12] xen/iommu: smmu: Introduce automatic stream-id-masking Julien Grall
2015-01-16 14:24 ` [PATCH v2 12/12] xen/iommu: smmu: Add Xen specific code to be able to use the driver Julien Grall
2015-01-27 16:46   ` Stefano Stabellini
2015-01-27 17:05     ` Julien Grall
2015-01-27 17:34       ` Stefano Stabellini
2015-01-28 10:31         ` Ian Campbell
2015-01-28 11:49           ` Julien Grall
2015-01-28 12:13             ` Ian Campbell
2015-01-28 12:15             ` Stefano Stabellini

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=20150127205429.GA24135@alberich \
    --to=herrmann.der.user@googlemail.com \
    --cc=Ian.Campbell@citrix.com \
    --cc=andreas.herrmann@calxeda.com \
    --cc=julien.grall@linaro.org \
    --cc=stefano.stabellini@citrix.com \
    --cc=stefano.stabellini@eu.citrix.com \
    --cc=tim@xen.org \
    --cc=xen-devel@lists.xenproject.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.