Thread (21 messages) flat view 21 messages, 7 authors, 2019-02-09
STALE2783d

Revision rfc of 4 in this series.

Revisions (4)
  1. rfc [diff vs current]
  2. rfc [diff vs current]
  3. rfc current
  4. rfc [diff vs current]

Re: [RFC PATCH 4/4] i2c: core: introduce master_xfer_irqless callback

From: Wolfram Sang <hidden>
Date: 2018-09-20 22:55:40
Also in: linux-arm-kernel, linux-omap, linux-renesas-soc

On Thu, Sep 20, 2018 at 07:41:05PM +0200, Peter Rosin wrote:
On 2018-09-20 18:14, Wolfram Sang wrote:
quoted
We had the request to access devices very late when interrupts are not
available anymore multiple times now. Mostly to prepare shutdown or
The first sentence is a bit backwards, I'd rephrase like so:

Multiple times now we've had the request to access devices very late, when
interrupts are no longer available.
Ok. Don't see much difference, but I don't mind.
quoted
reboot. Allow adapters to specify a specific callback for this case.
Note that we fall back to the generic master_xfer callback if this new
irqless one is not present. This is intentional to preserve the previous
behaviour and avoid regressions. Because there are drivers not using
interrupts or because it might have worked "accidently" before.
accidentally
Thanks.
quoted
@@ -498,6 +498,8 @@ i2c_register_board_info(int busnum, struct i2c_board_info const *info,
  * @master_xfer: Issue a set of i2c transactions to the given I2C adapter
  *   defined by the msgs array, with num messages available to transfer via
  *   the adapter specified by adap.
+ * @master_xfer_irqless: same as master_xfer. Yet, not using any interrupts
"Same" (with capital 'S') to match the other entries. Also, should it
not be @master_xfer to help the tools do the right thing?
I'll check. You are probably right.
quoted
+ *   so e.g. PMICs can be accessed very late before shutdown
Trailing period.

I'm fine with this change, but should it not wait until there is a user?
(I think there is one in the wings, so that's a very weak objection...)
As I mentioned in the cover-letter, this series is RFC because it is
mainly meant as assistance for Stefan, so he could base his imx patches
on top of it. Or the TI folks for their omap driver.

I somewhen need to implement irqless transfers for the i2c-sh_mobile
driver. But this may take a while, so I hope the others are first. And
yes, I won't apply this series without a user and proper testing.

Thanks for the review, Peter!
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help