Lines Matching refs:offset
29 static u8 lpc_read_bytes(unsigned int offset, unsigned int length, u8 *dest) in lpc_read_bytes() argument
35 dest[i] = inb(offset + i); in lpc_read_bytes()
43 static u8 lpc_write_bytes(unsigned int offset, unsigned int length, u8 *msg) in lpc_write_bytes() argument
49 outb(msg[i], offset + i); in lpc_write_bytes()
59 u8 cros_ec_lpc_read_bytes(unsigned int offset, unsigned int length, u8 *dest) in cros_ec_lpc_read_bytes() argument
65 if (offset >= MEC_EMI_RANGE_START && offset <= MEC_EMI_RANGE_END) { in cros_ec_lpc_read_bytes()
67 if (WARN_ON(offset + length - 1 > MEC_EMI_RANGE_END)) in cros_ec_lpc_read_bytes()
70 return cros_ec_lpc_io_bytes_mec(MEC_IO_READ, offset, length, in cros_ec_lpc_read_bytes()
74 if (WARN_ON(offset + length > MEC_EMI_RANGE_START && in cros_ec_lpc_read_bytes()
75 offset < MEC_EMI_RANGE_START)) in cros_ec_lpc_read_bytes()
78 return lpc_read_bytes(offset, length, dest); in cros_ec_lpc_read_bytes()
81 u8 cros_ec_lpc_write_bytes(unsigned int offset, unsigned int length, u8 *msg) in cros_ec_lpc_write_bytes() argument
87 if (offset >= MEC_EMI_RANGE_START && offset <= MEC_EMI_RANGE_END) { in cros_ec_lpc_write_bytes()
89 if (WARN_ON(offset + length - 1 > MEC_EMI_RANGE_END)) in cros_ec_lpc_write_bytes()
92 return cros_ec_lpc_io_bytes_mec(MEC_IO_WRITE, offset, length, in cros_ec_lpc_write_bytes()
96 if (WARN_ON(offset + length > MEC_EMI_RANGE_START && in cros_ec_lpc_write_bytes()
97 offset < MEC_EMI_RANGE_START)) in cros_ec_lpc_write_bytes()
100 return lpc_write_bytes(offset, length, msg); in cros_ec_lpc_write_bytes()
115 u8 cros_ec_lpc_read_bytes(unsigned int offset, unsigned int length, u8 *dest) in cros_ec_lpc_read_bytes() argument
117 return lpc_read_bytes(offset, length, dest); in cros_ec_lpc_read_bytes()
120 u8 cros_ec_lpc_write_bytes(unsigned int offset, unsigned int length, u8 *msg) in cros_ec_lpc_write_bytes() argument
122 return lpc_write_bytes(offset, length, msg); in cros_ec_lpc_write_bytes()