1 | /* SPDX-License-Identifier: GPL-2.0 */ |
2 | /* |
3 | * errors.h - Definitions of errors for DIM2 HAL API |
4 | * (MediaLB, Device Interface Macro IP, OS62420) |
5 | * |
6 | * Copyright (C) 2015, Microchip Technology Germany II GmbH & Co. KG |
7 | */ |
8 | |
9 | #ifndef _MOST_DIM_ERRORS_H |
10 | #define _MOST_DIM_ERRORS_H |
11 | |
12 | /** |
13 | * MOST DIM errors. |
14 | */ |
15 | enum dim_errors_t { |
16 | /** Not an error */ |
17 | DIM_NO_ERROR = 0, |
18 | |
19 | /** Bad base address for DIM2 IP */ |
20 | DIM_INIT_ERR_DIM_ADDR = 0x10, |
21 | |
22 | /**< Bad MediaLB clock */ |
23 | DIM_INIT_ERR_MLB_CLOCK, |
24 | |
25 | /** Bad channel address */ |
26 | DIM_INIT_ERR_CHANNEL_ADDRESS, |
27 | |
28 | /** Out of DBR memory */ |
29 | DIM_INIT_ERR_OUT_OF_MEMORY, |
30 | |
31 | /** DIM API is called while DIM is not initialized successfully */ |
32 | DIM_ERR_DRIVER_NOT_INITIALIZED = 0x20, |
33 | |
34 | /** |
35 | * Configuration does not respect hardware limitations |
36 | * for isochronous or synchronous channels |
37 | */ |
38 | DIM_ERR_BAD_CONFIG, |
39 | |
40 | /** |
41 | * Buffer size does not respect hardware limitations |
42 | * for isochronous or synchronous channels |
43 | */ |
44 | DIM_ERR_BAD_BUFFER_SIZE, |
45 | |
46 | DIM_ERR_UNDERFLOW, |
47 | |
48 | DIM_ERR_OVERFLOW, |
49 | }; |
50 | |
51 | #endif /* _MOST_DIM_ERRORS_H */ |
52 | |