Home
last modified time | relevance | path

Searched refs:emul (Results 1 – 25 of 38) sorted by relevance

12

/u-boot/drivers/power/pmic/
A Di2c_pmic_emul.c33 struct sandbox_i2c_pmic_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_pmic_read_data()
53 struct sandbox_i2c_pmic_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_pmic_write_data()
91 ret = sandbox_i2c_pmic_read_data(emul, msg->addr, in sandbox_i2c_pmic_xfer()
94 ret = sandbox_i2c_pmic_write_data(emul, msg->addr, in sandbox_i2c_pmic_xfer()
106 static int sandbox_i2c_pmic_of_to_plat(struct udevice *emul) in sandbox_i2c_pmic_of_to_plat() argument
108 struct sandbox_i2c_pmic_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_pmic_of_to_plat()
109 struct udevice *pmic_dev = i2c_emul_get_device(emul); in sandbox_i2c_pmic_of_to_plat()
117 static int sandbox_i2c_pmic_probe(struct udevice *emul) in sandbox_i2c_pmic_probe() argument
120 struct udevice *pmic_dev = i2c_emul_get_device(emul); in sandbox_i2c_pmic_probe()
134 reg_defaults = dev_read_u8_array_ptr(emul, "reg-defaults", in sandbox_i2c_pmic_probe()
[all …]
/u-boot/drivers/usb/host/
A Dusb-sandbox.c18 struct devrequest *setup, struct udevice *emul) in usbmon_trace() argument
34 debug(" %s", emul ? emul->name : "(no emul found)"); in usbmon_trace()
46 struct udevice *emul; in sandbox_submit_control() local
51 ret = usb_emul_find(bus, pipe, udev->portnr, &emul); in sandbox_submit_control()
52 usbmon_trace(bus, pipe, setup, emul); in sandbox_submit_control()
79 struct udevice *emul; in sandbox_submit_bulk() local
84 ret = usb_emul_find(bus, pipe, udev->portnr, &emul); in sandbox_submit_bulk()
85 usbmon_trace(bus, pipe, NULL, emul); in sandbox_submit_bulk()
105 struct udevice *emul; in sandbox_submit_int() local
110 ret = usb_emul_find(bus, pipe, udev->portnr, &emul); in sandbox_submit_int()
[all …]
/u-boot/drivers/axi/
A Daxi_sandbox.c28 struct udevice *emul; in axi_sandbox_read() local
32 ret = axi_sandbox_get_emul(bus, address, size, &emul); in axi_sandbox_read()
36 ops = axi_emul_get_ops(emul); in axi_sandbox_read()
40 return ops->read(emul, address, data, size); in axi_sandbox_read()
47 struct udevice *emul; in axi_sandbox_write() local
51 ret = axi_sandbox_get_emul(bus, address, size, &emul); in axi_sandbox_write()
55 ops = axi_emul_get_ops(emul); in axi_sandbox_write()
59 return ops->write(emul, address, data, size); in axi_sandbox_write()
A DMakefile9 obj-$(CONFIG_SANDBOX) += axi-emul-uclass.o
/u-boot/drivers/i2c/
A Di2c-emul-uclass.c38 struct udevice *i2c_emul_get_device(struct udevice *emul) in i2c_emul_get_device() argument
40 struct i2c_emul_uc_plat *uc_plat = dev_get_uclass_plat(emul); in i2c_emul_get_device()
48 struct udevice *emul; in i2c_emul_find() local
52 "sandbox,emul", &emul); in i2c_emul_find()
57 uc_plat = dev_get_uclass_plat(emul); in i2c_emul_find()
59 *emulp = emul; in i2c_emul_find()
61 return device_probe(emul); in i2c_emul_find()
A Dsandbox_i2c.c28 if (!plat->emul) { in get_emul()
29 ret = i2c_emul_find(dev, &plat->emul); in get_emul()
33 *devp = plat->emul; in get_emul()
34 *opsp = i2c_get_ops(plat->emul); in get_emul()
52 struct udevice *emul, *dev; in sandbox_i2c_xfer() local
64 ret = get_emul(dev, &emul, &ops); in sandbox_i2c_xfer()
81 return ops->xfer(emul, msg, nmsgs); in sandbox_i2c_xfer()
/u-boot/test/dm/
A Drtc.c62 struct udevice *dev, *emul; in dm_test_rtc_set_get() local
68 ut_assertok(i2c_emul_find(dev, &emul)); in dm_test_rtc_set_get()
69 ut_assert(emul != NULL); in dm_test_rtc_set_get()
102 offset = sandbox_i2c_rtc_set_offset(emul, false, 0); in dm_test_rtc_set_get()
115 sandbox_i2c_rtc_set_offset(emul, false, 0); in dm_test_rtc_set_get()
139 struct udevice *dev, *emul; in dm_test_rtc_read_write() local
163 ut_assertok(i2c_emul_find(dev, &emul)); in dm_test_rtc_read_write()
164 ut_assert(emul != NULL); in dm_test_rtc_read_write()
241 struct udevice *dev, *emul; in dm_test_rtc_reset() local
247 ut_assertok(i2c_emul_find(dev, &emul)); in dm_test_rtc_reset()
[all …]
/u-boot/drivers/usb/emul/
A Dusb-emul-uclass.c181 struct dm_usb_ops *ops = usb_get_emul_ops(emul); in usb_emul_control()
186 plat = dev_get_parent_plat(emul); in usb_emul_control()
189 debug("%s: dev=%s\n", __func__, emul->name); in usb_emul_control()
197 ret = device_probe(emul); in usb_emul_control()
206 debug(" ** set address %s %d\n", emul->name, in usb_emul_control()
220 ret = device_probe(emul); in usb_emul_control()
235 struct dm_usb_ops *ops = usb_get_emul_ops(emul); in usb_emul_bulk()
241 debug("%s: dev=%s\n", __func__, emul->name); in usb_emul_bulk()
242 ret = device_probe(emul); in usb_emul_bulk()
252 struct dm_usb_ops *ops = usb_get_emul_ops(emul); in usb_emul_int()
[all …]
A DMakefile9 obj-$(CONFIG_USB_EMUL) += usb-emul-uclass.o
/u-boot/arch/mips/
A Dconfig.mk7 32bit-emul := elf32btsmip
8 64bit-emul := elf64btsmip
16 32bit-emul := elf32ltsmip
17 64bit-emul := elf64ltsmip
26 KBUILD_LDFLAGS += -m $(32bit-emul)
33 KBUILD_LDFLAGS += -m$(64bit-emul)
/u-boot/arch/riscv/
A Dconfig.mk13 32bit-emul := elf32lriscv
14 64bit-emul := elf64lriscv
17 KBUILD_LDFLAGS += -m $(32bit-emul)
22 KBUILD_LDFLAGS += -m $(64bit-emul)
/u-boot/drivers/pci/
A Dpci_sandbox.c30 struct udevice *container, *emul; in sandbox_pci_write_config() local
33 ret = sandbox_pci_get_emul(bus, devfn, &container, &emul); in sandbox_pci_write_config()
36 ops = pci_get_emul_ops(emul); in sandbox_pci_write_config()
40 return ops->write_config(emul, offset, value, size); in sandbox_pci_write_config()
48 struct udevice *container, *emul; in sandbox_pci_read_config() local
54 ret = sandbox_pci_get_emul(bus, devfn, &container, &emul); in sandbox_pci_read_config()
73 ops = pci_get_emul_ops(emul); in sandbox_pci_read_config()
77 return ops->read_config(emul, offset, valuep, size); in sandbox_pci_read_config()
A Dpci-emul-uclass.c52 int sandbox_pci_get_client(struct udevice *emul, struct udevice **devp) in sandbox_pci_get_client() argument
54 struct pci_emul_uc_priv *upriv = dev_get_uclass_priv(emul); in sandbox_pci_get_client()
/u-boot/drivers/rtc/
A Di2c_rtc_emul.c125 static int sandbox_i2c_rtc_prepare_read(struct udevice *emul) in sandbox_i2c_rtc_prepare_read() argument
127 struct sandbox_i2c_rtc_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_rtc_prepare_read()
131 ret = sandbox_i2c_rtc_get(emul, &time); in sandbox_i2c_rtc_prepare_read()
146 static int sandbox_i2c_rtc_complete_write(struct udevice *emul) in sandbox_i2c_rtc_complete_write() argument
148 struct sandbox_i2c_rtc_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_rtc_complete_write()
160 ret = sandbox_i2c_rtc_set(emul, &time); in sandbox_i2c_rtc_complete_write()
167 static int sandbox_i2c_rtc_xfer(struct udevice *emul, struct i2c_msg *msg, in sandbox_i2c_rtc_xfer() argument
170 struct sandbox_i2c_rtc_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_rtc_xfer()
175 ret = sandbox_i2c_rtc_prepare_read(emul); in sandbox_i2c_rtc_xfer()
204 reset_time(emul); in sandbox_i2c_rtc_xfer()
[all …]
/u-boot/drivers/misc/
A Dp2sb_emul.c52 static int sandbox_p2sb_emul_read_config(const struct udevice *emul, in sandbox_p2sb_emul_read_config() argument
56 struct p2sb_emul_plat *plat = dev_get_plat(emul); in sandbox_p2sb_emul_read_config()
106 static int sandbox_p2sb_emul_write_config(struct udevice *emul, uint offset, in sandbox_p2sb_emul_write_config() argument
109 struct p2sb_emul_plat *plat = dev_get_plat(emul); in sandbox_p2sb_emul_write_config()
134 static int sandbox_p2sb_emul_find_bar(struct udevice *emul, unsigned int addr, in sandbox_p2sb_emul_find_bar() argument
137 struct p2sb_emul_plat *plat = dev_get_plat(emul); in sandbox_p2sb_emul_find_bar()
188 static int find_p2sb_channel(struct udevice *emul, uint offset, in find_p2sb_channel() argument
195 ret = sandbox_pci_get_client(emul, &p2sb); in find_p2sb_channel()
A Dswap_case.c86 static int sandbox_swap_case_read_ea(const struct udevice *emul, uint offset, in sandbox_swap_case_read_ea() argument
99 static int sandbox_swap_case_read_config(const struct udevice *emul, in sandbox_swap_case_read_config() argument
103 struct swap_case_plat *plat = dev_get_plat(emul); in sandbox_swap_case_read_config()
111 return sandbox_swap_case_read_ea(emul, offset, valuep, size); in sandbox_swap_case_read_config()
169 if (sandbox_swap_case_use_ea(emul)) in sandbox_swap_case_read_config()
175 if (sandbox_swap_case_use_ea(emul)) in sandbox_swap_case_read_config()
200 static int sandbox_swap_case_write_config(struct udevice *emul, uint offset, in sandbox_swap_case_write_config() argument
203 struct swap_case_plat *plat = dev_get_plat(emul); in sandbox_swap_case_write_config()
228 static int sandbox_swap_case_find_bar(struct udevice *emul, unsigned int addr, in sandbox_swap_case_find_bar() argument
231 struct swap_case_plat *plat = dev_get_plat(emul); in sandbox_swap_case_find_bar()
A Di2c_eeprom_emul.c73 static int sandbox_i2c_eeprom_xfer(struct udevice *emul, struct i2c_msg *msg, in sandbox_i2c_eeprom_xfer() argument
76 struct sandbox_i2c_flash *priv = dev_get_priv(emul); in sandbox_i2c_eeprom_xfer()
77 struct sandbox_i2c_flash_plat_data *plat = dev_get_plat(emul); in sandbox_i2c_eeprom_xfer()
/u-boot/drivers/spi/
A Dsandbox_spi.c75 struct udevice *emul; in sandbox_spi_xfer() local
98 ret = sandbox_spi_get_emul(state, bus, slave, &emul); in sandbox_spi_xfer()
104 ret = device_probe(emul); in sandbox_spi_xfer()
108 ops = spi_emul_get_ops(emul); in sandbox_spi_xfer()
109 ret = ops->xfer(emul, bitlen, dout, din, flags); in sandbox_spi_xfer()
/u-boot/drivers/power/acpi_pmc/
A Dpmc_emul.c46 static int sandbox_pmc_emul_read_config(const struct udevice *emul, uint offset, in sandbox_pmc_emul_read_config() argument
49 struct pmc_emul_plat *plat = dev_get_plat(emul); in sandbox_pmc_emul_read_config()
99 static int sandbox_pmc_emul_write_config(struct udevice *emul, uint offset, in sandbox_pmc_emul_write_config() argument
102 struct pmc_emul_plat *plat = dev_get_plat(emul); in sandbox_pmc_emul_write_config()
127 static int sandbox_pmc_emul_find_bar(struct udevice *emul, unsigned int addr, in sandbox_pmc_emul_find_bar() argument
130 struct pmc_emul_plat *plat = dev_get_plat(emul); in sandbox_pmc_emul_find_bar()
/u-boot/arch/sandbox/dts/
A Dsandbox.dtsi86 sandbox,emul = <&emul_eeprom>;
92 sandbox,emul = <&emul0>;
103 i2c_emul: emul {
106 emul_eeprom: emul-eeprom {
148 sandbox,emul = <&pmc_emul>;
159 sandbox,emul = <&swap_case_emul>;
163 emul {
165 pmc_emul: emul@1e,0 {
166 compatible = "sandbox,pmc-emul";
168 swap_case_emul: emul@1f,0 {
[all …]
A Dtest.dts589 sandbox,emul = <&emul0>;
595 sandbox,emul = <&emul1>;
598 i2c_emul: emul {
601 emul_eeprom: emul-eeprom {
616 sandbox,emul = <&emul_pmic0>;
621 sandbox,emul = <&emul_pmic1>;
777 sandbox,emul = <&p2sb_emul>;
815 p2sb_emul: emul@2,0 {
818 pmc_emul1e: emul@1e,0 {
1027 compatible = "mux-emul";
[all …]
/u-boot/drivers/mtd/spi/
A Dsandbox.c130 struct udevice *emul; in sandbox_sf_probe() local
135 ret = sandbox_spi_get_emul(state, bus, dev, &emul); in sandbox_sf_probe()
524 struct udevice *emul; in sandbox_sf_bind_emul() local
541 ret = device_bind(bus, drv, str, NULL, node, &emul); in sandbox_sf_bind_emul()
548 state->spi[busnum][cs].emul = emul; in sandbox_sf_bind_emul()
557 dev = state->spi[busnum][cs].emul; in sandbox_sf_unbind_emul()
560 state->spi[busnum][cs].emul = NULL; in sandbox_sf_unbind_emul()
573 if (!info->emul) { in sandbox_spi_get_emul()
585 *emulp = info->emul; in sandbox_spi_get_emul()
/u-boot/doc/device-tree-bindings/pmic/
A Dsandbox.txt16 Required PMIC's "emul" subnode, with property:
32 emul {
/u-boot/doc/driver-model/
A Dpci-info.rst122 sandbox,emul = <&emul_1f>;
124 pci-emul {
125 compatible = "sandbox,pci-emul-parent";
126 emul_1f: emul@1f,0 {
136 The pci-emul node should go outside the pci bus node, since otherwise it will
143 `- emul@1f,0 @ 05c662c8
/u-boot/arch/sandbox/include/asm/
A Dstate.h39 struct udevice *emul; member

Completed in 22 milliseconds

12