<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/cpufreq, branch v4.2</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=v4.2</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v4.2'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2015-08-14T09:33:47Z</updated>
<entry>
<title>cpufreq: exynos: Fix for memory leak in case SoC name does not match</title>
<updated>2015-08-14T09:33:47Z</updated>
<author>
<name>Shailendra Verma</name>
<email>shailendra.capricorn@gmail.com</email>
</author>
<published>2015-08-04T07:45:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=62c3f2fddd438d6d8d0a3cbb195637b74c3654eb'/>
<id>urn:sha1:62c3f2fddd438d6d8d0a3cbb195637b74c3654eb</id>
<content type='text'>
During probe free the memory allocated to "exynos_info" in case of
unknown SoC type.

Signed-off-by: Shailendra Verma &lt;shailendra.capricorn@gmail.com&gt;
Acked-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Acked-by: Lukasz Majewski &lt;l.majewski@samsung.com&gt;
[k.kozlowski: Rebased the patch around if(of_machine_is_compatible)]
Signed-off-by: Krzysztof Kozlowski &lt;k.kozlowski@samsung.com&gt;
Signed-off-by: Kukjin Kim &lt;kgene@kernel.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>CPUFREQ: Loongson2: Fix broken build due to incorrect include.</title>
<updated>2015-08-03T07:24:59Z</updated>
<author>
<name>Ralf Baechle</name>
<email>ralf@linux-mips.org</email>
</author>
<published>2015-07-19T21:27:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9b2b6f7f357d9a2473017295bb26ff907e149d34'/>
<id>urn:sha1:9b2b6f7f357d9a2473017295bb26ff907e149d34</id>
<content type='text'>
71eeedcf51544831ae356a773814401143ed32d4 (MIPS: Lemote 2F: Fix build caused
by recent mass rename.) only fixed one instance of this issue in arch/mips
but missed a 2nd one in drivers/cpufreq/loongson2_cpufreq.c.

[ralf@linux-mips.org: dropped the one segment for the already fixed
instance and changed the other avoiding an include &lt;path.h&gt; without a /
because that's generally is a bad idea.]

Signed-off-by: Ralf Baechle &lt;ralf@linux-mips.org&gt;
Acked-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Patchwork: https://patchwork.linux-mips.org/patch/10659/
</content>
</entry>
<entry>
<title>cpufreq: Avoid attempts to create duplicate symbolic links</title>
<updated>2015-07-28T15:19:26Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2015-07-26T00:07:47Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=559ed40752dc63e68f9b9ad301b20e6a3fe5cf21'/>
<id>urn:sha1:559ed40752dc63e68f9b9ad301b20e6a3fe5cf21</id>
<content type='text'>
After commit 87549141d516 (cpufreq: Stop migrating sysfs files on
hotplug) there is a problem with CPUs that share cpufreq policy
objects with other CPUs and are initially offline.

Say CPU1 shares a policy with CPU0 which is online and is registered
first.  As part of the registration process, cpufreq_add_dev() is
called for it.  It creates the policy object and a symbolic link
to it from the CPU1's sysfs directory.  If CPU1 is registered
subsequently and it is offline at that time, cpufreq_add_dev() will
attempt to create a symbolic link to the policy object for it, but
that link is present already, so a warning about that will be
triggered.

To avoid that warning, make cpufreq use an additional CPU mask
containing related CPUs that are actually present for each policy
object.  That mask is initialized when the policy object is populated
after its creation (for the first online CPU using it) and it includes
CPUs from the "policy CPUs" mask returned by the cpufreq driver's
-&gt;init() callback that are physically present at that time.  Symbolic
links to the policy are created only for the CPUs in that mask.

If cpufreq_add_dev() is invoked for an offline CPU, it checks the
new mask and only creates the symlink if the CPU was not in it (the
CPU is added to the mask at the same time).

In turn, cpufreq_remove_dev() drops the given CPU from the new mask,
removes its symlink to the policy object and returns, unless it is
the CPU owning the policy object.  In that case, the policy object
is moved to a new CPU's sysfs directory or deleted if the CPU being
removed was the last user of the policy.

While at it, notice that cpufreq_remove_dev() can't fail, because
its return value is ignored, so make it ignore return values from
__cpufreq_remove_dev_prepare() and __cpufreq_remove_dev_finish()
and prevent these functions from aborting on errors returned by
__cpufreq_governor().  Also drop the now unused sif argument from
them.

Fixes: 87549141d516 (cpufreq: Stop migrating sysfs files on hotplug)
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
Reported-and-tested-by: Russell King &lt;linux@arm.linux.org.uk&gt;
Acked-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
</content>
</entry>
<entry>
<title>intel_pstate: Add get_scaling cpu_defaults param to Knights Landing</title>
<updated>2015-07-26T23:59:43Z</updated>
<author>
<name>Lukasz Anaczkowski</name>
<email>lukasz.anaczkowski@intel.com</email>
</author>
<published>2015-07-21T08:41:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=69cefc273f942bd7bb347a02e8b5b738d5f6e6f3'/>
<id>urn:sha1:69cefc273f942bd7bb347a02e8b5b738d5f6e6f3</id>
<content type='text'>
Scaling for Knights Landing is same as the default scaling (100000).
When Knigts Landing support was added to the pstate driver, this
parameter was omitted resulting in a kernel panic during boot.

Fixes: b34ef932d79a (intel_pstate: Knights Landing support)
Reported-by: Yasuaki Ishimatsu &lt;yishimat@redhat.com&gt;
Signed-off-by: Dasaratharaman Chandramouli &lt;dasaratharaman.chandramouli@intel.com&gt;
Signed-off-by: Lukasz Anaczkowski &lt;lukasz.anaczkowski@intel.com&gt;
Acked-by: Kristen Carlson Accardi &lt;kristen@linux.intel.com&gt;
Cc: 4.1+ &lt;stable@vger.kernel.org&gt; # 4.1+
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge branches 'pm-cpuidle', 'pm-cpufreq' and 'acpi-resources'</title>
<updated>2015-07-16T21:47:19Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2015-07-16T21:47:19Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=17ffc8b083ac299ff798419d1887b7cdcd4ae4d2'/>
<id>urn:sha1:17ffc8b083ac299ff798419d1887b7cdcd4ae4d2</id>
<content type='text'>
* pm-cpuidle:
  suspend-to-idle: Prevent RCU from complaining about tick_freeze()

* pm-cpufreq:
  cpufreq: Allow freq_table to be obtained for offline CPUs
  cpufreq: Initialize the governor again while restoring policy

* acpi-resources:
  ACPI / PCI: Fix regressions caused by resource_size_t overflow with 32-bit kernel
</content>
</entry>
<entry>
<title>cpufreq: Allow freq_table to be obtained for offline CPUs</title>
<updated>2015-07-09T23:43:27Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2015-07-09T23:43:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=5a31d594a9732a2fa2eb83b0c4dcba75da2dff5d'/>
<id>urn:sha1:5a31d594a9732a2fa2eb83b0c4dcba75da2dff5d</id>
<content type='text'>
Users of freq table may want to access it for any CPU from
policy-&gt;related_cpus mask. One such user is cpu-cooling layer. It gets a
list of 'clip_cpus' (equivalent to policy-&gt;related_cpus) during
registration and tries to get freq_table for the first CPU of this mask.

If the CPU, for which it tries to fetch freq_table, is offline,
cpufreq_frequency_get_table() fails. This happens because it relies on
cpufreq_cpu_get_raw() for its functioning which returns policy only for
online CPUs.

The fix is to access the policy data structure for the given CPU
directly (which also returns a valid policy for offline CPUs), but the
policy itself has to be active (meaning that at least one CPU using it
is online) for the frequency table to be returned.

Because we will be using 'cpufreq_cpu_data' now, which is internal to
the cpufreq core, move cpufreq_frequency_get_table() to cpufreq.c.

Reported-and-tested-by: Pi-Cheng Chen &lt;pi-cheng.chen@linaro.org&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Initialize the governor again while restoring policy</title>
<updated>2015-07-09T23:36:27Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2015-07-09T23:36:27Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=35afd02e30d6368073df604920c4ea7cddadf5d0'/>
<id>urn:sha1:35afd02e30d6368073df604920c4ea7cddadf5d0</id>
<content type='text'>
When all CPUs of a policy are hot-unplugged, we EXIT the governor but
don't mark policy-&gt;governor as NULL. This was done in order to keep last
used governor's information intact in sysfs, while the CPUs are offline.

But we also need to clear policy-&gt;governor when restoring the policy.

Because policy-&gt;governor still points to the last governor while policy
is restored, following sequence of event happens:
 - cpufreq_init_policy() called while restoring policy
 - find_governor() matches last_governor string for present governors and
   returns last used governor's pointer, say ondemand. policy-&gt;governor
   already has the same address, unless the governor was removed in
   between.
 - cpufreq_set_policy() is called with both old/new policies governor set
   as ondemand.
 - Because governors matched, we skip governor initialization and return
   after calling __cpufreq_governor(CPUFREQ_GOV_LIMITS). Because the
   governor wasn't initialized for this policy, it returned -EBUSY.
 - cpufreq_init_policy() exits the policy on this error, but doesn't
   destroy it properly (should be fixed separately).
 - And so we enter a scenario where the policy isn't completely
   initialized but used.

Fix this by setting policy-&gt;governor to NULL while restoring the policy.

Reported-and-tested-by: Pi-Cheng Chen &lt;pi-cheng.chen@linaro.org&gt;
Reported-and-tested-by: "Jon Medhurst (Tixy)" &lt;tixy@linaro.org&gt;
Reported-and-tested-by: Steven Rostedt &lt;rostedt@goodmis.org&gt;
Fixes: 18bf3a124ef8 (cpufreq: Mark policy-&gt;governor = NULL for inactive policies)
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>MIPS, CPUFREQ: Fix spelling of Institute.</title>
<updated>2015-07-07T18:59:42Z</updated>
<author>
<name>Ralf Baechle</name>
<email>ralf@linux-mips.org</email>
</author>
<published>2015-07-07T18:56:04Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=0bb383a2d8f51e32ecc156f3f84067420ffe6d20'/>
<id>urn:sha1:0bb383a2d8f51e32ecc156f3f84067420ffe6d20</id>
<content type='text'>
Signed-off-by: Ralf Baechle &lt;ralf@linux-mips.org&gt;
</content>
</entry>
<entry>
<title>Merge tag 'module-builtin_driver-v4.1-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux</title>
<updated>2015-07-02T17:42:13Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-07-02T17:42:13Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=75462c8a87ec229e6796df5075318d824df31ead'/>
<id>urn:sha1:75462c8a87ec229e6796df5075318d824df31ead</id>
<content type='text'>
Pull module_platform_driver replacement from Paul Gortmaker:
 "Replace module_platform_driver with builtin_platform driver in non
  modules.

  We see an increasing number of non-modular drivers using
  modular_driver() type register functions.  There are several downsides
  to letting this continue unchecked:

   - The code can appear modular to a reader of the code, and they won't
     know if the code really is modular without checking the Makefile
     and Kconfig to see if compilation is governed by a bool or
     tristate.

   - Coders of drivers may be tempted to code up an __exit function that
     is never used, just in order to satisfy the required three args of
     the modular registration function.

   - Non-modular code ends up including the &lt;module.h&gt; which increases
     CPP overhead that they don't need.

   - It hinders us from performing better separation of the module init
     code and the generic init code.

  So here we introduce similar macros for builtin drivers.  Then we
  convert builtin drivers (controlled by a bool Kconfig) by making the
  following type of mapping:

    module_platform_driver()       ---&gt;  builtin_platform_driver()
    module_platform_driver_probe() ---&gt;  builtin_platform_driver_probe().

  The set of drivers that are converted here are just the ones that
  showed up as relying on an implicit include of &lt;module.h&gt; during a
  pending header cleanup.  So we convert them here vs adding an include
  of &lt;module.h&gt; to non-modular code to avoid compile fails.  Additonal
  conversions can be done asynchronously at any time.

  Once again, an unused module_exit function that is removed here
  appears in the diffstat as an outlier wrt all the other changes"

* tag 'module-builtin_driver-v4.1-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux:
  drivers/clk: convert sunxi/clk-mod0.c to use builtin_platform_driver
  drivers/power: Convert non-modular syscon-reboot to use builtin_platform_driver
  drivers/soc: Convert non-modular soc-realview to use builtin_platform_driver
  drivers/soc: Convert non-modular tegra/pmc to use builtin_platform_driver
  drivers/cpufreq: Convert non-modular s5pv210-cpufreq.c to use builtin_platform_driver
  drivers/cpuidle: Convert non-modular drivers to use builtin_platform_driver
  drivers/platform: Convert non-modular pdev_bus to use builtin_platform_driver
  platform_device: better support builtin boilerplate avoidance
</content>
</entry>
<entry>
<title>Merge tag 'module-implicit-v4.1-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux</title>
<updated>2015-07-02T17:25:22Z</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2015-07-02T17:25:22Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=9d86b4128cdf791a3e7c21ac1cf4564a4fca36b6'/>
<id>urn:sha1:9d86b4128cdf791a3e7c21ac1cf4564a4fca36b6</id>
<content type='text'>
Pull implicit module.h fixes from Paul Gortmaker:
 "Fix up implicit &lt;module.h&gt; users that will break later.

  The files changed here are simply modular source files that are
  implicitly relying on &lt;module.h&gt; being present.  We fix them up now,
  so that we can decouple some of the module related init code from the
  core init code in the future.

  The addition of the module.h include to several files here is also a
  no-op from a code generation point of view, else there would already
  be compile issues with these files today.

  There may be lots more implicit includes of &lt;module.h&gt; in tree, but
  these are the ones that extensive build test coverage has shown that
  must be fixed in order to avoid build breakage fallout for the pending
  module.h &lt;---&gt; init.h code relocation we desire to complete"

* tag 'module-implicit-v4.1-rc8' of git://git.kernel.org/pub/scm/linux/kernel/git/paulg/linux:
  frv: add module.h to mb93090-mb00/flash.c to avoid compile fail
  drivers/cpufreq: include &lt;module.h&gt; for modular exynos-cpufreq.c code
  drivers/staging: include &lt;module.h&gt; for modular android tegra_ion code
  crypto/asymmetric_keys: pkcs7_key_type needs module.h
  sh: mach-highlander/psw.c is tristate and should use module.h
  drivers/regulator: include &lt;module.h&gt; for modular max77802 code
  drivers/pcmcia: include &lt;module.h&gt; for modular xxs1500_ss code
  drivers/hsi: include &lt;module.h&gt; for modular omap_ssi code
  drivers/gpu: include &lt;module.h&gt; for modular rockchip code
  drivers/gpio: include &lt;module.h&gt; for modular crystalcove code
  drivers/clk: include &lt;module.h&gt; for clk-max77xxx modular code
</content>
</entry>
</feed>
