]> Pileus Git - ~andy/linux/commit
powerpc/scom: Improve debugfs interface
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>
Mon, 4 Nov 2013 02:20:35 +0000 (13:20 +1100)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Wed, 6 Nov 2013 03:13:50 +0000 (14:13 +1100)
commitcda13552d5055a87dd39334dabf47249b01fc5aa
tree411f67ed12f3dae298eec8d086804bad38441277
parentd7a88c7eb46acb486922822eec3224c0bcab29dc
powerpc/scom: Improve debugfs interface

The current debugfs interface to scom is essentially unused
and racy. It uses two different files "address" and "data"
to perform accesses which is at best impractical for anything
but manual use by a developer.

This replaces it with an "access" file which represent the entire
scom address space which can be lseek/read/writen too.

This file only supports accesses that are 8 bytes aligned and
multiple of 8 bytes in size. The offset is logically the SCOM
address multiplied by 8.

Since nothing in userspace exploits that file at the moment, the ABI
change is a no-brainer.

Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
arch/powerpc/sysdev/scom.c