All of lore.kernel.org
 help / color / mirror / Atom feed
* [ASAP] thermal_sys.c NULL ptr deref patch likely incomplete
@ 2013-02-14 14:44 Andreas Mohr
  2013-02-15  8:34 ` Zhang, Rui
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Andreas Mohr @ 2013-02-14 14:44 UTC (permalink / raw)
  To: Zhang Rui; +Cc: linux-kernel

Hi,

I just had a

# cat /sys/class/thermal/thermal_zone0/policy 
(null)


When looking at the code (on my -rc7), I saw:

drivers/thermal/thermal_sys.c

static ssize_t
policy_show(struct device *dev, struct device_attribute *devattr, char
*buf)
{
        struct thermal_zone_device *tz = to_thermal_zone(dev);

        return sprintf(buf, "%s\n", tz->governor->name);
}


(not sure though why I manage to get a "(null)" rather than a crash
due to the dereferencing prior to output - possibly since I do have a
valid governor allocated yet then only its name field is null?)


Seems we are missing a critical (and -rc-relevant) patch here
(and perhaps at other locations in this file, too, given that
this one was missed last time?).

Currently trying to get acerhdf operation into a working state
(and having some trouble with it - didn't know that I probably need some
governor setup which seems to have just been available on my last setup,
or so)

Thanks,

Andreas Mohr

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2013-02-18 11:49 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-14 14:44 [ASAP] thermal_sys.c NULL ptr deref patch likely incomplete Andreas Mohr
2013-02-15  8:34 ` Zhang, Rui
2013-02-15 16:25   ` Andreas Mohr
2013-02-15  9:56 ` Zhang, Rui
2013-02-18 11:48 ` Zhang, Rui

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.