Home
last modified time | relevance | path

Searched refs:nmsgs (Results 1 – 25 of 56) sorted by relevance

123

/openbmc/u-boot/drivers/i2c/
H A Dxilinx_xiic.c107 struct i2c_msg *msg, int nmsgs) in xiic_read_rx() argument
141 struct i2c_msg *msg, int nmsgs) in xiic_fill_tx_fifo() argument
152 if (pos == len && nmsgs == 1) { in xiic_fill_tx_fifo()
161 u16 flags, u32 len, u32 nmsgs) in xilinx_xiic_set_addr() argument
171 if (nmsgs == 1 && len == 0) in xilinx_xiic_set_addr()
180 u32 nmsgs) in xilinx_xiic_read_common() argument
200 xilinx_xiic_set_addr(dev, msg->addr, msg->flags, msg->len, nmsgs); in xilinx_xiic_read_common()
204 writew((msg->len & 0xff) | ((nmsgs == 1) ? XIIC_TX_DYN_STOP_MASK : 0), in xilinx_xiic_read_common()
207 if (nmsgs == 1) in xilinx_xiic_read_common()
211 return xiic_read_rx(priv, msg, nmsgs); in xilinx_xiic_read_common()
[all …]
H A Dintel_i2c.c204 static int intel_i2c_xfer(struct udevice *bus, struct i2c_msg *msg, int nmsgs) in intel_i2c_xfer() argument
209 debug("i2c_xfer: %d messages\n", nmsgs); in intel_i2c_xfer()
217 if (nmsgs > 2 || nmsgs == 0) { in intel_i2c_xfer()
222 omsg = nmsgs == 1 ? &dummy : msg; in intel_i2c_xfer()
223 dmsg = nmsgs == 1 ? msg : msg + 1; in intel_i2c_xfer()
H A Dcros_ec_ldo.c20 int nmsgs) in cros_ec_ldo_xfer() argument
22 bool is_read = nmsgs > 1; in cros_ec_ldo_xfer()
29 if (!nmsgs || !msg->len || (msg->flags & I2C_M_RD)) { in cros_ec_ldo_xfer()
H A Di2c-cdns.c399 int nmsgs) in cdns_i2c_xfer() argument
406 int num_msgs = nmsgs; in cdns_i2c_xfer()
410 if (nmsgs > 1) { in cdns_i2c_xfer()
418 for (count = 0; (count < nmsgs - 1) && hold_quirk; count++) { in cdns_i2c_xfer()
431 debug("i2c_xfer: %d messages\n", nmsgs); in cdns_i2c_xfer()
433 nmsgs > 0; nmsgs--, msg++) { in cdns_i2c_xfer()
444 nmsgs = num_msgs; in cdns_i2c_xfer()
H A Dsandbox_i2c.c48 int nmsgs) in sandbox_i2c_xfer() argument
74 is_read = nmsgs > 1; in sandbox_i2c_xfer()
81 return ops->xfer(emul, msg, nmsgs); in sandbox_i2c_xfer()
H A Dast_i2c.c269 static int ast_i2c_xfer(struct udevice *dev, struct i2c_msg *msg, int nmsgs) in ast_i2c_xfer() argument
277 debug("i2c_xfer: %d messages\n", nmsgs); in ast_i2c_xfer()
278 for (; nmsgs > 0; nmsgs--, msg++) { in ast_i2c_xfer()
283 msg->len, (nmsgs == 1)); in ast_i2c_xfer()
288 msg->len, (nmsgs == 1)); in ast_i2c_xfer()
H A Di2c-uniphier.c151 int nmsgs) in uniphier_i2c_xfer() argument
157 for (; nmsgs > 0; nmsgs--, msg++) { in uniphier_i2c_xfer()
159 stop = nmsgs > 1 && msg[1].flags & I2C_M_RD ? false : true; in uniphier_i2c_xfer()
H A Dlpc32xx_i2c.c298 int nmsgs)
309 if (nmsgs > 2 || nmsgs == 0) {
314 omsg = nmsgs == 1 ? &dummy : msg;
315 dmsg = nmsgs == 1 ? msg : msg + 1;
H A Dtegra186_bpmp_i2c.c37 int nmsgs) in tegra186_bpmp_i2c_xfer() argument
49 for (i = 0; i < nmsgs; i++) { in tegra186_bpmp_i2c_xfer()
78 for (i = 0; i < nmsgs; i++) { in tegra186_bpmp_i2c_xfer()
H A Dcros_ec_tunnel.c25 int nmsgs) in cros_ec_i2c_xfer() argument
29 return cros_ec_i2c_tunnel(dev->parent, i2c_bus->remote_bus, msg, nmsgs); in cros_ec_i2c_xfer()
H A Dihs_i2c.c294 static int ihs_i2c_xfer(struct udevice *bus, struct i2c_msg *msg, int nmsgs) in ihs_i2c_xfer() argument
303 if (nmsgs > 2 || nmsgs == 0) { in ihs_i2c_xfer()
308 omsg = nmsgs == 1 ? &dummy : msg; in ihs_i2c_xfer()
309 dmsg = nmsgs == 1 ? msg : msg + 1; in ihs_i2c_xfer()
H A Dast2600_i2c.c231 static int ast2600_i2c_xfer(struct udevice *dev, struct i2c_msg *msg, int nmsgs) in ast2600_i2c_xfer() argument
239 for (; nmsgs > 0; nmsgs--, msg++) { in ast2600_i2c_xfer()
244 msg->len, (nmsgs == 1)); in ast2600_i2c_xfer()
249 msg->len, (nmsgs == 1)); in ast2600_i2c_xfer()
H A Dtegra_i2c.c474 int nmsgs) in tegra_i2c_xfer() argument
479 debug("i2c_xfer: %d messages\n", nmsgs); in tegra_i2c_xfer()
480 for (; nmsgs > 0; nmsgs--, msg++) { in tegra_i2c_xfer()
481 bool next_is_read = nmsgs > 1 && (msg[1].flags & I2C_M_RD); in tegra_i2c_xfer()
H A Di2c-uniphier-f.c248 int nmsgs) in uniphier_fi2c_xfer() argument
258 for (; nmsgs > 0; nmsgs--, msg++) { in uniphier_fi2c_xfer()
260 stop = nmsgs > 1 && msg[1].flags & I2C_M_RD ? false : true; in uniphier_fi2c_xfer()
H A Di2c-gpio.c254 static int i2c_gpio_xfer(struct udevice *dev, struct i2c_msg *msg, int nmsgs) in i2c_gpio_xfer() argument
259 for (; nmsgs > 0; nmsgs--, msg++) { in i2c_gpio_xfer()
260 bool next_is_read = nmsgs > 1 && (msg[1].flags & I2C_M_RD); in i2c_gpio_xfer()
H A Di2c-versatile.c211 struct i2c_msg *msg, int nmsgs) in versatile_i2c_xfer() argument
216 for ( ; nmsgs > 0; nmsgs--, msg++) { in versatile_i2c_xfer()
H A Dmv_i2c.c536 static int mv_i2c_xfer(struct udevice *bus, struct i2c_msg *msg, int nmsgs) in mv_i2c_xfer() argument
547 if (nmsgs > 2 || nmsgs == 0) { in mv_i2c_xfer()
552 omsg = nmsgs == 1 ? &dummy : msg; in mv_i2c_xfer()
553 dmsg = nmsgs == 1 ? msg : msg + 1; in mv_i2c_xfer()
/openbmc/linux/drivers/i2c/
H A Di2c-dev.c236 unsigned nmsgs, struct i2c_msg *msgs) in i2cdev_ioctl_rdwr() argument
241 data_ptrs = kmalloc_array(nmsgs, sizeof(u8 __user *), GFP_KERNEL); in i2cdev_ioctl_rdwr()
248 for (i = 0; i < nmsgs; i++) { in i2cdev_ioctl_rdwr()
297 res = i2c_transfer(client->adapter, msgs, nmsgs); in i2cdev_ioctl_rdwr()
443 if (!rdwr_arg.msgs || rdwr_arg.nmsgs == 0) in i2cdev_ioctl()
450 if (rdwr_arg.nmsgs > I2C_RDWR_IOCTL_MAX_MSGS) in i2cdev_ioctl()
454 rdwr_arg.nmsgs, sizeof(struct i2c_msg)); in i2cdev_ioctl()
458 return i2cdev_ioctl_rdwr(client, rdwr_arg.nmsgs, rdwr_pa); in i2cdev_ioctl()
516 u32 nmsgs; member
538 if (!rdwr_arg.msgs || rdwr_arg.nmsgs == 0) in compat_i2cdev_ioctl()
[all …]
H A Di2c-core-smbus.c335 int nmsgs = read_write == I2C_SMBUS_READ ? 2 : 1; in i2c_smbus_xfer_emulated() local
361 nmsgs = 1; in i2c_smbus_xfer_emulated()
367 nmsgs = 1; in i2c_smbus_xfer_emulated()
388 nmsgs = 2; /* Special case */ in i2c_smbus_xfer_emulated()
415 nmsgs = 2; /* Another special case */ in i2c_smbus_xfer_emulated()
459 if (nmsgs == 1) /* Write only */ in i2c_smbus_xfer_emulated()
465 if (msg[nmsgs - 1].flags & I2C_M_RD) in i2c_smbus_xfer_emulated()
466 msg[nmsgs - 1].len++; in i2c_smbus_xfer_emulated()
469 status = __i2c_transfer(adapter, msg, nmsgs); in i2c_smbus_xfer_emulated()
472 if (status != nmsgs) { in i2c_smbus_xfer_emulated()
[all …]
/openbmc/linux/drivers/i2c/busses/
H A Di2c-xiic.c86 unsigned int nmsgs; member
586 if (i2c->nmsgs == 1) { in xiic_read_rx()
634 if (!xiic_tx_space(i2c) && i2c->nmsgs == 1) { in xiic_fill_tx_fifo()
662 i2c->nmsgs = 0; in xiic_wakeup()
691 i2c->tx_msg, i2c->nmsgs); in xiic_process()
748 __func__, i2c->nmsgs); in xiic_process()
754 if (i2c->nmsgs > 1) { in xiic_process()
755 i2c->nmsgs--; in xiic_process()
781 __func__, i2c->nmsgs); in xiic_process()
785 if (i2c->nmsgs > 1 && (pend & XIIC_INTR_TX_EMPTY_MASK)) { in xiic_process()
[all …]
H A Di2c-kempld.c61 int nmsgs; member
155 i2c->nmsgs--; in kempld_i2c_process()
160 if (i2c->nmsgs) { in kempld_i2c_process()
196 i2c->nmsgs = num; in kempld_i2c_xfer()
/openbmc/u-boot/drivers/power/pmic/
H A Di2c_pmic_emul.c82 int nmsgs) in sandbox_i2c_pmic_xfer() argument
86 for (; nmsgs > 0; nmsgs--, msg++) { in sandbox_i2c_pmic_xfer()
87 bool next_is_read = nmsgs > 1 && (msg[1].flags & I2C_M_RD); in sandbox_i2c_pmic_xfer()
/openbmc/u-boot/drivers/misc/
H A Di2c_eeprom_emul.c48 int nmsgs) in sandbox_i2c_eeprom_xfer() argument
55 for (; nmsgs > 0; nmsgs--, msg++) { in sandbox_i2c_eeprom_xfer()
/openbmc/u-boot/include/
H A Di2c.h130 uint nmsgs; member
217 int dm_i2c_xfer(struct udevice *dev, struct i2c_msg *msg, int nmsgs);
403 int (*xfer)(struct udevice *bus, struct i2c_msg *msg, int nmsgs);
570 void i2c_dump_msgs(struct i2c_msg *msg, int nmsgs);
/openbmc/u-boot/drivers/rtc/
H A Di2c_rtc_emul.c165 int nmsgs) in sandbox_i2c_rtc_xfer() argument
175 for (; nmsgs > 0; nmsgs--, msg++) { in sandbox_i2c_rtc_xfer()

123