I2c producing crazy console messages [[Re: insanely-high interrupt rates -- PARTIAL resolution (Pi2)]]

Ian Lepore ian at freebsd.org
Fri Apr 19 16:04:47 UTC 2019


On Fri, 2019-04-19 at 13:32 +0200, Per Hedeland wrote:
> But anyway I would be *extremely* surprised if I saw them, since
> AFAIU
> the i2c bus per se has no concept of interrupts - you need to connect
> some other wire from the device to e.g. a gpio pin (with appropriate
> config) in order to generate interrupts - and I haven't done that.
> (The
> ads1015 does have an ALERT/RDY pin that could potentially be used for
> it, but since FreeBSD AFAIK doesn't have a way to deliver the
> interrupts to userland code, I had no interest in it.)

You're thinking about this all wrong.  The interrupts have nothing to
do with the i2c bus, but the i2c controller still uses interrupts to
signal things like "trasnfer done" or "fifo empty".  If there's nothing
on the bus, you don't end up doing any transfers, so you don't get any
spurious interrupts.

I can't reproduce this using RTC or EEPROM chips.  We use ADS1013 parts
at $work, I may have some around here somewhere.  If so, I'll see if I
can reproduce the problem using them.

-- Ian



More information about the freebsd-arm mailing list