]> git.baikalelectronics.ru Git - kernel.git/commit
mailbox: Add device-managed registration functions
authorThierry Reding <treding@nvidia.com>
Thu, 20 Dec 2018 17:19:44 +0000 (18:19 +0100)
committerJassi Brar <jaswinder.singh@linaro.org>
Fri, 21 Dec 2018 22:49:25 +0000 (16:49 -0600)
commitfbc47842505e9e8d3666f911baa01ffa2992c5ad
tree48a3a80b84cc3a18b1589454d129c8b70cf18841
parente3bc3e502b33dc7bae05a0fc88d186f01679f01c
mailbox: Add device-managed registration functions

Add device-managed equivalents of the mbox_controller_register() and
mbox_controller_unregister() functions that can be used to have the
devres infrastructure automatically unregister mailbox controllers on
driver probe failure or driver removal. This can help remove a lot of
boiler plate code from drivers.

Reviewed-by: Bjorn Andersson <bjorn.andersson@linaro.org>
Reviewed-by: Sudeep Holla <sudeep.holla@arm.com>
Signed-off-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org>
drivers/mailbox/mailbox.c
include/linux/mailbox_controller.h