Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mailbox: mtk-cmdq: Remove needless devm_kfree() calls

Memory allocated through device-managed functions doesn't need to be
explicitly freed, so these calls can be removed.

Signed-off-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Jassi Brar <jaswinder.singh@linaro.org>

authored by

Thierry Reding and committed by
Jassi Brar
ec1c674f 8aed5719

-8
-8
drivers/mailbox/mtk-cmdq-mailbox.c
··· 339 339 340 340 clk_unprepare(cmdq->clock); 341 341 342 - if (cmdq->mbox.chans) 343 - devm_kfree(&pdev->dev, cmdq->mbox.chans); 344 - 345 - if (cmdq->thread) 346 - devm_kfree(&pdev->dev, cmdq->thread); 347 - 348 - devm_kfree(&pdev->dev, cmdq); 349 - 350 342 return 0; 351 343 } 352 344