]> git.baikalelectronics.ru Git - kernel.git/commit
ARM: PL08x: fix a leak when preparing TXDs
authorRussell King - ARM Linux <linux@arm.linux.org.uk>
Mon, 3 Jan 2011 22:31:45 +0000 (22:31 +0000)
committerDan Williams <dan.j.williams@intel.com>
Wed, 5 Jan 2011 03:16:10 +0000 (19:16 -0800)
commitc2022fb6d0167ba094f4e2a6501867129fcbb432
tree70d6d14b7be6543cbfe777a523c75dc0a332c402
parent7f4c3123e56615fc7b320d117b363ad80672a558
ARM: PL08x: fix a leak when preparing TXDs

If we fail to allocate the LLI, the prep_* function will return NULL.
However, the TXD we allocated will not be placed on any list, nor
will it be freed - we'll just drop all references to it.  Make sure
we free it rather than leaking TXDs.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Acked-by: Linus Walleij <linus.walleij@stericsson.com>
Signed-off-by: Dan Williams <dan.j.williams@intel.com>
drivers/dma/amba-pl08x.c