summaryrefslogtreecommitdiff
path: root/samples
diff options
context:
space:
mode:
authorStefan Lengfeld <contact@stefanchrist.eu>2020-12-08 20:53:38 +0200
committerIgor Opaniuk <igor.opaniuk@toradex.com>2020-12-08 21:05:25 +0200
commit5817454449802e0b55f914e4fa21049cbfe780d0 (patch)
tree79affa00b528dd63d22f5ea0637a648183f0cbc4 /samples
parentd0cdd508dba642622990f3ca9c01a0b6521ec1fd (diff)
i2c: imx: implement master_xfer_atomic callback
Rework the read and write code paths in the driver to support operation in atomic contexts. To achieve this, the driver must not rely on IRQs and not call schedule(), e.g. via a sleep routine, in these cases. With this patch the driver supports normal operation, DMA transfers and now the polling mode or also called sleep-free or IRQ-less operation. It makes the code not simpler or easier to read, but atomic I2C transfers are needed on some hardware configurations, e.g. to trigger reboots on an external PMIC chip. Related-to: ELB-3308 Related-to: ELB-1403 Signed-off-by: Stefan Lengfeld <contact@stefanchrist.eu> [m.felsch@pengutronix.de: integrate https://patchwork.ozlabs.org/patch/1085943/ review feedback] [m.felsch@pengutronix.de: adapt commit message] Signed-off-by: Marco Felsch <m.felsch@pengutronix.de> Acked-by: Oleksij Rempel <o.rempel@pengutronix.de> Reviewed-by: Stefan Agner <stefan@agner.ch> Tested-by: Stefan Lengfeld <contact@stefanchrist.eu> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> (cherry picked from commit 3a5ee18d2a32bda6b9a1260136f6805848e3839d)
Diffstat (limited to 'samples')
0 files changed, 0 insertions, 0 deletions