[patch] powerpc: implement optimised mutex fastpaths

2008-10-11 Thread Nick Piggin
Implement a more optimal mutex fastpath for powerpc, making use of acquire and release barrier semantics. This takes the mutex lock+unlock benchmark from 203 to 173 cycles on a G5. Signed-off-by: Nick Piggin <[EMAIL PROTECTED]> --- Index: linux-2.6/arch/powerpc/include/asm/mutex.h ===

[patch] mutex: optimise generic mutex implementations

2008-10-11 Thread Nick Piggin
Speed up generic mutex implementations. - atomic operations which both modify the variable and return something imply full smp memory barriers before and after the memory operations involved (failing atomic_cmpxchg, atomic_add_unless, etc don't imply a barrier because they don't modify the t

Re: performance: memcpy vs. __copy_tofrom_user

2008-10-11 Thread Benjamin Herrenschmidt
> Would the examples (page copy, page clear) be an okay place to do it? > These sections can't be preempted anyway (right?), and it's noted that > doing it with AltiVec is a tad faster than using MMU tricks or standard > copies? I think typically page copying and clearing -are- preemptible. I'm n

[PROBLEM] Soft lockup on Linux 2.6.27, 2 patches, Cell/PPC64

2008-10-11 Thread Aaron Tokhy
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hello, I recently built 2.6.27 with these patches on my PS3. http://www.kernel.org/pub/linux/kernel/people/geoff/cell/ps3-linux-patches/ps3-wip/ps3vram-driver.patch http://www.kernel.org/pub/linux/kernel/people/geoff/cell/ps3-linux-patches/ps3-wip/ps

Re: [RFC 0/6] Proposal for a Generic PWM Device API

2008-10-11 Thread Matt Sealey
Jon Loeliger wrote: On Fri, 2008-10-10 at 09:04 -0500, Bill Gatliff wrote: Jon Smirl wrote: What do the device tree deities have to say about PWM support? Dunno. What lists are they on? :) Perhaps [EMAIL PROTECTED] too. I thought this was what ePAPR was for. Why would it need all that

Re: [PATCH RFC] pata_platform: add 8 bit data io support

2008-10-11 Thread Wang Jian
Benjamin Herrenschmidt 写道: > On Sun, 2008-10-12 at 02:00 +0800, Wang Jian wrote: >> To avoid adding another rare used ata_port member, new bit is added to >> ata_port->flags. >> >> Originally, I hacked pata_platform to make it 8bit only to support 8bit >> data wired CF card. This patch is more gene

Re: performance: memcpy vs. __copy_tofrom_user

2008-10-11 Thread Matt Sealey
Benjamin Herrenschmidt wrote: On Thu, 2008-10-09 at 10:37 -0500, Matt Sealey wrote: Ahem, but nobody here wants AltiVec in the kernel do they? It depends. We do use altivec in the kernel for example for RAID accelerations. The reason where we require a -real-good- reason to do it is simply be

2.6.27 g5 config?

2008-10-11 Thread Kevin Diggs
Hi, I always have trouble getting an initial build to boot. Usually it is with keyboards and video console. Currently, I can't seem to find the root disk. With the attached config I get the early messages, a pair of "penguin" images. And then I think it says system restarting. Ha

Re: performance: memcpy vs. __copy_tofrom_user

2008-10-11 Thread Benjamin Herrenschmidt
On Wed, 2008-10-08 at 12:40 -0500, Scott Wood wrote: > > The performance difference most likely comes from the fact that copy > to/from user can assume that the memory is cacheable, while memcpy is > occasionally used on cache-inhibited memory -- so dcbz isn't used. We > may be better off hand

Re: performance: memcpy vs. __copy_tofrom_user

2008-10-11 Thread Benjamin Herrenschmidt
On Thu, 2008-10-09 at 10:37 -0500, Matt Sealey wrote: > > Ahem, but nobody here wants AltiVec in the kernel do they? It depends. We do use altivec in the kernel for example for RAID accelerations. The reason where we require a -real-good- reason to do it is simply because of the drawbacks. The c

Re: [PATCH RFC] pata_platform: add 8 bit data io support

2008-10-11 Thread Benjamin Herrenschmidt
On Sun, 2008-10-12 at 02:00 +0800, Wang Jian wrote: > To avoid adding another rare used ata_port member, new bit is added to > ata_port->flags. > > Originally, I hacked pata_platform to make it 8bit only to support 8bit > data wired CF card. This patch is more generic. > > With this patch, __pata

[PATCH RFC] pata_platform: add 8 bit data io support

2008-10-11 Thread Wang Jian
To avoid adding another rare used ata_port member, new bit is added to ata_port->flags. Originally, I hacked pata_platform to make it 8bit only to support 8bit data wired CF card. This patch is more generic. With this patch, __pata_platform_probe() interface is changed, and pata_of_platform is br

Re: [PATCH 1/3] powerpc: add driver for simple GPIO banks

2008-10-11 Thread David Gibson
On Fri, Oct 10, 2008 at 08:55:01PM +0400, Anton Vorontsov wrote: > The driver supports very simple GPIO controllers, that is, when a > controller provides just a 'data' register. Such controllers may be > found in various BCSRs (Board's FPGAs used to control board's > switches, LEDs, chip-selects,