summaryrefslogtreecommitdiffstats
path: root/drivers/staging/most/hdm-dim2/dim2_errors.h
diff options
context:
space:
mode:
authorChristian Gromm2015-07-24 16:11:53 +0200
committerGreg Kroah-Hartman2015-07-24 22:50:43 +0200
commitba3d7ddfb5c6a2529155ac24d7964adba8777419 (patch)
treed78d3298d1f057839f47025c39a37d1779d0848a /drivers/staging/most/hdm-dim2/dim2_errors.h
parentStaging: most: add MOST driver's aim-v4l2 module (diff)
downloadkernel-qcow2-linux-ba3d7ddfb5c6a2529155ac24d7964adba8777419.tar.gz
kernel-qcow2-linux-ba3d7ddfb5c6a2529155ac24d7964adba8777419.tar.xz
kernel-qcow2-linux-ba3d7ddfb5c6a2529155ac24d7964adba8777419.zip
Staging: most: add MOST driver's hdm-dim2 module
This patch adds the hdm-dim2 module of the MOST driver to the kernel's driver staging area. This module is part of the MOST driver and handles the MediaLB interface of the MOST network interface controller. This patch is needed in order to use the MediaLB peripheral interface of the network interface controller. Signed-off-by: Christian Gromm <christian.gromm@microchip.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/most/hdm-dim2/dim2_errors.h')
-rw-r--r--drivers/staging/most/hdm-dim2/dim2_errors.h67
1 files changed, 67 insertions, 0 deletions
diff --git a/drivers/staging/most/hdm-dim2/dim2_errors.h b/drivers/staging/most/hdm-dim2/dim2_errors.h
new file mode 100644
index 000000000000..314f7de2be73
--- /dev/null
+++ b/drivers/staging/most/hdm-dim2/dim2_errors.h
@@ -0,0 +1,67 @@
+/*
+ * dim2_errors.h - Definitions of errors for DIM2 HAL API
+ * (MediaLB, Device Interface Macro IP, OS62420)
+ *
+ * Copyright (C) 2015, Microchip Technology Germany II GmbH & Co. KG
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * This file is licensed under GPLv2.
+ */
+
+#ifndef _MOST_DIM_ERRORS_H
+#define _MOST_DIM_ERRORS_H
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+/**
+ * MOST DIM errors.
+ */
+enum dim_errors_t {
+ /** Not an error */
+ DIM_NO_ERROR = 0,
+
+ /** Bad base address for DIM2 IP */
+ DIM_INIT_ERR_DIM_ADDR = 0x10,
+
+ /**< Bad MediaLB clock */
+ DIM_INIT_ERR_MLB_CLOCK,
+
+ /** Bad channel address */
+ DIM_INIT_ERR_CHANNEL_ADDRESS,
+
+ /** Out of DBR memory */
+ DIM_INIT_ERR_OUT_OF_MEMORY,
+
+ /** DIM API is called while DIM is not initialized successfully */
+ DIM_ERR_DRIVER_NOT_INITIALIZED = 0x20,
+
+ /**
+ * Configuration does not respect hardware limitations
+ * for isochronous or synchronous channels
+ */
+ DIM_ERR_BAD_CONFIG,
+
+ /**
+ * Buffer size does not respect hardware limitations
+ * for isochronous or synchronous channels
+ */
+ DIM_ERR_BAD_BUFFER_SIZE,
+
+ DIM_ERR_UNDERFLOW,
+
+ DIM_ERR_OVERFLOW,
+};
+
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _MOST_DIM_ERRORS_H */