From: Rasmus Villemoes Date: Thu, 28 Nov 2019 14:55:47 +0000 (+0100) Subject: soc: fsl: qe: drop pointless check in qe_sdma_init() X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=71352b8c4016fbf24e5244877c2ebf93eb9d4c73;p=linux.git soc: fsl: qe: drop pointless check in qe_sdma_init() The sdma member of struct qe_immap is not at offset zero, so even if qe_immr wasn't initialized yet (i.e. NULL), &qe_immr->sdma would not be NULL. Reviewed-by: Timur Tabi Signed-off-by: Rasmus Villemoes Signed-off-by: Li Yang --- diff --git a/drivers/soc/fsl/qe/qe.c b/drivers/soc/fsl/qe/qe.c index 5bf279c679ef3..96c2057d8d8e0 100644 --- a/drivers/soc/fsl/qe/qe.c +++ b/drivers/soc/fsl/qe/qe.c @@ -367,9 +367,6 @@ static int qe_sdma_init(void) struct sdma __iomem *sdma = &qe_immr->sdma; static s32 sdma_buf_offset = -ENOMEM; - if (!sdma) - return -ENODEV; - /* allocate 2 internal temporary buffers (512 bytes size each) for * the SDMA */ if (sdma_buf_offset < 0) {