ia64/xen-unstable

changeset 10146:83c0449db67a

[IA64] work around ENOSYS vs EINVAL in ioremap

We should not panic the domain for an EINVAL return from the ioremap
hyerpcall. This was only meant for ENOSYS. Long term this is probably
not the best place for this kind of sanity checking.

Signed-off-by: Alex Williamson <alex.williamson@hp.com>
author awilliam@xenbuild.aw
date Tue May 23 17:05:27 2006 -0600 (2006-05-23)
parents 0dabd651b856
children 29d31af10e57
files linux-2.6-xen-sparse/include/asm-ia64/hypercall.h
line diff
     1.1 --- a/linux-2.6-xen-sparse/include/asm-ia64/hypercall.h	Tue May 23 15:10:27 2006 -0600
     1.2 +++ b/linux-2.6-xen-sparse/include/asm-ia64/hypercall.h	Tue May 23 17:05:27 2006 -0600
     1.3 @@ -431,10 +431,12 @@ HYPERVISOR_ioremap(unsigned long ioaddr,
     1.4  	unsigned long ret = ioaddr;
     1.5  	if (running_on_xen) {
     1.6  		ret = __HYPERVISOR_ioremap(ioaddr, size);
     1.7 -		if (unlikely(IS_ERR_VALUE(ret)))
     1.8 +		if (unlikely(ret == -ENOSYS))
     1.9  			panic("hypercall %s failed with %ld. "
    1.10  			      "Please check Xen and Linux config mismatch\n",
    1.11  			      __func__, -ret);
    1.12 +		else if (unlikely(IS_ERR_VALUE(ret)))
    1.13 +			ret = ioaddr;
    1.14  	}
    1.15  	return ret;
    1.16  }