<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/devfreq/devfreq.c, branch v5.9</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v5.9</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v5.9'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2020-09-23T04:35:58Z</updated>
<entry>
<title>PM / devfreq: Add timer type to devfreq_summary debugfs</title>
<updated>2020-09-23T04:35:58Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-09-08T10:57:07Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0c309ed17c50e7eeaf3c66102b475198064e80da'/>
<id>urn:sha1:0c309ed17c50e7eeaf3c66102b475198064e80da</id>
<content type='text'>
The commit 4dc3bab8687f ("PM / devfreq: Add support delayed timer for
polling mode") supports the delayed timer but this commit missed
the adding the timer type to devfreq_summary debugfs node.
Add the timer type to devfreq_summary debugfs.

Fixes: 4dc3bab8687f ("PM / devfreq: Add support delayed timer for polling mode")
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Fix the wrong end with semicolon</title>
<updated>2020-07-30T08:22:58Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-07-27T02:32:31Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=27a69714450f5c9288cec2b20f1ae4f7ad34dacf'/>
<id>urn:sha1:27a69714450f5c9288cec2b20f1ae4f7ad34dacf</id>
<content type='text'>
Fix the wrong grammar at the end of code line by using semicolon.

Cc: stable vger.kernel.org
Fixes: 490a421bc575 ("PM / devfreq: Add debugfs support with devfreq_summary file")
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Fix indentaion of devfreq_summary debugfs node</title>
<updated>2020-07-30T08:22:58Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-07-09T06:51:34Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0aae11bcdefb4894b6100656ad24cbd85ff34b52'/>
<id>urn:sha1:0aae11bcdefb4894b6100656ad24cbd85ff34b52</id>
<content type='text'>
The commit 66d0e797bf09 ("Revert "PM / devfreq: Modify the device name
as devfreq(X) for sysfs"") roll back the device name from 'devfreqX'
to device name explained in DT. After applied commit 66d0e797bf09,
the indentation of devfreq_summary debugfs node was broken.

So, fix indentaion of devfreq_summary debugfs node as following:

For example on Exynos5422-based Odroid-XU3 board,
$ cat /sys/kernel/debug/devfreq/devfreq_summary
dev                            parent_dev                     governor        polling_ms  cur_freq_Hz  min_freq_Hz  max_freq_Hz
------------------------------ ------------------------------ --------------- ---------- ------------ ------------ ------------
10c20000.memory-controller     null                           simple_ondemand          0    413000000    165000000    825000000
soc:bus_wcore                  null                           simple_ondemand         50     88700000     88700000    532000000
soc:bus_noc                    soc:bus_wcore                  passive                  0     66600000     66600000    111000000
soc:bus_fsys_apb               soc:bus_wcore                  passive                  0    111000000    111000000    222000000
soc:bus_fsys                   soc:bus_wcore                  passive                  0     75000000     75000000    200000000
soc:bus_fsys2                  soc:bus_wcore                  passive                  0     75000000     75000000    200000000
soc:bus_mfc                    soc:bus_wcore                  passive                  0     83250000     83250000    333000000
soc:bus_gen                    soc:bus_wcore                  passive                  0     88700000     88700000    266000000
soc:bus_peri                   soc:bus_wcore                  passive                  0     66600000     66600000     66600000
soc:bus_g2d                    soc:bus_wcore                  passive                  0     83250000     83250000    333000000
soc:bus_g2d_acp                soc:bus_wcore                  passive                  0            0     66500000    266000000
soc:bus_jpeg                   soc:bus_wcore                  passive                  0            0     75000000    300000000
soc:bus_jpeg_apb               soc:bus_wcore                  passive                  0            0     83250000    166500000
soc:bus_disp1_fimd             soc:bus_wcore                  passive                  0            0    120000000    200000000
soc:bus_disp1                  soc:bus_wcore                  passive                  0            0    120000000    300000000
soc:bus_gscl_scaler            soc:bus_wcore                  passive                  0            0    150000000    300000000
soc:bus_mscl                   soc:bus_wcore                  passive                  0            0     84000000    666000000

Cc: stable@vger.kernel.org
Fixes: 66d0e797bf09 ("Revert "PM / devfreq: Modify the device name as devfreq(X) for sysfs"")
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Clean up the devfreq instance name in sysfs attr</title>
<updated>2020-07-30T08:22:57Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-07-13T08:31:12Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=483d557ee9a3df5f21db4e4485705b17ed1a9e1e'/>
<id>urn:sha1:483d557ee9a3df5f21db4e4485705b17ed1a9e1e</id>
<content type='text'>
The sysfs attr interface used eithere 'df' or 'devfreq' for devfreq instance
name. In order to keep the consistency and to improve the readabilty,
unify the instance name as 'df'. Add add the missing conditional statement
to prevent the fault.

Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Add support delayed timer for polling mode</title>
<updated>2020-07-30T08:22:57Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-07-02T11:41:28Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4dc3bab8687f1ea11322611de6d4138b43eccdcd'/>
<id>urn:sha1:4dc3bab8687f1ea11322611de6d4138b43eccdcd</id>
<content type='text'>
Until now, the devfreq driver using polling mode like simple_ondemand
governor have used only deferrable timer for reducing the redundant
power consumption. It reduces the CPU wake-up from idle due to polling mode
which check the status of Non-CPU device.

But, it has a problem for Non-CPU device like DMC device with DMA operation.
Some Non-CPU device need to do monitor continuously regardless of CPU state
in order to decide the proper next status of Non-CPU device.

So, add support the delayed timer for polling mode to support
the repetitive monitoring. The devfreq driver and user can select
the kind of timer on either deferrable and delayed timer.

For example, change the timer type of DMC device
based on Exynos5422-based Odroid-XU3 as following:

- If want to use deferrable timer as following:
echo deferrable &gt; /sys/class/devfreq/10c20000.memory-controller/timer

- If want to use delayed timer as following:
echo delayed &gt; /sys/class/devfreq/10c20000.memory-controller/timer

Reviewed-by: Bartlomiej Zolnierkiewicz &lt;b.zolnierkie@samsung.com&gt;
Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Use lockdep asserts instead of manual checks for locked mutex</title>
<updated>2020-05-28T09:02:40Z</updated>
<author>
<name>Krzysztof Kozlowski</name>
<email>krzk@kernel.org</email>
</author>
<published>2020-05-12T06:41:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=8fc0e48e0faefef5064f3cb803d3d12314e16ec4'/>
<id>urn:sha1:8fc0e48e0faefef5064f3cb803d3d12314e16ec4</id>
<content type='text'>
Instead of warning when mutex_is_locked(), just use the lockdep
framework.  The code is smaller and checks could be disabled for
production environments (it is useful only during development).

Put asserts at beginning of function, even before validating arguments.

The behavior of update_devfreq() is now changed because lockdep assert
will only print a warning, not return with EINVAL.

Signed-off-by: Krzysztof Kozlowski &lt;krzk@kernel.org&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Replace strncpy with strscpy</title>
<updated>2020-05-28T09:02:39Z</updated>
<author>
<name>Dmitry Osipenko</name>
<email>digetx@gmail.com</email>
</author>
<published>2020-02-27T17:08:54Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a316b5ca9ead8065ac873e655c313248ecd732bc'/>
<id>urn:sha1:a316b5ca9ead8065ac873e655c313248ecd732bc</id>
<content type='text'>
GCC produces this warning when kernel compiled using `make W=1`:

  warning: ‘strncpy’ specified bound 16 equals destination size [-Wstringop-truncation]
  772 |  strncpy(devfreq-&gt;governor_name, governor_name, DEVFREQ_NAME_LEN);

The strncpy doesn't take care of NULL-termination of the destination
buffer, while the strscpy does.

Signed-off-by: Dmitry Osipenko &lt;digetx@gmail.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Fix handling dev_pm_qos_remove_request result</title>
<updated>2020-03-24T23:35:03Z</updated>
<author>
<name>Leonard Crestez</name>
<email>leonard.crestez@nxp.com</email>
</author>
<published>2020-03-12T15:36:06Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=4c6abef7b46204d2db790b209e799162f39112d0'/>
<id>urn:sha1:4c6abef7b46204d2db790b209e799162f39112d0</id>
<content type='text'>
The dev_pm_qos_remove_request function can return 1 if
"aggregated constraint value has changed" so only negative values should
be reported as errors.

Fixes: 27dbc542f651 ("PM / devfreq: Use PM QoS for sysfs min/max_freq")
Reported-by: Dan Carpenter &lt;dan.carpenter@oracle.com&gt;
Signed-off-by: Leonard Crestez &lt;leonard.crestez@nxp.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>PM / devfreq: Change to DEVFREQ_GOV_UPDATE_INTERVAL event name</title>
<updated>2020-03-24T23:35:03Z</updated>
<author>
<name>Chanwoo Choi</name>
<email>cw00.choi@samsung.com</email>
</author>
<published>2020-01-29T04:24:18Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=3a1ec2e8d8a9f5535f11dd3772a212434743e4f2'/>
<id>urn:sha1:3a1ec2e8d8a9f5535f11dd3772a212434743e4f2</id>
<content type='text'>
DEVFREQ_GOV_INTERVAL event indicates that update the interval
for polling mode of devfreq device. But, this event name doesn't
specify exactly what to do.

Change DEVFREQ_GOV_INTERVAL event name to DEVFREQ_GOV_UPDATE_INTERVAL
which specifies what to do by event name.

And modify the function name to DEVFREQ_GOV_UPDATE_INTERVAL
with 'devfreq_' prefix + verb + object as following:
- devfreq_interval_update -&gt; devfreq_updatee_interval

Reviewed-by: Lukasz Luba &lt;lukasz.luba@arm.com&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
<entry>
<title>Revert "PM / devfreq: Modify the device name as devfreq(X) for sysfs"</title>
<updated>2020-02-24T02:14:29Z</updated>
<author>
<name>Orson Zhai</name>
<email>orson.unisoc@gmail.com</email>
</author>
<published>2020-02-20T17:37:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=66d0e797bf095d407479c89952d42b1d96ef0a7f'/>
<id>urn:sha1:66d0e797bf095d407479c89952d42b1d96ef0a7f</id>
<content type='text'>
This reverts commit 4585fbcb5331fc910b7e553ad3efd0dd7b320d14.

The name changing as devfreq(X) breaks some user space applications,
such as Android HAL from Unisoc and Hikey [1].
The device name will be changed unexpectly after every boot depending
on module init sequence. It will make trouble to setup some system
configuration like selinux for Android.

So we'd like to revert it back to old naming rule before any better
way being found.

[1] https://lkml.org/lkml/2018/5/8/1042

Cc: John Stultz &lt;john.stultz@linaro.org&gt;
Cc: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Cc: stable@vger.kernel.org
Signed-off-by: Orson Zhai &lt;orson.unisoc@gmail.com&gt;
Acked-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
Signed-off-by: Chanwoo Choi &lt;cw00.choi@samsung.com&gt;
</content>
</entry>
</feed>
