lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <20080218045949.d75c4ab3.akpm@linux-foundation.org>
Date:	Mon, 18 Feb 2008 04:59:49 -0800
From:	Andrew Morton <akpm@...ux-foundation.org>
To:	"Dan Upton" <upton.dan.linux@...il.com>
Cc:	linux-kernel@...r.kernel.org
Subject: Re: accessing core temp sensors in the kernel

On Fri, 15 Feb 2008 16:12:40 -0500 "Dan Upton" <upton.dan.linux@...il.com> wrote:

> I'm trying to do some work on thermally-aware scheduling, specifically
> using the coretemp module to access core temperature sensors on the
> Intel Core2 platform.  I know how to access them from user mode,
> reading files from sysfs, but clearly that's not the way to do it in
> the kernel.  Specifically, I'm not sure how, in the scheduler, to get
> copies of the appropriate device structures to call
> 
> static struct coretemp_data *coretemp_update_device(struct device *dev)
> 
> (in hwmon/coretemp.c).
> 
> Can anybody give me pointers where to get started?

You shouldn't make the core scheduler dependent upon some hwmon module. 
I'd sugggest adding some register_cpu_temperature_monitor() function in the
scheduler then permit suitable monitoring modules to register themselves in
their module_init() functions.  Use a notifier chain from notifier.h.  The
CPU scheduler will walk that chain calling into the registered drivers at a
suitable time.


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ