summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Ellerman <mpe@ellerman.id.au>2014-10-28 12:13:32 +1100
committerMichael Ellerman <mpe@ellerman.id.au>2014-10-28 15:17:48 +1100
commitbf19edd290d5d2d53bba53f7f4cb2f7492997009 (patch)
treed285a4c2a99854da129dea7447994dd500330ef3
parent19d36c2152aaf093c97431b5b4d13d29305a63a3 (diff)
downloadop-kernel-dev-bf19edd290d5d2d53bba53f7f4cb2f7492997009.zip
op-kernel-dev-bf19edd290d5d2d53bba53f7f4cb2f7492997009.tar.gz
Revert "powerpc/powernv: Fix endian bug in LPC bus debugfs accessors"
This reverts commit bf7588a0859580a45c63cb082825d77c13eca357. Ben says although the code is not correct "[this] fix was completely wrong and does more damages than it fixes things." Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
-rw-r--r--arch/powerpc/platforms/powernv/opal-lpc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/arch/powerpc/platforms/powernv/opal-lpc.c b/arch/powerpc/platforms/powernv/opal-lpc.c
index dd2c285..ad4b31d 100644
--- a/arch/powerpc/platforms/powernv/opal-lpc.c
+++ b/arch/powerpc/platforms/powernv/opal-lpc.c
@@ -191,7 +191,6 @@ static ssize_t lpc_debug_read(struct file *filp, char __user *ubuf,
{
struct lpc_debugfs_entry *lpc = filp->private_data;
u32 data, pos, len, todo;
- __be32 bedata;
int rc;
if (!access_ok(VERIFY_WRITE, ubuf, count))
@@ -214,10 +213,9 @@ static ssize_t lpc_debug_read(struct file *filp, char __user *ubuf,
len = 2;
}
rc = opal_lpc_read(opal_lpc_chip_id, lpc->lpc_type, pos,
- &bedata, len);
+ &data, len);
if (rc)
return -ENXIO;
- data = be32_to_cpu(bedata);
switch(len) {
case 4:
rc = __put_user((u32)data, (u32 __user *)ubuf);
OpenPOWER on IntegriCloud