summaryrefslogtreecommitdiffstats
path: root/drivers/pinctrl/devicetree.h
diff options
context:
space:
mode:
authorJulia Lawall <julia@diku.dk>2012-08-04 23:52:33 +0000
committerAlexander Graf <agraf@suse.de>2012-10-05 23:38:55 +0200
commit12ecd9570d8941c15602a11725ec9b0ede48d6c2 (patch)
treee5a73f8d08601a3ef459fcf93a9e6f4ed0cb0611 /drivers/pinctrl/devicetree.h
parent55b665b0263ae88a776071306ef1eee4b769016b (diff)
downloadblackbird-op-linux-12ecd9570d8941c15602a11725ec9b0ede48d6c2.tar.gz
blackbird-op-linux-12ecd9570d8941c15602a11725ec9b0ede48d6c2.zip
arch/powerpc/kvm/e500_tlb.c: fix error return code
Convert a 0 error return code to a negative one, as returned elsewhere in the function. A new label is also added to avoid freeing things that are known to not yet be allocated. A simplified version of the semantic match that finds the first problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @@ identifier ret; expression e,e1,e2,e3,e4,x; @@ ( if (\(ret != 0\|ret < 0\) || ...) { ... return ...; } | ret = 0 ) ... when != ret = e1 *x = \(kmalloc\|kzalloc\|kcalloc\|devm_kzalloc\|ioremap\|ioremap_nocache\|devm_ioremap\|devm_ioremap_nocache\)(...); ... when != x = e2 when != ret = e3 *if (x == NULL || ...) { ... when != ret = e4 * return ret; } // </smpl> Signed-off-by: Julia Lawall <julia@diku.dk> Signed-off-by: Alexander Graf <agraf@suse.de>
Diffstat (limited to 'drivers/pinctrl/devicetree.h')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud