From: Wolfgang Grandegger <wg@grandegger.com>
To: Jakob Unterwurzacher <jakob.unterwurzacher@theobroma-systems.com>
Cc: Martin Elshuber <martin.elshuber@theobroma-systems.com>,
Philipp Tomsich <philipp.tomsich@theobroma-systems.com>,
Marc Kleine-Budde <mkl@pengutronix.de>,
linux-can@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 0/1] can: ucan: add driver for Theobroma Systems UCAN devices
Date: Fri, 23 Mar 2018 11:04:08 +0100 [thread overview]
Message-ID: <e6d4bfc8-d43f-20ef-7b00-43ecf0a87f96@grandegger.com> (raw)
In-Reply-To: <7e818d10-3410-b144-9cfb-c58a9945a8b1@theobroma-systems.com>
Am 23.03.2018 um 10:40 schrieb Jakob Unterwurzacher:
> On 23.03.18 09:32, Wolfgang Grandegger wrote:
>>> * add __func__ to all errors and warnings, and to info where it made
>>> sense
>>
>> The final output messages in the driver should especially be useful for
>> the end user... and not the developer! This is also true for the
>> function names. You already use more "__func__" than all other CAN
>> drivers together. Just my opinion!
>
> The idea was to make it clear which driver printed the message. In my
> opinion, this is a problem:
>
>> drivers/net/can/usb$ git grep "No memory left for USB buffer"
>> ems_usb.c: netdev_err(netdev, "No memory left for
>> USB buffer\n");
>> ems_usb.c: netdev_err(netdev, "No memory left for USB
>> buffer\n");
>> esd_usb2.c: "No memory left for USB
>> buffer\n");
>> esd_usb2.c: netdev_err(netdev, "No memory left for USB
>> buffer\n");
>> gs_usb.c: netdev_err(netdev, "No memory left for USB
>> buffer\n");
>> gs_usb.c: "No memory left for
>> USB buffer\n");
>> kvaser_usb.c: "No memory left for USB
>> buffer\n");
>> mcba_usb.c: netdev_err(netdev, "No memory left for
>> USB buffer\n");
>> usb_8dev.c: netdev_err(netdev, "No memory left for USB
>> buffer\n");
>> usb_8dev.c: netdev_err(netdev, "No memory left for
>> USB buffer\n");
> But I'm open to other suggestions (use a fixed "ucan: " prefix?) or to
> drop it entirely if you think it is not worth it.
But there is already a device prefix, e.g.:
peak_usb 1-6:1.0: PEAK-System PCAN-USB adapter hwrev 28 serial FFFFFFFF (1 channel)
peak_usb 1-6:1.0 can0: attached to PCAN-USB channel 0 (device 255)
^^^^^^^^
No need to add another one!
Wolfgang.
next prev parent reply other threads:[~2018-03-23 10:04 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-03-22 13:53 [PATCH v3 0/1] can: ucan: add driver for Theobroma Systems UCAN devices Jakob Unterwurzacher
2018-03-22 13:53 ` [PATCH v3 1/1] " Jakob Unterwurzacher
2018-03-23 8:42 ` Wolfgang Grandegger
2018-03-24 11:43 ` kbuild test robot
2018-03-27 10:20 ` Martin Elshuber
2018-03-23 8:32 ` [PATCH v3 0/1] " Wolfgang Grandegger
2018-03-23 9:40 ` Jakob Unterwurzacher
2018-03-23 10:04 ` Wolfgang Grandegger [this message]
2018-03-23 10:12 ` Jakob Unterwurzacher
2018-03-27 10:19 ` Martin Elshuber
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e6d4bfc8-d43f-20ef-7b00-43ecf0a87f96@grandegger.com \
--to=wg@grandegger.com \
--cc=jakob.unterwurzacher@theobroma-systems.com \
--cc=linux-can@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=martin.elshuber@theobroma-systems.com \
--cc=mkl@pengutronix.de \
--cc=philipp.tomsich@theobroma-systems.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox