• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2020 HiSilicon (Shanghai) Technologies CO., LIMITED.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  * Description: OSAL Error Definition.
15  */
16 
17 #ifndef OSAL_ERRNO_H_
18 #define OSAL_ERRNO_H_
19 
20 #define OS_HWI_PRIO_IGNORE 6
21 
22 /* Basic common errno 1~34 */
23 #define OSAL_EINTR (-4)  /* Interrupted system call */
24 #define OSAL_EINVAL (-22)  /* Interrupted system call */
25 #define OSAL_ETIME (-62)  /* Timer expired */
26 #define OSAL_EOVERFLOW (-75)  /* Value too large for defined data type */
27 
28 #define OSAL_ERESTARTSYS 512
29 
30 #ifndef ERESTARTSYS
31 #define ERESTARTSYS 512
32 #endif
33 
34 #define OSAL_NONEOS_DEFAULT_RET (-200) /* NoneOS's default return value */
35 #ifndef EOK
36 #define EOK 0
37 #endif
38 
39 #endif /* OSAL_ERRNO_H_ */
40