Hi Rafael,
As suggested, I have kept only what you suggested and fixed them based
on your review comments.
@Juri and Shilpa: I have also added your Tested-by's, please let me know
if you don't prefer to add them here.
V3->V4:
- Keep only relevant patches for lockdep, will send cleanups patches
separately.
- kobj_name is dropped
- Comment over update_sampling_rate is kept intact, with minor
additions.
- s/global/common for common tunables
Viresh Kumar (6):
cpufreq: governor: Create generic macro for global tuners
cpufreq: governor: Move common tunables to 'struct dbs_data'
cpufreq: governor: New sysfs show/store callbacks for governor
tunables
cpufreq: governor: Drop unused macros for creating governor tunable
attributes
Revert "cpufreq: Drop rwsem lock around CPUFREQ_GOV_POLICY_EXIT"
cpufreq: governor: Create and traverse list of policy_dbs to fix
lockdep
drivers/cpufreq/cpufreq.c | 5 -
drivers/cpufreq/cpufreq_conservative.c | 102 +++++++----------
drivers/cpufreq/cpufreq_governor.c | 127 ++++++++++++++-------
drivers/cpufreq/cpufreq_governor.h | 143 ++++++++----------------
drivers/cpufreq/cpufreq_ondemand.c | 194 ++++++++++++---------------------
include/linux/cpufreq.h | 4 -
6 files changed, 239 insertions(+), 336 deletions(-)
--
2.7.1.370.gb2aa7f8
Tree/Branch: master
Git describe: v4.5-rc3-23-g2178cbc
Commit: 2178cbc68f Merge tag 'fixes-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rusty/linux
Build Time: 83 min 12 sec
Passed: 9 / 9 (100.00 %)
Failed: 0 / 9 ( 0.00 %)
Errors: 0
Warnings: 5
Section Mismatches: 0
-------------------------------------------------------------------------------
defconfigs with issues (other than build errors):
1 warnings 0 mismatches : arm64-allmodconfig
1 warnings 0 mismatches : arm-multi_v7_defconfig
5 warnings 0 mismatches : arm-allmodconfig
1 warnings 0 mismatches : arm64-defconfig
-------------------------------------------------------------------------------
Warnings Summary: 5
4 ../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
1 ../lib/lz4/lz4hc_compress.c:514:1: warning: the frame size of 1472 bytes is larger than 1024 bytes [-Wframe-larger-than=]
1 ../drivers/ntb/test/ntb_perf.c:214:14: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
1 ../drivers/ntb/test/ntb_perf.c:213:10: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
1 ../drivers/mtd/chips/cfi_cmdset_0020.c:651:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=]
===============================================================================
Detailed per-defconfig build reports below:
-------------------------------------------------------------------------------
arm64-allmodconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm-multi_v7_defconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm-allmodconfig : PASS, 0 errors, 5 warnings, 0 section mismatches
Warnings:
../lib/lz4/lz4hc_compress.c:514:1: warning: the frame size of 1472 bytes is larger than 1024 bytes [-Wframe-larger-than=]
../drivers/mtd/chips/cfi_cmdset_0020.c:651:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=]
../drivers/ntb/test/ntb_perf.c:213:10: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
../drivers/ntb/test/ntb_perf.c:214:14: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm64-defconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
Passed with no errors, warnings or mismatches:
x86_64-allnoconfig
arm64-allnoconfig
arm-allnoconfig
arm-multi_v5_defconfig
x86_64-defconfig
Tree/Branch: master
Git describe: v4.5-rc3-19-g7cf91ad
Commit: 7cf91adc0d Merge branch 'linus' of git://git.kernel.org/pub/scm/linux/kernel/git/herbert/crypto-2.6
Build Time: 83 min 13 sec
Passed: 9 / 9 (100.00 %)
Failed: 0 / 9 ( 0.00 %)
Errors: 0
Warnings: 5
Section Mismatches: 0
-------------------------------------------------------------------------------
defconfigs with issues (other than build errors):
1 warnings 0 mismatches : arm64-allmodconfig
1 warnings 0 mismatches : arm-multi_v7_defconfig
5 warnings 0 mismatches : arm-allmodconfig
1 warnings 0 mismatches : arm64-defconfig
-------------------------------------------------------------------------------
Warnings Summary: 5
4 ../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
1 ../lib/lz4/lz4hc_compress.c:514:1: warning: the frame size of 1472 bytes is larger than 1024 bytes [-Wframe-larger-than=]
1 ../drivers/ntb/test/ntb_perf.c:214:14: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
1 ../drivers/ntb/test/ntb_perf.c:213:10: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
1 ../drivers/mtd/chips/cfi_cmdset_0020.c:651:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=]
===============================================================================
Detailed per-defconfig build reports below:
-------------------------------------------------------------------------------
arm64-allmodconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm-multi_v7_defconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm-allmodconfig : PASS, 0 errors, 5 warnings, 0 section mismatches
Warnings:
../lib/lz4/lz4hc_compress.c:514:1: warning: the frame size of 1472 bytes is larger than 1024 bytes [-Wframe-larger-than=]
../drivers/mtd/chips/cfi_cmdset_0020.c:651:1: warning: the frame size of 1032 bytes is larger than 1024 bytes [-Wframe-larger-than=]
../drivers/ntb/test/ntb_perf.c:213:10: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
../drivers/ntb/test/ntb_perf.c:214:14: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast]
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
arm64-defconfig : PASS, 0 errors, 1 warnings, 0 section mismatches
Warnings:
../drivers/tty/serial/amba-pl011.c:190:27: warning: 'vendor_zte' defined but not used [-Wunused-variable]
-------------------------------------------------------------------------------
Passed with no errors, warnings or mismatches:
x86_64-allnoconfig
arm64-allnoconfig
arm-allnoconfig
arm-multi_v5_defconfig
x86_64-defconfig
Hi Rafael,
Here is the V2 with updated patches as suggested by you guys.
These are pushed here:
git://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git cpufreq/governor-kobject
The first four patches are for 4.5, if possible and others you can keep
for 4.6.
V1->V2:
- Improved changelogs, thanks Rafael.
- Added new dbs_data->mutex to avoid concurrent updates to tunables.
- Moved kobj_type to common_dbs_data.
- Updated macros to static inline routines
- s/show/governor_show
- s/store/governor_store
- Improved comments
@Juri: More testing requested :)
Viresh Kumar (7):
cpufreq: governor: Treat min_sampling_rate as a governor-specific
tunable
cpufreq: governor: New sysfs show/store callbacks for governor
tunables
cpufreq: governor: Drop unused macros for creating governor tunable
attributes
Revert "cpufreq: Drop rwsem lock around CPUFREQ_GOV_POLICY_EXIT"
cpufreq: Merge cpufreq_offline_prepare/finish routines
cpufreq: Call __cpufreq_governor() with policy->rwsem held
cpufreq: Remove cpufreq_governor_lock
drivers/cpufreq/cpufreq.c | 93 +++++++++++++----------------
drivers/cpufreq/cpufreq_conservative.c | 79 +++++++++----------------
drivers/cpufreq/cpufreq_governor.c | 105 +++++++++++++++++++++++++--------
drivers/cpufreq/cpufreq_governor.h | 104 ++++++++------------------------
drivers/cpufreq/cpufreq_ondemand.c | 79 +++++++++----------------
include/linux/cpufreq.h | 4 --
6 files changed, 203 insertions(+), 261 deletions(-)
--
2.7.0.79.gdc08a19
Hi Rafael,
Things look much much better now. I have rebased this series over
pm/bleeding-edge, that has all your patches.
I have moved ahead and done few more changes in this series, that should
get rid of all the lockdeps we were getting earlier, that includes
fixing lockdep issue in update_sampling_rate() that we were chasing.
These are pushed here again:
git://git.kernel.org/pub/scm/linux/kernel/git/vireshk/pm.git cpufreq/governor-kobject
@Juri/Shilpa: Can you please confirm if all the issues got resolved now
?
V2->V3:
- The first patch from V2, that was moving min_sampling_rate to
per governor structure was dropped, as you suggested.
- Also, I have moved common tunables to struct dbs_data now, which you
also suggested sometime back.
- Last 5 patches are all new and fix rest of the issues we were facing.
--
viresh
Viresh Kumar (13):
cpufreq: governor: Create generic macro for global tuners
cpufreq: governor: Move common tunables to 'struct dbs_data'
cpufreq: governor: New sysfs show/store callbacks for governor
tunables
cpufreq: governor: Drop unused macros for creating governor tunable
attributes
Revert "cpufreq: Drop rwsem lock around CPUFREQ_GOV_POLICY_EXIT"
cpufreq: Merge cpufreq_offline_prepare/finish routines
cpufreq: Call __cpufreq_governor() with policy->rwsem held
cpufreq: Remove cpufreq_governor_lock
cpufreq: governor: Move common sysfs tunables to cpufreq_governor.c
cpufreq: governor: No need to manage state machine now
cpufreq: governor: Keep list of policy_dbs within dbs_data
cpufreq: ondemand: Traverse list of policy_dbs in
update_sampling_rate()
cpufreq: conservative: Update sample_delay_ns immediately
drivers/cpufreq/cpufreq.c | 98 ++++++------
drivers/cpufreq/cpufreq_conservative.c | 143 ++++--------------
drivers/cpufreq/cpufreq_governor.c | 266 +++++++++++++++++++++++++--------
drivers/cpufreq/cpufreq_governor.h | 156 ++++++++-----------
drivers/cpufreq/cpufreq_ondemand.c | 241 +++++------------------------
include/linux/cpufreq.h | 4 -
6 files changed, 381 insertions(+), 527 deletions(-)
--
2.7.1.370.gb2aa7f8