/drivers/pci/hotplug/ |
D | rpadlpar_core.c | 44 struct device_node *dn; in find_vio_slot_node() local 50 for_each_child_of_node(parent, dn) { in find_vio_slot_node() 51 rc = rpaphp_check_drc_props(dn, drc_name, NULL); in find_vio_slot_node() 57 return dn; in find_vio_slot_node() 79 struct device_node *dn; in find_dlpar_node() local 81 dn = find_php_slot_pci_node(drc_name, "SLOT"); in find_dlpar_node() 82 if (dn) { in find_dlpar_node() 84 return dn; in find_dlpar_node() 87 dn = find_php_slot_pci_node(drc_name, "PHB"); in find_dlpar_node() 88 if (dn) { in find_dlpar_node() [all …]
|
D | pnv_php.c | 34 static void pnv_php_register(struct device_node *dn); 35 static void pnv_php_unregister_one(struct device_node *dn); 36 static void pnv_php_unregister(struct device_node *dn); 91 static struct pnv_php_slot *pnv_php_match(struct device_node *dn, in pnv_php_match() argument 96 if (php_slot->dn == dn) { in pnv_php_match() 102 target = pnv_php_match(dn, tmp); in pnv_php_match() 110 struct pnv_php_slot *pnv_php_find_slot(struct device_node *dn) in pnv_php_find_slot() argument 117 php_slot = pnv_php_match(dn, tmp); in pnv_php_find_slot() 133 static void pnv_php_rmv_pdns(struct device_node *dn) in pnv_php_rmv_pdns() argument 137 for_each_child_of_node(dn, child) { in pnv_php_rmv_pdns() [all …]
|
D | rpaphp_core.c | 159 static int get_children_props(struct device_node *dn, const __be32 **drc_indexes, in get_children_props() argument 165 indexes = of_get_property(dn, "ibm,drc-indexes", NULL); in get_children_props() 166 names = of_get_property(dn, "ibm,drc-names", NULL); in get_children_props() 167 types = of_get_property(dn, "ibm,drc-types", NULL); in get_children_props() 168 domains = of_get_property(dn, "ibm,drc-power-domains", NULL); in get_children_props() 195 static int rpaphp_check_drc_props_v1(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props_v1() argument 203 rc = get_children_props(dn->parent, &indexes, &names, &types, &domains); in rpaphp_check_drc_props_v1() 227 static int rpaphp_check_drc_props_v2(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props_v2() argument 237 info = of_find_property(dn->parent, "ibm,drc-info", NULL); in rpaphp_check_drc_props_v2() 270 int rpaphp_check_drc_props(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props() argument [all …]
|
D | rpaphp_slot.c | 25 of_node_put(slot->dn); in dealloc_slot_struct() 30 struct slot *alloc_slot_struct(struct device_node *dn, in alloc_slot_struct() argument 41 slot->dn = of_node_get(dn); in alloc_slot_struct() 91 __func__, slot->dn, slot->index, slot->name, in rpaphp_register_slot() 100 for_each_child_of_node(slot->dn, child) { in rpaphp_register_slot()
|
/drivers/irqchip/ |
D | irq-bcm7120-l2.c | 106 static int bcm7120_l2_intc_init_one(struct device_node *dn, in bcm7120_l2_intc_init_one() argument 114 parent_irq = irq_of_parse_and_map(dn, irq); in bcm7120_l2_intc_init_one() 150 static int __init bcm7120_l2_intc_iomap_7120(struct device_node *dn, in bcm7120_l2_intc_iomap_7120() argument 155 data->map_base[0] = of_iomap(dn, 0); in bcm7120_l2_intc_iomap_7120() 166 ret = of_property_read_u32_array(dn, "brcm,int-fwd-mask", in bcm7120_l2_intc_iomap_7120() 174 data->map_mask_prop = of_get_property(dn, "brcm,int-map-mask", &ret); in bcm7120_l2_intc_iomap_7120() 184 static int __init bcm7120_l2_intc_iomap_3380(struct device_node *dn, in bcm7120_l2_intc_iomap_3380() argument 191 void __iomem *en = of_iomap(dn, map_idx + 0); in bcm7120_l2_intc_iomap_3380() 192 void __iomem *stat = of_iomap(dn, map_idx + 1); in bcm7120_l2_intc_iomap_3380() 215 static int __init bcm7120_l2_intc_probe(struct device_node *dn, in bcm7120_l2_intc_probe() argument [all …]
|
/drivers/perf/ |
D | arm-cmn.c | 393 const struct arm_cmn_node *dn) in arm_cmn_node_to_xp() argument 395 struct arm_cmn_nodeid nid = arm_cmn_nid(cmn, dn->id); in arm_cmn_node_to_xp() 403 struct arm_cmn_node *dn; in arm_cmn_node() local 405 for (dn = cmn->dns; dn->type; dn++) in arm_cmn_node() 406 if (dn->type == type) in arm_cmn_node() 407 return dn; in arm_cmn_node() 487 struct arm_cmn_node *dn; in arm_cmn_show_logid() local 489 for (dn = cmn->dns; dn->type; dn++) { in arm_cmn_show_logid() 490 struct arm_cmn_nodeid nid = arm_cmn_nid(cmn, dn->id); in arm_cmn_show_logid() 492 if (dn->type == CMN_TYPE_XP) in arm_cmn_show_logid() [all …]
|
/drivers/cpufreq/ |
D | pasemi-cpufreq.c | 131 struct device_node *cpu, *dn; in pas_cpufreq_cpu_init() local 148 dn = of_find_compatible_node(NULL, NULL, "1682m-sdc"); in pas_cpufreq_cpu_init() 149 if (!dn) in pas_cpufreq_cpu_init() 150 dn = of_find_compatible_node(NULL, NULL, in pas_cpufreq_cpu_init() 152 if (!dn) in pas_cpufreq_cpu_init() 154 err = of_address_to_resource(dn, 0, &res); in pas_cpufreq_cpu_init() 155 of_node_put(dn); in pas_cpufreq_cpu_init() 164 dn = of_find_compatible_node(NULL, NULL, "1682m-gizmo"); in pas_cpufreq_cpu_init() 165 if (!dn) in pas_cpufreq_cpu_init() 166 dn = of_find_compatible_node(NULL, NULL, in pas_cpufreq_cpu_init() [all …]
|
/drivers/char/tpm/ |
D | tpm_atmel.h | 43 struct device_node *dn; in atmel_get_base_addr() local 50 dn = of_find_node_by_name(NULL, "tpm"); in atmel_get_base_addr() 52 if (!dn) in atmel_get_base_addr() 55 if (!of_device_is_compatible(dn, "AT97SC3201")) { in atmel_get_base_addr() 56 of_node_put(dn); in atmel_get_base_addr() 60 reg = of_get_property(dn, "reg", ®len); in atmel_get_base_addr() 61 naddrc = of_n_addr_cells(dn); in atmel_get_base_addr() 62 nsizec = of_n_size_cells(dn); in atmel_get_base_addr() 64 of_node_put(dn); in atmel_get_base_addr()
|
/drivers/acpi/ |
D | property.c | 76 struct acpi_data_node *dn; in acpi_nondev_subnode_extract() local 79 dn = kzalloc(sizeof(*dn), GFP_KERNEL); in acpi_nondev_subnode_extract() 80 if (!dn) in acpi_nondev_subnode_extract() 83 dn->name = link->package.elements[0].string.pointer; in acpi_nondev_subnode_extract() 84 fwnode_init(&dn->fwnode, &acpi_data_fwnode_ops); in acpi_nondev_subnode_extract() 85 dn->parent = parent; in acpi_nondev_subnode_extract() 86 INIT_LIST_HEAD(&dn->data.properties); in acpi_nondev_subnode_extract() 87 INIT_LIST_HEAD(&dn->data.subnodes); in acpi_nondev_subnode_extract() 89 result = acpi_extract_properties(handle, desc, &dn->data); in acpi_nondev_subnode_extract() 103 && acpi_enumerate_nondev_subnodes(scope, desc, &dn->data, in acpi_nondev_subnode_extract() [all …]
|
D | device_sysfs.c | 45 static ssize_t data_node_show_path(struct acpi_data_node *dn, char *buf) in data_node_show_path() argument 47 return dn->handle ? acpi_object_path(dn->handle, buf) : 0; in data_node_show_path() 64 struct acpi_data_node *dn = to_data_node(kobj); in acpi_data_node_attr_show() local 67 return dn_attr->show ? dn_attr->show(dn, buf) : -ENXIO; in acpi_data_node_attr_show() 76 struct acpi_data_node *dn = to_data_node(kobj); in acpi_data_node_release() local 78 complete(&dn->kobj_done); in acpi_data_node_release() 91 struct acpi_data_node *dn; in acpi_expose_nondev_subnodes() local 96 list_for_each_entry(dn, list, sibling) { in acpi_expose_nondev_subnodes() 99 init_completion(&dn->kobj_done); in acpi_expose_nondev_subnodes() 100 ret = kobject_init_and_add(&dn->kobj, &acpi_data_node_ktype, in acpi_expose_nondev_subnodes() [all …]
|
/drivers/soc/renesas/ |
D | r9a06g032-smp.c | 53 struct device_node *dn; in r9a06g032_smp_prepare_cpus() local 57 dn = of_get_cpu_node(1, NULL); in r9a06g032_smp_prepare_cpus() 58 if (!dn) { in r9a06g032_smp_prepare_cpus() 67 if (of_find_property(dn, "cpu-release-addr", &dns)) { in r9a06g032_smp_prepare_cpus() 71 ret = of_property_read_u64(dn, in r9a06g032_smp_prepare_cpus() 75 ret = of_property_read_u32(dn, in r9a06g032_smp_prepare_cpus() 80 of_node_put(dn); in r9a06g032_smp_prepare_cpus()
|
/drivers/soc/bcm/brcmstb/pm/ |
D | pm-arm.c | 119 static int brcmstb_init_sram(struct device_node *dn) in brcmstb_init_sram() argument 125 ret = of_address_to_resource(dn, 0, &res); in brcmstb_init_sram() 654 struct device_node *dn; in brcmstb_ioremap_match() local 657 dn = of_find_matching_node_and_match(NULL, matches, &match); in brcmstb_ioremap_match() 658 if (!dn) in brcmstb_ioremap_match() 664 return of_io_request_and_map(dn, index, dn->full_name); in brcmstb_ioremap_match() 697 struct device_node *dn; in brcmstb_pm_probe() local 747 for_each_matching_node(dn, ddr_shimphy_dt_ids) { in brcmstb_pm_probe() 750 of_node_put(dn); in brcmstb_pm_probe() 755 base = of_io_request_and_map(dn, 0, dn->full_name); in brcmstb_pm_probe() [all …]
|
D | pm-mips.c | 358 static inline void __iomem *brcmstb_ioremap_node(struct device_node *dn, in brcmstb_ioremap_node() argument 361 return of_io_request_and_map(dn, index, dn->full_name); in brcmstb_ioremap_node() 367 struct device_node *dn; in brcmstb_ioremap_match() local 370 dn = of_find_matching_node_and_match(NULL, matches, &match); in brcmstb_ioremap_match() 371 if (!dn) in brcmstb_ioremap_match() 377 return brcmstb_ioremap_node(dn, index); in brcmstb_ioremap_match() 382 struct device_node *dn; in brcmstb_pm_init() local 404 for_each_matching_node(dn, ddr_phy_dt_ids) { in brcmstb_pm_init() 408 of_node_put(dn); in brcmstb_pm_init() 411 base = brcmstb_ioremap_node(dn, 0); in brcmstb_pm_init() [all …]
|
/drivers/usb/misc/ |
D | brcmstb-usb-pinmap.c | 112 static void get_pin_counts(struct device_node *dn, int *in_count, in get_pin_counts() argument 120 in = of_property_count_strings(dn, "brcm,in-functions"); in get_pin_counts() 123 out = of_property_count_strings(dn, "brcm,out-functions"); in get_pin_counts() 130 static int parse_pins(struct device *dev, struct device_node *dn, in parse_pins() argument 147 res = of_property_read_string_index(dn, "brcm,in-functions", x, in parse_pins() 154 res = of_property_read_u32_index(dn, "brcm,in-masks", index++, in parse_pins() 161 res = of_property_read_u32_index(dn, "brcm,in-masks", index++, in parse_pins() 179 res = of_property_read_string_index(dn, "brcm,out-functions", x, in parse_pins() 186 res = of_property_read_u32_index(dn, "brcm,out-masks", index++, in parse_pins() 193 res = of_property_read_u32_index(dn, "brcm,out-masks", index++, in parse_pins() [all …]
|
/drivers/usb/host/ |
D | ehci-ppc-of.c | 79 ppc44x_enable_bmt(struct device_node *dn) in ppc44x_enable_bmt() argument 83 insreg_virt = of_iomap(dn, 1); in ppc44x_enable_bmt() 96 struct device_node *dn = op->dev.of_node; in ehci_hcd_ppc_of_probe() local 110 rv = of_address_to_resource(dn, 0, &res); in ehci_hcd_ppc_of_probe() 121 irq = irq_of_parse_and_map(dn, 0); in ehci_hcd_ppc_of_probe() 154 if (of_get_property(dn, "big-endian", NULL)) { in ehci_hcd_ppc_of_probe() 158 if (of_get_property(dn, "big-endian-regs", NULL)) in ehci_hcd_ppc_of_probe() 160 if (of_get_property(dn, "big-endian-desc", NULL)) in ehci_hcd_ppc_of_probe() 165 if (of_device_is_compatible(dn, "ibm,usb-ehci-440epx")) { in ehci_hcd_ppc_of_probe() 166 rv = ppc44x_enable_bmt(dn); in ehci_hcd_ppc_of_probe()
|
D | ohci-ppc-of.c | 86 struct device_node *dn = op->dev.of_node; in ohci_hcd_ppc_of_probe() local 100 of_device_is_compatible(dn, "ohci-bigendian") || in ohci_hcd_ppc_of_probe() 101 of_device_is_compatible(dn, "ohci-be"); in ohci_hcd_ppc_of_probe() 105 rv = of_address_to_resource(dn, 0, &res); in ohci_hcd_ppc_of_probe() 122 irq = irq_of_parse_and_map(dn, 0); in ohci_hcd_ppc_of_probe() 133 if (of_device_is_compatible(dn, "fsl,mpc5200-ohci")) in ohci_hcd_ppc_of_probe() 135 if (of_device_is_compatible(dn, "mpc5200-ohci")) in ohci_hcd_ppc_of_probe()
|
/drivers/crypto/nx/ |
D | nx-common-powernv.c | 768 static int __init vas_cfg_coproc_info(struct device_node *dn, int chip_id, in vas_cfg_coproc_info() argument 779 ret = of_property_read_u64(dn, "rx-fifo-address", &rx_fifo); in vas_cfg_coproc_info() 785 ret = of_property_read_u32(dn, "rx-fifo-size", &fifo_size); in vas_cfg_coproc_info() 791 ret = of_property_read_u32(dn, "lpid", &lpid); in vas_cfg_coproc_info() 797 ret = of_property_read_u32(dn, "pid", &pid); in vas_cfg_coproc_info() 803 ret = of_property_read_u32(dn, "tid", &tid); in vas_cfg_coproc_info() 809 ret = of_property_read_string(dn, "priority", &priority); in vas_cfg_coproc_info() 894 static int __init find_nx_device_tree(struct device_node *dn, int chip_id, in find_nx_device_tree() argument 900 if (of_device_is_compatible(dn, devname)) { in find_nx_device_tree() 901 ret = vas_cfg_coproc_info(dn, chip_id, vasid, type, ct); in find_nx_device_tree() [all …]
|
/drivers/power/reset/ |
D | linkstation-poweroff.c | 160 struct device_node *dn; in linkstation_poweroff_init() local 163 dn = of_find_matching_node(NULL, ls_poweroff_of_match); in linkstation_poweroff_init() 164 if (!dn) in linkstation_poweroff_init() 166 of_node_put(dn); in linkstation_poweroff_init() 168 match = of_match_node(ls_poweroff_of_match, dn); in linkstation_poweroff_init() 171 dn = of_find_node_by_name(NULL, cfg->mdio_node_name); in linkstation_poweroff_init() 172 if (!dn) in linkstation_poweroff_init() 175 bus = of_mdio_find_bus(dn); in linkstation_poweroff_init() 176 of_node_put(dn); in linkstation_poweroff_init()
|
/drivers/net/ethernet/broadcom/genet/ |
D | bcmmii.c | 290 struct device_node *dn = kdev->of_node; in bcmgenet_mii_probe() local 335 if (dn) { in bcmgenet_mii_probe() 402 struct device_node *dn = priv->pdev->dev.of_node; in bcmgenet_mii_of_find_mdio() local 410 priv->mdio_dn = of_get_compatible_child(dn, compat); in bcmgenet_mii_of_find_mdio() 452 struct device_node *dn = pdev->dev.of_node; in bcmgenet_mii_register() local 477 if (dn) in bcmgenet_mii_register() 478 id = of_alias_get_id(dn, "eth"); in bcmgenet_mii_register() 489 if (dn) in bcmgenet_mii_register() 539 struct device_node *dn = priv->pdev->dev.of_node; in bcmgenet_mii_of_init() local 544 priv->phy_dn = of_parse_phandle(dn, "phy-handle", 0); in bcmgenet_mii_of_init() [all …]
|
/drivers/ata/ |
D | pata_atiixp.c | 108 int dn = 2 * ap->port_no + adev->devno; in atiixp_set_pio_timing() local 114 pio_mode_data &= ~(0x7 << (4 * dn)); in atiixp_set_pio_timing() 115 pio_mode_data |= pio << (4 * dn); in atiixp_set_pio_timing() 156 int dn = 2 * ap->port_no + adev->devno; in atiixp_set_dmamode() local 168 udma_mode_data &= ~(0x7 << (4 * dn)); in atiixp_set_dmamode() 169 udma_mode_data |= dma << (4 * dn); in atiixp_set_dmamode() 218 int dn = (2 * ap->port_no) + adev->devno; in atiixp_bmdma_start() local 223 tmp16 |= (1 << dn); in atiixp_bmdma_start() 225 tmp16 &= ~(1 << dn); in atiixp_bmdma_start() 245 int dn = (2 * ap->port_no) + qc->dev->devno; in atiixp_bmdma_stop() local [all …]
|
D | pata_hpt3x3.c | 41 int dn = 2 * ap->port_no + adev->devno; in hpt3x3_set_piomode() local 46 r1 &= ~(7 << (3 * dn)); in hpt3x3_set_piomode() 47 r1 |= (adev->pio_mode - XFER_PIO_0) << (3 * dn); in hpt3x3_set_piomode() 48 r2 &= ~(0x11 << dn); /* Clear MWDMA and UDMA bits */ in hpt3x3_set_piomode() 71 int dn = 2 * ap->port_no + adev->devno; in hpt3x3_set_dmamode() local 77 r1 &= ~(7 << (3 * dn)); in hpt3x3_set_dmamode() 78 r1 |= (mode_num << (3 * dn)); in hpt3x3_set_dmamode() 79 r2 &= ~(0x11 << dn); /* Clear MWDMA and UDMA bits */ in hpt3x3_set_dmamode() 82 r2 |= (0x01 << dn); /* Ultra mode */ in hpt3x3_set_dmamode() 84 r2 |= (0x10 << dn); /* MWDMA */ in hpt3x3_set_dmamode()
|
D | pata_of_platform.c | 25 struct device_node *dn = ofdev->dev.of_node; in pata_of_platform_probe() local 35 ret = of_address_to_resource(dn, 0, &io_res); in pata_of_platform_probe() 42 ret = of_address_to_resource(dn, 1, &ctl_res); in pata_of_platform_probe() 59 of_property_read_u32(dn, "reg-shift", ®_shift); in pata_of_platform_probe() 61 if (!of_property_read_u32(dn, "pio-mode", &pio_mode)) { in pata_of_platform_probe() 70 use16bit = of_property_read_bool(dn, "ata-generic,use16bit"); in pata_of_platform_probe()
|
/drivers/bus/ |
D | imx-weim.c | 315 of_id = of_match_node(weim_id_table, rd->dn->parent); in of_weim_notify() 321 pdev = of_find_device_by_node(rd->dn->parent); in of_weim_notify() 324 __func__, rd->dn->parent); in of_weim_notify() 329 if (weim_timing_setup(&pdev->dev, rd->dn, devtype)) in of_weim_notify() 331 "Failed to setup timing for '%pOF'\n", rd->dn); in of_weim_notify() 333 if (!of_node_check_flag(rd->dn, OF_POPULATED)) { in of_weim_notify() 339 rd->dn->fwnode.flags &= ~FWNODE_FLAG_NOT_DEVICE; in of_weim_notify() 340 if (!of_platform_device_create(rd->dn, NULL, &pdev->dev)) { in of_weim_notify() 343 rd->dn); in of_weim_notify() 352 if (!of_node_check_flag(rd->dn, OF_POPULATED)) in of_weim_notify() [all …]
|
D | arm-cci.c | 110 struct device_node *dn; member 161 static int __cci_ace_get_port(struct device_node *dn, int type) in __cci_ace_get_port() argument 167 cci_portn = of_parse_phandle(dn, "cci-control-port", 0); in __cci_ace_get_port() 170 if (ace_match && cci_portn == ports[i].dn) in __cci_ace_get_port() 176 int cci_ace_get_port(struct device_node *dn) in cci_ace_get_port() argument 178 return __cci_ace_get_port(dn, ACE_LITE_PORT); in cci_ace_get_port() 388 int notrace __cci_control_port_by_device(struct device_node *dn, bool enable) in __cci_control_port_by_device() argument 392 if (!dn) in __cci_control_port_by_device() 395 port = __cci_ace_get_port(dn, ACE_LITE_PORT); in __cci_control_port_by_device() 397 dn)) in __cci_control_port_by_device() [all …]
|
/drivers/clk/mvebu/ |
D | ap-cpu-clk.c | 234 struct device_node *dn, *np = dev->of_node; in ap_cpu_clock_probe() local 255 for_each_of_cpu_node(dn) { in ap_cpu_clock_probe() 258 err = of_property_read_u32(dn, "reg", &cpu); in ap_cpu_clock_probe() 260 of_node_put(dn); in ap_cpu_clock_probe() 267 of_node_put(dn); in ap_cpu_clock_probe() 286 for_each_of_cpu_node(dn) { in ap_cpu_clock_probe() 293 err = of_property_read_u32(dn, "reg", &cpu); in ap_cpu_clock_probe() 295 of_node_put(dn); in ap_cpu_clock_probe() 309 of_node_put(dn); in ap_cpu_clock_probe() 329 of_node_put(dn); in ap_cpu_clock_probe()
|