Loading arch/powerpc/kernel/prom.c +0 −24 Original line number Diff line number Diff line Loading @@ -1170,30 +1170,6 @@ int machine_is_compatible(const char *compat) } EXPORT_SYMBOL(machine_is_compatible); /** * Construct and return a list of the device_nodes with a given type * and compatible property. */ struct device_node *find_compatible_devices(const char *type, const char *compat) { struct device_node *head, **prevp, *np; prevp = &head; for (np = allnodes; np != 0; np = np->allnext) { if (type != NULL && !(np->type != 0 && strcasecmp(np->type, type) == 0)) continue; if (of_device_is_compatible(np, compat)) { *prevp = np; prevp = &np->next; } } *prevp = NULL; return head; } EXPORT_SYMBOL(find_compatible_devices); /** * Find the device_node with a given full_name. */ Loading arch/powerpc/platforms/chrp/time.c +9 −4 Original line number Diff line number Diff line Loading @@ -39,11 +39,16 @@ long __init chrp_time_init(void) struct resource r; int base; rtcs = find_compatible_devices("rtc", "pnpPNP,b00"); rtcs = of_find_compatible_node(NULL, "rtc", "pnpPNP,b00"); if (rtcs == NULL) rtcs = find_compatible_devices("rtc", "ds1385-rtc"); if (rtcs == NULL || of_address_to_resource(rtcs, 0, &r)) rtcs = of_find_compatible_node(NULL, "rtc", "ds1385-rtc"); if (rtcs == NULL) return 0; if (of_address_to_resource(rtcs, 0, &r)) { of_node_put(rtcs); return 0; } of_node_put(rtcs); base = r.start; nvram_as1 = 0; Loading drivers/macintosh/macio-adb.c +13 −3 Original line number Diff line number Diff line Loading @@ -82,7 +82,14 @@ struct adb_driver macio_adb_driver = { int macio_probe(void) { return find_compatible_devices("adb", "chrp,adb0")? 0: -ENODEV; struct device_node *np; np = of_find_compatible_node(NULL, "adb", "chrp,adb0"); if (np) { of_node_put(np); return 0; } return -ENODEV; } int macio_init(void) Loading @@ -91,12 +98,14 @@ int macio_init(void) struct resource r; unsigned int irq; adbs = find_compatible_devices("adb", "chrp,adb0"); adbs = of_find_compatible_node(NULL, "adb", "chrp,adb0"); if (adbs == 0) return -ENXIO; if (of_address_to_resource(adbs, 0, &r)) if (of_address_to_resource(adbs, 0, &r)) { of_node_put(adbs); return -ENXIO; } adb = ioremap(r.start, sizeof(struct adb_regs)); out_8(&adb->ctrl.r, 0); Loading @@ -107,6 +116,7 @@ int macio_init(void) out_8(&adb->autopoll.r, APE); irq = irq_of_parse_and_map(adbs, 0); of_node_put(adbs); if (request_irq(irq, macio_adb_interrupt, 0, "ADB", (void *)0)) { printk(KERN_ERR "ADB: can't get irq %d\n", irq); return -EAGAIN; Loading include/asm-powerpc/prom.h +0 −2 Original line number Diff line number Diff line Loading @@ -116,8 +116,6 @@ static inline void set_node_proc_entry(struct device_node *dn, struct proc_dir_e extern struct device_node *find_devices(const char *name); extern struct device_node *find_type_devices(const char *type); extern struct device_node *find_path_device(const char *path); extern struct device_node *find_compatible_devices(const char *type, const char *compat); extern struct device_node *find_all_nodes(void); /* New style node lookup */ Loading Loading
arch/powerpc/kernel/prom.c +0 −24 Original line number Diff line number Diff line Loading @@ -1170,30 +1170,6 @@ int machine_is_compatible(const char *compat) } EXPORT_SYMBOL(machine_is_compatible); /** * Construct and return a list of the device_nodes with a given type * and compatible property. */ struct device_node *find_compatible_devices(const char *type, const char *compat) { struct device_node *head, **prevp, *np; prevp = &head; for (np = allnodes; np != 0; np = np->allnext) { if (type != NULL && !(np->type != 0 && strcasecmp(np->type, type) == 0)) continue; if (of_device_is_compatible(np, compat)) { *prevp = np; prevp = &np->next; } } *prevp = NULL; return head; } EXPORT_SYMBOL(find_compatible_devices); /** * Find the device_node with a given full_name. */ Loading
arch/powerpc/platforms/chrp/time.c +9 −4 Original line number Diff line number Diff line Loading @@ -39,11 +39,16 @@ long __init chrp_time_init(void) struct resource r; int base; rtcs = find_compatible_devices("rtc", "pnpPNP,b00"); rtcs = of_find_compatible_node(NULL, "rtc", "pnpPNP,b00"); if (rtcs == NULL) rtcs = find_compatible_devices("rtc", "ds1385-rtc"); if (rtcs == NULL || of_address_to_resource(rtcs, 0, &r)) rtcs = of_find_compatible_node(NULL, "rtc", "ds1385-rtc"); if (rtcs == NULL) return 0; if (of_address_to_resource(rtcs, 0, &r)) { of_node_put(rtcs); return 0; } of_node_put(rtcs); base = r.start; nvram_as1 = 0; Loading
drivers/macintosh/macio-adb.c +13 −3 Original line number Diff line number Diff line Loading @@ -82,7 +82,14 @@ struct adb_driver macio_adb_driver = { int macio_probe(void) { return find_compatible_devices("adb", "chrp,adb0")? 0: -ENODEV; struct device_node *np; np = of_find_compatible_node(NULL, "adb", "chrp,adb0"); if (np) { of_node_put(np); return 0; } return -ENODEV; } int macio_init(void) Loading @@ -91,12 +98,14 @@ int macio_init(void) struct resource r; unsigned int irq; adbs = find_compatible_devices("adb", "chrp,adb0"); adbs = of_find_compatible_node(NULL, "adb", "chrp,adb0"); if (adbs == 0) return -ENXIO; if (of_address_to_resource(adbs, 0, &r)) if (of_address_to_resource(adbs, 0, &r)) { of_node_put(adbs); return -ENXIO; } adb = ioremap(r.start, sizeof(struct adb_regs)); out_8(&adb->ctrl.r, 0); Loading @@ -107,6 +116,7 @@ int macio_init(void) out_8(&adb->autopoll.r, APE); irq = irq_of_parse_and_map(adbs, 0); of_node_put(adbs); if (request_irq(irq, macio_adb_interrupt, 0, "ADB", (void *)0)) { printk(KERN_ERR "ADB: can't get irq %d\n", irq); return -EAGAIN; Loading
include/asm-powerpc/prom.h +0 −2 Original line number Diff line number Diff line Loading @@ -116,8 +116,6 @@ static inline void set_node_proc_entry(struct device_node *dn, struct proc_dir_e extern struct device_node *find_devices(const char *name); extern struct device_node *find_type_devices(const char *type); extern struct device_node *find_path_device(const char *path); extern struct device_node *find_compatible_devices(const char *type, const char *compat); extern struct device_node *find_all_nodes(void); /* New style node lookup */ Loading