1 /* drivers/media/platform/s5p-cec/s5p_cec.h
3 * Samsung S5P HDMI CEC driver
5 * Copyright (c) 2014 Samsung Electronics Co., Ltd.
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
14 #define _S5P_CEC_H_ __FILE__
16 #include <linux/clk.h>
17 #include <linux/interrupt.h>
18 #include <linux/kernel.h>
19 #include <linux/mfd/syscon.h>
20 #include <linux/module.h>
22 #include <linux/platform_device.h>
23 #include <linux/pm_runtime.h>
24 #include <linux/timer.h>
25 #include <linux/workqueue.h>
26 #include <media/cec.h>
28 #include "exynos_hdmi_cec.h"
32 #define CEC_NAME "s5p-cec"
34 #define CEC_STATUS_TX_RUNNING (1 << 0)
35 #define CEC_STATUS_TX_TRANSFERRING (1 << 1)
36 #define CEC_STATUS_TX_DONE (1 << 2)
37 #define CEC_STATUS_TX_ERROR (1 << 3)
38 #define CEC_STATUS_TX_NACK (1 << 4)
39 #define CEC_STATUS_TX_BYTES (0xFF << 8)
40 #define CEC_STATUS_RX_RUNNING (1 << 16)
41 #define CEC_STATUS_RX_RECEIVING (1 << 17)
42 #define CEC_STATUS_RX_DONE (1 << 18)
43 #define CEC_STATUS_RX_ERROR (1 << 19)
44 #define CEC_STATUS_RX_BCAST (1 << 20)
45 #define CEC_STATUS_RX_BYTES (0xFF << 24)
47 #define CEC_WORKER_TX_DONE (1 << 0)
48 #define CEC_WORKER_RX_MSG (1 << 1)
50 /* CEC Rx buffer size */
51 #define CEC_RX_BUFF_SIZE 16
52 /* CEC Tx buffer size */
53 #define CEC_TX_BUFF_SIZE 16
66 struct cec_adapter
*adap
;
71 struct cec_notifier
*notifier
;
80 #endif /* _S5P_CEC_H_ */