ia64/xen-unstable

changeset 11977:bd643d9db838

[LINUX] PV-on-HVM: Remove the attr parameter from device attribute
show methods on kernels prior to 2.6.13. The parameter was not present
before that.

Signed-off-by: Ian Campbell <ian.campbell@xensource.com>
Signed-off-by: K. Y. Srinivasan <ksrinivasan@novell.com>
Signed-off-by: Tsunehisa Doi <Doi.Tsunehisa@jp.fujitsu.com>
author Ian Campbell <ian.campbell@xensource.com>
date Wed Oct 25 13:58:30 2006 +0100 (2006-10-25)
parents 47cc7392741a
children 40107f658bd9
files linux-2.6-xen-sparse/drivers/xen/xenbus/xenbus_probe.c
line diff
     1.1 --- a/linux-2.6-xen-sparse/drivers/xen/xenbus/xenbus_probe.c	Wed Oct 25 13:58:30 2006 +0100
     1.2 +++ b/linux-2.6-xen-sparse/drivers/xen/xenbus/xenbus_probe.c	Wed Oct 25 13:58:30 2006 +0100
     1.3 @@ -453,14 +453,20 @@ char *kasprintf(const char *fmt, ...)
     1.4  }
     1.5  
     1.6  static ssize_t xendev_show_nodename(struct device *dev,
     1.7 -				    struct device_attribute *attr, char *buf)
     1.8 +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,13)
     1.9 +				    struct device_attribute *attr,
    1.10 +#endif
    1.11 +				    char *buf)
    1.12  {
    1.13  	return sprintf(buf, "%s\n", to_xenbus_device(dev)->nodename);
    1.14  }
    1.15  DEVICE_ATTR(nodename, S_IRUSR | S_IRGRP | S_IROTH, xendev_show_nodename, NULL);
    1.16  
    1.17  static ssize_t xendev_show_devtype(struct device *dev,
    1.18 -				   struct device_attribute *attr, char *buf)
    1.19 +#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,13)
    1.20 +				   struct device_attribute *attr,
    1.21 +#endif
    1.22 +				   char *buf)
    1.23  {
    1.24  	return sprintf(buf, "%s\n", to_xenbus_device(dev)->devicetype);
    1.25  }