Commit f2999e4ea41d6ec6252d3b6d275b40d468a3c07e
1 parent
25478bb26f
Exists in
master
and in
7 other branches
Export only the appropriate GS_xxx flags to userspace from generic_serial.h
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
Showing 1 changed file with 4 additions and 2 deletions Side-by-side Diff
include/linux/generic_serial.h
... | ... | @@ -12,6 +12,7 @@ |
12 | 12 | #ifndef GENERIC_SERIAL_H |
13 | 13 | #define GENERIC_SERIAL_H |
14 | 14 | |
15 | +#ifdef __KERNEL__ | |
15 | 16 | #include <linux/mutex.h> |
16 | 17 | |
17 | 18 | struct real_driver { |
... | ... | @@ -54,6 +55,7 @@ |
54 | 55 | spinlock_t driver_lock; |
55 | 56 | }; |
56 | 57 | |
58 | +#endif /* __KERNEL__ */ | |
57 | 59 | |
58 | 60 | /* Flags */ |
59 | 61 | /* Warning: serial.h defines some ASYNC_ flags, they say they are "only" |
... | ... | @@ -75,7 +77,7 @@ |
75 | 77 | #define GS_DEBUG_FLOW 0x00000020 |
76 | 78 | #define GS_DEBUG_WRITE 0x00000040 |
77 | 79 | |
78 | - | |
80 | +#ifdef __KERNEL__ | |
79 | 81 | void gs_put_char(struct tty_struct *tty, unsigned char ch); |
80 | 82 | int gs_write(struct tty_struct *tty, |
81 | 83 | const unsigned char *buf, int count); |
... | ... | @@ -94,6 +96,6 @@ |
94 | 96 | int gs_setserial(struct gs_port *port, struct serial_struct __user *sp); |
95 | 97 | int gs_getserial(struct gs_port *port, struct serial_struct __user *sp); |
96 | 98 | void gs_got_break(struct gs_port *port); |
97 | - | |
99 | +#endif /* __KERNEL__ */ | |
98 | 100 | #endif |