Treehugger Robot
f6c8f3edac
Merge "lmkd: Add clang-format upload hook" am: 8b4ad27706 am: db9a391406 am: 1fd840566e am: d68aa4a89c
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2154453
Change-Id: I84b932631027da1c0737bb6f0f13de03355ae9c8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-14 21:37:36 +00:00
Treehugger Robot
d68aa4a89c
Merge "lmkd: Add clang-format upload hook" am: 8b4ad27706 am: db9a391406 am: 1fd840566e
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2154453
Change-Id: Ib329f15a2fa5fd797c68f9fd0ac37d3a0684b572
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-14 21:20:44 +00:00
Treehugger Robot
1fd840566e
Merge "lmkd: Add clang-format upload hook" am: 8b4ad27706 am: db9a391406
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2154453
Change-Id: Ic25b988fc2e82d36f853c379870986e3178323f9
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-14 21:02:34 +00:00
Treehugger Robot
db9a391406
Merge "lmkd: Add clang-format upload hook" am: 8b4ad27706
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2154453
Change-Id: I9c568f2690cfca9f3e469a54f62718920b39c2db
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-14 20:45:46 +00:00
Treehugger Robot
8b4ad27706
Merge "lmkd: Add clang-format upload hook"
2022-07-14 20:26:12 +00:00
Kalesh Singh
08bb956823
lmkd: Add clang-format upload hook
...
Check code formatting on upload.
Bug: N/A
Test: repo upload
Signed-off-by: Kalesh Singh <kaleshsingh@google.com>
Change-Id: I7c849655539ac60e48cf2b4c25b33a1d222a6cfe
2022-07-14 11:18:20 -07:00
Ken Chen
4c18e91f22
Rename gpu_mem.o to gpuMem.o
...
Underscore character may cause bpf prog/map naming collision. For
example, x.o with map y_z and x_y.o with map z both result in x_y_z
prog/map name, which should be prevented during compile-time.
aosp/2147825 will prohibit underscore character in bpf source name
(source name derives the obj name). Existing bpf modules with underscore
characters in source name need to be updated accordingly.
Bug: 236706995
Test: adb root; adb shell ls -l /sys/fs/bpf/ | grep gpuMem
Change-Id: I213624e59ce1bca6ee7c22028504f2d51e9c50df
2022-07-08 19:09:50 +08:00
Yuming Han
1a19315add
lmkd : Fixed running wrong for Go devices when use_minfree_levels is TRUE am: ed8fc168e6 am: f3f9ff6e01 am: 60325c06b4 am: b80303c377
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2144719
Change-Id: I62c758560792bcbb6bcd627e4eb7f1f4a2449a81
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 19:51:50 +00:00
Yuming Han
b80303c377
lmkd : Fixed running wrong for Go devices when use_minfree_levels is TRUE am: ed8fc168e6 am: f3f9ff6e01 am: 60325c06b4
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2144719
Change-Id: I232c2f0afd705838e99896740f77c6e8a32c8f13
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 19:36:13 +00:00
Suren Baghdasaryan
0932e5c765
lmkd: Fix the text of the warning when pthread_setschedparam fails am: 508e73e105 am: 4a4e1590f1 am: 8d1acb0268 am: 45c03b00f7
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147680
Change-Id: I510eb3be2cb23e3e6381198ce31819409889151f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 19:17:11 +00:00
Yuming Han
60325c06b4
lmkd : Fixed running wrong for Go devices when use_minfree_levels is TRUE am: ed8fc168e6 am: f3f9ff6e01
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2144719
Change-Id: Iee575f456068a7cf98d57a4fbbbcbf1128205c7f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 19:09:44 +00:00
Suren Baghdasaryan
45c03b00f7
lmkd: Fix the text of the warning when pthread_setschedparam fails am: 508e73e105 am: 4a4e1590f1 am: 8d1acb0268
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147680
Change-Id: I2c79cdb3817c211f745950269cb3ee0cd8f78e55
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 18:53:54 +00:00
Yuming Han
f3f9ff6e01
lmkd : Fixed running wrong for Go devices when use_minfree_levels is TRUE am: ed8fc168e6
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2144719
Change-Id: I5b112f62879b9b577bdeb61939e629984e172f5a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 18:45:02 +00:00
Suren Baghdasaryan
8d1acb0268
lmkd: Fix the text of the warning when pthread_setschedparam fails am: 508e73e105 am: 4a4e1590f1
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147680
Change-Id: I38fa469fd049d2b196903af6acf7d8ce24d7c50a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 18:31:16 +00:00
Yuming Han
ed8fc168e6
lmkd : Fixed running wrong for Go devices when use_minfree_levels is TRUE
...
The lmkd run wrong for Go devices, because min_score_adj is unused
when use_minfree_levels is set TURE.
Bug: 237947900
Signed-off-by: Yuming Han <yuming.han@unisoc.com>
Change-Id: I717561cd9e5f4d1a2ca60d9fc84adcd6e129420a
2022-07-07 18:24:22 +00:00
Suren Baghdasaryan
4a4e1590f1
lmkd: Fix the text of the warning when pthread_setschedparam fails am: 508e73e105
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147680
Change-Id: I581e74df34e8174e5dd9b464a7b4bc0f4893711d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 18:11:12 +00:00
Suren Baghdasaryan
508e73e105
lmkd: Fix the text of the warning when pthread_setschedparam fails
...
Fix the text of the warning when pthread_setschedparam fails to set
SCHED_OTHER scheduling policy for a reaper thread.
Bug: 237180716
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: I1b04713d145f4f3c243f16f932c753f5b06d48e6
2022-07-07 08:39:49 -07:00
Suren Baghdasaryan
5da403fba5
lmkd: set normal scheduling policy for reaper threads am: 353c2f174f am: 94998a07dc am: 29215bbbd8 am: f394cd7f76
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147025
Change-Id: I75f62106e22498e04c2e294c240f85223d425691
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 02:12:58 +00:00
Suren Baghdasaryan
f394cd7f76
lmkd: set normal scheduling policy for reaper threads am: 353c2f174f am: 94998a07dc am: 29215bbbd8
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147025
Change-Id: Ia4931e7eac90aa0d68ef1fc282e5ccfec35495cb
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 01:57:35 +00:00
Suren Baghdasaryan
29215bbbd8
lmkd: set normal scheduling policy for reaper threads am: 353c2f174f am: 94998a07dc
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147025
Change-Id: Ie12bbd053db355fe23c55ac7ee6b7845663297c6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 01:39:54 +00:00
Suren Baghdasaryan
94998a07dc
lmkd: set normal scheduling policy for reaper threads am: 353c2f174f
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2147025
Change-Id: I7e333c8bfc132f362156d271bf1201d3a9aae8d2
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-07 01:20:20 +00:00
Suren Baghdasaryan
353c2f174f
lmkd: set normal scheduling policy for reaper threads
...
Reaper threads can take considerable time to free target's
memory running at RT priority that they inherit from LMKD.
This might prevent other critical tasks from being scheduled
while reaper threads are active.
Explicitly set reaper threads to run under normal scheduling
policy but set their nice value to ANDROID_PRIORITY_HIGHEST.
Bug: 237180716
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Idad817e698ae1d5ac6cee5aa3281c69c7e0d257f
2022-07-06 15:21:50 -07:00
Yuming Han
2894b22681
lmkd: Fixed data overflow on ARM am: 79f58c012d am: 800f962338 am: 4c3a9f2601 am: f53e9e74db
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2138097
Change-Id: If55bc3956657505488c093a1b2998f22b68a2a8a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 21:27:10 +00:00
Yuming Han
f53e9e74db
lmkd: Fixed data overflow on ARM am: 79f58c012d am: 800f962338 am: 4c3a9f2601
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2138097
Change-Id: I256d30895f90ee6a0e5b89f6d57e34be474dcabf
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 20:52:41 +00:00
Yuming Han
4c3a9f2601
lmkd: Fixed data overflow on ARM am: 79f58c012d am: 800f962338
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2138097
Change-Id: Ic496e5e01f9aed3b571495c033f20a5218aa98d4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 20:28:11 +00:00
Yuming Han
800f962338
lmkd: Fixed data overflow on ARM am: 79f58c012d
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2138097
Change-Id: I522fd95dbc7acc2774e0961ae6956fd3bd827e18
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-07-01 20:08:46 +00:00
Yuming Han
79f58c012d
lmkd: Fixed data overflow on ARM
...
Both pgscan_kwsapd and pgscan_direct are defined as unsigned long,
the overflow issues occur on ARM kernel space. Just check whether
their values changed.
Signed-off-by: Yuming Han <yuming.han@unisoc.com>
Change-Id: I73b27855ede9ca729208775e982660bae967ab92
2022-06-29 16:06:18 +08:00
Suren Baghdasaryan
a49cf928a4
lmkd: Fix the size of vmstat_field_names array am: caebcddf9f am: 2c75c4987c am: 150ff325ac am: ab1cf2b96b
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2132969
Change-Id: Ifd1c4404f5c3636b6dd16a2a46df6e926b94bd59
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-23 01:32:55 +00:00
Suren Baghdasaryan
ab1cf2b96b
lmkd: Fix the size of vmstat_field_names array am: caebcddf9f am: 2c75c4987c am: 150ff325ac
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2132969
Change-Id: I0c799db1ec9111994b36c88a54231dc1b0d4dd86
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-23 01:16:35 +00:00
Suren Baghdasaryan
150ff325ac
lmkd: Fix the size of vmstat_field_names array am: caebcddf9f am: 2c75c4987c
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2132969
Change-Id: I693d2d097a08df644df33b951e4330ed2a846aed
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-23 00:58:13 +00:00
Suren Baghdasaryan
2c75c4987c
lmkd: Fix the size of vmstat_field_names array am: caebcddf9f
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2132969
Change-Id: Id034f3723232a95b220d3f15e4f2aa7668b26294
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-23 00:39:22 +00:00
Suren Baghdasaryan
caebcddf9f
lmkd: Fix the size of vmstat_field_names array
...
The size of the vmstat_field_names array should correspond to the number
of elements in vmstat_field enum (VS_FIELD_COUNT).
Bug: 227769256
Reported-by: Yuming Han <yuming.han@unisoc.com>
Signed-off-by: Suren Baghdasaryan <surenb@google.com>
Change-Id: Icac2810c4efca2a07cefba6e220165ef4f194867
2022-06-22 23:10:47 +00:00
Kameron Lutes
b915fba841
lmkd: Fix potential null dereference in hook call am: e9769f7cf3 am: 12371c792c am: e07a5bee30 am: 6bceb12f9b
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133711
Change-Id: I4c4d724998b856d9428edb16596ba623de98863a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:39:11 +00:00
Kameron Lutes
0ca2d7083b
lmkd: Add hooks to LMKD am: 2cce3066da am: 60969b1fef am: 4fb05dfe00 am: d10338cbbd
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133710
Change-Id: I152bb02c32f95ced589cccca0e3237ec22f32546
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:39:02 +00:00
Kameron Lutes
6bceb12f9b
lmkd: Fix potential null dereference in hook call am: e9769f7cf3 am: 12371c792c am: e07a5bee30
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133711
Change-Id: I6c0a2451bea9515564a8c240b4a7c71b960138f4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:23:28 +00:00
Kameron Lutes
d10338cbbd
lmkd: Add hooks to LMKD am: 2cce3066da am: 60969b1fef am: 4fb05dfe00
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133710
Change-Id: Iad313f2ac0cc500cc09ecbe4119bdf8561a9bc7a
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:23:27 +00:00
Kameron Lutes
e07a5bee30
lmkd: Fix potential null dereference in hook call am: e9769f7cf3 am: 12371c792c
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133711
Change-Id: Ib5496447d3b5667cc5f28dd3002339c5ed448350
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:04:33 +00:00
Kameron Lutes
4fb05dfe00
lmkd: Add hooks to LMKD am: 2cce3066da am: 60969b1fef
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133710
Change-Id: If262e1cd80111a6cec8027144f9504e4042dd77f
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 22:04:29 +00:00
Kameron Lutes
12371c792c
lmkd: Fix potential null dereference in hook call am: e9769f7cf3
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133711
Change-Id: I01aeddc9d39f351e49b3d63b09ffb10f3ab7f8ae
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 21:45:39 +00:00
Kameron Lutes
60969b1fef
lmkd: Add hooks to LMKD am: 2cce3066da
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2133710
Change-Id: I5a99f58b135fa865635c2873bae0e9eea9733815
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-06-22 21:45:38 +00:00
Kameron Lutes
e9769f7cf3
lmkd: Fix potential null dereference in hook call
...
If hooks are enabled in LMKD and kill_info is not supplied to
kill_one_process, there will be a null dereference on kill_info. This
changes validates ki before dereferencing.
Bug: b/210075795
Test: cq
Change-Id: Ie81ca9bdb73a71f16dc5682c8721a557b8b094fb
Merged-In: Ie81ca9bdb73a71f16dc5682c8721a557b8b094fb
2022-06-22 03:40:33 +00:00
Kameron Lutes
2cce3066da
lmkd: Add hooks to LMKD
...
Adds several hooks to LMKD that can be overridden by the vendor. This
allows for device specific control of LMKD when necessary.
Bug: b/210075795
Test: cq
Change-Id: Ib231743183134b05148d45d681765860da6274ae
(cherry picked from commit 2c1248381a52fc520c6cd1acfaee80818eaa9ee1)
Merged-In: Ib231743183134b05148d45d681765860da6274ae
2022-06-22 03:35:23 +00:00
Yongqin Liu
788190b880
lmkd: fix the cgroup attribute name to MemCgroupEventControl am: bf819b5593 am: 14512ee7af am: 09c2245060 am: 7d2fad9ecd
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2080181
Change-Id: Ie2325f3c6bba3a46f2b8d5dd341c9a72d88a9aa6
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-29 19:49:43 +00:00
Yongqin Liu
7d2fad9ecd
lmkd: fix the cgroup attribute name to MemCgroupEventControl am: bf819b5593 am: 14512ee7af am: 09c2245060
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2080181
Change-Id: Ibb8a4af76320e100862d5d690f9a6df07f39e73c
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-29 19:16:35 +00:00
Yongqin Liu
09c2245060
lmkd: fix the cgroup attribute name to MemCgroupEventControl am: bf819b5593 am: 14512ee7af
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2080181
Change-Id: I644bfe01465528f5807c3c6977e5bdebbc5528a8
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-29 18:25:40 +00:00
Yongqin Liu
14512ee7af
lmkd: fix the cgroup attribute name to MemCgroupEventControl am: bf819b5593
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2080181
Change-Id: I8d68056cbd082ac936ef6fe7e3215665622d12e4
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-29 17:59:28 +00:00
Yongqin Liu
bf819b5593
lmkd: fix the cgroup attribute name to MemCgroupEventControl
...
which was CgroupEventControl before, but it's not the one
that definied in system/core/libprocessgroup/profiles/task_profiles.json.
And it causes lmkd crash for some setups like 4.19q + AOSP Master
Bug: 230642311
Test: boot the 4.19q + AOSP master setup with hikey960 board
Signed-off-by: Yongqin Liu <yongqin.liu@linaro.org>
Change-Id: I87b1ea2040f21c52d549db58692fc8a2b114f8e6
2022-04-29 18:50:20 +08:00
전윤재
af1c7d5046
lmkd: Fix a comparison operation with uninitialized variable. am: f70a8a260f am: 1c09b504c8 am: 48e232df6a am: c0f9ea88cc
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2073128
Change-Id: Icbe87fe387219223e0840eb9b5f10b48e032ecda
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-27 01:19:23 +00:00
전윤재
c0f9ea88cc
lmkd: Fix a comparison operation with uninitialized variable. am: f70a8a260f am: 1c09b504c8 am: 48e232df6a
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2073128
Change-Id: Ic5e857e2f840c1a828cc6794d92f88f1b570816d
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-27 00:56:46 +00:00
전윤재
48e232df6a
lmkd: Fix a comparison operation with uninitialized variable. am: f70a8a260f am: 1c09b504c8
...
Original change: https://android-review.googlesource.com/c/platform/system/memory/lmkd/+/2073128
Change-Id: I205fd40567e6842081f2cedf15feb522b31f8478
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
2022-04-27 00:41:34 +00:00