Message ID | 1299588365-2749-3-git-send-email-dacohen@gmail.com (mailing list archive) |
---|---|
State | Not Applicable, archived |
Headers |
Return-path: <mchehab@pedra> Envelope-to: mchehab@pedra Delivery-date: Tue, 08 Mar 2011 09:47:14 -0300 Received: from mchehab by pedra with local (Exim 4.72) (envelope-from <mchehab@pedra>) id 1PwwJl-00064j-O8 for mchehab@pedra; Tue, 08 Mar 2011 09:47:14 -0300 Received: from casper.infradead.org [85.118.1.10] by pedra with IMAP (fetchmail-6.3.17) for <mchehab@localhost> (single-drop); Tue, 08 Mar 2011 09:47:13 -0300 (BRT) Received: from vger.kernel.org ([209.132.180.67]) by casper.infradead.org with esmtp (Exim 4.72 #1 (Red Hat Linux)) id 1PwwJ1-0001Uu-Ej; Tue, 08 Mar 2011 12:46:27 +0000 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754081Ab1CHMqV (ORCPT <rfc822; kmpark@infradead.org> + 1 other); Tue, 8 Mar 2011 07:46:21 -0500 Received: from mail-ey0-f174.google.com ([209.85.215.174]:47005 "EHLO mail-ey0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753589Ab1CHMqT (ORCPT <rfc822; linux-media@vger.kernel.org>); Tue, 8 Mar 2011 07:46:19 -0500 Received: by eyx24 with SMTP id 24so1950557eyx.19 for <multiple recipients>; Tue, 08 Mar 2011 04:46:18 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references; bh=fNAVzewxzl8CUadkSgxlhdjuZMMLpPXSLv2oEJSFpdA=; b=ARNXjQ1dEmJ9pWCqHSN6aahq4eBnTQfb5t1B0taV6FxHCY2svXIbh107S/34P5pdhI fX23+7BsbljtlYJa3/w3KnyL47j+rmZjrQusL9c15b4nIhA95wyQykUcwgnlx+SnBUHY aJmEMXw6Ne1fRy5ZeMmXarMr3AWEVajUW3GV4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references; b=bLl6dj/ozbvBIC2sP4/gw9BaM34SaKpOVQD8PzRm1M23NFXmPkKNlvivCwqBICAnCC iA+93cxi61MKFQlejF7hPRWNRRbOBGwiIx4P2P2QvTMs9/t53bYQF/3dwEAUzh6gL+sm oJE36ds3fqGJREPdu6/5JCrW5pzkTBmPI1msk= Received: by 10.213.112.196 with SMTP id x4mr866037ebp.21.1299588378324; Tue, 08 Mar 2011 04:46:18 -0800 (PST) Received: from localhost.localdomain (a91-152-72-10.elisa-laajakaista.fi [91.152.72.10]) by mx.google.com with ESMTPS id x54sm609369eeh.11.2011.03.08.04.46.16 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 08 Mar 2011 04:46:17 -0800 (PST) From: David Cohen <dacohen@gmail.com> To: Hiroshi.DOYU@nokia.com Cc: linux-omap@vger.kernel.org, fernando.lugo@ti.com, linux-media@vger.kernel.org, laurent.pinchart@ideasonboard.com, sakari.ailus@maxwell.research.nokia.com, David Cohen <dacohen@gmail.com> Subject: [PATCH 2/3] omap3: change ISP's IOMMU da_start address Date: Tue, 8 Mar 2011 14:46:04 +0200 Message-Id: <1299588365-2749-3-git-send-email-dacohen@gmail.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1299588365-2749-1-git-send-email-dacohen@gmail.com> References: <1299588365-2749-1-git-send-email-dacohen@gmail.com> Precedence: bulk List-ID: <linux-media.vger.kernel.org> X-Mailing-List: linux-media@vger.kernel.org Sender: <mchehab@pedra> |
Commit Message
David Cohen
March 8, 2011, 12:46 p.m. UTC
ISP doesn't consider 0x0 as a valid address, so it should explicitly
exclude first page from allowed 'da' range.
Signed-off-by: David Cohen <dacohen@gmail.com>
---
arch/arm/mach-omap2/omap-iommu.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
Comments
David Cohen wrote: > ISP doesn't consider 0x0 as a valid address, so it should explicitly > exclude first page from allowed 'da' range. > > Signed-off-by: David Cohen <dacohen@gmail.com> > --- > arch/arm/mach-omap2/omap-iommu.c | 2 +- > 1 files changed, 1 insertions(+), 1 deletions(-) > > diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c > index 3fc5dc7..3bea489 100644 > --- a/arch/arm/mach-omap2/omap-iommu.c > +++ b/arch/arm/mach-omap2/omap-iommu.c > @@ -33,7 +33,7 @@ static struct iommu_device omap3_devices[] = { > .name = "isp", > .nr_tlb_entries = 8, > .clk_name = "cam_ick", > - .da_start = 0x0, > + .da_start = 0x1000, The NULL address is still valid for the MMU. Can the IOVMF_DA_ANON mapping be specified by the API to be always non-NULL? This way it would be possible to combine IOVMF_DA_FIXED and IOVMF_DA_ANON mappings in the same IOMMU while still being able to rely that IOVMF_DA_ANON mappings would always be non-NULL. Regards,
Hi Sakari, On Tue, Mar 8, 2011 at 4:06 PM, Sakari Ailus <sakari.ailus@maxwell.research.nokia.com> wrote: > David Cohen wrote: >> ISP doesn't consider 0x0 as a valid address, so it should explicitly >> exclude first page from allowed 'da' range. >> >> Signed-off-by: David Cohen <dacohen@gmail.com> >> --- >> arch/arm/mach-omap2/omap-iommu.c | 2 +- >> 1 files changed, 1 insertions(+), 1 deletions(-) >> >> diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c >> index 3fc5dc7..3bea489 100644 >> --- a/arch/arm/mach-omap2/omap-iommu.c >> +++ b/arch/arm/mach-omap2/omap-iommu.c >> @@ -33,7 +33,7 @@ static struct iommu_device omap3_devices[] = { >> .name = "isp", >> .nr_tlb_entries = 8, >> .clk_name = "cam_ick", >> - .da_start = 0x0, >> + .da_start = 0x1000, > > The NULL address is still valid for the MMU. Can the IOVMF_DA_ANON > mapping be specified by the API to be always non-NULL? The patch 1/3 does that :) > > This way it would be possible to combine IOVMF_DA_FIXED and > IOVMF_DA_ANON mappings in the same IOMMU while still being able to rely > that IOVMF_DA_ANON mappings would always be non-NULL. Indeed the IOMMU driver supports it. The flag is set by iovm area and each IOMMU instance supports a mix of mappings with fixed da or not. By changing the OMAP3 "isp" IOMMU pdata's da_start to 0x1000, we're explicitly saying that iovm areas with fixed 'da' or not will never map first page to OMAP3 ISP driver, what is the behavior it expects. Without this patch, thanks to patch 1/3 the IOMMU driver will not map address 0x0 to OMAP3 ISP anyway. But then ISP will be passing wrong information that it would be fine to map first page. :) Kind regards, David Cohen > > Regards, > > -- > Sakari Ailus > sakari.ailus@maxwell.research.nokia.com > -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c index 3fc5dc7..3bea489 100644 --- a/arch/arm/mach-omap2/omap-iommu.c +++ b/arch/arm/mach-omap2/omap-iommu.c @@ -33,7 +33,7 @@ static struct iommu_device omap3_devices[] = { .name = "isp", .nr_tlb_entries = 8, .clk_name = "cam_ick", - .da_start = 0x0, + .da_start = 0x1000, .da_end = 0xFFFFF000, }, },