lkml.org 
[lkml]   [2010]   [Nov]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [lm-sensors] [PATCH 3/8] hwmon: applesmc: Dynamic creation of temperature files
On Sun, Oct 31, 2010 at 03:50:29AM -0400, Henrik Rydberg wrote:
> The current driver creates temperature files based on a list
> of temperature keys given per device. Apart from slow adaption
> to new machine models, the number of sensors also depends on
> the number of processors. This patch looks up the temperature
> keys dynamically, thereby supporting all models.
>
> Signed-off-by: Henrik Rydberg <rydberg@euromail.se>

Hi Henrik,

Nice cleanup. Just a coule of minor comments.

> ---
> drivers/hwmon/applesmc.c | 498 +++++++++++-----------------------------------
> 1 files changed, 113 insertions(+), 385 deletions(-)
>
> diff --git a/drivers/hwmon/applesmc.c b/drivers/hwmon/applesmc.c
> index 7f030f0..0207618 100644
> --- a/drivers/hwmon/applesmc.c
> +++ b/drivers/hwmon/applesmc.c
[ ...]
>
> - pr_info("key=%d\n", s->key_count);
> + pr_info("key=%d temp=%d\n", s->key_count, s->temp_count);

Is this useful or just noisy ? How about pr_debug instead ?

>
> return 0;
> }

[ ... ]

> @@ -1429,13 +1122,66 @@ static int applesmc_dmi_match(const struct dmi_system_id *id)
> pr_info(" - Model %s light sensors and backlight\n",
> applesmc_light ? "with" : "without");
>
> - applesmc_temperature_set = dmi_data->temperature_set;
> - while (temperature_sensors_sets[applesmc_temperature_set][i] != NULL)
> - i++;
> - pr_info(" - Model with %d temperature sensors\n", i);
> +

This results in another double empty line.

Guenter


\
 
 \ /
  Last update: 2010-11-05 03:27    [W:0.278 / U:2.804 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site