ia64 SGI-SN2: fix silent data corruption caused by XPC
commitc1646ad43e8273c4748ce2d4be2ec71f9329dbbd
authorDean Nelson <dcn@sgi.com>
Wed, 6 Sep 2006 17:25:46 +0000 (6 19:25 +0200)
committerAdrian Bunk <bunk@stusta.de>
Wed, 6 Sep 2006 17:25:46 +0000 (6 19:25 +0200)
tree9760f99e594cca5ce3e0e83aeed68f442732ff34
parenta3c94d77000442a64e0776174ad2a70e8aff1943
ia64 SGI-SN2: fix silent data corruption caused by XPC

Jack Steiner identified a problem where XPC can cause a silent
data corruption.  On module load, the placement may cause the
xpc_remote_copy_buffer to span two physical pages.  DMA transfers are
done to the start virtual address translated to physical.

This patch changes the buffer from a statically allocated buffer to a
kmalloc'd buffer.  Dean Nelson reviewed this before posting.  I have
tested it in the configuration that was showing the memory corruption
and verified it works.  I also added a BUG_ON statement to help catch
this if a similar situation is encountered.

Signed-off-by: Robin Holt <holt@sgi.com>
Signed-off-by: Dean Nelson <dcn@sgi.com>
Signed-off-by: Jack Steiner <steiner@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
arch/ia64/sn/kernel/xpc_channel.c
arch/ia64/sn/kernel/xpc_main.c
arch/ia64/sn/kernel/xpc_partition.c
include/asm-ia64/sn/xp.h
include/asm-ia64/sn/xpc.h