Commit Graph

405349 Commits

Author SHA1 Message Date
Huang, Tao
a3cebb509a arm: rockchip: efuse: fix compilation error on arm
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-20 20:31:57 +08:00
Huang, Tao
d2cd7b6321 arm: rockchip: use read_cpuid_part instead of read_cpuid_part_number
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-20 16:02:24 +08:00
Huang, Tao
ceaf071f79 rk: gcc-wrapper.py ignore sysctl_net_core.c:24
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-20 15:34:59 +08:00
Huang, Tao
addd2754f3 rkwifi: dhd_config: fix compilation warning
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-20 15:34:03 +08:00
Huang, Tao
250ff749b2 rk1000: fix compilation warning 2015-05-20 15:17:32 +08:00
Huang, Tao
231897adf5 Merge branch develop-3.10-next 2015-05-20 14:49:34 +08:00
Xiao Feng
13cd935ba6 ddrfreq: add vop bandwidth freq table in dts, in order to support more boards
Signed-off-by: Xiao Feng <xf@rock-chips.com>
2015-05-20 14:33:20 +08:00
Xiao Feng
70a937f8a3 ddrfreq: fix new_freq=0 when the current load of ddr is between high_load and low_load
Signed-off-by: Xiao Feng <xf@rock-chips.com>
2015-05-20 14:32:03 +08:00
Alpha Lin
3dac608904 VPU, set the power-on flag after power domain already on.
Previous register operation before power on.
Software reset vpu inside vdpu interrupt handle.

Signed-off-by: Alpha Lin <alpha.lin@rock-chips.com>
2015-05-20 13:54:47 +08:00
Sugar Zhang
3fcbca1c7c ASoC: es8316: reduce standby power consumption around ~uA.
Signed-off-by: Sugar Zhang <sugar.zhang@rock-chips.com>
2015-05-20 11:10:11 +08:00
hjc
a597d99bfe rk fb:extern rockchip_get_screen_type for mipi dsi
Signed-off-by: hjc <hjc@rock-chips.com>
2015-05-20 11:05:09 +08:00
hjc
7369a1c17b rk fb: fix hdmi/cvbs display error when uboot display logo
Signed-off-by: hjc <hjc@rock-chips.com>
2015-05-20 11:00:21 +08:00
Zheng Yang
33f635665a HDMI: Not filter the input 3dmode with EDID information.
If input 3dmode is not list in EDID, we print a
	warning log and send it to sink, no longer return
	error.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2015-05-19 18:08:02 +08:00
Zheng Yang
77d30fd62d HDMI: fix edid 3d information offset parse error.
In EDID 3D descriptor, 3d information is after
	4K format. But we did not increase the offset of
	3d content if 4K format is zero, which make 3d
	information error.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2015-05-19 18:07:45 +08:00
Zheng Yang
c0e8b29213 HDMI: Not filter the input 3dmode with EDID information.
If input 3dmode is not list in EDID, we print a
	warning log and send it to sink, no longer return
	error.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2015-05-19 17:53:55 +08:00
Zheng Yang
09fe887fd1 HDMI: fix edid 3d information offset parse error.
In EDID 3D descriptor, 3d information is after
	4K format. But we did not increase the offset of
	3d content if 4K format is zero, which make 3d
	information error.

Signed-off-by: Zheng Yang <zhengyang@rock-chips.com>
2015-05-19 17:50:55 +08:00
Mark Yao
ea92877923 rk_fb: compatible for mid hdmi switch screen
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2015-05-19 11:37:42 +08:00
Mark Yao
63f03d7c12 rockchip: video: fix logo display when switch screen
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2015-05-19 11:37:35 +08:00
Huang, Tao
50b9a50e3e input: keyboard: rk_keys: add wake lock
New version Android will never call EPOLLWAKEUP or EVIOCSSUSPENDBLOCK.
So we need add wake lock in driver.

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-19 11:09:02 +08:00
Huang, Tao
3d5bfb827c input: keyboard: rk_keys: use jiffies rather than msecs_to_jiffies
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-19 11:09:02 +08:00
Huang, Tao
3b6c8b4b8d input: keyboard: rk_keys: fix CodingStyle issues only
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-19 11:09:01 +08:00
Mark Yao
16deb4e06f rk_fb: compatible for mid hdmi switch screen
Signed-off-by: Mark Yao <mark.yao@rock-chips.com>
2015-05-19 10:56:48 +08:00
Xiao Feng
b79a8ca460 rk3368: cpufreq: fix pm_notifier return NOTIFY_BAD
the big cluster mask is random when down cpu1~cpu7, so we get the error policy cpu in pm_notifier.

Signed-off-by: Xiao Feng <xf@rock-chips.com>
2015-05-18 21:23:31 +08:00
Huang, Tao
7185846301 arm64: rockchip: cpuquiet: be quiet when cpu up/down
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 18:22:30 +08:00
Huang, Tao
065c345991 cpufreq: rockchip_big_little: minor cleanups
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:26:13 +08:00
Huang, Tao
55c23da59b rockchip: hmp: adjust hmp_up/down_threshold
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:25:12 +08:00
Huang, Tao
33df9dc9ce cpuquiet: add rockchip cpuquiet bl_balanced governor driver
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:22:52 +08:00
Huang, Tao
35ada0dbd7 cpuquiet: add rockchip cpuquiet driver
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:20:35 +08:00
Huang, Tao
0c1b12d1c3 cpuquiet: Update averaging of nr_runnables
Doing a Exponential moving average per nr_running++/-- does not
guarantee a fixed sample rate which induces errors if there are lots of
threads being enqueued/dequeued from the rq (Linpack mt). Instead of
keeping track of the avg, the scheduler now keeps track of the integral
of nr_running and allows the readers to perform filtering on top.

Implemented a proper exponential moving average for the runnables
governor and a straight 100ms average for the balanced governor. Tweaked
the thresholds for the runnables governor to minimize latency. Also,
decreased sample_rate for the runnables governor to the absolute minimum
of 10msecs.

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:17:28 +08:00
Huang, Tao
e615617818 cpuquiet: PM QoS: Add max/min online cpus as PM QoS parameter
Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
2015-05-18 17:08:55 +08:00
Krishna Sitaraman
330f2357c1 arm64: add cpu power configs to arm64/Kconfig
Add cpuquiet to proper location

Bug 1453967

Change-Id: I03b35ed12acdf5c6fc62c3bddc8b5a2a018a1303
Signed-off-by: Krishna Sitaraman <ksitaraman@nvidia.com>
Reviewed-on: http://git-master/r/396582
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Adeel Raza <araza@nvidia.com>
Reviewed-by: Alexander Van Brunt <avanbrunt@nvidia.com>
2015-05-18 16:56:46 +08:00
Sai Charan Gurrappadi
af40718fd7 cpuquiet: Added cpuquiet to driver Makefile
Change-Id: I8a3fd51df81de8d4375b9ddabbaf4fed5277b17d
Signed-off-by: Sai Charan Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/123849
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>

Rebase-Id: R90846374c2567592a285664e65941d6534017c8a
2015-05-18 16:56:29 +08:00
Sai Gurrappadi
336b58f94a drivers: cpuquiet: Fix runnable gov device_busy
On device_busy, the runnable governor stops its sample timer and cancels
any queued runnable_work. However, it is possible for the cpuquiet
platform driver to call device_busy on cpuquiet_quiesence/wake_cpu calls
which can be invoked from the queued runnable_worker thread. This will
lead to the runnable_worker thread waiting infinitely on it self
finishing in cancel_work_sync.

Fix this by removing the cancel_work_sync call as it isn't necessary
because the worker doesn't requeue it self. Stopping the timer is
sufficient.

Bug 200002511

Change-Id: Ic69061b12d4dbb96b259ed9b62a0475271bd36d0
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
(cherry picked from commit b9a2a2cfa91d14935fdef626517d738399af4e4d)
Reviewed-on: http://git-master/r/415315
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
Reviewed-by: Kerwin Wan <kerwinw@nvidia.com>
2015-05-18 16:07:12 +08:00
Sai Gurrappadi
b9cd6df053 cpuquiet: Add Sysfs node for nr_run_thresholds
Added sysfs node that exposes the nr_runnable threshold at which cores
are quiesenced/woken up. To write into this node:

echo 1core# 2core# ... n_core# > nr_run_thresholds

Bug 1427140

Change-Id: I7cabd63692cf92f7fe8d1064437b1d73002d4ba5
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/369017
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:12 +08:00
Sai Gurrappadi
e3d26340f7 cpuquiet: Support X cpus for runnables governor
Runnables govenror will now work properly for any number of cpus as
defined by NR_CPUS. Switched the ordering of nr_run_threshold init to
ensure that array is initialized correctly to UINT_MAX for NR_CPUS-1 cpu.

Bug 1427140

Change-Id: Ic612406ceaf80dd7e0b6693906df339f8b6512aa
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/369016
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:12 +08:00
Sai Gurrappadi
46f7d5dbde cpuquiet: Clean up sysfs memory properly
Runnable sysfs node wasn't being free'd in stop via a kobject_put call
because the sysfs node wasn't allocated with kobject_create. Now do an
explicity kfree on stop after the kobject_put.

Change-Id: I5ba554312757380dfb2e814f75832b28d4c7edf8
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/346645
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:11 +08:00
Sai Gurrappadi
e7e8701d15 cpuquiet: Fix locking in driver_unregister
cpuquiet_switch_governors needs to be protected with the cpuquiet_lock.

Change-Id: I948d1190a270b9e8b732eaad80a303560fe9f282
Signed-off-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-on: http://git-master/r/345013
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:11 +08:00
Jubeom Kim
6ad827eb42 cpuquiet: move back cpuquiet_lock
Moved cpuquiet_lock to the back of cpuquiet_switch_governor().
cpuquiet_switch_governor() has to be protected by cpuquiet_lock.
In the runnable cpuquiet_governor case, it can occur a kernel panic or BUG_ON
because schedule_work() and INIT_WORK() can be performed at the same time.

Bug 1410816

Change-Id: I6d3d69bd8896e5425a762cbc4a58343a319edf29
Signed-off-by: Jubeom Kim <jubeomk@nvidia.com>
(cherry picked from commit 8502d0b7c057f96b7cd0495b49e37fc968d4bf8a)
Reviewed-on: http://git-master/r/337335
Reviewed-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Tested-by: Sai Gurrappadi <sgurrappadi@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:11 +08:00
Dan Willemsen
853a480588 cpuquiet: balanced: WQ_RESCUER has been removed
Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com>
2015-05-18 16:07:11 +08:00
Simo Melenius
b84a489e75 ARM: tegra: cpuquiet: augment no_lp to force both LP and G
- tegra_cpuquiet 'no_lp' node now accepts '-1' to force LP cluster on
- when a cluster is forced the switches take place immediately without
  any delay

Bug 1247636

Change-Id: I1ec07acc3cf51419a4770542c6a1c90b92e0bf66
Signed-off-by: Simo Melenius <smelenius@nvidia.com>
Reviewed-on: http://git-master/r/208772
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
(cherry picked from commit ab16bbb6f581da538448d2a64e03dd272b8fb985)
Reviewed-on: http://git-master/r/210358
2015-05-18 16:07:11 +08:00
Peter De Schrijver
92c4d8b6f0 ARM: tegra: cpuquiet: make userspace governor actions synchronous
Userspace expects changes to happen synchronously. Implement this by waiting
with a (configureable) timeout for the action to happen.

Bug 1220065

Change-Id: I81301719707e4baf2b3aea62c38fc771ffe1205d
Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
Reviewed-on: http://git-master/r/200013
Reviewed-by: Simone Willett <swillett@nvidia.com>
Tested-by: Simone Willett <swillett@nvidia.com>
2015-05-18 16:07:10 +08:00
Peter Boonstoppel
a0529ec18b cpuquiet: Remove synchronization from runnables_work_func()
runnables_stop() can deadlock when cancel_work_sync() waits for the
work function to end and the work function blocks on the same lock
held by runnables_stop().

Removing the locks from runnables_work_func() fixes this. This should
be safe because runnables_lock protects runnables_state and
runnables_work_func() only reads runnables_state. Also, the functions
that change state to DISABLED do a cancel_work_sync() to guarantee the
work function stopped running.

Bug 1215668

Change-Id: I70617b3b0fc81db8555869e67e3b11652af8d94c
Signed-off-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-on: http://git-master/r/193881
Reviewed-by: Mandar Padmawar <mpadmawar@nvidia.com>
Tested-by: Mandar Padmawar <mpadmawar@nvidia.com>
2015-05-18 16:07:10 +08:00
Sami Liedes
a5ba2c6a79 cpuquiet: Fix warning about unused variable
drivers/cpuquiet/governors/runnable_threads.c: In function 'runnables_work_func':
drivers/cpuquiet/governors/runnable_threads.c:184:14: warning: unused variable 'state' [-Wunused-variable]

Change-Id: I26c2288876043cf3dd21e1b57317a1f5b2de5a9b
Signed-off-by: Sami Liedes <sliedes@nvidia.com>
Reviewed-on: http://git-master/r/197469
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
2015-05-18 16:07:10 +08:00
Juha Tukkinen
be640e7ea9 cpuquiet: Add GCOV_PROFILE for governors
Include cpuquiet in GCOV profiling when enabled by defconfig.

Change-Id: Iadac806d4b7efd9e34afa765dbec59f0491b96a8
Signed-off-by: Juha Tukkinen <jtukkinen@nvidia.com>
Reviewed-on: http://git-master/r/192980
Reviewed-by: Automatic_Commit_Validation_User
2015-05-18 16:07:10 +08:00
Juha Tukkinen
73bd03ae8d cpuquiet: Add GCOV_PROFILE
Include cpuquiet in GCOV profiling when enabled by defconfig.

Change-Id: I448602d2c79f4113b99e6546743585e629fa726e
Signed-off-by: Juha Tukkinen <jtukkinen@nvidia.com>
Reviewed-on: http://git-master/r/131127
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>

Rebase-Id: R7daa534f10a211bf7b15a253f5cfee7a126428f0
2015-05-18 16:07:09 +08:00
Peter Boonstoppel
e2f9ff4d86 cpuquiet: Fix race in runnable governor
Fixed a race where the cpuquiet driver would call device_free() before
the governor was started, which would lead to a kernel panic because
runnables_timer was not initialized.

Introduced RUNNING state, so states are:
- DISABLED: truly disabled
- IDLE: enabled, but not polling upon request from the driver
- RUNNING: actively polling

Bug 1189042

Change-Id: I45b9ce40e61e1cfddde74ff7b2691722204045bb
Signed-off-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-on: http://git-master/r/168803
Reviewed-by: Sang-Hun Lee <sanlee@nvidia.com>
Tested-by: Sang-Hun Lee <sanlee@nvidia.com>
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:09 +08:00
Peter De Schrijver
4643c04d29 cpuquiet: Make stats optional
Make the per CPU statistics a configureable option.

bug 1049625

Change-Id: I28b248bbbad89a19e8d8d69400733dfd4a2cf052
Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
Reviewed-on: http://git-master/r/168749
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:09 +08:00
Peter Boonstoppel
c516e3445c cpuquiet: Update runnable gov param 20/100ms (1.25/2.25/2.5 +.5)
Sampling interval: 20ms
Window size: 100ms

Thresholds: 1.25/2.25/2.5 thread
Hysteresis: .5 thread

Bug 1050445

Change-Id: I5138bed06e6f3548ec440d2b9ee17460fc37adfb
Signed-off-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-on: http://git-master/r/163105
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Diwakar Tundlam <dtundlam@nvidia.com>
2015-05-18 16:07:09 +08:00
Peter De Schrijver
c5ee21ccde cpuquiet: initialize runnable threads first as the default governor
Add the necessary code to initialize the runnable threads governor first when
selected as the default governor.

Change-Id: Iebbf304f3934b429d8a217011b3cb45ecddfd558
Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
Reviewed-on: http://git-master/r/131438
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

Rebase-Id: Rb5009930e554648a17d78edf9d8bdd17199c9c6a
2015-05-18 16:07:08 +08:00
Peter De Schrijver
3f82668838 cpuquiet: balanced governor requires cpufreq
The balanced governor relies on cpufreq for some of its decisions. Fail
initialization if there are no cpufreq OPP tables available.

Change-Id: I5d64215d56f50d5df52c1433208b1eb40440c812
Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
Reviewed-on: http://git-master/r/131437
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Peter Boonstoppel <pboonstoppel@nvidia.com>
Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>

Rebase-Id: R03bb471218a088a816a67232861759cba2b91f38
2015-05-18 16:07:08 +08:00