[PATCH] cxgb4: use pgprot_writecombine() on powerpc
Nishanth Aravamudan
nacc at us.ibm.com
Tue Mar 15 07:36:11 EST 2011
Commit fe3cc0d99de6a9bf99b6c279a8afb5833888c1f7 ("powerpc: Add
pgprot_writecombine") in benh's tree exposes the pgprot_writecombine()
API to drivers on powerpc. cxgb4 has an open-coded version of the same,
so use the common API now that it's available.
Signed-off-by: Nishanth Aravamudan <nacc at us.ibm.com>
Cc: Steve Wise <swise at opengridcomputing.com>
Cc: Anton Blanchard <anton at samba.org>
---
Given that this depends on a patch in Ben's tree, should this go in via
the powerpc tree? Presuming Steve acks it, of course.
drivers/infiniband/hw/cxgb4/t4.h | 5 +----
1 files changed, 1 insertions(+), 4 deletions(-)
diff --git a/drivers/infiniband/hw/cxgb4/t4.h b/drivers/infiniband/hw/cxgb4/t4.h
index 7000442..2fce083 100644
--- a/drivers/infiniband/hw/cxgb4/t4.h
+++ b/drivers/infiniband/hw/cxgb4/t4.h
@@ -269,11 +269,8 @@ struct t4_swsqe {
static inline pgprot_t t4_pgprot_wc(pgprot_t prot)
{
-#if defined(__i386__) || defined(__x86_64__)
+#if defined(__i386__) || defined(__x86_64__) || defined(CONFIG_PPC64)
return pgprot_writecombine(prot);
-#elif defined(CONFIG_PPC64)
- return __pgprot((pgprot_val(prot) | _PAGE_NO_CACHE) &
- ~(pgprot_t)_PAGE_GUARDED);
#else
return pgprot_noncached(prot);
#endif
--
1.7.1
More information about the Linuxppc-dev
mailing list