[IA64-SGI] Fix sn_flush_device_kernel & spinlock initialization
commit6d6e420005f3753392b608a614eee8475bdc16f7
authorPrarit Bhargava <prarit@sgi.com>
Fri, 23 Dec 2005 18:33:25 +0000 (23 13:33 -0500)
committerTony Luck <tony.luck@intel.com>
Fri, 13 Jan 2006 22:13:08 +0000 (13 14:13 -0800)
treea59860fc15ce4e92c00015d068de4aba12a9b889
parentcfbb1426bd76c4ba6ec4491c8df2a5dd3d984750
[IA64-SGI] Fix sn_flush_device_kernel & spinlock initialization

This patch separates the sn_flush_device_list struct into kernel and
common (both kernel and PROM accessible) structures.  As it was, if the
size of a spinlock_t changed (due to additional CONFIG options, etc.) the
sal call which populated the sn_flush_device_list structs would erroneously
write data (and cause memory corruption and/or a panic).

This patch does the following:

1.  Removes sn_flush_device_list and adds sn_flush_device_common and
sn_flush_device_kernel.

2.  Adds a new SAL call to populate a sn_flush_device_common struct per
device, not per widget as previously done.

3.  Correctly initializes each device's sn_flush_device_kernel spinlock_t
struct (before it was only doing each widget's first device).

Signed-off-by: Prarit Bhargava <prarit@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
arch/ia64/sn/include/xtalk/hubdev.h
arch/ia64/sn/kernel/io_init.c
arch/ia64/sn/pci/pcibr/pcibr_dma.c
arch/ia64/sn/pci/pcibr/pcibr_provider.c
include/asm-ia64/sn/sn_sal.h