From: Aditya Pakki Date: Fri, 28 Dec 2018 20:11:19 +0000 (-0600) Subject: dmaengine: qcom_hidma: Check for driver register failure X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=a474b3f0428d6b02a538aa10b3c3b722751cb382;p=linux.git dmaengine: qcom_hidma: Check for driver register failure While initializing the driver, the function platform_driver_register can fail and return an error. Consistent with other invocations, this patch returns the error upstream. Signed-off-by: Aditya Pakki Acked-by: Sinan Kaya Signed-off-by: Vinod Koul --- diff --git a/drivers/dma/qcom/hidma_mgmt.c b/drivers/dma/qcom/hidma_mgmt.c index d64edeb6771a9..681de12f4c679 100644 --- a/drivers/dma/qcom/hidma_mgmt.c +++ b/drivers/dma/qcom/hidma_mgmt.c @@ -423,9 +423,8 @@ static int __init hidma_mgmt_init(void) hidma_mgmt_of_populate_channels(child); } #endif - platform_driver_register(&hidma_mgmt_driver); + return platform_driver_register(&hidma_mgmt_driver); - return 0; } module_init(hidma_mgmt_init); MODULE_LICENSE("GPL v2");