diff options
Diffstat (limited to 'drivers/s390/s390_rdev.c')
-rw-r--r-- | drivers/s390/s390_rdev.c | 51 |
1 files changed, 0 insertions, 51 deletions
diff --git a/drivers/s390/s390_rdev.c b/drivers/s390/s390_rdev.c deleted file mode 100644 index 64371c05a3b3..000000000000 --- a/drivers/s390/s390_rdev.c +++ /dev/null | |||
@@ -1,51 +0,0 @@ | |||
1 | /* | ||
2 | * drivers/s390/s390_rdev.c | ||
3 | * s390 root device | ||
4 | * | ||
5 | * Copyright (C) 2002, 2005 IBM Deutschland Entwicklung GmbH, | ||
6 | * IBM Corporation | ||
7 | * Author(s): Cornelia Huck (cornelia.huck@de.ibm.com) | ||
8 | * Carsten Otte (cotte@de.ibm.com) | ||
9 | */ | ||
10 | |||
11 | #include <linux/slab.h> | ||
12 | #include <linux/err.h> | ||
13 | #include <linux/device.h> | ||
14 | #include <asm/s390_rdev.h> | ||
15 | |||
16 | static void | ||
17 | s390_root_dev_release(struct device *dev) | ||
18 | { | ||
19 | kfree(dev); | ||
20 | } | ||
21 | |||
22 | struct device * | ||
23 | s390_root_dev_register(const char *name) | ||
24 | { | ||
25 | struct device *dev; | ||
26 | int ret; | ||
27 | |||
28 | if (!strlen(name)) | ||
29 | return ERR_PTR(-EINVAL); | ||
30 | dev = kzalloc(sizeof(struct device), GFP_KERNEL); | ||
31 | if (!dev) | ||
32 | return ERR_PTR(-ENOMEM); | ||
33 | dev_set_name(dev, name); | ||
34 | dev->release = s390_root_dev_release; | ||
35 | ret = device_register(dev); | ||
36 | if (ret) { | ||
37 | kfree(dev); | ||
38 | return ERR_PTR(ret); | ||
39 | } | ||
40 | return dev; | ||
41 | } | ||
42 | |||
43 | void | ||
44 | s390_root_dev_unregister(struct device *dev) | ||
45 | { | ||
46 | if (dev) | ||
47 | device_unregister(dev); | ||
48 | } | ||
49 | |||
50 | EXPORT_SYMBOL(s390_root_dev_register); | ||
51 | EXPORT_SYMBOL(s390_root_dev_unregister); | ||