Re: [PATCH 1/4] hwmon: (lm70) Simplify show_name function

2012-09-16 Thread Jean Delvare
Hi Guenter, On Tue, 11 Sep 2012 13:52:50 -0700, Guenter Roeck wrote: Instead of using a switch statement to determine the device name, use to_spi_device(dev)-modalias to simplify the code and reduce module size. Signed-off-by: Guenter Roeck li...@roeck-us.net --- drivers/hwmon/lm70.c |

Re: [PATCH 1/4] hwmon: (lm70) Simplify show_name function

2012-09-16 Thread Guenter Roeck
On Sun, Sep 16, 2012 at 03:09:01PM +0200, Jean Delvare wrote: Hi Guenter, On Tue, 11 Sep 2012 13:52:50 -0700, Guenter Roeck wrote: Instead of using a switch statement to determine the device name, use to_spi_device(dev)-modalias to simplify the code and reduce module size.

Re: [PATCH 1/4] hwmon: (lm70) Simplify show_name function

2012-09-16 Thread Jean Delvare
On Sun, 16 Sep 2012 09:19:34 -0700, Guenter Roeck wrote: On Sun, Sep 16, 2012 at 03:09:01PM +0200, Jean Delvare wrote: On Tue, 11 Sep 2012 13:52:50 -0700, Guenter Roeck wrote: That's a very nice cleanup, but it makes me wonder... Wouldn't it make sense to create the name attribute of spi

Re: [PATCH 1/4] hwmon: (lm70) Simplify show_name function

2012-09-16 Thread Guenter Roeck
On Sun, Sep 16, 2012 at 08:44:56PM +0200, Jean Delvare wrote: On Sun, 16 Sep 2012 09:19:34 -0700, Guenter Roeck wrote: On Sun, Sep 16, 2012 at 03:09:01PM +0200, Jean Delvare wrote: On Tue, 11 Sep 2012 13:52:50 -0700, Guenter Roeck wrote: That's a very nice cleanup, but it makes me