i2c: mux: pca954x: call request irq after adding mux segments
authorPhil Reid <preid@electromag.com.au>
Thu, 24 Aug 2017 09:31:05 +0000 (17:31 +0800)
committerWolfram Sang <wsa@the-dreams.de>
Sat, 28 Oct 2017 21:43:04 +0000 (23:43 +0200)
commit148baf1ddfb65019ee510ba2a76c2e7cd9752982
tree03c452b51fcf17b1ae14106c505bc3c29693eec2
parentf8756c67b3de71a46255aa478ab590ff28e60ac9
i2c: mux: pca954x: call request irq after adding mux segments

The pca954x device do not have the ability to mask interrupts. For
i2c slave devices that also don't have masking ability (eg ltc1760
smbalert output) delay registering the irq until after the mux
segments have been configured. During the mux add_adaptor call the
core i2c system can register an smbalert handler which would then
be called immediately when the irq is registered. This smbalert
handler will then clear the pending irq.

This removes the need for the irq_mask / irq_unmask calls that were
original used to do this.

Signed-off-by: Phil Reid <preid@electromag.com.au>
Acked-by: Peter Rosin <peda@axentia.se>
Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
drivers/i2c/muxes/i2c-mux-pca954x.c