summaryrefslogtreecommitdiff
path: root/scripts/dtc/pylibfdt
diff options
context:
space:
mode:
authorAndrew Goodbody <andrew.goodbody@linaro.org>2025-08-01 10:54:04 +0100
committerMichael Trimarchi <michael@amarulasolutions.com>2025-08-03 10:22:04 +0200
commitebf8aaf7afdeb306b0fb85be2226a00aef18162f (patch)
treec5c8f4fbdf9aeb36e8e12a50caa2cfd81ba8ba91 /scripts/dtc/pylibfdt
parent56372f834c717402882112ba888943421020b6d5 (diff)
mtd: rawnand: cortina_nand: Fix -ENOMEM detection
In init_nand_dma there was code to detect failure to allocate memory but it had two problems. Firstly the 2nd clause when info->tx_desc was NULL attempted to free info->tx_desc when it should be freeing info->rx_desc. Secondly there was no detection of both allocations failing, arguably the more likely scenario. Refactor the code to simplify it and just fail as soon as either allocation fails. This issue was found by Smatch. Signed-off-by: Andrew Goodbody <andrew.goodbody@linaro.org> Reviewed-by: Michael Trimarchi <michael@amarulasolutions.com>
Diffstat (limited to 'scripts/dtc/pylibfdt')
0 files changed, 0 insertions, 0 deletions