Linux-libre 4.19.20-gnu
[librecmc/linux-libre.git] / drivers / staging / vc04_services / bcm2835-camera / mmal-msg-common.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Broadcom BM2835 V4L2 driver
4  *
5  * Copyright © 2013 Raspberry Pi (Trading) Ltd.
6  *
7  * Authors: Vincent Sanders <vincent.sanders@collabora.co.uk>
8  *          Dave Stevenson <dsteve@broadcom.com>
9  *          Simon Mellor <simellor@broadcom.com>
10  *          Luke Diamand <luked@broadcom.com>
11  */
12
13 #ifndef MMAL_MSG_COMMON_H
14 #define MMAL_MSG_COMMON_H
15
16 enum mmal_msg_status {
17         MMAL_MSG_STATUS_SUCCESS = 0, /**< Success */
18         MMAL_MSG_STATUS_ENOMEM,      /**< Out of memory */
19         MMAL_MSG_STATUS_ENOSPC,      /**< Out of resources other than memory */
20         MMAL_MSG_STATUS_EINVAL,      /**< Argument is invalid */
21         MMAL_MSG_STATUS_ENOSYS,      /**< Function not implemented */
22         MMAL_MSG_STATUS_ENOENT,      /**< No such file or directory */
23         MMAL_MSG_STATUS_ENXIO,       /**< No such device or address */
24         MMAL_MSG_STATUS_EIO,         /**< I/O error */
25         MMAL_MSG_STATUS_ESPIPE,      /**< Illegal seek */
26         MMAL_MSG_STATUS_ECORRUPT,    /**< Data is corrupt \attention */
27         MMAL_MSG_STATUS_ENOTREADY,   /**< Component is not ready */
28         MMAL_MSG_STATUS_ECONFIG,     /**< Component is not configured */
29         MMAL_MSG_STATUS_EISCONN,     /**< Port is already connected */
30         MMAL_MSG_STATUS_ENOTCONN,    /**< Port is disconnected */
31         MMAL_MSG_STATUS_EAGAIN,      /**< Resource temporarily unavailable. */
32         MMAL_MSG_STATUS_EFAULT,      /**< Bad address */
33 };
34
35 struct mmal_rect {
36         s32 x;      /**< x coordinate (from left) */
37         s32 y;      /**< y coordinate (from top) */
38         s32 width;  /**< width */
39         s32 height; /**< height */
40 };
41
42 struct mmal_rational {
43         s32 num;    /**< Numerator */
44         s32 den;    /**< Denominator */
45 };
46
47 #endif /* MMAL_MSG_COMMON_H */