mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 02:22:34 +03:00
gpu: nvgpu: unit: fifo: move assert to unit_assert
unit_assert macro is provided to check a condition and execute bail_out action given as a second argument. Currently, in fifo unit, unit_assert() is redefined as assert with common bail_out action. However, name assert() creates confusion with linux assert macro. So, this patch removes redefined assert macro and replaces with unit_assert. Jira NVGPU-4684 Change-Id: I3a880f965a191f16efdabced5e23723e66ecaf3c Signed-off-by: Vedashree Vidwans <vvidwans@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2276863 GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman <alexw@nvidia.com> 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
4a287f08cd
commit
652cff2cd0
@@ -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"),
|
||||
@@ -55,7 +55,6 @@
|
||||
} while (0)
|
||||
#endif
|
||||
|
||||
#define assert(cond) unit_assert(cond, goto done)
|
||||
#define branches_str test_fifo_flags_str
|
||||
|
||||
int test_gk20a_userd_entry_size(struct unit_module *m,
|
||||
@@ -64,7 +63,7 @@ int test_gk20a_userd_entry_size(struct unit_module *m,
|
||||
int ret = UNIT_FAIL;
|
||||
u32 size = gk20a_userd_entry_size(g);
|
||||
|
||||
assert(size == ram_userd_chan_size_v());
|
||||
unit_assert(size == ram_userd_chan_size_v(), goto done);
|
||||
ret = UNIT_SUCCESS;
|
||||
done:
|
||||
return ret;
|
||||
|
||||
Reference in New Issue
Block a user