Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 1 | /* |
| 2 | * pSeries_reconfig.c - support for dynamic reconfiguration (including PCI |
| 3 | * Hotplug and Dynamic Logical Partitioning on RPA platforms). |
| 4 | * |
| 5 | * Copyright (C) 2005 Nathan Lynch |
| 6 | * Copyright (C) 2005 IBM Corporation |
| 7 | * |
| 8 | * |
| 9 | * This program is free software; you can redistribute it and/or |
| 10 | * modify it under the terms of the GNU General Public License version |
| 11 | * 2 as published by the Free Software Foundation. |
| 12 | */ |
| 13 | |
| 14 | #include <linux/kernel.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 15 | #include <linux/notifier.h> |
| 16 | #include <linux/proc_fs.h> |
Tejun Heo | 5a0e3ad | 2010-03-24 17:04:11 +0900 | [diff] [blame] | 17 | #include <linux/slab.h> |
Nathan Fontenot | 1cf3d8b | 2012-10-02 16:57:57 +0000 | [diff] [blame] | 18 | #include <linux/of.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 19 | |
| 20 | #include <asm/prom.h> |
Benjamin Herrenschmidt | e822250 | 2006-03-28 23:15:54 +1100 | [diff] [blame] | 21 | #include <asm/machdep.h> |
Linus Torvalds | 7c0f6ba | 2016-12-24 11:46:01 -0800 | [diff] [blame] | 22 | #include <linux/uaccess.h> |
Brian King | 46db2f8 | 2009-08-28 12:06:29 +0000 | [diff] [blame] | 23 | #include <asm/mmu.h> |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 24 | |
Andy Shevchenko | 948ad1a | 2015-10-01 12:46:06 +0300 | [diff] [blame] | 25 | #include "of_helpers.h" |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 26 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 27 | static int pSeries_reconfig_add_node(const char *path, struct property *proplist) |
| 28 | { |
| 29 | struct device_node *np; |
| 30 | int err = -ENOMEM; |
| 31 | |
Pekka Enberg | 874ca6c | 2005-09-06 15:18:32 -0700 | [diff] [blame] | 32 | np = kzalloc(sizeof(*np), GFP_KERNEL); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 33 | if (!np) |
| 34 | goto out_err; |
| 35 | |
Julia Lawall | 7405217 | 2010-05-14 09:30:13 +0000 | [diff] [blame] | 36 | np->full_name = kstrdup(path, GFP_KERNEL); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 37 | if (!np->full_name) |
| 38 | goto out_err; |
| 39 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 40 | np->properties = proplist; |
Michael Ellerman | d3b814b | 2007-06-19 16:07:58 +1000 | [diff] [blame] | 41 | of_node_set_flag(np, OF_DYNAMIC); |
Tyrel Datwyler | 97a9a71 | 2014-07-10 14:50:57 -0400 | [diff] [blame] | 42 | of_node_init(np); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 43 | |
Andy Shevchenko | 948ad1a | 2015-10-01 12:46:06 +0300 | [diff] [blame] | 44 | np->parent = pseries_of_derive_parent(path); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 45 | if (IS_ERR(np->parent)) { |
| 46 | err = PTR_ERR(np->parent); |
| 47 | goto out_err; |
| 48 | } |
| 49 | |
Nathan Fontenot | 1cf3d8b | 2012-10-02 16:57:57 +0000 | [diff] [blame] | 50 | err = of_attach_node(np); |
Akinobu Mita | 3aef19f | 2011-06-21 03:35:55 +0000 | [diff] [blame] | 51 | if (err) { |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 52 | printk(KERN_ERR "Failed to add device node %s\n", path); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 53 | goto out_err; |
| 54 | } |
| 55 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 56 | of_node_put(np->parent); |
| 57 | |
| 58 | return 0; |
| 59 | |
| 60 | out_err: |
| 61 | if (np) { |
| 62 | of_node_put(np->parent); |
| 63 | kfree(np->full_name); |
| 64 | kfree(np); |
| 65 | } |
| 66 | return err; |
| 67 | } |
| 68 | |
| 69 | static int pSeries_reconfig_remove_node(struct device_node *np) |
| 70 | { |
| 71 | struct device_node *parent, *child; |
| 72 | |
| 73 | parent = of_get_parent(np); |
| 74 | if (!parent) |
| 75 | return -EINVAL; |
| 76 | |
| 77 | if ((child = of_get_next_child(np, NULL))) { |
| 78 | of_node_put(child); |
Julia Lawall | 842decb | 2008-02-04 23:34:58 -0800 | [diff] [blame] | 79 | of_node_put(parent); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 80 | return -EBUSY; |
| 81 | } |
| 82 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 83 | of_detach_node(np); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 84 | of_node_put(parent); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 85 | return 0; |
| 86 | } |
| 87 | |
| 88 | /* |
Benjamin Herrenschmidt | 188917e | 2009-09-24 19:29:13 +0000 | [diff] [blame] | 89 | * /proc/powerpc/ofdt - yucky binary interface for adding and removing |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 90 | * OF device nodes. Should be deprecated as soon as we get an |
| 91 | * in-kernel wrapper for the RTAS ibm,configure-connector call. |
| 92 | */ |
| 93 | |
| 94 | static void release_prop_list(const struct property *prop) |
| 95 | { |
| 96 | struct property *next; |
| 97 | for (; prop; prop = next) { |
| 98 | next = prop->next; |
| 99 | kfree(prop->name); |
| 100 | kfree(prop->value); |
| 101 | kfree(prop); |
| 102 | } |
| 103 | |
| 104 | } |
| 105 | |
| 106 | /** |
| 107 | * parse_next_property - process the next property from raw input buffer |
| 108 | * @buf: input buffer, must be nul-terminated |
| 109 | * @end: end of the input buffer + 1, for validation |
| 110 | * @name: return value; set to property name in buf |
| 111 | * @length: return value; set to length of value |
| 112 | * @value: return value; set to the property value in buf |
| 113 | * |
| 114 | * Note that the caller must make copies of the name and value returned, |
| 115 | * this function does no allocation or copying of the data. Return value |
| 116 | * is set to the next name in buf, or NULL on error. |
| 117 | */ |
| 118 | static char * parse_next_property(char *buf, char *end, char **name, int *length, |
| 119 | unsigned char **value) |
| 120 | { |
| 121 | char *tmp; |
| 122 | |
| 123 | *name = buf; |
| 124 | |
| 125 | tmp = strchr(buf, ' '); |
| 126 | if (!tmp) { |
| 127 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 128 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 129 | return NULL; |
| 130 | } |
| 131 | *tmp = '\0'; |
| 132 | |
| 133 | if (++tmp >= end) { |
| 134 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 135 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 136 | return NULL; |
| 137 | } |
| 138 | |
| 139 | /* now we're on the length */ |
| 140 | *length = -1; |
| 141 | *length = simple_strtoul(tmp, &tmp, 10); |
| 142 | if (*length == -1) { |
| 143 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 144 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 145 | return NULL; |
| 146 | } |
| 147 | if (*tmp != ' ' || ++tmp >= end) { |
| 148 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 149 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 150 | return NULL; |
| 151 | } |
| 152 | |
| 153 | /* now we're on the value */ |
| 154 | *value = tmp; |
| 155 | tmp += *length; |
| 156 | if (tmp > end) { |
| 157 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 158 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 159 | return NULL; |
| 160 | } |
| 161 | else if (tmp < end && *tmp != ' ' && *tmp != '\0') { |
| 162 | printk(KERN_ERR "property parse failed in %s at line %d\n", |
Harvey Harrison | e48b1b4 | 2008-03-29 08:21:07 +1100 | [diff] [blame] | 163 | __func__, __LINE__); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 164 | return NULL; |
| 165 | } |
| 166 | tmp++; |
| 167 | |
| 168 | /* and now we should be on the next name, or the end */ |
| 169 | return tmp; |
| 170 | } |
| 171 | |
| 172 | static struct property *new_property(const char *name, const int length, |
| 173 | const unsigned char *value, struct property *last) |
| 174 | { |
Yan Burman | f848535 | 2006-12-02 13:26:57 +0200 | [diff] [blame] | 175 | struct property *new = kzalloc(sizeof(*new), GFP_KERNEL); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 176 | |
| 177 | if (!new) |
| 178 | return NULL; |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 179 | |
Grant Likely | c22618a | 2012-11-14 22:37:12 +0000 | [diff] [blame] | 180 | if (!(new->name = kstrdup(name, GFP_KERNEL))) |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 181 | goto cleanup; |
| 182 | if (!(new->value = kmalloc(length + 1, GFP_KERNEL))) |
| 183 | goto cleanup; |
| 184 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 185 | memcpy(new->value, value, length); |
| 186 | *(((char *)new->value) + length) = 0; |
| 187 | new->length = length; |
| 188 | new->next = last; |
| 189 | return new; |
| 190 | |
| 191 | cleanup: |
Jesper Juhl | b2325fe | 2005-11-07 01:01:35 -0800 | [diff] [blame] | 192 | kfree(new->name); |
| 193 | kfree(new->value); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 194 | kfree(new); |
| 195 | return NULL; |
| 196 | } |
| 197 | |
| 198 | static int do_add_node(char *buf, size_t bufsize) |
| 199 | { |
| 200 | char *path, *end, *name; |
| 201 | struct device_node *np; |
| 202 | struct property *prop = NULL; |
| 203 | unsigned char* value; |
| 204 | int length, rv = 0; |
| 205 | |
| 206 | end = buf + bufsize; |
| 207 | path = buf; |
| 208 | buf = strchr(buf, ' '); |
| 209 | if (!buf) |
| 210 | return -EINVAL; |
| 211 | *buf = '\0'; |
| 212 | buf++; |
| 213 | |
| 214 | if ((np = of_find_node_by_path(path))) { |
| 215 | of_node_put(np); |
| 216 | return -EINVAL; |
| 217 | } |
| 218 | |
| 219 | /* rv = build_prop_list(tmp, bufsize - (tmp - buf), &proplist); */ |
| 220 | while (buf < end && |
| 221 | (buf = parse_next_property(buf, end, &name, &length, &value))) { |
| 222 | struct property *last = prop; |
| 223 | |
| 224 | prop = new_property(name, length, value, last); |
| 225 | if (!prop) { |
| 226 | rv = -ENOMEM; |
| 227 | prop = last; |
| 228 | goto out; |
| 229 | } |
| 230 | } |
| 231 | if (!buf) { |
| 232 | rv = -EINVAL; |
| 233 | goto out; |
| 234 | } |
| 235 | |
| 236 | rv = pSeries_reconfig_add_node(path, prop); |
| 237 | |
| 238 | out: |
| 239 | if (rv) |
| 240 | release_prop_list(prop); |
| 241 | return rv; |
| 242 | } |
| 243 | |
| 244 | static int do_remove_node(char *buf) |
| 245 | { |
| 246 | struct device_node *node; |
| 247 | int rv = -ENODEV; |
| 248 | |
| 249 | if ((node = of_find_node_by_path(buf))) |
| 250 | rv = pSeries_reconfig_remove_node(node); |
| 251 | |
| 252 | of_node_put(node); |
| 253 | return rv; |
| 254 | } |
| 255 | |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 256 | static char *parse_node(char *buf, size_t bufsize, struct device_node **npp) |
| 257 | { |
| 258 | char *handle_str; |
| 259 | phandle handle; |
| 260 | *npp = NULL; |
| 261 | |
| 262 | handle_str = buf; |
| 263 | |
| 264 | buf = strchr(buf, ' '); |
| 265 | if (!buf) |
| 266 | return NULL; |
| 267 | *buf = '\0'; |
| 268 | buf++; |
| 269 | |
Nathan Fontenot | 4b6e805 | 2008-07-03 13:19:24 +1000 | [diff] [blame] | 270 | handle = simple_strtoul(handle_str, NULL, 0); |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 271 | |
| 272 | *npp = of_find_node_by_phandle(handle); |
| 273 | return buf; |
| 274 | } |
| 275 | |
| 276 | static int do_add_property(char *buf, size_t bufsize) |
| 277 | { |
| 278 | struct property *prop = NULL; |
| 279 | struct device_node *np; |
| 280 | unsigned char *value; |
| 281 | char *name, *end; |
| 282 | int length; |
| 283 | end = buf + bufsize; |
| 284 | buf = parse_node(buf, bufsize, &np); |
| 285 | |
| 286 | if (!np) |
| 287 | return -ENODEV; |
| 288 | |
| 289 | if (parse_next_property(buf, end, &name, &length, &value) == NULL) |
| 290 | return -EINVAL; |
| 291 | |
| 292 | prop = new_property(name, length, value, NULL); |
| 293 | if (!prop) |
| 294 | return -ENOMEM; |
| 295 | |
Nathan Fontenot | 79d1c71 | 2012-10-02 16:58:46 +0000 | [diff] [blame] | 296 | of_add_property(np, prop); |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 297 | |
| 298 | return 0; |
| 299 | } |
| 300 | |
| 301 | static int do_remove_property(char *buf, size_t bufsize) |
| 302 | { |
| 303 | struct device_node *np; |
| 304 | char *tmp; |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 305 | buf = parse_node(buf, bufsize, &np); |
| 306 | |
| 307 | if (!np) |
| 308 | return -ENODEV; |
| 309 | |
| 310 | tmp = strchr(buf,' '); |
| 311 | if (tmp) |
| 312 | *tmp = '\0'; |
| 313 | |
| 314 | if (strlen(buf) == 0) |
| 315 | return -EINVAL; |
| 316 | |
Suraj Jitindar Singh | 925e2d1 | 2016-04-28 15:34:55 +1000 | [diff] [blame] | 317 | return of_remove_property(np, of_find_property(np, buf, NULL)); |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 318 | } |
| 319 | |
| 320 | static int do_update_property(char *buf, size_t bufsize) |
| 321 | { |
| 322 | struct device_node *np; |
| 323 | unsigned char *value; |
Nathan Fontenot | 3c3f67e | 2008-07-03 13:22:39 +1000 | [diff] [blame] | 324 | char *name, *end, *next_prop; |
Nathan Fontenot | 1cf3d8b | 2012-10-02 16:57:57 +0000 | [diff] [blame] | 325 | int length; |
Dong Aisheng | 475d009 | 2012-07-11 15:16:37 +1000 | [diff] [blame] | 326 | struct property *newprop; |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 327 | buf = parse_node(buf, bufsize, &np); |
| 328 | end = buf + bufsize; |
| 329 | |
| 330 | if (!np) |
| 331 | return -ENODEV; |
| 332 | |
Nathan Fontenot | 3c3f67e | 2008-07-03 13:22:39 +1000 | [diff] [blame] | 333 | next_prop = parse_next_property(buf, end, &name, &length, &value); |
| 334 | if (!next_prop) |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 335 | return -EINVAL; |
| 336 | |
Dong Aisheng | 475d009 | 2012-07-11 15:16:37 +1000 | [diff] [blame] | 337 | if (!strlen(name)) |
| 338 | return -ENODEV; |
| 339 | |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 340 | newprop = new_property(name, length, value, NULL); |
| 341 | if (!newprop) |
| 342 | return -ENOMEM; |
| 343 | |
Brian King | 46db2f8 | 2009-08-28 12:06:29 +0000 | [diff] [blame] | 344 | if (!strcmp(name, "slb-size") || !strcmp(name, "ibm,slb-size")) |
| 345 | slb_set_size(*(int *)value); |
| 346 | |
Nathan Fontenot | 79d1c71 | 2012-10-02 16:58:46 +0000 | [diff] [blame] | 347 | return of_update_property(np, newprop); |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 348 | } |
| 349 | |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 350 | /** |
| 351 | * ofdt_write - perform operations on the Open Firmware device tree |
| 352 | * |
| 353 | * @file: not used |
| 354 | * @buf: command and arguments |
| 355 | * @count: size of the command buffer |
| 356 | * @off: not used |
| 357 | * |
| 358 | * Operations supported at this time are addition and removal of |
| 359 | * whole nodes along with their properties. Operations on individual |
| 360 | * properties are not implemented (yet). |
| 361 | */ |
| 362 | static ssize_t ofdt_write(struct file *file, const char __user *buf, size_t count, |
| 363 | loff_t *off) |
| 364 | { |
| 365 | int rv = 0; |
| 366 | char *kbuf; |
| 367 | char *tmp; |
| 368 | |
| 369 | if (!(kbuf = kmalloc(count + 1, GFP_KERNEL))) { |
| 370 | rv = -ENOMEM; |
| 371 | goto out; |
| 372 | } |
| 373 | if (copy_from_user(kbuf, buf, count)) { |
| 374 | rv = -EFAULT; |
| 375 | goto out; |
| 376 | } |
| 377 | |
| 378 | kbuf[count] = '\0'; |
| 379 | |
| 380 | tmp = strchr(kbuf, ' '); |
| 381 | if (!tmp) { |
| 382 | rv = -EINVAL; |
| 383 | goto out; |
| 384 | } |
| 385 | *tmp = '\0'; |
| 386 | tmp++; |
| 387 | |
| 388 | if (!strcmp(kbuf, "add_node")) |
| 389 | rv = do_add_node(tmp, count - (tmp - kbuf)); |
| 390 | else if (!strcmp(kbuf, "remove_node")) |
| 391 | rv = do_remove_node(tmp); |
Dave C Boutcher | 610d915 | 2006-01-12 16:10:22 -0600 | [diff] [blame] | 392 | else if (!strcmp(kbuf, "add_property")) |
| 393 | rv = do_add_property(tmp, count - (tmp - kbuf)); |
| 394 | else if (!strcmp(kbuf, "remove_property")) |
| 395 | rv = do_remove_property(tmp, count - (tmp - kbuf)); |
| 396 | else if (!strcmp(kbuf, "update_property")) |
| 397 | rv = do_update_property(tmp, count - (tmp - kbuf)); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 398 | else |
| 399 | rv = -EINVAL; |
| 400 | out: |
| 401 | kfree(kbuf); |
| 402 | return rv ? rv : count; |
| 403 | } |
| 404 | |
Arjan van de Ven | 5dfe4c9 | 2007-02-12 00:55:31 -0800 | [diff] [blame] | 405 | static const struct file_operations ofdt_fops = { |
Arnd Bergmann | 6038f37 | 2010-08-15 18:52:59 +0200 | [diff] [blame] | 406 | .write = ofdt_write, |
| 407 | .llseek = noop_llseek, |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 408 | }; |
| 409 | |
Benjamin Herrenschmidt | 188917e | 2009-09-24 19:29:13 +0000 | [diff] [blame] | 410 | /* create /proc/powerpc/ofdt write-only by root */ |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 411 | static int proc_ppc64_create_ofdt(void) |
| 412 | { |
| 413 | struct proc_dir_entry *ent; |
| 414 | |
Benjamin Herrenschmidt | 188917e | 2009-09-24 19:29:13 +0000 | [diff] [blame] | 415 | ent = proc_create("powerpc/ofdt", S_IWUSR, NULL, &ofdt_fops); |
Denis V. Lunev | 6674713 | 2008-04-29 01:02:26 -0700 | [diff] [blame] | 416 | if (ent) |
David Howells | 271a15e | 2013-04-12 00:38:51 +0100 | [diff] [blame] | 417 | proc_set_size(ent, 0); |
Linus Torvalds | 1da177e | 2005-04-16 15:20:36 -0700 | [diff] [blame] | 418 | |
| 419 | return 0; |
| 420 | } |
Michael Ellerman | 8e83e90 | 2014-07-16 12:02:43 +1000 | [diff] [blame] | 421 | machine_device_initcall(pseries, proc_ppc64_create_ofdt); |