diff options
author | Arunpravin <Arunpravin.PaneerSelvam@amd.com> | 2022-02-22 23:18:41 +0530 |
---|---|---|
committer | Christian König <christian.koenig@amd.com> | 2022-02-23 10:44:43 +0100 |
commit | 92937f170d3f49f41d7acb86243ee691a98eb2be (patch) | |
tree | a3705c67a108d61b397be2328c6b6085c67606cb /drivers/gpu/drm/lib/drm_random.h | |
parent | cb8f00f27ae7a1e8d047f1e2c96acc257f09d51b (diff) | |
download | lwn-92937f170d3f49f41d7acb86243ee691a98eb2be.tar.gz lwn-92937f170d3f49f41d7acb86243ee691a98eb2be.zip |
drm/selftests: add drm buddy alloc range testcase
- add a test to check the range allocation
- export get_buddy() function in drm_buddy.c
- export drm_prandom_u32_max_state() in lib/drm_random.c
- include helper functions
- include prime number header file
v2:
- add drm_get_buddy() function description (Matthew Auld)
- removed unnecessary test succeeded print
Signed-off-by: Arunpravin <Arunpravin.PaneerSelvam@amd.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Acked-by: Christian König <christian.koenig@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220222174845.2175-3-Arunpravin.PaneerSelvam@amd.com
Signed-off-by: Christian König <christian.koenig@amd.com>
Diffstat (limited to 'drivers/gpu/drm/lib/drm_random.h')
-rw-r--r-- | drivers/gpu/drm/lib/drm_random.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/drm/lib/drm_random.h b/drivers/gpu/drm/lib/drm_random.h index 4a3e94dfa0c0..5543bf0474bc 100644 --- a/drivers/gpu/drm/lib/drm_random.h +++ b/drivers/gpu/drm/lib/drm_random.h @@ -22,5 +22,7 @@ unsigned int *drm_random_order(unsigned int count, void drm_random_reorder(unsigned int *order, unsigned int count, struct rnd_state *state); +u32 drm_prandom_u32_max_state(u32 ep_ro, + struct rnd_state *state); #endif /* !__DRM_RANDOM_H__ */ |