diff options
| author | James Morris <james.morris@microsoft.com> | 2019-01-10 11:41:59 -0800 |
|---|---|---|
| committer | James Morris <james.morris@microsoft.com> | 2019-01-10 11:41:59 -0800 |
| commit | 49e41801b335f64610bbfd23e8f2bbaf34d46276 (patch) | |
| tree | 4fbedacd1de1bbd4054f07f93031aebcb7b7a919 /include/linux/mailbox_controller.h | |
| parent | b49d564344f773d8afee982153c8493e5f2eaf38 (diff) | |
| parent | bfeffd155283772bbe78c6a05dec7c0128ee500c (diff) | |
Merge tag 'v5.0-rc1' into next-general
Linux 5.0-rc1
Sync to pick up LSM stacking work (which is based on -rc1).
Diffstat (limited to 'include/linux/mailbox_controller.h')
| -rw-r--r-- | include/linux/mailbox_controller.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/linux/mailbox_controller.h b/include/linux/mailbox_controller.h index 74deadb42d76..4994a438444c 100644 --- a/include/linux/mailbox_controller.h +++ b/include/linux/mailbox_controller.h @@ -24,6 +24,9 @@ struct mbox_chan; * transmission of data is reported by the controller via * mbox_chan_txdone (if it has some TX ACK irq). It must not * sleep. + * @flush: Called when a client requests transmissions to be blocking but + * the context doesn't allow sleeping. Typically the controller + * will implement a busy loop waiting for the data to flush out. * @startup: Called when a client requests the chan. The controller * could ask clients for additional parameters of communication * to be provided via client's chan_data. This call may @@ -46,6 +49,7 @@ struct mbox_chan; */ struct mbox_chan_ops { int (*send_data)(struct mbox_chan *chan, void *data); + int (*flush)(struct mbox_chan *chan, unsigned long timeout); int (*startup)(struct mbox_chan *chan); void (*shutdown)(struct mbox_chan *chan); bool (*last_tx_done)(struct mbox_chan *chan); @@ -131,4 +135,9 @@ void mbox_controller_unregister(struct mbox_controller *mbox); /* can sleep */ void mbox_chan_received_data(struct mbox_chan *chan, void *data); /* atomic */ void mbox_chan_txdone(struct mbox_chan *chan, int r); /* atomic */ +int devm_mbox_controller_register(struct device *dev, + struct mbox_controller *mbox); +void devm_mbox_controller_unregister(struct device *dev, + struct mbox_controller *mbox); + #endif /* __MAILBOX_CONTROLLER_H */ |
