Camera: create three new groups for camera threads
high-group is running on CPU 6-7. mid-group is running on CPU 4-5. mid-high-gropu is running on CPU 4-7. Move camera tasks to CPU 4-7 for 1 seconds when AP launch. Bug: 194271751 Test: GCA Change-Id: I8e13e9ad0057b8f42f8ed3958bf0c6d58a5a02bc
This commit is contained in:
parent
9a20a9faee
commit
f3b644db0c
3 changed files with 171 additions and 0 deletions
|
@ -149,6 +149,24 @@ on init
|
|||
chown root root /dev/cpuctl/camera-daemon/cpu.uclamp.latency_sensitive
|
||||
chown system system /dev/cpuctl/camera-daemon/cgroup.procs
|
||||
|
||||
mkdir /dev/cpuset/camera-daemon-high-group
|
||||
write /dev/cpuset/camera-daemon-high-group/cpus 0-7
|
||||
write /dev/cpuset/camera-daemon-high-group/mems 0
|
||||
chown system system /dev/cpuset/camera-daemon-high-group/tasks
|
||||
chmod 0664 /dev/cpuset/camera-daemon-high-group/tasks
|
||||
|
||||
mkdir /dev/cpuset/camera-daemon-mid-group
|
||||
write /dev/cpuset/camera-daemon-mid-group/cpus 0-7
|
||||
write /dev/cpuset/camera-daemon-mid-group/mems 0
|
||||
chown system system /dev/cpuset/camera-daemon-mid-group/tasks
|
||||
chmod 0664 /dev/cpuset/camera-daemon-mid-group/tasks
|
||||
|
||||
mkdir /dev/cpuset/camera-daemon-mid-high-group
|
||||
write /dev/cpuset/camera-daemon-mid-high-group/cpus 0-7
|
||||
write /dev/cpuset/camera-daemon-mid-high-group/mems 0
|
||||
chown system system /dev/cpuset/camera-daemon-mid-high-group/tasks
|
||||
chmod 0664 /dev/cpuset/camera-daemon-mid-high-group/tasks
|
||||
|
||||
write /sys/kernel/vendor_sched/cam_prefer_idle 1
|
||||
write /sys/kernel/vendor_sched/cam_uclamp_min 1
|
||||
|
||||
|
|
114
powerhint.json
114
powerhint.json
|
@ -154,6 +154,42 @@
|
|||
],
|
||||
"ResetOnInit": true
|
||||
},
|
||||
{
|
||||
"Name": "CDCpuset",
|
||||
"Path": "/dev/cpuset/camera-daemon/cpus",
|
||||
"Values": [
|
||||
"4-7",
|
||||
"0-7"
|
||||
],
|
||||
"ResetOnInit": true
|
||||
},
|
||||
{
|
||||
"Name": "CDHighCpusetCpus",
|
||||
"Path": "/dev/cpuset/camera-daemon-high-group/cpus",
|
||||
"Values": [
|
||||
"6-7",
|
||||
"0-7"
|
||||
],
|
||||
"ResetOnInit": true
|
||||
},
|
||||
{
|
||||
"Name": "CDMidCpusetCpus",
|
||||
"Path": "/dev/cpuset/camera-daemon-mid-group/cpus",
|
||||
"Values": [
|
||||
"4-5",
|
||||
"0-7"
|
||||
],
|
||||
"ResetOnInit": true
|
||||
},
|
||||
{
|
||||
"Name": "CDMidHighCpusetCpus",
|
||||
"Path": "/dev/cpuset/camera-daemon-mid-high-group/cpus",
|
||||
"Values": [
|
||||
"4-7",
|
||||
"0-7"
|
||||
],
|
||||
"ResetOnInit": true
|
||||
},
|
||||
{
|
||||
"Name": "F2fsRecessModeEnable",
|
||||
"Path": "/dev/sys/fs/by-name/userdata/gc_urgent",
|
||||
|
@ -420,6 +456,12 @@
|
|||
"Duration": 1000,
|
||||
"Value": "9999999"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_LAUNCH",
|
||||
"Node": "CDCpuset",
|
||||
"Duration": 1000,
|
||||
"Value": "4-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_SHOT",
|
||||
"Node": "MemFreq",
|
||||
|
@ -624,6 +666,24 @@
|
|||
"Duration": 0,
|
||||
"Value": "0"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_EXTREME",
|
||||
"Node": "CDHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "6-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_EXTREME",
|
||||
"Node": "CDMidCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-5"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_EXTREME",
|
||||
"Node": "CDMidHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_HIGH",
|
||||
"Node": "CPUUtilThreshold",
|
||||
|
@ -690,6 +750,24 @@
|
|||
"Duration": 0,
|
||||
"Value": "0"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_HIGH",
|
||||
"Node": "CDHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "6-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_HIGH",
|
||||
"Node": "CDMidCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-5"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_HIGH",
|
||||
"Node": "CDMidHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_STANDARD",
|
||||
"Node": "CDPreferHighCap",
|
||||
|
@ -738,6 +816,24 @@
|
|||
"Duration": 0,
|
||||
"Value": "20 10 80"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_STANDARD",
|
||||
"Node": "CDHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "6-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_STANDARD",
|
||||
"Node": "CDMidCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-5"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_STANDARD",
|
||||
"Node": "CDMidHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_LOW",
|
||||
"Node": "CDPreferHighCap",
|
||||
|
@ -792,6 +888,24 @@
|
|||
"Duration": 0,
|
||||
"Value": "20 10 80"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_LOW",
|
||||
"Node": "CDHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "6-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_LOW",
|
||||
"Node": "CDMidCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-5"
|
||||
},
|
||||
{
|
||||
"PowerHint": "CAMERA_STREAMING_LOW",
|
||||
"Node": "CDMidHighCpusetCpus",
|
||||
"Duration": 0,
|
||||
"Value": "4-7"
|
||||
},
|
||||
{
|
||||
"PowerHint": "FIXED_PERFORMANCE",
|
||||
"Node": "CPUBigClusterMaxFreq",
|
||||
|
|
|
@ -44,6 +44,45 @@
|
|||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "CameraServiceHighCapacity",
|
||||
"Actions": [
|
||||
{
|
||||
"Name": "JoinCgroup",
|
||||
"Params":
|
||||
{
|
||||
"Controller": "cpuset",
|
||||
"Path": "camera-daemon-high-group"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "CameraServiceMidCapacity",
|
||||
"Actions": [
|
||||
{
|
||||
"Name": "JoinCgroup",
|
||||
"Params":
|
||||
{
|
||||
"Controller": "cpuset",
|
||||
"Path": "camera-daemon-mid-group"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "CameraServiceMidHighCapacity",
|
||||
"Actions": [
|
||||
{
|
||||
"Name": "JoinCgroup",
|
||||
"Params":
|
||||
{
|
||||
"Controller": "cpuset",
|
||||
"Path": "camera-daemon-mid-high-group"
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"Name": "HighEnergySaving",
|
||||
"Actions": [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue