mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-28 04:15:07 +07:00
51a0e301a5
This patch adds BPF_MAP_TYPE_SK_STORAGE test to test_maps. The src file is rather long, so it is put into another dir map_tests/ and compile like the current prog_tests/ does. Other existing tests in test_maps can also be re-factored into map_tests/ in the future. Signed-off-by: Martin KaFai Lau <kafai@fb.com> Signed-off-by: Alexei Starovoitov <ast@kernel.org>
18 lines
350 B
C
18 lines
350 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef _TEST_MAPS_H
|
|
#define _TEST_MAPS_H
|
|
|
|
#include <stdio.h>
|
|
#include <stdlib.h>
|
|
|
|
#define CHECK(condition, tag, format...) ({ \
|
|
int __ret = !!(condition); \
|
|
if (__ret) { \
|
|
printf("%s(%d):FAIL:%s ", __func__, __LINE__, tag); \
|
|
printf(format); \
|
|
exit(-1); \
|
|
} \
|
|
})
|
|
|
|
#endif
|