/openbmc/linux/arch/powerpc/boot/ |
H A D | cuboot-hotfoot.c | 47 void *devp; in hotfoot_fixups() local 52 if (!devp) in hotfoot_fixups() 57 if (!devp) in hotfoot_fixups() 68 if (!devp) in hotfoot_fixups() 82 if (!devp) in hotfoot_fixups() 89 if (!devp) in hotfoot_fixups() 96 if (!devp) in hotfoot_fixups() 103 if (!devp) in hotfoot_fixups() 110 if (!devp) in hotfoot_fixups() 117 if (!devp) in hotfoot_fixups() [all …]
|
H A D | serial.c | 85 void *devp; in serial_get_stdout_devp() local 89 devp = finddevice("/chosen"); in serial_get_stdout_devp() 90 if (devp == NULL) in serial_get_stdout_devp() 95 devp = finddevice(path); in serial_get_stdout_devp() 96 if (devp == NULL) in serial_get_stdout_devp() 101 return devp; in serial_get_stdout_devp() 112 void *devp; in serial_console_init() local 115 devp = serial_get_stdout_devp(); in serial_console_init() 116 if (devp == NULL) in serial_console_init() 119 if (dt_is_compatible(devp, "ns16550") || in serial_console_init() [all …]
|
H A D | libfdt-wrapper.c | 37 #define devp_offset_find(devp) (((unsigned long)(devp))-1) argument 38 #define devp_offset(devp) (devp ? ((unsigned long)(devp))-1 : 0) argument 73 p = fdt_getprop(fdt, devp_offset(devp), name, &len); in fdt_wrapper_getprop() 85 rc = fdt_setprop(fdt, devp_offset(devp), name, buf, len); in fdt_wrapper_setprop() 88 rc = fdt_setprop(fdt, devp_offset(devp), name, buf, len); in fdt_wrapper_setprop() 94 static int fdt_wrapper_del_node(const void *devp) in fdt_wrapper_del_node() argument 96 return fdt_del_node(fdt, devp_offset(devp)); in fdt_wrapper_del_node() 99 static void *fdt_wrapper_get_parent(const void *devp) in fdt_wrapper_get_parent() argument 108 offset = fdt_add_subnode(fdt, devp_offset(devp), name); in fdt_wrapper_create_node() 111 offset = fdt_add_subnode(fdt, devp_offset(devp), name); in fdt_wrapper_create_node() [all …]
|
H A D | ops.h | 109 static inline int setprop(void *devp, const char *name, in setprop() argument 114 #define setprop_val(devp, name, val) \ argument 117 setprop((devp), (name), &x, sizeof(x)); \ 123 return dt_ops.setprop(devp, name, buf, strlen(buf) + 1); in setprop_str() 128 static inline int del_node(const void *devp) in del_node() argument 130 return dt_ops.del_node ? dt_ops.del_node(devp) : -1; in del_node() 133 static inline void *get_parent(const char *devp) in get_parent() argument 135 return dt_ops.get_parent ? dt_ops.get_parent(devp) : NULL; in get_parent() 171 void *devp = finddevice("/aliases"); in find_node_by_alias() local 173 if (devp) { in find_node_by_alias() [all …]
|
H A D | cuboot-85xx-cpm2.c | 22 void *devp; in platform_fixups() local 34 devp = find_node_by_devtype(NULL, "soc"); in platform_fixups() 35 if (devp) { in platform_fixups() 38 setprop(devp, "bus-frequency", &bd.bi_busfreq, in platform_fixups() 42 if (get_parent(serial) != devp) in platform_fixups() 50 devp = find_node_by_compatible(NULL, "fsl,cpm2-brg"); in platform_fixups() 51 if (devp) in platform_fixups() 52 setprop(devp, "clock-frequency", &bd.bi_brgfreq, in platform_fixups()
|
H A D | ebony.c | 36 void *devp; in ebony_flashsel_fixup() local 41 devp = finddevice(EBONY_FPGA_PATH); in ebony_flashsel_fixup() 42 if (!devp) in ebony_flashsel_fixup() 45 if (getprop(devp, "virtual-reg", &fpga, sizeof(fpga)) != sizeof(fpga)) in ebony_flashsel_fixup() 51 devp = finddevice(EBONY_SMALL_FLASH_PATH); in ebony_flashsel_fixup() 52 if (!devp) in ebony_flashsel_fixup() 56 if (getprop(devp, "reg", reg, sizeof(reg)) != sizeof(reg)) in ebony_flashsel_fixup() 64 setprop(devp, "reg", reg, sizeof(reg)); in ebony_flashsel_fixup()
|
H A D | mvme7100.c | 26 void *devp; in mvme7100_fixups() local 31 devp = finddevice("/soc@f1000000"); in mvme7100_fixups() 32 if (devp) in mvme7100_fixups() 33 setprop(devp, "bus-frequency", &busfreq, sizeof(busfreq)); in mvme7100_fixups() 35 devp = finddevice("/soc/serial@4500"); in mvme7100_fixups() 36 if (devp) in mvme7100_fixups() 37 setprop(devp, "clock-frequency", &busfreq, sizeof(busfreq)); in mvme7100_fixups()
|
H A D | devtree.c | 65 void *devp = NULL; in dt_fixup_cpu_clocks() local 72 while ((devp = find_node_by_devtype(devp, "cpu"))) { in dt_fixup_cpu_clocks() 73 setprop_val(devp, "clock-frequency", cpu_to_be32(cpu)); in dt_fixup_cpu_clocks() 76 setprop_val(devp, "bus-frequency", cpu_to_be32(bus)); in dt_fixup_cpu_clocks() 84 void *devp = finddevice(path); in dt_fixup_clock() local 86 if (devp) { in dt_fixup_clock() 94 void *devp = find_node_by_alias(alias); in dt_fixup_mac_address_by_alias() local 96 if (devp) { in dt_fixup_mac_address_by_alias() 102 setprop(devp, "local-mac-address", addr, 6); in dt_fixup_mac_address_by_alias() 111 if (devp) { in dt_fixup_mac_address() [all …]
|
H A D | treeboot-currituck.c | 61 void *devp = finddevice("/"); in ibm_currituck_fixups() local 66 while ((devp = find_node_by_devtype(devp, "pci"))) { in ibm_currituck_fixups() 67 if (getprop(devp, "dma-ranges", dma_ranges, sizeof(dma_ranges)) < 0) { in ibm_currituck_fixups() 75 setprop(devp, "dma-ranges", dma_ranges, sizeof(dma_ranges)); in ibm_currituck_fixups()
|
H A D | ns16550.c | 57 int ns16550_console_init(void *devp, struct serial_console_data *scdp) in ns16550_console_init() argument 62 if (dt_get_virtual_reg(devp, (void **)®_base, 1) < 1) { in ns16550_console_init() 67 n = getprop(devp, "reg-offset", ®_offset, sizeof(reg_offset)); in ns16550_console_init() 71 n = getprop(devp, "reg-shift", ®_shift, sizeof(reg_shift)); in ns16550_console_init()
|
H A D | ofconsole.c | 21 void *devp; in of_console_open() local 23 if (((devp = of_finddevice("/chosen")) != NULL) in of_console_open() 24 && (of_getprop(devp, "stdout", &of_stdout_handle, in of_console_open()
|
/openbmc/linux/drivers/char/ |
H A D | hpet.c | 129 devp = data; in hpet_interrupt() 130 isr = 1 << (devp - devp->hd_hpets->hp_dev); in hpet_interrupt() 137 devp->hd_irqdata++; in hpet_interrupt() 263 if (!devp) { in hpet_open() 426 irq = devp->hd_irq; in hpet_release() 427 devp->hd_irq = 0; in hpet_release() 495 isr = 1 << (devp - devp->hd_hpets->hp_dev); in hpet_ioctl_ieon() 499 sprintf(devp->hd_name, "hpet%d", (int)(devp - hpetp->hp_dev)); in hpet_ioctl_ieon() 502 devp->hd_name, (void *)devp)) { in hpet_ioctl_ieon() 551 isr = 1 << (devp - devp->hd_hpets->hp_dev); in hpet_ioctl_ieon() [all …]
|
/openbmc/u-boot/drivers/core/ |
H A D | uclass.c | 201 *devp = NULL; in uclass_find_device() 223 *devp = NULL; in uclass_find_first_device() 239 *devp = NULL; in uclass_find_next_device() 255 *devp = NULL; in uclass_find_device_by_name() 303 *devp = NULL; in uclass_find_device_by_seq() 332 *devp = NULL; in uclass_find_device_by_of_offset() 357 *devp = NULL; in uclass_find_device_by_ofnode() 389 *devp = NULL; in uclass_find_device_by_phandle() 442 *devp = dev; in uclass_get_device_tail() 608 if (!*devp) in uclass_first_device_check() [all …]
|
H A D | device.c | 42 if (devp) in device_bind_common() 43 *devp = NULL; in device_bind_common() 169 if (devp) in device_bind_common() 170 *devp = dev; in device_bind_common() 225 0, devp); in device_bind_with_driver_data() 241 devp); in device_bind_ofnode() 261 devp); in device_bind_by_name() 517 *devp = dev; in device_get_device_tail() 566 *devp = NULL; in device_find_child_by_seq() 587 *devp = NULL; in device_get_child_by_seq() [all …]
|
H A D | lists.c | 74 const char *dev_name, struct udevice **devp) in device_bind_driver() argument 77 ofnode_null(), devp); in device_bind_driver() 82 struct udevice **devp) in device_bind_driver_to_node() argument 93 node, devp); in device_bind_driver_to_node() 125 int lists_bind_fdt(struct udevice *parent, ofnode node, struct udevice **devp, in lists_bind_fdt() argument 139 if (devp) in lists_bind_fdt() 140 *devp = NULL; in lists_bind_fdt() 194 if (devp) in lists_bind_fdt() 195 *devp = dev; in lists_bind_fdt()
|
/openbmc/u-boot/include/dm/ |
H A D | uclass.h | 168 struct udevice **devp); 200 struct udevice **devp); 216 struct udevice **devp); 232 struct udevice **devp); 249 const char *name, struct udevice **devp); 266 struct udevice **devp); 282 int uclass_first_device(enum uclass_id id, struct udevice **devp); 293 int uclass_first_device_err(enum uclass_id id, struct udevice **devp); 308 int uclass_next_device(struct udevice **devp); 320 int uclass_next_device_err(struct udevice **devp); [all …]
|
H A D | uclass-internal.h | 37 int uclass_get_device_tail(struct udevice *dev, int ret, struct udevice **devp); 62 int uclass_find_device(enum uclass_id id, int index, struct udevice **devp); 74 int uclass_find_first_device(enum uclass_id id, struct udevice **devp); 86 int uclass_find_next_device(struct udevice **devp); 101 struct udevice **devp); 124 bool find_req_seq, struct udevice **devp); 140 struct udevice **devp); 156 struct udevice **devp); 173 const char *name, struct udevice **devp);
|
H A D | device.h | 427 bool find_req_seq, struct udevice **devp); 445 struct udevice **devp); 458 struct udevice **devp); 473 struct udevice **devp); 488 int device_find_global_by_ofnode(ofnode node, struct udevice **devp); 502 int device_get_global_by_ofnode(ofnode node, struct udevice **devp); 511 int device_find_first_child(struct udevice *parent, struct udevice **devp); 520 int device_find_next_child(struct udevice **devp); 537 struct udevice **devp); 549 struct udevice **devp); [all …]
|
/openbmc/linux/drivers/infiniband/hw/cxgb4/ |
H A D | device.c | 78 struct c4iw_dev *devp; member 970 struct c4iw_dev *devp; in c4iw_alloc() local 983 if (!devp) { in c4iw_alloc() 1015 devp->rdev.bar2_pa = pci_resource_start(devp->rdev.lldi.pdev, 2); in c4iw_alloc() 1017 devp->rdev.bar2_kva = ioremap_wc(devp->rdev.bar2_pa, in c4iw_alloc() 1029 devp->rdev.oc_mw_kva = ioremap_wc(devp->rdev.oc_mw_pa, in c4iw_alloc() 1039 devp->rdev.lldi.vr->ocq.start, devp->rdev.lldi.vr->ocq.size, in c4iw_alloc() 1040 devp->rdev.oc_mw_pa, devp->rdev.oc_mw_kva); in c4iw_alloc() 1059 devp->avail_ird = devp->rdev.lldi.max_ird_adapter; in c4iw_alloc() 1065 setup_debugfs(devp); in c4iw_alloc() [all …]
|
/openbmc/linux/arch/loongarch/pci/ |
H A D | pci.c | 88 struct pci_dev *devp = NULL; in pci_fixup_vgadev() local 90 while ((devp = pci_get_class(PCI_CLASS_DISPLAY_VGA << 8, devp))) { in pci_fixup_vgadev() 91 if (devp->vendor != PCI_VENDOR_ID_LOONGSON) { in pci_fixup_vgadev() 92 vga_set_default_device(devp); in pci_fixup_vgadev() 95 devp->vendor, devp->device); in pci_fixup_vgadev()
|
/openbmc/u-boot/drivers/block/ |
H A D | blk-uclass.c | 362 if (!*devp) in blk_first_device() 368 ret = uclass_find_next_device(devp); in blk_first_device() 371 } while (*devp); in blk_first_device() 384 ret = uclass_find_next_device(devp); in blk_next_device() 387 if (!*devp) in blk_next_device() 410 *devp = dev; in blk_find_device() 426 return device_probe(*devp); in blk_get_device() 497 *devp = dev; in blk_get_from_parent() 587 *devp = dev; in blk_create_device() 605 blksz, lba, devp); in blk_create_devicef() [all …]
|
/openbmc/u-boot/arch/arm/mach-rockchip/rk3399/ |
H A D | clk_rk3399.c | 13 static int rockchip_get_cruclk(struct udevice **devp) in rockchip_get_cruclk() argument 16 DM_GET_DRIVER(clk_rk3399), devp); in rockchip_get_cruclk() 34 static int rockchip_get_pmucruclk(struct udevice **devp) in rockchip_get_pmucruclk() argument 37 DM_GET_DRIVER(rockchip_rk3399_pmuclk), devp); in rockchip_get_pmucruclk()
|
/openbmc/u-boot/drivers/net/mdio/ |
H A D | mdio-uclass.c | 25 int mdio_device_get_from_phy(ofnode phy_node, struct udevice **devp) in mdio_device_get_from_phy() argument 30 return uclass_get_device_by_ofnode(UCLASS_MDIO, mdio_node, devp); in mdio_device_get_from_phy() 47 int mdio_device_get_from_eth(struct udevice *eth, struct udevice **devp) in mdio_device_get_from_eth() argument 54 return mdio_device_get_from_phy(phy_args.node, devp); in mdio_device_get_from_eth() 62 *devp = NULL; in mdio_device_get_from_eth()
|
/openbmc/u-boot/drivers/pci/ |
H A D | pci-uclass.c | 126 *devp = dev; in pci_bus_find_devfn() 174 *devp = dev; in pci_bus_find_devices() 195 *devp = NULL; in pci_find_device_id() 213 *devp = dev; in dm_pci_bus_find_device() 234 *devp = NULL; in dm_pci_find_device() 250 *devp = dev; in dm_pci_find_class() 254 *devp = NULL; in dm_pci_find_class() 672 *devp = NULL; in pci_find_and_bind_driver() 719 *devp = dev; in pci_find_and_bind_driver() 1092 *devp = NULL; in pci_find_next_device() [all …]
|
/openbmc/linux/drivers/infiniband/hw/hfi1/ |
H A D | device.c | 40 struct cdev *cdev, struct device **devp, in hfi1_cdev_init() argument 73 *devp = device; in hfi1_cdev_init() 77 void hfi1_cdev_cleanup(struct cdev *cdev, struct device **devp) in hfi1_cdev_cleanup() argument 79 struct device *device = *devp; in hfi1_cdev_cleanup() 83 *devp = NULL; in hfi1_cdev_cleanup()
|