1 /* SPDX-License-Identifier: BSD-3-Clause 2 * Copyright (c) 2015-2019 Amazon.com, Inc. or its affiliates. 3 * All rights reserved. 4 */ 5 6 #ifndef __ENA_PLATFORM_H__ 7 #define __ENA_PLATFORM_H__ 8 9 #define ena_assert_msg(cond, msg) \ 10 do { \ 11 if (unlikely(!(cond))) { \ 12 RTE_LOG_LINE(ERR, ENA_DRIVER, \ 13 "Assert failed on %s:%s:%d: ", \ 14 __FILE__, __func__, __LINE__); \ 15 rte_panic(msg); \ 16 } \ 17 } while (0) 18 19 #endif /* __ENA_PLATFORM_H__ */ 20