]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
auxdisplay: hd44780: Make use of hd44780_common_free()
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 24 Feb 2025 17:27:41 +0000 (19:27 +0200)
committerAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Mon, 10 Mar 2025 16:03:02 +0000 (18:03 +0200)
Use the symmetrical API to free the common resources.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
drivers/auxdisplay/hd44780.c

index 1d67fe3243412424c5b7b7994dbd7f303c374bc6..ef38cb7bf13d8bd9f4600ed58a2962b4ebe3de52 100644 (file)
@@ -315,7 +315,7 @@ fail3:
 fail2:
        charlcd_free(lcd);
 fail1:
-       kfree(hdc);
+       hd44780_common_free(hdc);
        return ret;
 }
 
@@ -326,8 +326,7 @@ static void hd44780_remove(struct platform_device *pdev)
 
        charlcd_unregister(lcd);
        kfree(hdc->hd44780);
-       kfree(lcd->drvdata);
-
+       hd44780_common_free(hdc);
        charlcd_free(lcd);
 }