mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-23 18:16:01 +03:00
gpu: nvgpu: unit: improve coverage for gm20b pbdma HAL
Add unit test for the following HAL: - gm20b_pbdma_get_ctrl_hce_priv_mode_yes Jira NVGPU-3694 Jira NVGPU-4673 Change-Id: Ie6c0266753877b5fe7a5c32bf6b971d1ef34d724 Signed-off-by: Thomas Fleury <tfleury@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/2263651 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
This commit is contained in:
committed by
Alex Waterman
parent
5629bd900c
commit
31d689d489
@@ -55,6 +55,7 @@ gm20b_mm_get_big_page_sizes
|
||||
gm20b_pbdma_acquire_val
|
||||
gm20b_pbdma_device_fatal_0_intr_descs
|
||||
gm20b_pbdma_format_gpfifo_entry
|
||||
gm20b_pbdma_get_ctrl_hce_priv_mode_yes
|
||||
gm20b_pbdma_get_fc_subdevice
|
||||
gm20b_pbdma_get_gp_base
|
||||
gm20b_pbdma_get_gp_base_hi
|
||||
|
||||
@@ -481,6 +481,20 @@ done:
|
||||
return ret;
|
||||
}
|
||||
|
||||
int test_gm20b_pbdma_get_ctrl_hce_priv_mode_yes(struct unit_module *m,
|
||||
struct gk20a *g, void *args)
|
||||
{
|
||||
int ret = UNIT_FAIL;
|
||||
|
||||
assert(gm20b_pbdma_get_ctrl_hce_priv_mode_yes() ==
|
||||
pbdma_hce_ctrl_hce_priv_mode_yes_f());
|
||||
|
||||
ret = UNIT_SUCCESS;
|
||||
done:
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
int test_gm20b_pbdma_get_userd(struct unit_module *m,
|
||||
struct gk20a *g, void *args)
|
||||
{
|
||||
@@ -531,6 +545,7 @@ struct unit_module_test nvgpu_pbdma_gm20b_tests[] = {
|
||||
UNIT_TEST(pbdma_format_gpfifo_entry, test_gm20b_pbdma_format_gpfifo_entry, NULL, 0),
|
||||
UNIT_TEST(pbdma_get_gp_base, test_gm20b_pbdma_get_gp_base, NULL, 0),
|
||||
UNIT_TEST(pbdma_get_fc_subdevice, test_gm20b_pbdma_get_fc_subdevice, NULL, 0),
|
||||
UNIT_TEST(pbdma_get_ctrl_hce_priv_mode_yes, test_gm20b_pbdma_get_ctrl_hce_priv_mode_yes, NULL, 0),
|
||||
UNIT_TEST(pbdma_get_userd, test_gm20b_pbdma_get_userd, NULL, 0),
|
||||
UNIT_TEST(remove_support, test_fifo_remove_support, NULL, 0),
|
||||
};
|
||||
|
||||
@@ -232,6 +232,26 @@ int test_gm20b_pbdma_get_gp_base(struct unit_module *m,
|
||||
int test_gm20b_pbdma_get_fc_subdevice(struct unit_module *m,
|
||||
struct gk20a *g, void *args);
|
||||
|
||||
/**
|
||||
* Test specification for: test_gm20b_pbdma_get_ctrl_hce_priv_mode_yes
|
||||
*
|
||||
* Description: Check RAMFC wrappers for instance block init
|
||||
*
|
||||
* Test Type: Feature based
|
||||
*
|
||||
* Targets: gm20b_pbdma_get_ctrl_hce_priv_mode_yes
|
||||
*
|
||||
* Input: test_fifo_init_support() run for this GPU
|
||||
*
|
||||
* Steps:
|
||||
* - Check that value returned by gm20b_pbdma_get_ctrl_hce_priv_mode_yes
|
||||
* is consistent with H/W manuals.
|
||||
*
|
||||
* Output: Returns PASS if all branches gave expected results. FAIL otherwise.
|
||||
*/
|
||||
int test_gm20b_pbdma_get_ctrl_hce_priv_mode_yes(struct unit_module *m,
|
||||
struct gk20a *g, void *args);
|
||||
|
||||
/**
|
||||
* Test specification for: test_gm20b_pbdma_get_userd_addr
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user