com.samsung.sdk.sperf
Class CustomParams
- java.lang.Object
-
- com.samsung.sdk.sperf.CustomParams
-
public class CustomParams extends java.lang.Object
This class defines the system resources that can be requested.- Since:
- v1.0.0
-
-
Field Summary
Fields Modifier and Type Field and Description static int
TYPE_BUS_MAX
Maximum RAM bus frequency for the power preferred mode.static int
TYPE_BUS_MIN
Minimum RAM bus frequency for the performance preferred mode.static int
TYPE_CPU_AWAKE
Keep the CPU awake (disable the C-state.)static int
TYPE_CPU_CORE_NUM_MAX
Maximum number of active CPU cores for the power preferred mode.static int
TYPE_CPU_CORE_NUM_MIN
Minimum number of active CPU cores for the performance preferred mode.static int
TYPE_CPU_MAX
Maximum CPU frequency for the power preferred mode.static int
TYPE_CPU_MIN
Minimum CPU frequency for the performance preferred mode.static int
TYPE_GPU_MAX
Maximum GPU frequency for the power preferred mode.static int
TYPE_GPU_MIN
Minimum GPU frequency for the performance preferred mode.static int
TYPE_TASK_AFFINITY
CPU core for the process.static int
TYPE_TASK_PRIORITY
Process scheduler priority.
-
Constructor Summary
Constructors Constructor and Description CustomParams()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description int
add(int type, int level, int timeout)
Add a resource to the CustomParams instance for boosting.
-
-
-
Field Detail
-
TYPE_CPU_MIN
public static final int TYPE_CPU_MIN
- Level range
- [ 0 ~ 4 ]
- Description
-
Minimum CPU frequency for the performance preferred mode.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_CPU_MAX
public static final int TYPE_CPU_MAX
- Level range
- [ 0 ~ 4 ]
- Description
-
Maximum CPU frequency for the power preferred mode. This request has a higher priority than TYPE_CPU_MIN.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_GPU_MIN
public static final int TYPE_GPU_MIN
- Level range
- [ 0 ~ 4 ]
- Description
-
Minimum GPU frequency for the performance preferred mode.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_GPU_MAX
public static final int TYPE_GPU_MAX
- Level range
- [ 0 ~ 4 ]
- Description
-
Maximum GPU frequency for the power preferred mode. This request has a higher priority than TYPE_GPU_MIN.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_BUS_MIN
public static final int TYPE_BUS_MIN
- Level range
- [ 0 ~ 4 ]
- Description
-
Minimum RAM bus frequency for the performance preferred mode.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_BUS_MAX
public static final int TYPE_BUS_MAX
- Level range
- [ 0 ~ 4 ]
- Description
-
Maximum RAM bus frequency for the power preferred mode. This request has a higher priority than TYPE_BUS_MIN.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_CPU_CORE_NUM_MIN
public static final int TYPE_CPU_CORE_NUM_MIN
- Level range
- [ 0 ~ 1 ]
- Level 1: Use all cores
- Description
-
Minimum number of active CPU cores for the performance preferred mode.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_CPU_CORE_NUM_MAX
public static final int TYPE_CPU_CORE_NUM_MAX
- Level range
- [ 0 ~ 1 ]
- Level 1: Use all cores
- Description
-
Maximum number of active CPU cores for the power preferred mode. This request has a higher priority than TYPE_CPU_CORE_NUM_MIN.
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_TASK_AFFINITY
public static final int TYPE_TASK_AFFINITY
- Level range
- [ 0 ~ 2 ]
- Level 0: Use all cores (default)
- Level 1: Use performance preferred core
- Level 2: Use power saving preferred core
- Description
-
CPU core for the process. This resource must be reset manually to level 0.
Valid only as an argument for the doBoostForPid() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_TASK_PRIORITY
public static final int TYPE_TASK_PRIORITY
- Level range
- [ 0 ~ 4 ]
- Level 0: Highest priority
- Level 4: Lowest priority
- Description
-
Process scheduler priority. This resource must be reset manually to level 2.
Valid only as an argument for the doBoostForPid() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
TYPE_CPU_AWAKE
public static final int TYPE_CPU_AWAKE
- Level range
- [ 0 ]
- Level 0: Enable
- Description
-
Keep the CPU awake (disable the C-state.)
Valid only as an argument for the requestPerfLevel() method.
- See Also:
add(int type, int level, int timeout)
, Constant Field Values
-
-
Method Detail
-
add
public int add(int type, int level, int timeout)
Add a resource to the CustomParams instance for boosting. If a resource of the same type already exists, it is overwritten.
To run the boost, usestart(CustomParams)
.- Parameters:
type
- Resource type field.level
- Level to set for the resource type.timeout
- Duration to boost after this module is called, in milliseconds.- Returns:
- 0: success -1: fail
-
-