All of lore.kernel.org
 help / color / mirror / Atom feed
From: Thomas Renninger <trenn@suse.de>
To: Matthew Garrett <mjg59@srcf.ucam.org>
Cc: linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
	rui.zhang@intel.com, pavel@suse.cz
Subject: Re: [PATCH v2] thermal: Make it simpler to use the thermal layer inside the kernel
Date: Fri, 3 Oct 2008 19:08:36 +0200	[thread overview]
Message-ID: <200810031908.37618.trenn@suse.de> (raw)
In-Reply-To: <20081001184111.GA3330@srcf.ucam.org>

On Wednesday 01 October 2008 08:41:11 pm Matthew Garrett wrote:
> The thermal layer passes temperatures and trip point types around as
> strings. This is fine for sysfs, but makes it hard to use them for other
> purposes in-kernel. Move the string conversion to the sysfs-specific
> code.
I went through your very first version and I also like the string to 
int conversion very much.
I wanted to move the polling from acpi/thermal.c to the new thermal
layer to have the thermal polling in the architecture independent part
and started on top of your first version, but I got stuck and run out of time, 
otherwise I'd also sent this.

>  struct thermal_cooling_device_ops {
> -	int (*get_max_state) (struct thermal_cooling_device *, char *);
> -	int (*get_cur_state) (struct thermal_cooling_device *, char *);
> +	int (*get_max_state) (struct thermal_cooling_device *, unsigned int *);
> +	int (*get_cur_state) (struct thermal_cooling_device *, unsigned int *);
>  	int (*set_cur_state) (struct thermal_cooling_device *, unsigned int);
>  };
Looks like you forgot the menlow driver again which also makes use of this:

grep get_max_state drivers/misc/intel_menlow.c
        .get_max_state = memory_get_max_bandwidth,

It would be great to see the conversion in .28.

        Thomas

  parent reply	other threads:[~2008-10-03 17:08 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-10-01 12:04 [PATCH] thermal: Make it simpler to use the thermal layer inside the kernel Matthew Garrett
2008-10-01 12:13 ` [RFC] thermal: Move trip point handling code from ACPI to generic code Matthew Garrett
2008-10-01 18:42   ` Matthew Garrett
2008-10-02  8:22     ` Pavel Machek
2008-10-01 12:41 ` [PATCH] thermal: Make it simpler to use the thermal layer inside the kernel Pavel Machek
2008-10-01 18:41 ` [PATCH v2] " Matthew Garrett
2008-10-01 20:32   ` Pavel Machek
2008-10-03 17:08   ` Thomas Renninger [this message]
2008-10-03 17:10     ` Matthew Garrett

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=200810031908.37618.trenn@suse.de \
    --to=trenn@suse.de \
    --cc=linux-acpi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mjg59@srcf.ucam.org \
    --cc=pavel@suse.cz \
    --cc=rui.zhang@intel.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 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.