Docs: usb: update err() to pr_err() and replace __FILE__
authorPhilipp Hortmann <philipp.g.hortmann@gmail.com>
Sat, 30 Oct 2021 11:24:55 +0000 (13:24 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 Nov 2021 13:54:58 +0000 (14:54 +0100)
update err() to pr_err() and replace __FILE__

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/2c477cb0cf5214ae9abf9a4a9de28fcb38f90070.1635591623.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Documentation/driver-api/usb/writing_usb_driver.rst

index b43e1ce..0093dea 100644 (file)
@@ -94,8 +94,8 @@ usually in the driver's init function, as shown here::
            /* register this driver with the USB subsystem */
            result = usb_register(&skel_driver);
            if (result < 0) {
-                   err("usb_register failed for the "__FILE__ "driver."
-                       "Error number %d", result);
+                   pr_err("usb_register failed for the %s driver. Error number %d\n",
+                          skel_driver.name, result);
                    return -1;
            }