/drivers/pci/hotplug/ |
D | rpadlpar_core.c | 43 struct device_node *dn; in find_vio_slot_node() local 49 for_each_child_of_node(parent, dn) { in find_vio_slot_node() 50 rc = rpaphp_check_drc_props(dn, drc_name, NULL); in find_vio_slot_node() 56 return dn; in find_vio_slot_node() 78 struct device_node *dn; in find_dlpar_node() local 80 dn = find_php_slot_pci_node(drc_name, "SLOT"); in find_dlpar_node() 81 if (dn) { in find_dlpar_node() 83 return dn; in find_dlpar_node() 86 dn = find_php_slot_pci_node(drc_name, "PHB"); in find_dlpar_node() 87 if (dn) { in find_dlpar_node() [all …]
|
D | pnv_php.c | 33 static void pnv_php_register(struct device_node *dn); 34 static void pnv_php_unregister_one(struct device_node *dn); 35 static void pnv_php_unregister(struct device_node *dn); 90 static struct pnv_php_slot *pnv_php_match(struct device_node *dn, in pnv_php_match() argument 95 if (php_slot->dn == dn) { in pnv_php_match() 101 target = pnv_php_match(dn, tmp); in pnv_php_match() 109 struct pnv_php_slot *pnv_php_find_slot(struct device_node *dn) in pnv_php_find_slot() argument 116 php_slot = pnv_php_match(dn, tmp); in pnv_php_find_slot() 132 static void pnv_php_rmv_pdns(struct device_node *dn) in pnv_php_rmv_pdns() argument 136 for_each_child_of_node(dn, child) { in pnv_php_rmv_pdns() [all …]
|
D | rpaphp_core.c | 157 static int get_children_props(struct device_node *dn, const __be32 **drc_indexes, in get_children_props() argument 163 indexes = of_get_property(dn, "ibm,drc-indexes", NULL); in get_children_props() 164 names = of_get_property(dn, "ibm,drc-names", NULL); in get_children_props() 165 types = of_get_property(dn, "ibm,drc-types", NULL); in get_children_props() 166 domains = of_get_property(dn, "ibm,drc-power-domains", NULL); in get_children_props() 193 static int rpaphp_check_drc_props_v1(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props_v1() argument 201 rc = get_children_props(dn->parent, &indexes, &names, &types, &domains); in rpaphp_check_drc_props_v1() 225 static int rpaphp_check_drc_props_v2(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props_v2() argument 235 info = of_find_property(dn->parent, "ibm,drc-info", NULL); in rpaphp_check_drc_props_v2() 268 int rpaphp_check_drc_props(struct device_node *dn, char *drc_name, in rpaphp_check_drc_props() argument [all …]
|
D | rpaphp_slot.c | 24 of_node_put(slot->dn); in dealloc_slot_struct() 29 struct slot *alloc_slot_struct(struct device_node *dn, in alloc_slot_struct() argument 40 slot->dn = of_node_get(dn); in alloc_slot_struct() 90 __func__, slot->dn, slot->index, slot->name, in rpaphp_register_slot() 99 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 | 341 const struct arm_cmn_node *dn) in arm_cmn_node_to_xp() argument 343 struct arm_cmn_nodeid nid = arm_cmn_nid(cmn, dn->id); in arm_cmn_node_to_xp() 351 struct arm_cmn_node *dn; in arm_cmn_node() local 353 for (dn = cmn->dns; dn->type; dn++) in arm_cmn_node() 354 if (dn->type == type) in arm_cmn_node() 355 return dn; in arm_cmn_node() 394 struct arm_cmn_node *dn; in arm_cmn_show_logid() local 396 for (dn = cmn->dns; dn->type; dn++) { in arm_cmn_show_logid() 397 struct arm_cmn_nodeid nid = arm_cmn_nid(cmn, dn->id); in arm_cmn_show_logid() 399 if (dn->type == CMN_TYPE_XP) in arm_cmn_show_logid() [all …]
|
/drivers/cpufreq/ |
D | pasemi-cpufreq.c | 132 struct device_node *cpu, *dn; in pas_cpufreq_cpu_init() local 149 dn = of_find_compatible_node(NULL, NULL, "1682m-sdc"); in pas_cpufreq_cpu_init() 150 if (!dn) in pas_cpufreq_cpu_init() 151 dn = of_find_compatible_node(NULL, NULL, in pas_cpufreq_cpu_init() 153 if (!dn) in pas_cpufreq_cpu_init() 155 err = of_address_to_resource(dn, 0, &res); in pas_cpufreq_cpu_init() 156 of_node_put(dn); in pas_cpufreq_cpu_init() 165 dn = of_find_compatible_node(NULL, NULL, "1682m-gizmo"); in pas_cpufreq_cpu_init() 166 if (!dn) in pas_cpufreq_cpu_init() 167 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/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 | 120 static int brcmstb_init_sram(struct device_node *dn) in brcmstb_init_sram() argument 126 ret = of_address_to_resource(dn, 0, &res); in brcmstb_init_sram() 655 struct device_node *dn; in brcmstb_ioremap_match() local 658 dn = of_find_matching_node_and_match(NULL, matches, &match); in brcmstb_ioremap_match() 659 if (!dn) in brcmstb_ioremap_match() 665 return of_io_request_and_map(dn, index, dn->full_name); in brcmstb_ioremap_match() 685 struct device_node *dn; in brcmstb_pm_probe() local 735 for_each_matching_node(dn, ddr_shimphy_dt_ids) { in brcmstb_pm_probe() 738 of_node_put(dn); in brcmstb_pm_probe() 743 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() 410 base = brcmstb_ioremap_node(dn, 0); in brcmstb_pm_init()
|
/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 | 89 struct device_node *dn = op->dev.of_node; in ohci_hcd_ppc_of_probe() local 103 of_device_is_compatible(dn, "ohci-bigendian") || in ohci_hcd_ppc_of_probe() 104 of_device_is_compatible(dn, "ohci-be"); in ohci_hcd_ppc_of_probe() 108 rv = of_address_to_resource(dn, 0, &res); in ohci_hcd_ppc_of_probe() 125 irq = irq_of_parse_and_map(dn, 0); in ohci_hcd_ppc_of_probe() 136 if (of_device_is_compatible(dn, "fsl,mpc5200-ohci")) in ohci_hcd_ppc_of_probe() 138 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/acpi/ |
D | property.c | 71 struct acpi_data_node *dn; in acpi_nondev_subnode_extract() local 74 dn = kzalloc(sizeof(*dn), GFP_KERNEL); in acpi_nondev_subnode_extract() 75 if (!dn) in acpi_nondev_subnode_extract() 78 dn->name = link->package.elements[0].string.pointer; in acpi_nondev_subnode_extract() 79 fwnode_init(&dn->fwnode, &acpi_data_fwnode_ops); in acpi_nondev_subnode_extract() 80 dn->parent = parent; in acpi_nondev_subnode_extract() 81 INIT_LIST_HEAD(&dn->data.properties); in acpi_nondev_subnode_extract() 82 INIT_LIST_HEAD(&dn->data.subnodes); in acpi_nondev_subnode_extract() 84 result = acpi_extract_properties(desc, &dn->data); in acpi_nondev_subnode_extract() 98 && 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() 63 struct acpi_data_node *dn = to_data_node(kobj); in acpi_data_node_attr_show() local 66 return dn_attr->show ? dn_attr->show(dn, buf) : -ENXIO; in acpi_data_node_attr_show() 75 struct acpi_data_node *dn = to_data_node(kobj); in acpi_data_node_release() local 77 complete(&dn->kobj_done); in acpi_data_node_release() 90 struct acpi_data_node *dn; in acpi_expose_nondev_subnodes() local 95 list_for_each_entry(dn, list, sibling) { in acpi_expose_nondev_subnodes() 98 init_completion(&dn->kobj_done); in acpi_expose_nondev_subnodes() 99 ret = kobject_init_and_add(&dn->kobj, &acpi_data_node_ktype, in acpi_expose_nondev_subnodes() [all …]
|
/drivers/net/ethernet/broadcom/genet/ |
D | bcmmii.c | 287 struct device_node *dn = kdev->of_node; in bcmgenet_mii_probe() local 302 if (dn) { in bcmgenet_mii_probe() 371 struct device_node *dn = priv->pdev->dev.of_node; in bcmgenet_mii_of_find_mdio() local 379 priv->mdio_dn = of_get_compatible_child(dn, compat); in bcmgenet_mii_of_find_mdio() 421 struct device_node *dn = pdev->dev.of_node; in bcmgenet_mii_register() local 446 if (dn) in bcmgenet_mii_register() 447 id = of_alias_get_id(dn, "eth"); in bcmgenet_mii_register() 458 if (dn) in bcmgenet_mii_register() 508 struct device_node *dn = priv->pdev->dev.of_node; in bcmgenet_mii_of_init() local 513 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 34 ret = of_address_to_resource(dn, 0, &io_res); in pata_of_platform_probe() 41 ret = of_address_to_resource(dn, 1, &ctl_res); in pata_of_platform_probe() 50 of_property_read_u32(dn, "reg-shift", ®_shift); in pata_of_platform_probe() 52 if (!of_property_read_u32(dn, "pio-mode", &pio_mode)) { in pata_of_platform_probe() 61 use16bit = of_property_read_bool(dn, "ata-generic,use16bit"); in pata_of_platform_probe()
|
/drivers/bus/ |
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()
|
/drivers/interconnect/imx/ |
D | imx.c | 84 struct device_node *dn = NULL; in imx_icc_node_init_qos() local 92 dn = of_parse_phandle(dev->of_node, adj->phandle_name, 0); in imx_icc_node_init_qos() 93 if (!dn) { in imx_icc_node_init_qos() 99 if (!of_device_is_available(dn)) { in imx_icc_node_init_qos() 102 of_node_put(dn); in imx_icc_node_init_qos() 106 pdev = of_find_device_by_node(dn); in imx_icc_node_init_qos() 107 of_node_put(dn); in imx_icc_node_init_qos() 110 node->name, node->id, dn); in imx_icc_node_init_qos() 115 node->name, node->id, dn); in imx_icc_node_init_qos()
|