lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 24 Apr 2012 10:59:48 +0200
From:	Hiroshi Doyu <hdoyu@...dia.com>
To:	"swarren@...dotorg.org" <swarren@...dotorg.org>
CC:	"linux-tegra@...r.kernel.org" <linux-tegra@...r.kernel.org>,
	"grant.likely@...retlab.ca" <grant.likely@...retlab.ca>,
	"rob.herring@...xeda.com" <rob.herring@...xeda.com>,
	"rob@...dley.net" <rob@...dley.net>,
	"joerg.roedel@....com" <joerg.roedel@....com>,
	"thierry.reding@...onic-design.de" <thierry.reding@...onic-design.de>,
	"devicetree-discuss@...ts.ozlabs.org" 
	<devicetree-discuss@...ts.ozlabs.org>,
	"linux-doc@...r.kernel.org" <linux-doc@...r.kernel.org>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/3] iommu/tegra: smmu: Add device tree support for SMMU

From: Stephen Warren <swarren@...dotorg.org>
Subject: Re: [PATCH 2/3] iommu/tegra: smmu: Add device tree support for SMMU
Date: Mon, 23 Apr 2012 20:27:28 +0200
Message-ID: <4F959F10.9010908@...dotorg.org>

> On 04/23/2012 05:58 AM, Hiroshi DOYU wrote:
> > Add device tree support for Tegra30 IOMMU(SMMU).
> 
> > diff --git a/drivers/iommu/tegra-smmu.c b/drivers/iommu/tegra-smmu.c
> 
> > +	err = of_parse_dma_window(dev->of_node, "dma-window", 0, NULL,
> > +				  &base, &size);
> 
> This patch also depends on "dt: Add general DMA window parser" that you
> sent earlier.
> 
> > +	asids = be32_to_cpup(of_get_property(dev->of_node, "asids", NULL));
> > +	if (!asids)
> > +		return -ENODEV;
> 
> What if of_get_property() fails?

Ok, need to be checked. I'll fix.

> BTW, does the # ASIDs vary? I wonder if it's worth representing it in
> the device tree or not. If this driver has a chance of working
> unmodified on some future chip just by updating this DT property without
> any code changes, then it seems reasonable to have it in DT.

Yes, ASID should be passed from DT.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ