'\" t .\" Title: struct i2c_adapter_quirks .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.79.1 .\" Date: January 2017 .\" Manual: I2C and SMBus Subsystem .\" Source: Kernel Hackers Manual 4.8.15 .\" Language: English .\" .TH "STRUCT I2C_ADAPTER_Q" "9" "January 2017" "Kernel Hackers Manual 4\&.8\&." "I2C and SMBus Subsystem" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" struct_i2c_adapter_quirks \- describe flaws of an i2c adapter .SH "SYNOPSIS" .sp .nf struct i2c_adapter_quirks { u64 flags; int max_num_msgs; u16 max_write_len; u16 max_read_len; u16 max_comb_1st_msg_len; u16 max_comb_2nd_msg_len; }; .fi .SH "MEMBERS" .PP flags .RS 4 see I2C_AQ_* for possible flags and read below .RE .PP max_num_msgs .RS 4 maximum number of messages per transfer .RE .PP max_write_len .RS 4 maximum length of a write message .RE .PP max_read_len .RS 4 maximum length of a read message .RE .PP max_comb_1st_msg_len .RS 4 maximum length of the first msg in a combined message .RE .PP max_comb_2nd_msg_len .RS 4 maximum length of the second msg in a combined message .RE .SH "DESCRIPTION" .PP Note about combined messages: Some I2C controllers can only send one message per transfer, plus something called combined message or write\-then\-read\&. This is (usually) a small write message followed by a read message and barely enough to access register based devices like EEPROMs\&. There is a flag to support this mode\&. It implies max_num_msg = 2 and does the length checks with max_comb_*_len because combined message mode usually has its own limitations\&. Because of HW implementations, some controllers can actually do write\-then\-anything or other variants\&. To support that, write\-then\-read has been broken out into smaller bits like write\-first and read\-second which can be combined as needed\&. .SH "COPYRIGHT" .br