Commit Graph

870786 Commits

Author SHA1 Message Date
lucaswei
574d524746 sched/fair: Fix compilation issues for !CONFIG_SCHED_WALT
For compilation issues for !CONFIG_SCHED_WALT of the following two
commits:

commit a80cf2007d ("sched: Add support to spread tasks")

Bug: 154086870
Bug: 153823050
Signed-off-by: lucaswei <lucaswei@google.com>
Change-Id: I89e224e18f6700ea2abcd162a5b9f3f938a7ad92
2022-11-12 11:25:02 +00:00
Saravana Kannan
b80407dfe1 GKI: sched: Add back the root_domain.overutilized field
This field is necessary to maintain ABI compatibility with ACK. Add it
back, but leave it unused.

Bug: 153905799
Change-Id: Ic9ef5640fa77c3aada023843658e7e4de3bada82
Signed-off-by: Saravana Kannan <saravanak@google.com>
2022-11-12 11:25:02 +00:00
Saravana Kannan
9c949d2746 GKI: sched: Compile out push_task field in struct rq
The push_task field is a WALT related field that shouldn't be needed
since we run PELT. So conditionally compile in the field only when WALT
is enabled. Also add #ifdefs around all the uses of this field.

Bug: 153905799
Change-Id: I12edd3f2180ebab14719ba2548e83519beffacc2
Signed-off-by: Saravana Kannan <saravanak@google.com>
2022-11-12 11:25:02 +00:00
Wei Wang
d8903199a6 sched: restrict iowait boost to tasks with prefer_idle
Currently iowait doesn't distinguish background/foreground tasks and we
have seen cases where a device run to high frequency unnecessarily when
running some background I/O. This patch limits iowait boost to tasks with
prefer_idle only. Specifically, on Pixel, those are foreground and top
app tasks.

Bug: 130308826
Bug: 144961757
Test: Boot and trace
Change-Id: I2d892beeb4b12b7e8f0fb2848c23982148648a10
Signed-off-by: Wei Wang <wvw@google.com>
2022-11-12 11:25:02 +00:00
Wei Wang
ef3ff76413 trace: sched: add capacity change tracing
Add a new tracepoint sched_capacity_update when capacity value
updated.

Bug: 144177658
Bug: 144961676
Test: Boot and grab trace to check
Change-Id: I30ee55bfcc2fb5a92dd448ad364768ee428f3cc4
Signed-off-by: Wei Wang <wvw@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:01 +00:00
Miguel de Dios
ca3ca78250 sched: reduce softirq conflicts with RT
This is a forward port of pa/890483 with modifications from the original
patch due to changes in sched/softirq.c which applies the same logic.

We're finding audio glitches caused by audio-producing RT tasks
that are either interrupted to handle softirq's or that are
scheduled onto cpu's that are handling softirq's.
In a previous patch, we attempted to catch many cases of the
latter problem, but it's clear that we are still losing
significant numbers of races in some apps.

This patch attempts to address the following problem::
   It attempts to reduce the most common windows in which
   we lose the race between scheduling an RT task on a remote
   core and starting to handle softirq's on that core.
   We still lose some races, but we lose significantly fewer.
   (And we don't want to introduce any heavyweight forms
   of synchronization on these paths.)

Bug: 64912585
Bug: 136771796
Bug: 144961676
Change-Id: Ida89a903be0f1965552dd0e84e67ef1d3158c7d8
Signed-off-by: Miguel de Dios <migueldedios@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:01 +00:00
Rick Yiu
060d70c387 sched/fair: let scheduler skip util checking if cpu is idle
Current cpu util includes util of runnable tasks plus the recent
utilization of currently non-runnable tasks, so it may return a non-zero
value even there is no task running on a cpu. When scheduler is selecting
a cpu for a task, it will check if cpu util is over its capacity, what
could happen is that it will skip a cpu even it is idle, so let scheduler
skip util checking if the task perfers idle cpu and the cpu is idle.

Bug: 133284637
Bug: 144961676
Test: cpu selected as expected
Change-Id: I2c15d6b79b1cc83c72e84add70962a8e74c178b8
Signed-off-by: Rick Yiu <rickyiu@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:01 +00:00
Miguel de Dios
da4cf7a00a kernel: sched: Mitigate non-boosted tasks preempting boosted tasks
Currently when a boosted task is scheduled we use prefer_idle to try and
get it to an idle core. Once it's scheduled, there is a possibility we
can schedule a non-boosted task on the same core where the boosted task
is running on. This change aims to mitigate that possibility by checking
if the core we're targeting has a boosted task and if so, use the next
best idle core instead.

Bug: 131626264
Bug: 144961676
Change-Id: I3d321e1c71f96526f55f7f3a56e32db411311aa2
Signed-off-by: Miguel de Dios <migueldedios@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:01 +00:00
Wei Wang
34fc5a101d Revert "sched/core: fix userspace affining threads incorrectly"
This reverts commit d43b69c4ad2a977406c84d47fe8a5261e0099e78.

Bug: 133481659
Bug: 144961676
Test: build
Change-Id: I615023c611c4de1eb334e4374af7306991f4216b
Signed-off-by: Wei Wang <wvw@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:01 +00:00
Wei Wang
a756d68b85 Revert "sched/core: Fix use after free issue in is_sched_lib_based_app()"
This reverts commit 0e6ca1640cec57004d702e5e7c3e59ba77541e2f.

Bug: 133481659
Bug: 144961676
Test: build
Change-Id: Ie6a0b5e46386c98882614be19dedc61ffd3870e5
Signed-off-by: Wei Wang <wvw@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:00 +00:00
Wei Wang
79e8a318d9 Revert "sched: Improve the scheduler"
This reverts commit a3dd94a1bb80ec98924070f28ba80d93a4d559a6.

Bug: 133481659
Bug: 144961676
Test: build
Change-Id: Ib23609315f3446223521612621fe54469537c172
Signed-off-by: Wei Wang <wvw@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:00 +00:00
Rick Yiu
1de73888bd sched/fair: prefer exclusive mid cluster cpu for top-app task
For a top-app task, if it fits in mid cluster, then prefer the first
cpu in this cluster whenever possible, which happens to be the top-app
exclusive cpu in our cpuset design.

Bug: 128477368
Bug: 144961676
Test: top-app tasks assigned as expected
Change-Id: Ifdd0614f6c8c03edde4ed674c4193f4ba31aac16
Signed-off-by: Rick Yiu <rickyiu@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:00 +00:00
Connor O'Brien
ca35ac869e sched: delete unused & buggy function definitions
None of these functions does what its name implies when
CONFIG_SCHED_WALT=n. While all are currently unused, future patches
could introduce subtle bugs by calling any of them from non WALT
specific code. Delete the functions so it's obvious if new callers are
added.

Bug: 144961676
Test: build kernel
Change-Id: Ib7552afb5668b48fe2ae56307016e98716e00e63
Signed-off-by: Connor O'Brien <connoro@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:00 +00:00
Connor O'Brien
d2be4585d5 sched/fair: fix implementation of is_min_capacity_cpu()
With CONFIG_SCHED_WALT disabled, is_min_capacity_cpu() is defined to
always return true, which breaks the intended behavior of
task_fits_max(). Revise is_min_capacity_cpu() to return correct
results.

An earlier version of this patch failed to handle the case when
min_cap_orig_cpu == -1 while sched domains are being updated due to
hotplug. Add a check for this case.

Test: trace shows increased top-app placement on medium cores
Bug: 117499098
Bug: 128477368
Bug: 130756111
Bug: 144961676
Change-Id: Ia2b41aa7c57f071c997bcd0e9cdfd0808f6a2bf9
Signed-off-by: Connor O'Brien <connoro@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:25:00 +00:00
Jimmy Shiu
d11b3619dc sched/fair: refine some scheduler changes from AU drop
Refine some changes from AU90. One is to allow boosted task run on min
capacity cpu if it fits in. The other is to check fast exit for
prefer-idle task first.

Bug: 128477368
Bug: 130576120
Bug: 144961676
Test: task rq selection behavior is as expected

Change-Id: Ied57b37a361ed137d10167f0346f52a149d08cd6
Signed-off-by: Rick Yiu <rickyiu@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:59 +00:00
Rick Yiu
51456080e3 BACKPORT: sched/fair: if sync flag ignored, try to place in mid cluster
If the sync flag is ignored because the current cpu is not in
the affinity mask for the target of a sync wakeup (usually
binder call), prefer to place in the mid cluster if
possible. The main case is a "top-app" task waking a
"foreground" task when the top-app task is running on
a CPU that is not in the foreground cpuset. This patch
causes the search order from mid capacity cpu be used
when the sync flag failed.

backport from commit 98ae57d9eaf7
("ANDROID: sched/fair: if sync flag ignored, try to place in same cluster")

Bug: 117438867
Bug: 144961676
Test: boot to home, operation normal
Change-Id: I68d0cc05db1bc2cb02d4445c71b02215209e8c04
Signed-off-by: Rick Yiu <rickyiu@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:59 +00:00
spakkkk
90313858c4 Revert "sched/walt: Improve the scheduler"
This reverts commit aa790dea926ec08b236cf754bf36e3b1673f4efd.
2022-11-12 11:24:59 +00:00
Connor O'Brien
1a4353af5d cpufreq: schedutil: fix check for stale utilization values
Part of the fix from commit d86ab9cff8 ("cpufreq: schedutil: use now
as reference when aggregating shared policy requests") is reversed in
commit 05d2ca242067 ("cpufreq: schedutil: Ignore CPU load older than
WALT window size") due to a porting mistake. Restore it while keeping
the relevant change from the latter patch.

Bug: 117438867
Bug: 144961676
Test: build & boot
Change-Id: I21399be760d7c8e2fff6c158368a285dc6261647
Signed-off-by: Connor O'Brien <connoro@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:59 +00:00
Miguel de Dios
8399535f1b sched: core: Disable double lock/unlock balance in move_queued_task()
CONFIG_LOCK_STAT shows warnings in move_queued_task() for releasing a
pinned lock. The warnings are due to the calls to
double_unlock_balance() added to snapshot WALT. Lets disable them if
not building with SCHED_WALT.

Bug: 123720375
Bug: 148940637
Change-Id: I8bff8550c4f79ca535556f6ec626f17ff5fce637
Signed-off-by: Miguel de Dios <migueldedios@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:59 +00:00
Miguel de Dios
96c3f64cd4 sched: fair: Disable double lock/unlock balance in detach_task()
CONFIG_LOCK_STAT shows warnings in detach_task() for releasing a
pinned lock. The warnings are due to the calls to
double_unlock_balance() added to snapshot WALT. Lets disable them if
not building with SCHED_WALT.

Bug: 123720375
Bug: 148940637
Change-Id: Ibfa28b1434fa6006fa0117fd2df1a3eadb321568
Signed-off-by: Miguel de Dios <migueldedios@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:58 +00:00
Rick Yiu
7de89e1d8b sched/fair: apply sync wake-up to pure CFS path
Since CONFIG_SCHED_WALT is disabled, we need another way to boost
perf as sched_boost does, and skipping EAS has similar effect. We
use powerhal to handle it. Also apply sync wake-up so that pure
CFS path (when skipping EAS) can benefit from it.

(Combine the following two commits
  2d21560126cb sched/fair: apply sync wake-up to pure CFS path
  9917d5335479 sched/fair: refine check for sync wake-up)

Bug: 119932121
Bug: 117438867
Bug: 144961676
Test: boot to home, operation normal
Change-Id: I970852540839881a926b7e7da5f70ef7e0185349
Signed-off-by: Rick Yiu <rickyiu@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:58 +00:00
Connor O'Brien
63e23634b7 Revert "sched: fair: Always try to use energy efficient cpu for wakeups"
This reverts commit 63c27502786646271b4c4ba32268b727e294bbb2.

Bug: 117438867
Bug: 144961676
Test: Tracing confirms EAS is no longer always used
Change-Id: If321547a86592527438ac21c3734a9f4decda712
Signed-off-by: Connor O'Brien <connoro@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:58 +00:00
Jimmy Shiu
7d9ac85ec1 sched: fair: avoid little cpus due to sync, prev bias
Important threads can get forced to little cpu's
when the sync or prev_bias hints are followed
blindly. This patch adds a check to see whether
those paths are forcing the task to a cpu that
has less capacity than other cpu's available for
the task. If so, we ignore the sync and prev_bias
and allow the scheduler to make a free decision.

Bug: 117438867
Bug: 144961676
Change-Id: Ie5a99f9a8b65ba9382a8d0de2ae0aad843e558d1
Signed-off-by: Miguel de Dios <migueldedios@google.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:58 +00:00
Srinath Sridharan
d7ab758a70 ANDROID: sched: EAS: take cstate into account when selecting idle core
Introduce a new sysctl for this option, 'sched_cstate_aware'.
When this is enabled, select_idle_sibling in CFS is modified to
choose the idle CPU in the sibling group which has the lowest
idle state index - idle state indexes are assumed to increase
as sleep depth and hence wakeup latency increase. In this way,
we attempt to minimise wakeup latency when an idle CPU is
required.

Signed-off-by: Srinath Sridharan <srinathsr@google.com>

Includes:
sched: EAS: fix select_idle_sibling
when sysctl_sched_cstate_aware is enabled, best_idle cpu will not be chosen
in the original flow because it will goto done directly

Bug: 30107557
Bug: 144961676
Change-Id: Ie09c2e3960cafbb976f8d472747faefab3b4d6ac
Signed-off-by: martin_liu <martin_liu@htc.com>
Signed-off-by: Andres Oportus <andresoportus@google.com>
[refactored and fixed conflicts]
Signed-off-by: Chris Redpath <chris.redpath@arm.com>
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:58 +00:00
Rick Yiu
d72455859d sched: fix issue of cpu freq running at max always
All cpus are running at max freq, the reason is that in the check of
sugov_up_down_rate_limit() in cpufreq_schedutil.c, the time passed in
is always 0, so the check is always true and hence the freq will not
be updated. It is caused by sched_ktime_clock() will return 0 if
CONFIG_SCHED_WALT is not set. Fix it by replacing sched_ktime_clock()
with ktime_get_ns().

Bug: 119932718
Test: cpu freq could change after fix
Change-Id: I62a0b35208dcd7a1d23da27f909cce3e59208d1f
Signed-off-by: Rick Yiu <rickyiu@google.com>
2022-11-12 11:24:57 +00:00
Jimmy Shiu
dd13056973 sched/fair: Fix compilation issues for !CONFIG_SCHED_WALT
For compilation issues for !CONFIG_SCHED_WALT of the following two
commits:

commit fbd15b6297 ("sched/fair: Avoid force newly idle load balance if have
iowait task")
commit 5250fc5df0 ("sched/fair: Force gold cpus to do idle lb when silver has
big tasks")

Bug: 148766738
Test: build pass and boot to home
Change-Id: Ia2c6ed57d1385a8105bbd7f0aefad6efd7d76c01
Signed-off-by: Jimmy Shiu <jimmyshiu@google.com>
2022-11-12 11:24:57 +00:00
Wei Wang
06bad29583 drivers: arch_topology: wire up thermal limit for arch_scale_max_freq_capacity
before patch and "echo 50000 > /sys/class/thermal/tz-by-name/sdm-therm/emul_temp"
com.android.uibench.janktests.UiBenchJankTests#testInvalidateTree: PASSED (02m6.247s)
        gfx-avg-slow-ui-thread: 0.07110321338664297
        gfx-avg-missed-vsync: 0.0
        gfx-avg-high-input-latency: 74.25140826299423
        gfx-max-frame-time-50: 12
        gfx-min-total-frames: 2250
        gfx-avg-frame-time-99: 11.8
        gfx-avg-num-frame-deadline-missed: 1.6
        gfx-avg-frame-time-50: 9.6
        gfx-max-high-input-latency: 99.86666666666667
        gfx-avg-frame-time-90: 11.0
        gfx-avg-frame-time-95: 11.0
        gfx-max-frame-time-95: 13
        gfx-max-frame-time-90: 13
        gfx-max-slow-draw: 0.0
        gfx-max-frame-time-99: 13
        gfx-avg-slow-draw: 0.0
        gfx-max-total-frames: 2251
        gfx-avg-jank: 43.678000000000004
        gfx-max-slow-bitmap-uploads: 0.0
        gfx-max-missed-vsync: 0.0
        gfx-avg-total-frames: 2250
        gfx-max-jank: 96.67
        gfx-max-slow-ui-thread: 0.13333333333333333
        gfx-max-num-frame-deadline-missed: 3
        gfx-avg-slow-bitmap-uploads: 0.0

aefore patch and "echo 50000 > /sys/class/thermal/tz-by-name/sdm-therm/emul_temp"
google/perf/jank/UIBench/UIBench (1 Test)
----------------------------------------
[1/1] com.android.uibench.janktests.UiBenchJankTests#testInvalidateTree: PASSED (02m7.027s)
        gfx-avg-slow-ui-thread: 0.0
        gfx-avg-missed-vsync: 0.0
        gfx-avg-high-input-latency: 11.53777777777778
        gfx-max-frame-time-50: 7
        gfx-min-total-frames: 2250
        gfx-avg-frame-time-99: 8.0
        gfx-avg-num-frame-deadline-missed: 0.0
        gfx-avg-frame-time-50: 7.0
        gfx-max-high-input-latency: 41.15555555555556
        gfx-avg-frame-time-90: 7.2
        gfx-avg-frame-time-95: 7.8
        gfx-max-frame-time-95: 8
        gfx-max-frame-time-90: 8
        gfx-max-slow-draw: 0.0
        gfx-max-frame-time-99: 8
        gfx-avg-slow-draw: 0.0
        gfx-max-total-frames: 2250
        gfx-avg-jank: 0.0
        gfx-max-slow-bitmap-uploads: 0.0
        gfx-max-missed-vsync: 0.0
        gfx-avg-total-frames: 2250
        gfx-max-jank: 0.0
        gfx-max-slow-ui-thread: 0.0
        gfx-max-num-frame-deadline-missed: 0
        gfx-avg-slow-bitmap-uploads: 0.0

Bug: 143162654
Test: use emul_temp to change thermal condition and see capacity changed
Change-Id: Idbf943f9c831c288db40d820682583ade3bbf05e
Signed-off-by: Wei Wang <wvw@google.com>
Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:57 +00:00
Wei Wang
5736acecef kernel: sched: fix cpu cpu_capacity_orig being capped incorrectly
update_cpu_capacity will update cpu_capacity_orig capped with
thermal_cap, in non-WALT case, thermal_cap is previous
cpu_capacity_orig. This caused cpu_capacity_orig being capped
incorrectly.

Test: Build
Bug: 144143594
Change-Id: I1ff9d9c87554c2d2395d46b215276b7ab50585c0
Signed-off-by: Wei Wang <wvw@google.com>
(cherry picked from commit dac65a5a494f8d0c80101acc5d482d94cda6f158)
Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:57 +00:00
Pavankumar Kondeti
3d4772825c sched/walt: Fix negative count of sched_asym_cpucapacity static key
The current code sets per-cpu variable sd_asym_cpucapacity while
building sched domains even when there are no asymmetric CPUs.
This is done to make sure that EAS remains enabled on a b.L system
after hotplugging out all big/LITTLE CPUs. However it is causing
the below warning during CPU hotplug.

[13988.932604] pc : static_key_slow_dec_cpuslocked+0xe8/0x150
[13988.932608] lr : static_key_slow_dec_cpuslocked+0xe8/0x150
[13988.932610] sp : ffffffc010333c00
[13988.932612] x29: ffffffc010333c00 x28: ffffff8138d88088
[13988.932615] x27: 0000000000000000 x26: 0000000000000081
[13988.932618] x25: ffffff80917efc80 x24: ffffffc010333c60
[13988.932621] x23: ffffffd32bf09c58 x22: 0000000000000000
[13988.932623] x21: 0000000000000000 x20: ffffff80917efc80
[13988.932626] x19: ffffffd32bf0a3e0 x18: ffffff8138039c38
[13988.932628] x17: ffffffd32bf2b000 x16: 0000000000000050
[13988.932631] x15: 0000000000000050 x14: 0000000000040000
[13988.932633] x13: 0000000000000178 x12: 0000000000000001
[13988.932636] x11: 16a9ca5426841300 x10: 16a9ca5426841300
[13988.932639] x9 : 16a9ca5426841300 x8 : 16a9ca5426841300
[13988.932641] x7 : 0000000000000000 x6 : ffffff813f4edadb
[13988.932643] x5 : 0000000000000000 x4 : 0000000000000004
[13988.932646] x3 : ffffffc010333880 x2 : ffffffd32a683a2c
[13988.932648] x1 : ffffffd329355498 x0 : 000000000000001b
[13988.932651] Call trace:
[13988.932656]  static_key_slow_dec_cpuslocked+0xe8/0x150
[13988.932660]  partition_sched_domains_locked+0x1f8/0x80c
[13988.932666]  sched_cpu_deactivate+0x9c/0x13c
[13988.932670]  cpuhp_invoke_callback+0x6ac/0xa8c
[13988.932675]  cpuhp_thread_fun+0x158/0x1ac
[13988.932678]  smpboot_thread_fn+0x244/0x3e4
[13988.932681]  kthread+0x168/0x178
[13988.932685]  ret_from_fork+0x10/0x18

The mismatch between increment/decrement of sched_asym_cpucapacity
static key is resulting in the above warning. It is due to
the fact that the increment happens only when the system really
has asymmetric capacity CPUs. This check is done by going through
each CPU capacity. So when system becomes SMP during hotplug,
the increment never happens. However the decrement of this static
key is done when any of the currently online CPU has per-cpu variable
sd_asym_cpucapacity value as non-NULL. Since we always set this
variable, we run into this issue.

Our goal was to enable EAS on SMP. To achieve that enable EAS and
build perf domains (required for compute energy) irrespective
of per-cpu variable sd_asym_cpucapacity value. In this way we
no longer have to enable sched_asym_cpucapacity feature on SMP
to enable EAS.

Change-Id: Id46f2b80350b742c75195ad6939b814d4695eb07
Signed-off-by: Pavankumar Kondeti <pkondeti@codeaurora.org>
2022-11-12 11:24:57 +00:00
spakkkk
dd87470fed Revert "sched/fair: Add policy for restricting prefer_spread to newly idle balance"
To fix PELT build

This reverts commit f177186646.
2022-11-12 11:24:56 +00:00
spakkkk
202e7d3077 arm64: config: sched changes
*switch to 300Hz timer frequency
*disable cgroup freezer
*disable fair group sched
*disable cpu isolation
*disable WALT
*disable corectl
*disable cpu-boost
*disable msm-performance
*disable sched_autogroup
2022-11-12 11:24:56 +00:00
spakkkk
b297a634f5 arm64: config: disable SLUB per-CPU partial caches 2022-11-12 11:24:56 +00:00
spakkkk
43101fe0ca arm64: config: enable fq_codel queueing discipline 2022-11-12 11:24:56 +00:00
spakkkk
e5f009e15f arm64: config: disable EL2 vector hardening 2022-11-12 11:24:56 +00:00
spakkkk
04e3beff47 arm64: config: disable more unnecessary errata 2022-11-12 11:24:55 +00:00
spakkkk
431e8beb04 arm64: config: disable per-cgroup pressure tracking
Based on: 87124d3f2d
2022-11-12 11:24:55 +00:00
spakkkk
387b5b7cc4 arm64: config: disable EDAC
de0b90de78
2022-11-12 11:24:55 +00:00
momojuro
d3947c5bfd arm64: config: disable IPA unit test
"The IPA_UT (Unit Test) is onky for debugging purposes and it's
meaningless to keep it enabled for production / daily usage." kholk on Github.
2022-11-12 11:24:55 +00:00
spakkkk
18241de031 arm64: config: disable logo 2022-11-12 11:24:54 +00:00
spakkkk
640aed7a38 arm64: config: disable stack frame size warning 2022-11-12 11:24:54 +00:00
spakkkk
df7c65a9f2 arm64: config: add required configs to pass CTS tests mandatory
Based on: 672529f93d
2022-11-12 11:24:54 +00:00
spakkkk
e5dadd9ea0 arm64: config: disable some drivers
b45a3c963c
f123413842
55dfa3ce88
2022-11-12 11:24:54 +00:00
spakkkk
caef7be1c2 arm64: config: disable stability debug config 2022-11-12 11:24:54 +00:00
Danny Lin
71f41132c1 regulator: core: Set more descriptive device names
We have proper names for regulators, so use them instead of meaningless
numbers generated at boot that make it hard to identify regulators
based on their device names alone.

Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:53 +00:00
Danny Lin
0e4c247c72 Suppress overly verbose log spam
It's hard to see anything that's actually useful with so much verbose
spam in the log buffer.

Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:53 +00:00
Panchajanya1999
67d7e0a712 f2fs/sysfs: Introduce a Read-Only attribute macro
Useful when we need to set a node RO to avoid Android over-riding
the custom set values.

Change-Id: Iad8cf81504d55b8ed75e6b5563f7cf397595ec1a
Signed-off-by: Panchajanya1999 <rsk52959@gmail.com>
2022-11-12 11:24:53 +00:00
Panchajanya1999
c6eab8dcb9 f2fs/gc: Reduce GC thread urgent sleep time to 50ms
Android sets the value to 50ms via vold's IdleMaint service. Since
500ms is too long for GC to colllect all invalid segments in time
which results in performance degradation.

On un-encrypted device, vold fails to set this value to 50ms thus
degrades the performance over time.

Based on [1].

[1] https://github.com/topjohnwu/Magisk/pull/5462
Signed-off-by: Panchajanya1999 <rsk52959@gmail.com>
Change-Id: I80f2c29558393d726d5e696aaf285096c8108b23
Signed-off-by: Panchajanya1999 <rsk52959@gmail.com>
2022-11-12 11:24:53 +00:00
Park Ju Hyung
9566261ba1 f2fs: reduce timeout for uncongestion
On high fs utilization, congestion is hit quite frequently and waiting for a
whooping 20ms is too expensive, especially on critical paths.

Reduce it to an amount that is unlikely to affect UI rendering paths.

The new times are as follows:
  100 Hz  => 1 jiffy   (effective: 10 ms)
  250 Hz  => 2 jiffies (effective: 8 ms)
  300 Hz  => 2 jiffies (effective: 6 ms)
  1000 Hz => 6 jiffies (effective: 6 ms)

Co-authored-by: Danny Lin <danny@kdrag0n.dev>
Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
Signed-off-by: Adam W. Willis <return.of.octobot@gmail.com>
Signed-off-by: LibXZR <xzr467706992@163.com>
2022-11-12 11:24:53 +00:00
Danny Lin
182804e6fc f2fs: Demote GC thread to idle scheduler class
We don't want the background GC work causing UI jitter should it ever
collide with periods of user activity.

Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:52 +00:00
Park Ju Hyung
78e3f5a4b3 f2fs: set ioprio of GC kthread to idle
GC should run conservatively as possible to reduce latency spikes to the user.

Setting ioprio to idle class will allow the kernel to schedule GC thread's I/O
to not affect any other processes' I/O requests.

Signed-off-by: Park Ju Hyung <qkrwngud825@gmail.com>
Signed-off-by: Danny Lin <danny@kdrag0n.dev>
2022-11-12 11:24:52 +00:00