summaryrefslogtreecommitdiff
path: root/include/linux/clonedev.h
blob: 575233f07e994868a7d242f656459b3aa644eef7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
/*
 * Copyright (C) ST-Ericsson SA 2011
 *
 * ST-Ericsson Display overlay compositer device driver
 *
 * Author: Per-Daniel Olsson <per-daniel.olsson@stericsson.com>
 * for ST-Ericsson.
 *
 * License terms: GNU General Public License (GPL), version 2.
 */

#ifndef _CLONEDEV_H_
#define _CLONEDEV_H_

#if !defined(__KERNEL__) && !defined(_KERNEL)
#include <stdint.h>
#else
#include <linux/types.h>
#include <video/mcde.h>
#endif

#if defined(__KERNEL__) || defined(_KERNEL)
#include <linux/mm_types.h>
#include <linux/bitops.h>
#else
#define BIT(nr)			(1UL << (nr))
#endif

#define CLONEDEV_DEFAULT_DEVICE_PREFIX "clone"

/* Cloning mode */
enum clonedev_mode {
	CLONEDEV_CLONE_NONE,
	CLONEDEV_CLONE_VIDEO_OR_UI,
	CLONEDEV_CLONE_VIDEO_AND_UI,
	CLONEDEV_CLONE_VIDEO,
	CLONEDEV_CLONE_UI,
};

#define CLONEDEV_SET_MODE_IOC      _IOW('D', 1, __u32*)

#ifdef __KERNEL__

int clonedev_create(void);
void clonedev_destroy(void);

#endif /* __KERNEL__ */

#endif /* _CLONEDEV_H_ */