linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: s-anna@ti.com (Suman Anna)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] omap: iommu: fix pte attributes for super section
Date: Wed, 4 May 2011 17:45:37 -0500	[thread overview]
Message-ID: <mailman.223.1305048323.1530.linux-arm-kernel@lists.infradead.org> (raw)

The PTE programming causes a 16MB entry to be interpreted
as a 4K entry because of the bitwise check, and therefore does
not set the attributes properly in the first-level descriptor
table. The bitwise check has been replaced appropriately.

Signed-off-by: Suman Anna <s-anna@ti.com>
---
 arch/arm/mach-omap2/iommu2.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/arch/arm/mach-omap2/iommu2.c b/arch/arm/mach-omap2/iommu2.c
index adb083e..c21fbe6 100644
--- a/arch/arm/mach-omap2/iommu2.c
+++ b/arch/arm/mach-omap2/iommu2.c
@@ -225,7 +225,8 @@ static u32 omap2_get_pte_attr(struct iotlb_entry *e)
        attr = e->mixed << 5;
        attr |= e->endian;
        attr |= e->elsz >> 3;
-       attr <<= ((e->pgsz & MMU_CAM_PGSZ_4K) ? 0 : 6);
+       attr <<= (((e->pgsz == MMU_CAM_PGSZ_4K) ||
+                       (e->pgsz == MMU_CAM_PGSZ_64K)) ? 0 : 6);

        return attr;
 }
--
1.7.0.4

             reply	other threads:[~2011-05-04 22:45 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-05-04 22:45 Suman Anna [this message]
  -- strict thread matches above, loose matches on Subject: below --
2011-05-10 17:25 [PATCH] omap: iommu: fix pte attributes for super section Anna, Suman
2011-05-16  7:11 ` Hiroshi DOYU
2011-06-28 19:46   ` Anna, Suman

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=mailman.223.1305048323.1530.linux-arm-kernel@lists.infradead.org \
    --to=s-anna@ti.com \
    --cc=linux-arm-kernel@lists.infradead.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 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).