All of lore.kernel.org
 help / color / mirror / Atom feed
From: arno@natisbad.org (Arnaud Ebalard)
To: Guenter Roeck <linux@roeck-us.net>
Cc: Andrew Lunn <andrew@lunn.ch>,
	Russell King - ARM Linux <linux@arm.linux.org.uk>,
	Jason Cooper <jason@lakedaemon.net>,
	linux-doc@vger.kernel.org, devicetree-discuss@lists.ozlabs.org,
	Olivier Mouchet <olivier.mouchet@gmail.com>,
	Rob Herring <rob.herring@calxeda.com>,
	lm-sensors@lm-sensors.org,
	Grant Likely <grant.likely@secretlab.ca>,
	Rob Landley <rob@landley.net>, Jean Delvare <khali@linux-fr.org>,
	Linux ARM Kernel Mailing List
	<linux-arm-kernel@lists.infradead.org>,
	Simon Guinot <simon.guinot@sequanux.org>
Subject: Re: [lm-sensors] [PATCHv3 1/3] Add support for GMT G762/G763 PWM fan controller
Date: Tue, 04 Jun 2013 06:54:23 +0000	[thread overview]
Message-ID: <87li6qz7q8.fsf@natisbad.org> (raw)
In-Reply-To: 20130603023444.GB11723@roeck-us.net

Hi,

Guenter Roeck <linux@roeck-us.net> writes:

> On Sun, Jun 02, 2013 at 10:14:19PM +0200, Arnaud Ebalard wrote:
>> 
>> Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
>> ---
>>  drivers/hwmon/Kconfig              |   10 +
>>  drivers/hwmon/Makefile             |    1 +
>>  drivers/hwmon/g762.c               | 1179 ++++++++++++++++++++++++++++++++++++
>>  include/linux/platform_data/g762.h |   51 ++
>>  4 files changed, 1241 insertions(+)
>>  create mode 100644 drivers/hwmon/g762.c
>>  create mode 100644 include/linux/platform_data/g762.h
>> 
> [ ... ]
>
>> +static inline int g762_read_byte(const struct i2c_client *client, u8 reg,
>> +				 u8 *dest)
>> +{
>> +	int ret;
>> +
>> +	ret = i2c_smbus_read_byte_data(client, reg);
>> +	if (ret < 0) {
>> +		dev_err(&client->dev, "failed to read reg %x02x, err %d\n",
>> +			(int)reg, ret);
>
> I would suggest to write a piece of test code for the above statement and
> observe its output. "printf("%x02x\n", 0x1234);" should do.

good catch. s/%x02x/0x%02x/.

> Is the error message really needed ? If there is a persistent error,
> it will clog the log.

I removed it in v4 to come.

Cheers,

a+

_______________________________________________
lm-sensors mailing list
lm-sensors@lm-sensors.org
http://lists.lm-sensors.org/mailman/listinfo/lm-sensors

WARNING: multiple messages have this Message-ID (diff)
From: arno@natisbad.org (Arnaud Ebalard)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv3 1/3] Add support for GMT G762/G763 PWM fan controller
Date: Tue, 04 Jun 2013 08:54:23 +0200	[thread overview]
Message-ID: <87li6qz7q8.fsf@natisbad.org> (raw)
In-Reply-To: 20130603023444.GB11723@roeck-us.net

Hi,

Guenter Roeck <linux@roeck-us.net> writes:

> On Sun, Jun 02, 2013 at 10:14:19PM +0200, Arnaud Ebalard wrote:
>> 
>> Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
>> ---
>>  drivers/hwmon/Kconfig              |   10 +
>>  drivers/hwmon/Makefile             |    1 +
>>  drivers/hwmon/g762.c               | 1179 ++++++++++++++++++++++++++++++++++++
>>  include/linux/platform_data/g762.h |   51 ++
>>  4 files changed, 1241 insertions(+)
>>  create mode 100644 drivers/hwmon/g762.c
>>  create mode 100644 include/linux/platform_data/g762.h
>> 
> [ ... ]
>
>> +static inline int g762_read_byte(const struct i2c_client *client, u8 reg,
>> +				 u8 *dest)
>> +{
>> +	int ret;
>> +
>> +	ret = i2c_smbus_read_byte_data(client, reg);
>> +	if (ret < 0) {
>> +		dev_err(&client->dev, "failed to read reg %x02x, err %d\n",
>> +			(int)reg, ret);
>
> I would suggest to write a piece of test code for the above statement and
> observe its output. "printf("%x02x\n", 0x1234);" should do.

good catch. s/%x02x/0x%02x/.

> Is the error message really needed ? If there is a persistent error,
> it will clog the log.

I removed it in v4 to come.

Cheers,

a+

WARNING: multiple messages have this Message-ID (diff)
From: arno@natisbad.org (Arnaud Ebalard)
To: Guenter Roeck <linux@roeck-us.net>
Cc: Andrew Lunn <andrew@lunn.ch>,
	Russell King - ARM Linux <linux@arm.linux.org.uk>,
	Jason Cooper <jason@lakedaemon.net>,
	linux-doc@vger.kernel.org, devicetree-discuss@lists.ozlabs.org,
	Olivier Mouchet <olivier.mouchet@gmail.com>,
	Rob Herring <rob.herring@calxeda.com>,
	lm-sensors@lm-sensors.org,
	Grant Likely <grant.likely@secretlab.ca>,
	Rob Landley <rob@landley.net>, Jean Delvare <khali@linux-fr.org>,
	Linux ARM Kernel Mailing List
	<linux-arm-kernel@lists.infradead.org>,
	Simon Guinot <simon.guinot@sequanux.org>
Subject: Re: [PATCHv3 1/3] Add support for GMT G762/G763 PWM fan controller
Date: Tue, 04 Jun 2013 08:54:23 +0200	[thread overview]
Message-ID: <87li6qz7q8.fsf@natisbad.org> (raw)
In-Reply-To: 20130603023444.GB11723@roeck-us.net

Hi,

Guenter Roeck <linux@roeck-us.net> writes:

> On Sun, Jun 02, 2013 at 10:14:19PM +0200, Arnaud Ebalard wrote:
>> 
>> Signed-off-by: Arnaud Ebalard <arno@natisbad.org>
>> ---
>>  drivers/hwmon/Kconfig              |   10 +
>>  drivers/hwmon/Makefile             |    1 +
>>  drivers/hwmon/g762.c               | 1179 ++++++++++++++++++++++++++++++++++++
>>  include/linux/platform_data/g762.h |   51 ++
>>  4 files changed, 1241 insertions(+)
>>  create mode 100644 drivers/hwmon/g762.c
>>  create mode 100644 include/linux/platform_data/g762.h
>> 
> [ ... ]
>
>> +static inline int g762_read_byte(const struct i2c_client *client, u8 reg,
>> +				 u8 *dest)
>> +{
>> +	int ret;
>> +
>> +	ret = i2c_smbus_read_byte_data(client, reg);
>> +	if (ret < 0) {
>> +		dev_err(&client->dev, "failed to read reg %x02x, err %d\n",
>> +			(int)reg, ret);
>
> I would suggest to write a piece of test code for the above statement and
> observe its output. "printf("%x02x\n", 0x1234);" should do.

good catch. s/%x02x/0x%02x/.

> Is the error message really needed ? If there is a persistent error,
> it will clog the log.

I removed it in v4 to come.

Cheers,

a+

  reply	other threads:[~2013-06-04  6:54 UTC|newest]

Thread overview: 24+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-02 20:14 [lm-sensors] [PATCHv3 0/3] Add G762/G763 PWM fan controller Arnaud Ebalard
2013-06-02 20:14 ` Arnaud Ebalard
2013-06-02 20:14 ` Arnaud Ebalard
2013-06-02 20:14 ` [lm-sensors] [PATCHv3 1/3] Add support for GMT " Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-03  2:34   ` [lm-sensors] " Guenter Roeck
2013-06-03  2:34     ` Guenter Roeck
2013-06-03  2:34     ` Guenter Roeck
2013-06-04  6:54     ` Arnaud Ebalard [this message]
2013-06-04  6:54       ` Arnaud Ebalard
2013-06-04  6:54       ` Arnaud Ebalard
2013-06-02 20:14 ` [lm-sensors] [PATCHv3 2/3] Add documentation for g762 driver Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-02 20:14 ` [lm-sensors] [PATCHv3 3/3] Add DT bindings " Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-02 20:14   ` Arnaud Ebalard
2013-06-03  2:30 ` [lm-sensors] [PATCHv3 0/3] Add G762/G763 PWM fan controller Guenter Roeck
2013-06-03  2:30   ` Guenter Roeck
2013-06-03  2:30   ` Guenter Roeck
     [not found]   ` <20130603023053.GA11723-0h96xk9xTtrk1uMJSBkQmQ@public.gmane.org>
2013-06-03 14:15     ` [lm-sensors] " Jason Cooper
2013-06-03 14:15       ` Jason Cooper
2013-06-03 14:15       ` Jason Cooper

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=87li6qz7q8.fsf@natisbad.org \
    --to=arno@natisbad.org \
    --cc=andrew@lunn.ch \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=grant.likely@secretlab.ca \
    --cc=jason@lakedaemon.net \
    --cc=khali@linux-fr.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-doc@vger.kernel.org \
    --cc=linux@arm.linux.org.uk \
    --cc=linux@roeck-us.net \
    --cc=lm-sensors@lm-sensors.org \
    --cc=olivier.mouchet@gmail.com \
    --cc=rob.herring@calxeda.com \
    --cc=rob@landley.net \
    --cc=simon.guinot@sequanux.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.