/arch/powerpc/kernel/ |
D | legacy_serial.c | 32 struct device_node *np; member 73 static int __init add_legacy_port(struct device_node *np, int want_index, in add_legacy_port() argument 84 clk = of_get_property(np, "clock-frequency", NULL); in add_legacy_port() 89 spd = of_get_property(np, "current-speed", NULL); in add_legacy_port() 92 rs = of_get_property(np, "reg-shift", NULL); in add_legacy_port() 112 if (legacy_serial_infos[index].np != NULL) { in add_legacy_port() 141 legacy_serial_infos[index].np = of_node_get(np); in add_legacy_port() 152 index, np); in add_legacy_port() 162 static int __init add_legacy_soc_port(struct device_node *np, in add_legacy_soc_port() argument 167 struct device_node *tsi = of_get_parent(np); in add_legacy_soc_port() [all …]
|
D | isa-bridge.c | 143 struct device_node *np, *parent = NULL, *tmp; in isa_bridge_find_early() local 154 for_each_node_by_type(np, "isa") { in isa_bridge_find_early() 156 for (parent = of_get_parent(np); parent;) { in isa_bridge_find_early() 168 if (np == NULL) in isa_bridge_find_early() 170 isa_bridge_devnode = np; in isa_bridge_find_early() 173 pci_process_ISA_OF_ranges(np, hose->io_base_phys); in isa_bridge_find_early() 178 pr_debug("ISA bridge (early) is %pOF\n", np); in isa_bridge_find_early() 187 void __init isa_bridge_init_non_pci(struct device_node *np) in isa_bridge_init_non_pci() argument 198 pna = of_n_addr_cells(np); in isa_bridge_init_non_pci() 199 if (of_property_read_u32(np, "#address-cells", &na) || in isa_bridge_init_non_pci() [all …]
|
/arch/powerpc/platforms/83xx/ |
D | usb.c | 27 struct device_node *np = NULL; in mpc834x_usb_cfg() local 41 np = of_find_compatible_node(NULL, NULL, "fsl-usb2-dr"); in mpc834x_usb_cfg() 42 if (np) { in mpc834x_usb_cfg() 45 prop = of_get_property(np, "phy_type", NULL); in mpc834x_usb_cfg() 53 dr_mode = of_get_property(np, "dr_mode", NULL); in mpc834x_usb_cfg() 65 of_node_put(np); in mpc834x_usb_cfg() 67 np = of_find_compatible_node(NULL, NULL, "fsl-usb2-mph"); in mpc834x_usb_cfg() 68 if (np) { in mpc834x_usb_cfg() 71 prop = of_get_property(np, "port0", NULL); in mpc834x_usb_cfg() 78 prop = of_get_property(np, "port1", NULL); in mpc834x_usb_cfg() [all …]
|
D | mpc836x_mds.c | 60 struct device_node *np; in mpc836x_mds_setup_arch() local 66 np = of_find_node_by_name(NULL, "bcsr"); in mpc836x_mds_setup_arch() 67 if (np) { in mpc836x_mds_setup_arch() 70 of_address_to_resource(np, 0, &res); in mpc836x_mds_setup_arch() 72 of_node_put(np); in mpc836x_mds_setup_arch() 76 if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) { in mpc836x_mds_setup_arch() 77 par_io_init(np); in mpc836x_mds_setup_arch() 78 of_node_put(np); in mpc836x_mds_setup_arch() 80 for_each_node_by_name(np, "ucc") in mpc836x_mds_setup_arch() 81 par_io_of_config(np); in mpc836x_mds_setup_arch() [all …]
|
D | mpc832x_mds.c | 53 struct device_node *np; in mpc832x_sys_setup_arch() local 59 np = of_find_node_by_name(NULL, "bcsr"); in mpc832x_sys_setup_arch() 60 if (np) { in mpc832x_sys_setup_arch() 63 of_address_to_resource(np, 0, &res); in mpc832x_sys_setup_arch() 65 of_node_put(np); in mpc832x_sys_setup_arch() 69 if ((np = of_find_node_by_name(NULL, "par_io")) != NULL) { in mpc832x_sys_setup_arch() 70 par_io_init(np); in mpc832x_sys_setup_arch() 71 of_node_put(np); in mpc832x_sys_setup_arch() 73 for_each_node_by_name(np, "ucc") in mpc832x_sys_setup_arch() 74 par_io_of_config(np); in mpc832x_sys_setup_arch() [all …]
|
D | km83xx.c | 128 struct device_node *np; in mpc83xx_km_setup_arch() local 134 np = of_find_node_by_name(NULL, "par_io"); in mpc83xx_km_setup_arch() 135 if (np != NULL) { in mpc83xx_km_setup_arch() 136 par_io_init(np); in mpc83xx_km_setup_arch() 137 of_node_put(np); in mpc83xx_km_setup_arch() 139 for_each_node_by_name(np, "spi") in mpc83xx_km_setup_arch() 140 par_io_of_config(np); in mpc83xx_km_setup_arch() 142 for_each_node_by_name(np, "ucc") in mpc83xx_km_setup_arch() 143 par_io_of_config(np); in mpc83xx_km_setup_arch() 146 np = of_find_compatible_node(NULL, "network", "ucc_geth"); in mpc83xx_km_setup_arch() [all …]
|
D | misc.c | 74 struct device_node *np; in mpc83xx_ipic_init_IRQ() local 77 np = of_find_compatible_node(NULL, NULL, "fsl,ipic"); in mpc83xx_ipic_init_IRQ() 78 if (!np) in mpc83xx_ipic_init_IRQ() 79 np = of_find_node_by_type(NULL, "ipic"); in mpc83xx_ipic_init_IRQ() 80 if (!np) in mpc83xx_ipic_init_IRQ() 83 ipic_init(np, 0); in mpc83xx_ipic_init_IRQ() 85 of_node_put(np); in mpc83xx_ipic_init_IRQ() 113 struct device_node *np; in mpc83xx_setup_pci() local 115 for_each_compatible_node(np, "pci", "fsl,mpc8349-pci") in mpc83xx_setup_pci() 116 mpc83xx_add_bridge(np); in mpc83xx_setup_pci() [all …]
|
D | mpc837x_mds.c | 28 struct device_node *np; in mpc837xmds_usb_cfg() local 38 np = of_find_compatible_node(NULL, NULL, "fsl,mpc837xmds-bcsr"); in mpc837xmds_usb_cfg() 39 if (np) { in mpc837xmds_usb_cfg() 40 bcsr_regs = of_iomap(np, 0); in mpc837xmds_usb_cfg() 41 of_node_put(np); in mpc837xmds_usb_cfg() 46 np = of_find_node_by_name(NULL, "usb"); in mpc837xmds_usb_cfg() 47 if (!np) { in mpc837xmds_usb_cfg() 51 phy_type = of_get_property(np, "phy_type", NULL); in mpc837xmds_usb_cfg() 55 mode = of_get_property(np, "dr_mode", NULL); in mpc837xmds_usb_cfg() 65 of_node_put(np); in mpc837xmds_usb_cfg()
|
/arch/riscv/kernel/ |
D | cacheinfo.c | 119 struct device_node *np = of_cpu_device_node_get(cpu); in init_cache_level() local 123 if (of_property_read_bool(np, "cache-size")) in init_cache_level() 125 if (of_property_read_bool(np, "i-cache-size")) in init_cache_level() 127 if (of_property_read_bool(np, "d-cache-size")) in init_cache_level() 132 prev = np; in init_cache_level() 133 while ((np = of_find_next_cache_node(np))) { in init_cache_level() 135 prev = np; in init_cache_level() 136 if (!of_device_is_compatible(np, "cache")) in init_cache_level() 138 if (of_property_read_u32(np, "cache-level", &level)) in init_cache_level() 142 if (of_property_read_bool(np, "cache-size")) in init_cache_level() [all …]
|
/arch/powerpc/platforms/cell/ |
D | cbe_regs.c | 52 static struct cbe_regs_map *cbe_find_map(struct device_node *np) in cbe_find_map() argument 57 if (!of_node_is_type(np, "spe")) { in cbe_find_map() 59 if (cbe_regs_maps[i].cpu_node == np || in cbe_find_map() 60 cbe_regs_maps[i].be_node == np) in cbe_find_map() 65 if (np->data) in cbe_find_map() 66 return np->data; in cbe_find_map() 69 tmp_np = np; in cbe_find_map() 77 np->data = cbe_find_map(tmp_np); in cbe_find_map() 79 return np->data; in cbe_find_map() 82 struct cbe_pmd_regs __iomem *cbe_get_pmd_regs(struct device_node *np) in cbe_get_pmd_regs() argument [all …]
|
D | iommu.c | 258 struct device_node *np; in cell_iommu_find_ioc() local 264 for_each_node_by_name(np, "ioc") { in cell_iommu_find_ioc() 265 if (of_node_to_nid(np) != nid) in cell_iommu_find_ioc() 267 if (of_address_to_resource(np, 0, &r)) { in cell_iommu_find_ioc() 269 np); in cell_iommu_find_ioc() 273 of_node_put(np); in cell_iommu_find_ioc() 278 for_each_node_by_type(np, "cpu") { in cell_iommu_find_ioc() 282 nidp = of_get_property(np, "node-id", NULL); in cell_iommu_find_ioc() 284 tmp = of_get_property(np, "ioc-translation", NULL); in cell_iommu_find_ioc() 287 of_node_put(np); in cell_iommu_find_ioc() [all …]
|
/arch/powerpc/platforms/pseries/ |
D | reconfig.c | 25 struct device_node *np; in pSeries_reconfig_add_node() local 28 np = kzalloc(sizeof(*np), GFP_KERNEL); in pSeries_reconfig_add_node() 29 if (!np) in pSeries_reconfig_add_node() 32 np->full_name = kstrdup(kbasename(path), GFP_KERNEL); in pSeries_reconfig_add_node() 33 if (!np->full_name) in pSeries_reconfig_add_node() 36 np->properties = proplist; in pSeries_reconfig_add_node() 37 of_node_set_flag(np, OF_DYNAMIC); in pSeries_reconfig_add_node() 38 of_node_init(np); in pSeries_reconfig_add_node() 40 np->parent = pseries_of_derive_parent(path); in pSeries_reconfig_add_node() 41 if (IS_ERR(np->parent)) { in pSeries_reconfig_add_node() [all …]
|
/arch/powerpc/platforms/powermac/ |
D | setup.c | 95 struct device_node *np; in pmac_show_cpuinfo() local 112 np = of_find_node_by_path("/"); in pmac_show_cpuinfo() 113 if (np != NULL) { in pmac_show_cpuinfo() 114 pp = of_get_property(np, "model", NULL); in pmac_show_cpuinfo() 119 pp = of_get_property(np, "compatible", &plen); in pmac_show_cpuinfo() 130 of_node_put(np); in pmac_show_cpuinfo() 139 np = of_find_node_by_name(NULL, "l2-cache"); in pmac_show_cpuinfo() 140 if (np == NULL) in pmac_show_cpuinfo() 141 np = of_find_node_by_type(NULL, "cache"); in pmac_show_cpuinfo() 142 if (np != NULL) { in pmac_show_cpuinfo() [all …]
|
/arch/arm/mach-imx/ |
D | cpu-imx5.c | 26 struct device_node *np; in imx5_read_srev_reg() local 29 np = of_find_compatible_node(NULL, NULL, compat); in imx5_read_srev_reg() 30 iim_base = of_iomap(np, 0); in imx5_read_srev_reg() 31 of_node_put(np); in imx5_read_srev_reg() 129 struct device_node *np; in imx5_pmu_init() local 135 np = of_find_compatible_node(NULL, NULL, "arm,cortex-a8-pmu"); in imx5_pmu_init() 136 if (!np) in imx5_pmu_init() 139 if (!of_property_read_bool(np, "secure-reg-access")) in imx5_pmu_init() 142 of_node_put(np); in imx5_pmu_init() 144 np = of_find_compatible_node(NULL, NULL, "fsl,imx51-tigerp"); in imx5_pmu_init() [all …]
|
/arch/powerpc/platforms/44x/ |
D | warp.c | 62 struct device_node *np; in warp_post_info() local 67 np = of_find_compatible_node(NULL, NULL, "pika,fpga-sd"); in warp_post_info() 68 if (np == NULL) in warp_post_info() 71 fpga = of_iomap(np, 0); in warp_post_info() 72 of_node_put(np); in warp_post_info() 166 struct device_node *np, *child; in pika_setup_leds() local 168 np = of_find_compatible_node(NULL, NULL, "gpio-leds"); in pika_setup_leds() 169 if (!np) { in pika_setup_leds() 174 for_each_child_of_node(np, child) in pika_setup_leds() 180 of_node_put(np); in pika_setup_leds() [all …]
|
/arch/powerpc/platforms/85xx/ |
D | common.c | 66 struct device_node *np; in mpc85xx_cpm2_pic_init() local 70 np = of_find_compatible_node(NULL, NULL, "fsl,cpm2-pic"); in mpc85xx_cpm2_pic_init() 71 if (np == NULL) { in mpc85xx_cpm2_pic_init() 75 irq = irq_of_parse_and_map(np, 0); in mpc85xx_cpm2_pic_init() 77 of_node_put(np); in mpc85xx_cpm2_pic_init() 82 cpm2_pic_init(np); in mpc85xx_cpm2_pic_init() 83 of_node_put(np); in mpc85xx_cpm2_pic_init() 91 struct device_node *np; in mpc85xx_qe_par_io_init() local 93 np = of_find_node_by_name(NULL, "par_io"); in mpc85xx_qe_par_io_init() 94 if (np) { in mpc85xx_qe_par_io_init() [all …]
|
/arch/arm/mach-vt8500/ |
D | vt8500.c | 63 struct device_node *np; in vt8500_init() local 72 np = of_find_compatible_node(NULL, NULL, "via,vt8500-gpio"); in vt8500_init() 73 if (np) { in vt8500_init() 74 gpio_base = of_iomap(np, 0); in vt8500_init() 80 of_node_put(np); in vt8500_init() 101 np = of_find_compatible_node(NULL, NULL, "wm,wm8505-gpio"); in vt8500_init() 102 if (!np) in vt8500_init() 103 np = of_find_compatible_node(NULL, NULL, in vt8500_init() 105 if (np) { in vt8500_init() 106 gpio_base = of_iomap(np, 0); in vt8500_init() [all …]
|
/arch/powerpc/sysdev/ |
D | rtc_cmos_setup.c | 22 struct device_node *np; in add_rtc() local 30 np = of_find_compatible_node(NULL, NULL, "pnpPNP,b00"); in add_rtc() 31 if (!np) in add_rtc() 34 ret = of_address_to_resource(np, 0, &res[0]); in add_rtc() 35 of_node_put(np); in add_rtc() 46 np = of_find_compatible_node(NULL, NULL, "chrp,iic"); in add_rtc() 47 if (!np) in add_rtc() 48 np = of_find_compatible_node(NULL, NULL, "pnpPNP,000"); in add_rtc() 49 if (np) { in add_rtc() 50 of_node_put(np); in add_rtc()
|
/arch/powerpc/platforms/512x/ |
D | mpc512x_shared.c | 34 struct device_node *np; in mpc512x_restart_init() local 38 np = of_find_compatible_node(NULL, NULL, reset_compat); in mpc512x_restart_init() 39 if (!np) in mpc512x_restart_init() 42 reset_module_base = of_iomap(np, 0); in mpc512x_restart_init() 43 of_node_put(np); in mpc512x_restart_init() 71 struct device_node *np; in mpc512x_set_pixel_clock() local 77 np = of_find_compatible_node(NULL, NULL, "fsl,mpc5121-diu"); in mpc512x_set_pixel_clock() 78 if (!np) { in mpc512x_set_pixel_clock() 82 clk_diu = of_clk_get(np, 0); in mpc512x_set_pixel_clock() 85 clk_diu = clk_get_sys(np->name, "ipg"); in mpc512x_set_pixel_clock() [all …]
|
/arch/arm/mach-socfpga/ |
D | l2_cache.c | 25 struct device_node *np; in socfpga_init_l2_ecc() local 28 np = of_find_compatible_node(NULL, NULL, "altr,socfpga-l2-ecc"); in socfpga_init_l2_ecc() 29 if (!np) { in socfpga_init_l2_ecc() 34 mapped_l2_edac_addr = of_iomap(np, 0); in socfpga_init_l2_ecc() 35 of_node_put(np); in socfpga_init_l2_ecc() 48 struct device_node *np; in socfpga_init_arria10_l2_ecc() local 52 np = of_find_compatible_node(NULL, NULL, "altr,socfpga-a10-l2-ecc"); in socfpga_init_arria10_l2_ecc() 53 if (!np) { in socfpga_init_arria10_l2_ecc() 58 mapped_l2_edac_addr = of_iomap(np, 0); in socfpga_init_arria10_l2_ecc() 59 of_node_put(np); in socfpga_init_arria10_l2_ecc()
|
/arch/arm/mach-mvebu/ |
D | cpu-reset.c | 44 static int mvebu_cpu_reset_map(struct device_node *np, int res_idx) in mvebu_cpu_reset_map() argument 48 if (of_address_to_resource(np, res_idx, &res)) { in mvebu_cpu_reset_map() 54 np->full_name)) { in mvebu_cpu_reset_map() 73 struct device_node *np; in mvebu_cpu_reset_init() local 77 np = of_find_compatible_node(NULL, NULL, in mvebu_cpu_reset_init() 79 if (np) { in mvebu_cpu_reset_init() 86 np = of_find_compatible_node(NULL, NULL, in mvebu_cpu_reset_init() 88 if (np) { in mvebu_cpu_reset_init() 95 if (!np) in mvebu_cpu_reset_init() 98 ret = mvebu_cpu_reset_map(np, res_idx); in mvebu_cpu_reset_init() [all …]
|
/arch/arm/mach-oxnas/ |
D | platsmp.c | 62 struct device_node *np; in ox820_smp_prepare_cpus() local 65 np = of_find_compatible_node(NULL, NULL, "arm,arm11mp-scu"); in ox820_smp_prepare_cpus() 66 scu_base = of_iomap(np, 0); in ox820_smp_prepare_cpus() 67 of_node_put(np); in ox820_smp_prepare_cpus() 72 np = of_find_compatible_node(NULL, NULL, "arm,arm11mp-gic"); in ox820_smp_prepare_cpus() 73 gic_cpu_ctrl = of_iomap(np, 1); in ox820_smp_prepare_cpus() 74 of_node_put(np); in ox820_smp_prepare_cpus() 78 np = of_find_compatible_node(NULL, NULL, "oxsemi,ox820-sys-ctrl"); in ox820_smp_prepare_cpus() 79 cpu_ctrl = of_iomap(np, 0); in ox820_smp_prepare_cpus() 80 of_node_put(np); in ox820_smp_prepare_cpus()
|
/arch/powerpc/platforms/4xx/ |
D | soc.c | 72 struct device_node *np; in ppc4xx_l2c_probe() local 82 np = of_find_compatible_node(NULL, NULL, "ibm,l2-cache"); in ppc4xx_l2c_probe() 83 if (!np) in ppc4xx_l2c_probe() 87 prop = of_get_property(np, "cache-size", NULL); in ppc4xx_l2c_probe() 89 printk(KERN_ERR "%pOF: Can't get cache-size!\n", np); in ppc4xx_l2c_probe() 90 of_node_put(np); in ppc4xx_l2c_probe() 96 dcrreg = of_get_property(np, "dcr-reg", &len); in ppc4xx_l2c_probe() 98 printk(KERN_ERR "%pOF: Can't get DCR register base !", np); in ppc4xx_l2c_probe() 99 of_node_put(np); in ppc4xx_l2c_probe() 106 irq = irq_of_parse_and_map(np, 0); in ppc4xx_l2c_probe() [all …]
|
/arch/powerpc/platforms/52xx/ |
D | mpc52xx_common.c | 59 struct device_node *np; in mpc5200_setup_xlb_arbiter() local 62 np = of_find_matching_node(NULL, mpc52xx_xlb_ids); in mpc5200_setup_xlb_arbiter() 63 xlb = of_iomap(np, 0); in mpc5200_setup_xlb_arbiter() 64 of_node_put(np); in mpc5200_setup_xlb_arbiter() 137 struct device_node *np; in mpc52xx_map_common_devices() local 143 for_each_matching_node(np, mpc52xx_gpt_ids) { in mpc52xx_map_common_devices() 144 if (of_get_property(np, "fsl,has-wdt", NULL) || in mpc52xx_map_common_devices() 145 of_get_property(np, "has-wdt", NULL)) { in mpc52xx_map_common_devices() 146 mpc52xx_wdt = of_iomap(np, 0); in mpc52xx_map_common_devices() 147 of_node_put(np); in mpc52xx_map_common_devices() [all …]
|
/arch/arm/mach-zx/ |
D | platsmp.c | 43 struct device_node *np; in zx_smp_prepare_cpus() local 57 np = of_find_compatible_node(NULL, NULL, "zte,sysctrl"); in zx_smp_prepare_cpus() 58 if (!np) { in zx_smp_prepare_cpus() 63 aonsysctrl_base = of_iomap(np, 0); in zx_smp_prepare_cpus() 66 of_node_put(np); in zx_smp_prepare_cpus() 80 of_node_put(np); in zx_smp_prepare_cpus() 82 np = of_find_compatible_node(NULL, NULL, "zte,zx296702-pcu"); in zx_smp_prepare_cpus() 83 pcu_base = of_iomap(np, 0); in zx_smp_prepare_cpus() 84 of_node_put(np); in zx_smp_prepare_cpus() 87 np = of_find_compatible_node(NULL, NULL, "zte,zx-bus-matrix"); in zx_smp_prepare_cpus() [all …]
|