bfcmap_sal.h (1020B)
1 /* 2 * 3 * This license is set out in https://raw.githubusercontent.com/Broadcom-Network-Switching-Software/OpenBCM/master/Legal/LICENSE file. 4 * 5 * Copyright 2007-2019 Broadcom Inc. All rights reserved. 6 */ 7 8 #ifndef BFCMAP_SAL_H 9 #define BFCMAP_SAL_H 10 #include <buser_sal.h> 11 12 typedef buser_sal_lock_t bfcmap_sal_lock_t; 13 14 /* 15 * BFCMAP_SAL_SEM_CREATE creates a bfcmap_sal_lock_t and return 16 * bfcmap_sal_lock_t back. 17 */ 18 #define BFCMAP_SAL_LOCK_CREATE(n) BMF_SAL_LOCK_CREATE(n) 19 20 /* 21 * Destroy lock. 22 */ 23 #define BFCMAP_SAL_LOCK_DESTROY(s) BMF_SAL_LOCK_DESTROY(s) 24 25 /* 26 * Take lock. 27 */ 28 #define BFCMAP_SAL_LOCK(s) BMF_SAL_LOCK(s) 29 30 /* 31 * unlock. 32 */ 33 #define BFCMAP_SAL_UNLOCK(s) BMF_SAL_UNLOCK(s) 34 35 /* 36 * memory allocation. 37 */ 38 #define BFCMAP_SAL_MALLOC(s,n) BMF_SAL_MALLOC(s,n) 39 40 /* 41 * free memory. 42 */ 43 #define BFCMAP_SAL_FREE(p) BMF_SAL_FREE(p) 44 45 /* 46 * Sleep for t microseconds 47 */ 48 #define BFCMAP_SAL_USLEEP(t) BMF_SAL_USLEEP(t) 49 50 51 52 #endif /* BFCMAP_SAL_H */ 53