diff --git a/userspace/required_tests.json b/userspace/required_tests.json index 0cebaff36..ee323776b 100644 --- a/userspace/required_tests.json +++ b/userspace/required_tests.json @@ -3365,6 +3365,12 @@ "unit": "nvgpu_tsg", "test_level": 0 }, + { + "test": "test_gv11b_tsg_bind_channel_eng_method_buffers", + "case": "gv11b_tsg_bind_channel_eng_method_buffers", + "unit": "nvgpu_tsg_gv11b", + "test_level": 0 + }, { "test": "test_gv11b_tsg_init_eng_method_buffers", "case": "gv11b_tsg_init_eng_method_buffers", diff --git a/userspace/units/fifo/tsg/gv11b/nvgpu-tsg-gv11b.c b/userspace/units/fifo/tsg/gv11b/nvgpu-tsg-gv11b.c index 113bb4873..76a5e186c 100644 --- a/userspace/units/fifo/tsg/gv11b/nvgpu-tsg-gv11b.c +++ b/userspace/units/fifo/tsg/gv11b/nvgpu-tsg-gv11b.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2019, NVIDIA CORPORATION. All rights reserved. + * Copyright (c) 2019-2020, NVIDIA CORPORATION. All rights reserved. * * Permission is hereby granted, free of charge, to any person obtaining a * copy of this software and associated documentation files (the "Software"), @@ -238,10 +238,10 @@ int test_gv11b_tsg_bind_channel_eng_method_buffers(struct unit_module *m, if (branches & F_TSG_BIND_BUF_FAST_CE_RUNLIST_ID) { tsg->runlist_id = nvgpu_engine_get_fast_ce_runlist_id(g); - gpu_va = tsg->eng_method_buffers[ASYNC_CE_RUNQUE].gpu_va; + gpu_va = eng_method_buffers[ASYNC_CE_RUNQUE].gpu_va; } else { tsg->runlist_id = nvgpu_engine_get_gr_runlist_id(g); - gpu_va = tsg->eng_method_buffers[GR_RUNQUE].gpu_va; + gpu_va = eng_method_buffers[GR_RUNQUE].gpu_va; } nvgpu_mem_wr32(g, &ch->inst_block, @@ -259,7 +259,7 @@ int test_gv11b_tsg_bind_channel_eng_method_buffers(struct unit_module *m, } else { assert(nvgpu_mem_rd32(g, &ch->inst_block, - ram_in_eng_method_buffer_addr_lo_w()) != + ram_in_eng_method_buffer_addr_lo_w()) == u64_lo32(gpu_va)); assert(nvgpu_mem_rd32(g, &ch->inst_block, ram_in_eng_method_buffer_addr_hi_w()) == @@ -378,6 +378,8 @@ struct unit_module_test nvgpu_tsg_gv11b_tests[] = { UNIT_TEST(init_support, test_fifo_init_support, &unit_ctx, 0), UNIT_TEST(gv11b_tsg_init_eng_method_buffers, \ test_gv11b_tsg_init_eng_method_buffers, &unit_ctx, 0), + UNIT_TEST(gv11b_tsg_bind_channel_eng_method_buffers, + test_gv11b_tsg_bind_channel_eng_method_buffers, &unit_ctx, 0), UNIT_TEST(gv11b_tsg_unbind_channel_check_eng_faulted, \ test_gv11b_tsg_unbind_channel_check_eng_faulted, &unit_ctx, 0), UNIT_TEST(remove_support, test_fifo_remove_support, &unit_ctx, 0),