1*4882a593SmuzhiyunU-Boot I2C 2*4882a593Smuzhiyun---------- 3*4882a593Smuzhiyun 4*4882a593SmuzhiyunU-Boot's I2C model has the concept of an offset within a chip (I2C target 5*4882a593Smuzhiyundevice). The offset can be up to 4 bytes long, but is normally 1 byte, 6*4882a593Smuzhiyunmeaning that offsets from 0 to 255 are supported by the chip. This often 7*4882a593Smuzhiyuncorresponds to register numbers. 8*4882a593Smuzhiyun 9*4882a593SmuzhiyunApart from the controller-specific I2C bindings, U-Boot supports a special 10*4882a593Smuzhiyunproperty which allows the chip offset length to be selected. 11*4882a593Smuzhiyun 12*4882a593SmuzhiyunOptional properties: 13*4882a593Smuzhiyun- u-boot,i2c-offset-len - length of chip offset in bytes. If omitted the 14*4882a593Smuzhiyun default value of 1 is used. 15*4882a593Smuzhiyun 16*4882a593Smuzhiyun 17*4882a593SmuzhiyunExample 18*4882a593Smuzhiyun------- 19*4882a593Smuzhiyun 20*4882a593Smuzhiyuni2c4: i2c@12ca0000 { 21*4882a593Smuzhiyun cros-ec@1e { 22*4882a593Smuzhiyun reg = <0x1e>; 23*4882a593Smuzhiyun compatible = "google,cros-ec"; 24*4882a593Smuzhiyun i2c-max-frequency = <100000>; 25*4882a593Smuzhiyun u-boot,i2c-offset-len = <0>; 26*4882a593Smuzhiyun ec-interrupt = <&gpx1 6 GPIO_ACTIVE_LOW>; 27*4882a593Smuzhiyun }; 28*4882a593Smuzhiyun}; 29