On Wed, Nov 13, 2019 at 9:13 AM Wolfram Sang <wsa@xxxxxxxxxxxxx> wrote: > > Hi, > > > +/* Helper function to check I2C-transferred data. */ > > I assume I2C is just one of the first users and other users like SPI > will be implemented as time passes? Otherwise I would wonder why I2C > needs to be handled with this special function. Initially this was just because I2C errors kept firing in the default build. v3 adds DMA support to KMSAN, so I think we don't need to specially handle i2c. > > +void kmsan_handle_i2c_transfer(struct i2c_msg *msgs, int num) > > +{ > > + int i; > > + > > + if (!msgs) > > + return; > > Can go. You call this function from __i2c_transfer and this checks for > valid 'msgs'. > > Kind regards, > > Wolfram > -- Alexander Potapenko Software Engineer Google Germany GmbH Erika-Mann-Straße, 33 80636 München Geschäftsführer: Paul Manicle, Halimah DeLaine Prado Registergericht und -nummer: Hamburg, HRB 86891 Sitz der Gesellschaft: Hamburg