OSDN Git Service

auxdisplay: hd44780: Convert to use charlcd_free()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 12 Mar 2019 14:44:32 +0000 (16:44 +0200)
committerMiguel Ojeda <miguel.ojeda.sandonis@gmail.com>
Sun, 17 Mar 2019 07:48:28 +0000 (08:48 +0100)
Convert to use charlcd_free() instead of kfree() for sake of type check.

Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Miguel Ojeda <miguel.ojeda.sandonis@gmail.com>
drivers/auxdisplay/hd44780.c

index 3cde351..ab15b64 100644 (file)
@@ -271,7 +271,7 @@ static int hd44780_probe(struct platform_device *pdev)
        return 0;
 
 fail:
-       kfree(lcd);
+       charlcd_free(lcd);
        return ret;
 }
 
@@ -281,7 +281,7 @@ static int hd44780_remove(struct platform_device *pdev)
 
        charlcd_unregister(lcd);
 
-       kfree(lcd);
+       charlcd_free(lcd);
        return 0;
 }