mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-24 02:22:34 +03:00
The else path in the nvgpu_assert() call definition handles the non-Linux kernel platforms. These platforms are generally safety conscious and as a result care about MISRA scans and unit testing. The static inline hides the BUG_ON() call from the unit test branch analyzer and the MISRA analyzer. Note: the MISRA issue still exists; however, it's just not seen when analyzing patches that only use the nvgpu_assert() call. This patch combines the __POSIX__ path with the general else path to ensure that all non-Linux platforms use the aforementioned static inline. JIRA NVGPU-1246 Change-Id: I3f267224acd0b27429302118872c40ca6d7b9137 Signed-off-by: Alex Waterman <alexw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1977276 Reviewed-by: Adeel Raza <araza@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> GVS: Gerrit_Virtual_Submit Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>