: error: C++ style comments are not allowed in ISO C90 // Copyright (C) 2018 Hangzhou C-SKY Microsystems co.,ltd. ^ error: (this will be reported only once per input file) Signed-off-by: Guo Ren <guoren@linux.alibaba.com>
18 lines
463 B
C
18 lines
463 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
|
|
#ifndef __ASM_CSKY_SEGMENT_H
|
|
#define __ASM_CSKY_SEGMENT_H
|
|
|
|
typedef struct {
|
|
unsigned long seg;
|
|
} mm_segment_t;
|
|
|
|
#define KERNEL_DS ((mm_segment_t) { 0xFFFFFFFF })
|
|
|
|
#define USER_DS ((mm_segment_t) { PAGE_OFFSET })
|
|
#define get_fs() (current_thread_info()->addr_limit)
|
|
#define set_fs(x) (current_thread_info()->addr_limit = (x))
|
|
#define uaccess_kernel() (get_fs().seg == KERNEL_DS.seg)
|
|
|
|
#endif /* __ASM_CSKY_SEGMENT_H */
|