<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-toradex.git/include/linux/devfreq_cooling.h, branch v4.11-rc3</title>
<subtitle>Linux kernel for Apalis and Colibri modules</subtitle>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/'/>
<entry>
<title>devfreq_cooling: pass a pointer to devfreq in the power model callbacks</title>
<updated>2016-11-23T02:07:35+00:00</updated>
<author>
<name>Javi Merino</name>
<email>javi.merino@arm.com</email>
</author>
<published>2016-09-15T14:44:23+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3aa5374376746f20a27be8682be7f91c8b71d1d8'/>
<id>3aa5374376746f20a27be8682be7f91c8b71d1d8</id>
<content type='text'>
When the devfreq cooling device was designed, it was an oversight not to
pass a pointer to the struct devfreq as the first parameters of the
callbacks.  The design patterns of the kernel suggest it for a good
reason.

By passing a pointer to struct devfreq, the driver can register one
function that works with multiple devices.  With the current
implementation, a driver that can work with multiple devices has to
create multiple copies of the same function with different parameters so
that each devfreq_cooling_device can use the appropriate one.  By
passing a pointer to struct devfreq, the driver can identify which
device it's referring to.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Reviewed-by: Punit Agrawal &lt;punit.agrawal@arm.com&gt;
Reviewed-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When the devfreq cooling device was designed, it was an oversight not to
pass a pointer to the struct devfreq as the first parameters of the
callbacks.  The design patterns of the kernel suggest it for a good
reason.

By passing a pointer to struct devfreq, the driver can register one
function that works with multiple devices.  With the current
implementation, a driver that can work with multiple devices has to
create multiple copies of the same function with different parameters so
that each devfreq_cooling_device can use the appropriate one.  By
passing a pointer to struct devfreq, the driver can identify which
device it's referring to.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Reviewed-by: Punit Agrawal &lt;punit.agrawal@arm.com&gt;
Reviewed-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>devfreq_cooling: make the structs devfreq_cooling_xxx visible for all</title>
<updated>2016-11-23T02:07:35+00:00</updated>
<author>
<name>Lukasz Luba</name>
<email>lukasz.luba@arm.com</email>
</author>
<published>2016-09-15T14:44:22+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=1cea4e7776b7e9096b696eeb66364f51a8d321ec'/>
<id>1cea4e7776b7e9096b696eeb66364f51a8d321ec</id>
<content type='text'>
Currently the protection #ifdef CONFIG_DEVFREQ_THERMAL cuts the needed
structures devfreq_cooling_ops and devfreq_cooling_device.
The functions which are supposed to provide the empty implementation complain
about unknown structures.
Similar solution is present in include/linux/devfreq.h.

Reviewed-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Currently the protection #ifdef CONFIG_DEVFREQ_THERMAL cuts the needed
structures devfreq_cooling_ops and devfreq_cooling_device.
The functions which are supposed to provide the empty implementation complain
about unknown structures.
Similar solution is present in include/linux/devfreq.h.

Reviewed-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Signed-off-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thermal: devfreq_cooling: use a thermal_cooling_device for register and unregister</title>
<updated>2015-11-02T21:14:44+00:00</updated>
<author>
<name>Javi Merino</name>
<email>javi.merino@arm.com</email>
</author>
<published>2015-11-02T19:03:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=3c99c2cef75eb5bfc05c5728e4560f3ee656d47e'/>
<id>3c99c2cef75eb5bfc05c5728e4560f3ee656d47e</id>
<content type='text'>
Be consistent with what other cooling devices do and return a struct
thermal_cooling_device * on register.  Also, for the unregister, accept
a struct thermal_cooling_device * as parameter.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Be consistent with what other cooling devices do and return a struct
thermal_cooling_device * on register.  Also, for the unregister, accept
a struct thermal_cooling_device * as parameter.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>thermal: Add devfreq cooling</title>
<updated>2015-10-30T17:21:01+00:00</updated>
<author>
<name>Ørjan Eide</name>
<email>orjan.eide@arm.com</email>
</author>
<published>2015-09-10T17:09:30+00:00</published>
<link rel='alternate' type='text/html' href='https://git.toradex.cn/cgit/linux-toradex.git/commit/?id=a76caf55e5b356ba20a5a43ac4d9f7a04b20941d'/>
<id>a76caf55e5b356ba20a5a43ac4d9f7a04b20941d</id>
<content type='text'>
Add a generic thermal cooling device for devfreq, that is similar to
cpu_cooling.

The device must use devfreq.  In order to use the power extension of the
cooling device, it must have registered its OPPs using the OPP library.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add a generic thermal cooling device for devfreq, that is similar to
cpu_cooling.

The device must use devfreq.  In order to use the power extension of the
cooling device, it must have registered its OPPs using the OPP library.

Cc: Zhang Rui &lt;rui.zhang@intel.com&gt;
Cc: Eduardo Valentin &lt;edubezval@gmail.com&gt;
Signed-off-by: Javi Merino &lt;javi.merino@arm.com&gt;
Signed-off-by: Ørjan Eide &lt;orjan.eide@arm.com&gt;
Signed-off-by: Eduardo Valentin &lt;edubezval@gmail.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
