Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit e68b1130 authored by Cong Ding's avatar Cong Ding Committed by Vinod Koul
Browse files

dma: of-dma.c: fix memory leakage



The memory allocated to ofdma might be a leakage when error occurs.

Signed-off-by: default avatarCong Ding <dinggnu@gmail.com>
Signed-off-by: default avatarVinod Koul <vinod.koul@intel.com>
parent 877e86f2
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -107,6 +107,7 @@ int of_dma_controller_register(struct device_node *np,
	if (!nbcells) {
		pr_err("%s: #dma-cells property is missing or invalid\n",
		       __func__);
		kfree(ofdma);
		return -EINVAL;
	}