aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
diff options
context:
space:
mode:
authorDavid Gow <[email protected]>2021-12-15 20:50:14 +0000
committerShuah Khan <[email protected]>2021-12-15 23:44:55 +0000
commitad659ccb5412874c6a89d3588cb18857c00e9d0f (patch)
treeb05076d26e9ab1469cb9aca3e6f993d7eb185e96 /drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c
parentkunit: tool: fix newly introduced typechecker errors (diff)
downloadkernel-ad659ccb5412874c6a89d3588cb18857c00e9d0f.tar.gz
kernel-ad659ccb5412874c6a89d3588cb18857c00e9d0f.zip
kunit: tool: Default --jobs to number of CPUs
The --jobs parameter for kunit_tool currently defaults to 8 CPUs, regardless of the number available. For systems with significantly more (or less), this is not as efficient. Instead, default --jobs to the number of CPUs available to the process: while there are as many superstitions as to exactly what the ideal jobs:CPU ratio is, this seems sufficiently sensible to me. A new helper function to get the default number of jobs is added: get_default_jobs() -- this is used in kunit_tool_test instead of a hardcoded value, or an explicit call to len(os.sched_getaffinity()), so should be more flexible if this needs to change in the future. Signed-off-by: David Gow <[email protected]> Signed-off-by: Daniel Latypov <[email protected]> Reviewed-by: Daniel Latypov <[email protected]> Reviewed-by: Brendan Higgins <[email protected]> Signed-off-by: Shuah Khan <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_dma_buf.c')
0 files changed, 0 insertions, 0 deletions