diff options
Diffstat (limited to 'drivers/s390/cio')
-rw-r--r-- | drivers/s390/cio/cmf.c | 3 | ||||
-rw-r--r-- | drivers/s390/cio/device.c | 20 | ||||
-rw-r--r-- | drivers/s390/cio/device_fsm.c | 2 |
3 files changed, 25 insertions, 0 deletions
diff --git a/drivers/s390/cio/cmf.c b/drivers/s390/cio/cmf.c index 8cc4f1a940dc..c05b069c2996 100644 --- a/drivers/s390/cio/cmf.c +++ b/drivers/s390/cio/cmf.c | |||
@@ -30,10 +30,13 @@ | |||
30 | #include <linux/list.h> | 30 | #include <linux/list.h> |
31 | #include <linux/module.h> | 31 | #include <linux/module.h> |
32 | #include <linux/moduleparam.h> | 32 | #include <linux/moduleparam.h> |
33 | #include <linux/slab.h> | ||
34 | #include <linux/timex.h> /* get_clock() */ | ||
33 | 35 | ||
34 | #include <asm/ccwdev.h> | 36 | #include <asm/ccwdev.h> |
35 | #include <asm/cio.h> | 37 | #include <asm/cio.h> |
36 | #include <asm/cmb.h> | 38 | #include <asm/cmb.h> |
39 | #include <asm/div64.h> | ||
37 | 40 | ||
38 | #include "cio.h" | 41 | #include "cio.h" |
39 | #include "css.h" | 42 | #include "css.h" |
diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 9adc11e8b8bc..811c9d150637 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c | |||
@@ -22,6 +22,7 @@ | |||
22 | 22 | ||
23 | #include <asm/ccwdev.h> | 23 | #include <asm/ccwdev.h> |
24 | #include <asm/cio.h> | 24 | #include <asm/cio.h> |
25 | #include <asm/param.h> /* HZ */ | ||
25 | 26 | ||
26 | #include "cio.h" | 27 | #include "cio.h" |
27 | #include "css.h" | 28 | #include "css.h" |
@@ -252,6 +253,23 @@ cutype_show (struct device *dev, struct device_attribute *attr, char *buf) | |||
252 | } | 253 | } |
253 | 254 | ||
254 | static ssize_t | 255 | static ssize_t |
256 | modalias_show (struct device *dev, struct device_attribute *attr, char *buf) | ||
257 | { | ||
258 | struct ccw_device *cdev = to_ccwdev(dev); | ||
259 | struct ccw_device_id *id = &(cdev->id); | ||
260 | int ret; | ||
261 | |||
262 | ret = sprintf(buf, "ccw:t%04Xm%02x", | ||
263 | id->cu_type, id->cu_model); | ||
264 | if (id->dev_type != 0) | ||
265 | ret += sprintf(buf + ret, "dt%04Xdm%02X\n", | ||
266 | id->dev_type, id->dev_model); | ||
267 | else | ||
268 | ret += sprintf(buf + ret, "dtdm\n"); | ||
269 | return ret; | ||
270 | } | ||
271 | |||
272 | static ssize_t | ||
255 | online_show (struct device *dev, struct device_attribute *attr, char *buf) | 273 | online_show (struct device *dev, struct device_attribute *attr, char *buf) |
256 | { | 274 | { |
257 | struct ccw_device *cdev = to_ccwdev(dev); | 275 | struct ccw_device *cdev = to_ccwdev(dev); |
@@ -448,6 +466,7 @@ static DEVICE_ATTR(chpids, 0444, chpids_show, NULL); | |||
448 | static DEVICE_ATTR(pimpampom, 0444, pimpampom_show, NULL); | 466 | static DEVICE_ATTR(pimpampom, 0444, pimpampom_show, NULL); |
449 | static DEVICE_ATTR(devtype, 0444, devtype_show, NULL); | 467 | static DEVICE_ATTR(devtype, 0444, devtype_show, NULL); |
450 | static DEVICE_ATTR(cutype, 0444, cutype_show, NULL); | 468 | static DEVICE_ATTR(cutype, 0444, cutype_show, NULL); |
469 | static DEVICE_ATTR(modalias, 0444, modalias_show, NULL); | ||
451 | static DEVICE_ATTR(online, 0644, online_show, online_store); | 470 | static DEVICE_ATTR(online, 0644, online_show, online_store); |
452 | extern struct device_attribute dev_attr_cmb_enable; | 471 | extern struct device_attribute dev_attr_cmb_enable; |
453 | static DEVICE_ATTR(availability, 0444, available_show, NULL); | 472 | static DEVICE_ATTR(availability, 0444, available_show, NULL); |
@@ -471,6 +490,7 @@ subchannel_add_files (struct device *dev) | |||
471 | static struct attribute * ccwdev_attrs[] = { | 490 | static struct attribute * ccwdev_attrs[] = { |
472 | &dev_attr_devtype.attr, | 491 | &dev_attr_devtype.attr, |
473 | &dev_attr_cutype.attr, | 492 | &dev_attr_cutype.attr, |
493 | &dev_attr_modalias.attr, | ||
474 | &dev_attr_online.attr, | 494 | &dev_attr_online.attr, |
475 | &dev_attr_cmb_enable.attr, | 495 | &dev_attr_cmb_enable.attr, |
476 | &dev_attr_availability.attr, | 496 | &dev_attr_availability.attr, |
diff --git a/drivers/s390/cio/device_fsm.c b/drivers/s390/cio/device_fsm.c index fbe4202a3f6f..c1c89f4fd4e3 100644 --- a/drivers/s390/cio/device_fsm.c +++ b/drivers/s390/cio/device_fsm.c | |||
@@ -11,6 +11,8 @@ | |||
11 | #include <linux/module.h> | 11 | #include <linux/module.h> |
12 | #include <linux/config.h> | 12 | #include <linux/config.h> |
13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
14 | #include <linux/jiffies.h> | ||
15 | #include <linux/string.h> | ||
14 | 16 | ||
15 | #include <asm/ccwdev.h> | 17 | #include <asm/ccwdev.h> |
16 | #include <asm/cio.h> | 18 | #include <asm/cio.h> |