summaryrefslogtreecommitdiff
path: root/crypto/twofish_generic.c
diff options
context:
space:
mode:
authorHimangi Saraogi <himangi774@gmail.com>2014-05-20 23:45:37 +0530
committerGuenter Roeck <linux@roeck-us.net>2014-05-21 16:02:27 -0700
commite8cba3cda44e1b042a64ab43d15d4d77c2038235 (patch)
tree6af1bb362281982527c8c58dee1e8013581b8ef9 /crypto/twofish_generic.c
parent41082d66bfd6fafe001c0902bb4622d7aee6f128 (diff)
downloadlwn-e8cba3cda44e1b042a64ab43d15d4d77c2038235.tar.gz
lwn-e8cba3cda44e1b042a64ab43d15d4d77c2038235.zip
hwmon: (ultra45_env) Introduce managed version of kzalloc
This patch moves data allocated using kzalloc to managed data allocated using devm_kzalloc and cleans now unnecessary kfrees in probe and remove functions. Also, the unnecessary label out_free is removed. The following Coccinelle semantic patch was used for making the change: @platform@ identifier p, probefn, removefn; @@ struct platform_driver p = { .probe = probefn, .remove = removefn, }; @prb@ identifier platform.probefn, pdev; expression e, e1, e2; @@ probefn(struct platform_device *pdev, ...) { <+... - e = kzalloc(e1, e2) + e = devm_kzalloc(&pdev->dev, e1, e2) ... ?-kfree(e); ...+> } @rem depends on prb@ identifier platform.removefn; expression e; @@ removefn(...) { <... - kfree(e); ...> } Signed-off-by: Himangi Saraogi <himangi774@gmail.com> Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Diffstat (limited to 'crypto/twofish_generic.c')
0 files changed, 0 insertions, 0 deletions