aboutsummaryrefslogtreecommitdiff
path: root/arch/parisc/kernel/cache.c
diff options
context:
space:
mode:
authorKyle McMartin <kyle@parisc-linux.org>2006-06-16 18:20:00 -0400
committerKyle McMartin <kyle@hera.kernel.org>2006-06-27 23:28:42 +0000
commita9d2d386c42b816a81eb1d02dfb7b502ba8cea82 (patch)
tree0c01caa8a470713dc8a68db0ed584cfe3142392d /arch/parisc/kernel/cache.c
parente5a2e7fdb53028ce187c0ce0ae0d45ca7546fd5e (diff)
downloadlinux-a9d2d386c42b816a81eb1d02dfb7b502ba8cea82.tar.gz
[PARISC] Ensure Space ID hashing is turned off
Check PDC_CACHE to see if spaceid hashing is turned on, and fail to boot if that is the case. However, some old machines do not implement the PDC_CACHE_RET_SPID firmware call, so continue to boot if the call fails because of PDC_BAD_OPTION (but fail in all other error returns). Signed-off-by: Kyle McMartin <kyle@parisc-linux.org>
Diffstat (limited to 'arch/parisc/kernel/cache.c')
-rw-r--r--arch/parisc/kernel/cache.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/arch/parisc/kernel/cache.c b/arch/parisc/kernel/cache.c
index 851519cbad6..bc7c4a4e26a 100644
--- a/arch/parisc/kernel/cache.c
+++ b/arch/parisc/kernel/cache.c
@@ -236,7 +236,8 @@ parisc_cache_init(void)
void disable_sr_hashing(void)
{
- int srhash_type;
+ int srhash_type, retval;
+ unsigned long space_bits;
switch (boot_cpu_data.cpu_type) {
case pcx: /* We shouldn't get this far. setup.c should prevent it. */
@@ -262,6 +263,13 @@ void disable_sr_hashing(void)
}
disable_sr_hashing_asm(srhash_type);
+
+ retval = pdc_spaceid_bits(&space_bits);
+ /* If this procedure isn't implemented, don't panic. */
+ if (retval < 0 && retval != PDC_BAD_OPTION)
+ panic("pdc_spaceid_bits call failed.\n");
+ if (space_bits != 0)
+ panic("SpaceID hashing is still on!\n");
}
void flush_dcache_page(struct page *page)