mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-25 06:03:36 -04:00
Merge commit 'v2.6.31-rc9' into tracing/core
Merge reason: move from -rc5 to -rc9. Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
commit
ed011b22ce
585 changed files with 6905 additions and 3930 deletions
|
|
@ -117,6 +117,7 @@ extern int setup_arg_pages(struct linux_binprm * bprm,
|
|||
int executable_stack);
|
||||
extern int bprm_mm_init(struct linux_binprm *bprm);
|
||||
extern int copy_strings_kernel(int argc,char ** argv,struct linux_binprm *bprm);
|
||||
extern int prepare_bprm_creds(struct linux_binprm *bprm);
|
||||
extern void install_exec_creds(struct linux_binprm *bprm);
|
||||
extern void do_coredump(long signr, int exit_code, struct pt_regs *regs);
|
||||
extern int set_binfmt(struct linux_binfmt *new);
|
||||
|
|
|
|||
|
|
@ -94,13 +94,13 @@ extern void __bitmap_shift_right(unsigned long *dst,
|
|||
const unsigned long *src, int shift, int bits);
|
||||
extern void __bitmap_shift_left(unsigned long *dst,
|
||||
const unsigned long *src, int shift, int bits);
|
||||
extern void __bitmap_and(unsigned long *dst, const unsigned long *bitmap1,
|
||||
extern int __bitmap_and(unsigned long *dst, const unsigned long *bitmap1,
|
||||
const unsigned long *bitmap2, int bits);
|
||||
extern void __bitmap_or(unsigned long *dst, const unsigned long *bitmap1,
|
||||
const unsigned long *bitmap2, int bits);
|
||||
extern void __bitmap_xor(unsigned long *dst, const unsigned long *bitmap1,
|
||||
const unsigned long *bitmap2, int bits);
|
||||
extern void __bitmap_andnot(unsigned long *dst, const unsigned long *bitmap1,
|
||||
extern int __bitmap_andnot(unsigned long *dst, const unsigned long *bitmap1,
|
||||
const unsigned long *bitmap2, int bits);
|
||||
extern int __bitmap_intersects(const unsigned long *bitmap1,
|
||||
const unsigned long *bitmap2, int bits);
|
||||
|
|
@ -171,13 +171,12 @@ static inline void bitmap_copy(unsigned long *dst, const unsigned long *src,
|
|||
}
|
||||
}
|
||||
|
||||
static inline void bitmap_and(unsigned long *dst, const unsigned long *src1,
|
||||
static inline int bitmap_and(unsigned long *dst, const unsigned long *src1,
|
||||
const unsigned long *src2, int nbits)
|
||||
{
|
||||
if (small_const_nbits(nbits))
|
||||
*dst = *src1 & *src2;
|
||||
else
|
||||
__bitmap_and(dst, src1, src2, nbits);
|
||||
return (*dst = *src1 & *src2) != 0;
|
||||
return __bitmap_and(dst, src1, src2, nbits);
|
||||
}
|
||||
|
||||
static inline void bitmap_or(unsigned long *dst, const unsigned long *src1,
|
||||
|
|
@ -198,13 +197,12 @@ static inline void bitmap_xor(unsigned long *dst, const unsigned long *src1,
|
|||
__bitmap_xor(dst, src1, src2, nbits);
|
||||
}
|
||||
|
||||
static inline void bitmap_andnot(unsigned long *dst, const unsigned long *src1,
|
||||
static inline int bitmap_andnot(unsigned long *dst, const unsigned long *src1,
|
||||
const unsigned long *src2, int nbits)
|
||||
{
|
||||
if (small_const_nbits(nbits))
|
||||
*dst = *src1 & ~(*src2);
|
||||
else
|
||||
__bitmap_andnot(dst, src1, src2, nbits);
|
||||
return (*dst = *src1 & ~(*src2)) != 0;
|
||||
return __bitmap_andnot(dst, src1, src2, nbits);
|
||||
}
|
||||
|
||||
static inline void bitmap_complement(unsigned long *dst, const unsigned long *src,
|
||||
|
|
|
|||
|
|
@ -43,10 +43,10 @@
|
|||
* int cpu_isset(cpu, mask) true iff bit 'cpu' set in mask
|
||||
* int cpu_test_and_set(cpu, mask) test and set bit 'cpu' in mask
|
||||
*
|
||||
* void cpus_and(dst, src1, src2) dst = src1 & src2 [intersection]
|
||||
* int cpus_and(dst, src1, src2) dst = src1 & src2 [intersection]
|
||||
* void cpus_or(dst, src1, src2) dst = src1 | src2 [union]
|
||||
* void cpus_xor(dst, src1, src2) dst = src1 ^ src2
|
||||
* void cpus_andnot(dst, src1, src2) dst = src1 & ~src2
|
||||
* int cpus_andnot(dst, src1, src2) dst = src1 & ~src2
|
||||
* void cpus_complement(dst, src) dst = ~src
|
||||
*
|
||||
* int cpus_equal(mask1, mask2) Does mask1 == mask2?
|
||||
|
|
@ -179,10 +179,10 @@ static inline int __cpu_test_and_set(int cpu, cpumask_t *addr)
|
|||
}
|
||||
|
||||
#define cpus_and(dst, src1, src2) __cpus_and(&(dst), &(src1), &(src2), NR_CPUS)
|
||||
static inline void __cpus_and(cpumask_t *dstp, const cpumask_t *src1p,
|
||||
static inline int __cpus_and(cpumask_t *dstp, const cpumask_t *src1p,
|
||||
const cpumask_t *src2p, int nbits)
|
||||
{
|
||||
bitmap_and(dstp->bits, src1p->bits, src2p->bits, nbits);
|
||||
return bitmap_and(dstp->bits, src1p->bits, src2p->bits, nbits);
|
||||
}
|
||||
|
||||
#define cpus_or(dst, src1, src2) __cpus_or(&(dst), &(src1), &(src2), NR_CPUS)
|
||||
|
|
@ -201,10 +201,10 @@ static inline void __cpus_xor(cpumask_t *dstp, const cpumask_t *src1p,
|
|||
|
||||
#define cpus_andnot(dst, src1, src2) \
|
||||
__cpus_andnot(&(dst), &(src1), &(src2), NR_CPUS)
|
||||
static inline void __cpus_andnot(cpumask_t *dstp, const cpumask_t *src1p,
|
||||
static inline int __cpus_andnot(cpumask_t *dstp, const cpumask_t *src1p,
|
||||
const cpumask_t *src2p, int nbits)
|
||||
{
|
||||
bitmap_andnot(dstp->bits, src1p->bits, src2p->bits, nbits);
|
||||
return bitmap_andnot(dstp->bits, src1p->bits, src2p->bits, nbits);
|
||||
}
|
||||
|
||||
#define cpus_complement(dst, src) __cpus_complement(&(dst), &(src), NR_CPUS)
|
||||
|
|
@ -738,11 +738,11 @@ static inline void cpumask_clear(struct cpumask *dstp)
|
|||
* @src1p: the first input
|
||||
* @src2p: the second input
|
||||
*/
|
||||
static inline void cpumask_and(struct cpumask *dstp,
|
||||
static inline int cpumask_and(struct cpumask *dstp,
|
||||
const struct cpumask *src1p,
|
||||
const struct cpumask *src2p)
|
||||
{
|
||||
bitmap_and(cpumask_bits(dstp), cpumask_bits(src1p),
|
||||
return bitmap_and(cpumask_bits(dstp), cpumask_bits(src1p),
|
||||
cpumask_bits(src2p), nr_cpumask_bits);
|
||||
}
|
||||
|
||||
|
|
@ -779,11 +779,11 @@ static inline void cpumask_xor(struct cpumask *dstp,
|
|||
* @src1p: the first input
|
||||
* @src2p: the second input
|
||||
*/
|
||||
static inline void cpumask_andnot(struct cpumask *dstp,
|
||||
static inline int cpumask_andnot(struct cpumask *dstp,
|
||||
const struct cpumask *src1p,
|
||||
const struct cpumask *src2p)
|
||||
{
|
||||
bitmap_andnot(cpumask_bits(dstp), cpumask_bits(src1p),
|
||||
return bitmap_andnot(cpumask_bits(dstp), cpumask_bits(src1p),
|
||||
cpumask_bits(src2p), nr_cpumask_bits);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -91,6 +91,9 @@ typedef int (*dm_iterate_devices_fn) (struct dm_target *ti,
|
|||
iterate_devices_callout_fn fn,
|
||||
void *data);
|
||||
|
||||
typedef void (*dm_io_hints_fn) (struct dm_target *ti,
|
||||
struct queue_limits *limits);
|
||||
|
||||
/*
|
||||
* Returns:
|
||||
* 0: The target can handle the next I/O immediately.
|
||||
|
|
@ -151,6 +154,7 @@ struct target_type {
|
|||
dm_merge_fn merge;
|
||||
dm_busy_fn busy;
|
||||
dm_iterate_devices_fn iterate_devices;
|
||||
dm_io_hints_fn io_hints;
|
||||
|
||||
/* For internal device-mapper use. */
|
||||
struct list_head list;
|
||||
|
|
|
|||
|
|
@ -371,7 +371,18 @@
|
|||
(DM_ULOG_REQUEST_MASK & (request_type))
|
||||
|
||||
struct dm_ulog_request {
|
||||
char uuid[DM_UUID_LEN]; /* Ties a request to a specific mirror log */
|
||||
/*
|
||||
* The local unique identifier (luid) and the universally unique
|
||||
* identifier (uuid) are used to tie a request to a specific
|
||||
* mirror log. A single machine log could probably make due with
|
||||
* just the 'luid', but a cluster-aware log must use the 'uuid' and
|
||||
* the 'luid'. The uuid is what is required for node to node
|
||||
* communication concerning a particular log, but the 'luid' helps
|
||||
* differentiate between logs that are being swapped and have the
|
||||
* same 'uuid'. (Think "live" and "inactive" device-mapper tables.)
|
||||
*/
|
||||
uint64_t luid;
|
||||
char uuid[DM_UUID_LEN];
|
||||
char padding[7]; /* Padding because DM_UUID_LEN = 129 */
|
||||
|
||||
int32_t error; /* Used to report back processing errors */
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ struct flex_array {
|
|||
struct {
|
||||
int element_size;
|
||||
int total_nr_elements;
|
||||
struct flex_array_part *parts[0];
|
||||
struct flex_array_part *parts[];
|
||||
};
|
||||
/*
|
||||
* This little trick makes sure that
|
||||
|
|
@ -36,12 +36,14 @@ struct flex_array {
|
|||
.total_nr_elements = (total), \
|
||||
} } }
|
||||
|
||||
struct flex_array *flex_array_alloc(int element_size, int total, gfp_t flags);
|
||||
int flex_array_prealloc(struct flex_array *fa, int start, int end, gfp_t flags);
|
||||
struct flex_array *flex_array_alloc(int element_size, unsigned int total,
|
||||
gfp_t flags);
|
||||
int flex_array_prealloc(struct flex_array *fa, unsigned int start,
|
||||
unsigned int end, gfp_t flags);
|
||||
void flex_array_free(struct flex_array *fa);
|
||||
void flex_array_free_parts(struct flex_array *fa);
|
||||
int flex_array_put(struct flex_array *fa, int element_nr, void *src,
|
||||
int flex_array_put(struct flex_array *fa, unsigned int element_nr, void *src,
|
||||
gfp_t flags);
|
||||
void *flex_array_get(struct flex_array *fa, int element_nr);
|
||||
void *flex_array_get(struct flex_array *fa, unsigned int element_nr);
|
||||
|
||||
#endif /* _FLEX_ARRAY_H */
|
||||
|
|
|
|||
|
|
@ -2123,7 +2123,7 @@ extern struct file *do_filp_open(int dfd, const char *pathname,
|
|||
int open_flag, int mode, int acc_mode);
|
||||
extern int may_open(struct path *, int, int);
|
||||
|
||||
extern int kernel_read(struct file *, unsigned long, char *, unsigned long);
|
||||
extern int kernel_read(struct file *, loff_t, char *, unsigned long);
|
||||
extern struct file * open_exec(const char *);
|
||||
|
||||
/* fs/dcache.c -- generic fs support functions */
|
||||
|
|
|
|||
|
|
@ -19,6 +19,11 @@ enum {
|
|||
* @packets: number of seen packets
|
||||
*/
|
||||
struct gnet_stats_basic
|
||||
{
|
||||
__u64 bytes;
|
||||
__u32 packets;
|
||||
};
|
||||
struct gnet_stats_basic_packed
|
||||
{
|
||||
__u64 bytes;
|
||||
__u32 packets;
|
||||
|
|
|
|||
|
|
@ -10,6 +10,7 @@
|
|||
#include <asm/tlbflush.h>
|
||||
|
||||
struct ctl_table;
|
||||
struct user_struct;
|
||||
|
||||
int PageHuge(struct page *page);
|
||||
|
||||
|
|
@ -146,7 +147,8 @@ static inline struct hugetlbfs_sb_info *HUGETLBFS_SB(struct super_block *sb)
|
|||
|
||||
extern const struct file_operations hugetlbfs_file_operations;
|
||||
extern struct vm_operations_struct hugetlb_vm_ops;
|
||||
struct file *hugetlb_file_setup(const char *name, size_t, int);
|
||||
struct file *hugetlb_file_setup(const char *name, size_t size, int acct,
|
||||
struct user_struct **user);
|
||||
int hugetlb_get_quota(struct address_space *mapping, long delta);
|
||||
void hugetlb_put_quota(struct address_space *mapping, long delta);
|
||||
|
||||
|
|
@ -168,7 +170,7 @@ static inline void set_file_hugepages(struct file *file)
|
|||
|
||||
#define is_file_hugepages(file) 0
|
||||
#define set_file_hugepages(file) BUG()
|
||||
#define hugetlb_file_setup(name,size,acctflag) ERR_PTR(-ENOSYS)
|
||||
#define hugetlb_file_setup(name,size,acct,user) ERR_PTR(-ENOSYS)
|
||||
|
||||
#endif /* !CONFIG_HUGETLBFS */
|
||||
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ extern u64 __init lmb_alloc_base(u64 size,
|
|||
extern u64 __init __lmb_alloc_base(u64 size,
|
||||
u64 align, u64 max_addr);
|
||||
extern u64 __init lmb_phys_mem_size(void);
|
||||
extern u64 __init lmb_end_of_DRAM(void);
|
||||
extern u64 lmb_end_of_DRAM(void);
|
||||
extern void __init lmb_enforce_memory_limit(u64 memory_limit);
|
||||
extern int __init lmb_is_reserved(u64 addr);
|
||||
extern int lmb_find(struct lmb_property *res);
|
||||
|
|
|
|||
|
|
@ -34,8 +34,6 @@ extern int sysctl_legacy_va_layout;
|
|||
#define sysctl_legacy_va_layout 0
|
||||
#endif
|
||||
|
||||
extern unsigned long mmap_min_addr;
|
||||
|
||||
#include <asm/page.h>
|
||||
#include <asm/pgtable.h>
|
||||
#include <asm/processor.h>
|
||||
|
|
@ -574,19 +572,6 @@ static inline void set_page_links(struct page *page, enum zone_type zone,
|
|||
set_page_section(page, pfn_to_section_nr(pfn));
|
||||
}
|
||||
|
||||
/*
|
||||
* If a hint addr is less than mmap_min_addr change hint to be as
|
||||
* low as possible but still greater than mmap_min_addr
|
||||
*/
|
||||
static inline unsigned long round_hint_to_min(unsigned long hint)
|
||||
{
|
||||
hint &= PAGE_MASK;
|
||||
if (((void *)hint != NULL) &&
|
||||
(hint < mmap_min_addr))
|
||||
return PAGE_ALIGN(mmap_min_addr);
|
||||
return hint;
|
||||
}
|
||||
|
||||
/*
|
||||
* Some inline functions in vmstat.h depend on page_zone()
|
||||
*/
|
||||
|
|
|
|||
|
|
@ -240,8 +240,6 @@ struct mm_struct {
|
|||
|
||||
unsigned long saved_auxv[AT_VECTOR_SIZE]; /* for /proc/PID/auxv */
|
||||
|
||||
s8 oom_adj; /* OOM kill score adjustment (bit shift) */
|
||||
|
||||
cpumask_t cpu_vm_mask;
|
||||
|
||||
/* Architecture-specific MM context */
|
||||
|
|
|
|||
|
|
@ -473,7 +473,6 @@ extern int nfs_writepages(struct address_space *, struct writeback_control *);
|
|||
extern int nfs_flush_incompatible(struct file *file, struct page *page);
|
||||
extern int nfs_updatepage(struct file *, struct page *, unsigned int, unsigned int);
|
||||
extern int nfs_writeback_done(struct rpc_task *, struct nfs_write_data *);
|
||||
extern void nfs_writedata_release(void *);
|
||||
|
||||
/*
|
||||
* Try to write back everything synchronously (but check the
|
||||
|
|
@ -488,7 +487,6 @@ extern int nfs_wb_page_cancel(struct inode *inode, struct page* page);
|
|||
extern int nfs_commit_inode(struct inode *, int);
|
||||
extern struct nfs_write_data *nfs_commitdata_alloc(void);
|
||||
extern void nfs_commit_free(struct nfs_write_data *wdata);
|
||||
extern void nfs_commitdata_release(void *wdata);
|
||||
#else
|
||||
static inline int
|
||||
nfs_commit_inode(struct inode *inode, int how)
|
||||
|
|
@ -507,6 +505,7 @@ nfs_have_writebacks(struct inode *inode)
|
|||
* Allocate nfs_write_data structures
|
||||
*/
|
||||
extern struct nfs_write_data *nfs_writedata_alloc(unsigned int npages);
|
||||
extern void nfs_writedata_free(struct nfs_write_data *);
|
||||
|
||||
/*
|
||||
* linux/fs/nfs/read.c
|
||||
|
|
@ -515,7 +514,6 @@ extern int nfs_readpage(struct file *, struct page *);
|
|||
extern int nfs_readpages(struct file *, struct address_space *,
|
||||
struct list_head *, unsigned);
|
||||
extern int nfs_readpage_result(struct rpc_task *, struct nfs_read_data *);
|
||||
extern void nfs_readdata_release(void *data);
|
||||
extern int nfs_readpage_async(struct nfs_open_context *, struct inode *,
|
||||
struct page *);
|
||||
|
||||
|
|
@ -523,6 +521,7 @@ extern int nfs_readpage_async(struct nfs_open_context *, struct inode *,
|
|||
* Allocate nfs_read_data structures
|
||||
*/
|
||||
extern struct nfs_read_data *nfs_readdata_alloc(unsigned int npages);
|
||||
extern void nfs_readdata_free(struct nfs_read_data *);
|
||||
|
||||
/*
|
||||
* linux/fs/nfs3proc.c
|
||||
|
|
|
|||
|
|
@ -115,7 +115,7 @@ enum perf_counter_sample_format {
|
|||
PERF_SAMPLE_TID = 1U << 1,
|
||||
PERF_SAMPLE_TIME = 1U << 2,
|
||||
PERF_SAMPLE_ADDR = 1U << 3,
|
||||
PERF_SAMPLE_GROUP = 1U << 4,
|
||||
PERF_SAMPLE_READ = 1U << 4,
|
||||
PERF_SAMPLE_CALLCHAIN = 1U << 5,
|
||||
PERF_SAMPLE_ID = 1U << 6,
|
||||
PERF_SAMPLE_CPU = 1U << 7,
|
||||
|
|
@ -127,16 +127,32 @@ enum perf_counter_sample_format {
|
|||
};
|
||||
|
||||
/*
|
||||
* Bits that can be set in attr.read_format to request that
|
||||
* reads on the counter should return the indicated quantities,
|
||||
* in increasing order of bit value, after the counter value.
|
||||
* The format of the data returned by read() on a perf counter fd,
|
||||
* as specified by attr.read_format:
|
||||
*
|
||||
* struct read_format {
|
||||
* { u64 value;
|
||||
* { u64 time_enabled; } && PERF_FORMAT_ENABLED
|
||||
* { u64 time_running; } && PERF_FORMAT_RUNNING
|
||||
* { u64 id; } && PERF_FORMAT_ID
|
||||
* } && !PERF_FORMAT_GROUP
|
||||
*
|
||||
* { u64 nr;
|
||||
* { u64 time_enabled; } && PERF_FORMAT_ENABLED
|
||||
* { u64 time_running; } && PERF_FORMAT_RUNNING
|
||||
* { u64 value;
|
||||
* { u64 id; } && PERF_FORMAT_ID
|
||||
* } cntr[nr];
|
||||
* } && PERF_FORMAT_GROUP
|
||||
* };
|
||||
*/
|
||||
enum perf_counter_read_format {
|
||||
PERF_FORMAT_TOTAL_TIME_ENABLED = 1U << 0,
|
||||
PERF_FORMAT_TOTAL_TIME_RUNNING = 1U << 1,
|
||||
PERF_FORMAT_ID = 1U << 2,
|
||||
PERF_FORMAT_GROUP = 1U << 3,
|
||||
|
||||
PERF_FORMAT_MAX = 1U << 3, /* non-ABI */
|
||||
PERF_FORMAT_MAX = 1U << 4, /* non-ABI */
|
||||
};
|
||||
|
||||
#define PERF_ATTR_SIZE_VER0 64 /* sizeof first published struct */
|
||||
|
|
@ -343,10 +359,8 @@ enum perf_event_type {
|
|||
* struct {
|
||||
* struct perf_event_header header;
|
||||
* u32 pid, tid;
|
||||
* u64 value;
|
||||
* { u64 time_enabled; } && PERF_FORMAT_ENABLED
|
||||
* { u64 time_running; } && PERF_FORMAT_RUNNING
|
||||
* { u64 parent_id; } && PERF_FORMAT_ID
|
||||
*
|
||||
* struct read_format values;
|
||||
* };
|
||||
*/
|
||||
PERF_EVENT_READ = 8,
|
||||
|
|
@ -364,11 +378,22 @@ enum perf_event_type {
|
|||
* { u32 cpu, res; } && PERF_SAMPLE_CPU
|
||||
* { u64 period; } && PERF_SAMPLE_PERIOD
|
||||
*
|
||||
* { u64 nr;
|
||||
* { u64 id, val; } cnt[nr]; } && PERF_SAMPLE_GROUP
|
||||
* { struct read_format values; } && PERF_SAMPLE_READ
|
||||
*
|
||||
* { u64 nr,
|
||||
* u64 ips[nr]; } && PERF_SAMPLE_CALLCHAIN
|
||||
*
|
||||
* #
|
||||
* # The RAW record below is opaque data wrt the ABI
|
||||
* #
|
||||
* # That is, the ABI doesn't make any promises wrt to
|
||||
* # the stability of its content, it may vary depending
|
||||
* # on event, hardware, kernel version and phase of
|
||||
* # the moon.
|
||||
* #
|
||||
* # In other words, PERF_SAMPLE_RAW contents are not an ABI.
|
||||
* #
|
||||
*
|
||||
* { u32 size;
|
||||
* char data[size];}&& PERF_SAMPLE_RAW
|
||||
* };
|
||||
|
|
@ -694,6 +719,8 @@ struct perf_sample_data {
|
|||
|
||||
extern int perf_counter_overflow(struct perf_counter *counter, int nmi,
|
||||
struct perf_sample_data *data);
|
||||
extern void perf_counter_output(struct perf_counter *counter, int nmi,
|
||||
struct perf_sample_data *data);
|
||||
|
||||
/*
|
||||
* Return 1 for a software counter, 0 for a hardware counter
|
||||
|
|
|
|||
|
|
@ -1198,6 +1198,7 @@ struct task_struct {
|
|||
* a short time
|
||||
*/
|
||||
unsigned char fpu_counter;
|
||||
s8 oomkilladj; /* OOM kill score adjustment (bit shift). */
|
||||
#ifdef CONFIG_BLK_DEV_IO_TRACE
|
||||
unsigned int btrace_seq;
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -28,6 +28,7 @@
|
|||
#include <linux/resource.h>
|
||||
#include <linux/sem.h>
|
||||
#include <linux/shm.h>
|
||||
#include <linux/mm.h> /* PAGE_ALIGN */
|
||||
#include <linux/msg.h>
|
||||
#include <linux/sched.h>
|
||||
#include <linux/key.h>
|
||||
|
|
@ -66,6 +67,9 @@ extern int cap_inode_setxattr(struct dentry *dentry, const char *name,
|
|||
extern int cap_inode_removexattr(struct dentry *dentry, const char *name);
|
||||
extern int cap_inode_need_killpriv(struct dentry *dentry);
|
||||
extern int cap_inode_killpriv(struct dentry *dentry);
|
||||
extern int cap_file_mmap(struct file *file, unsigned long reqprot,
|
||||
unsigned long prot, unsigned long flags,
|
||||
unsigned long addr, unsigned long addr_only);
|
||||
extern int cap_task_fix_setuid(struct cred *new, const struct cred *old, int flags);
|
||||
extern int cap_task_prctl(int option, unsigned long arg2, unsigned long arg3,
|
||||
unsigned long arg4, unsigned long arg5);
|
||||
|
|
@ -92,6 +96,7 @@ extern int cap_netlink_send(struct sock *sk, struct sk_buff *skb);
|
|||
extern int cap_netlink_recv(struct sk_buff *skb, int cap);
|
||||
|
||||
extern unsigned long mmap_min_addr;
|
||||
extern unsigned long dac_mmap_min_addr;
|
||||
/*
|
||||
* Values used in the task_security_ops calls
|
||||
*/
|
||||
|
|
@ -116,6 +121,21 @@ struct request_sock;
|
|||
#define LSM_UNSAFE_PTRACE 2
|
||||
#define LSM_UNSAFE_PTRACE_CAP 4
|
||||
|
||||
/*
|
||||
* If a hint addr is less than mmap_min_addr change hint to be as
|
||||
* low as possible but still greater than mmap_min_addr
|
||||
*/
|
||||
static inline unsigned long round_hint_to_min(unsigned long hint)
|
||||
{
|
||||
hint &= PAGE_MASK;
|
||||
if (((void *)hint != NULL) &&
|
||||
(hint < mmap_min_addr))
|
||||
return PAGE_ALIGN(mmap_min_addr);
|
||||
return hint;
|
||||
}
|
||||
extern int mmap_min_addr_handler(struct ctl_table *table, int write, struct file *filp,
|
||||
void __user *buffer, size_t *lenp, loff_t *ppos);
|
||||
|
||||
#ifdef CONFIG_SECURITY
|
||||
|
||||
struct security_mnt_opts {
|
||||
|
|
@ -2197,9 +2217,7 @@ static inline int security_file_mmap(struct file *file, unsigned long reqprot,
|
|||
unsigned long addr,
|
||||
unsigned long addr_only)
|
||||
{
|
||||
if ((addr < mmap_min_addr) && !capable(CAP_SYS_RAWIO))
|
||||
return -EACCES;
|
||||
return 0;
|
||||
return cap_file_mmap(file, reqprot, prot, flags, addr, addr_only);
|
||||
}
|
||||
|
||||
static inline int security_file_mprotect(struct vm_area_struct *vma,
|
||||
|
|
|
|||
|
|
@ -73,6 +73,10 @@
|
|||
|
||||
#define UCB_ADC_DATA 0x68
|
||||
#define UCB_ADC_DAT_VALID (1 << 15)
|
||||
|
||||
#define UCB_FCSR 0x6c
|
||||
#define UCB_FCSR_AVE (1 << 12)
|
||||
|
||||
#define UCB_ADC_DAT_MASK 0x3ff
|
||||
|
||||
#define UCB_ID 0x7e
|
||||
|
|
|
|||
|
|
@ -77,7 +77,14 @@ struct task_struct;
|
|||
#define __WAIT_BIT_KEY_INITIALIZER(word, bit) \
|
||||
{ .flags = word, .bit_nr = bit, }
|
||||
|
||||
extern void init_waitqueue_head(wait_queue_head_t *q);
|
||||
extern void __init_waitqueue_head(wait_queue_head_t *q, struct lock_class_key *);
|
||||
|
||||
#define init_waitqueue_head(q) \
|
||||
do { \
|
||||
static struct lock_class_key __key; \
|
||||
\
|
||||
__init_waitqueue_head((q), &__key); \
|
||||
} while (0)
|
||||
|
||||
#ifdef CONFIG_LOCKDEP
|
||||
# define __WAIT_QUEUE_HEAD_INIT_ONSTACK(name) \
|
||||
|
|
|
|||
|
|
@ -240,6 +240,21 @@ static inline int cancel_delayed_work(struct delayed_work *work)
|
|||
return ret;
|
||||
}
|
||||
|
||||
/*
|
||||
* Like above, but uses del_timer() instead of del_timer_sync(). This means,
|
||||
* if it returns 0 the timer function may be running and the queueing is in
|
||||
* progress.
|
||||
*/
|
||||
static inline int __cancel_delayed_work(struct delayed_work *work)
|
||||
{
|
||||
int ret;
|
||||
|
||||
ret = del_timer(&work->timer);
|
||||
if (ret)
|
||||
work_clear_pending(&work->work);
|
||||
return ret;
|
||||
}
|
||||
|
||||
extern int cancel_delayed_work_sync(struct delayed_work *work);
|
||||
|
||||
/* Obsolete. use cancel_delayed_work_sync() */
|
||||
|
|
|
|||
Loading…
Reference in a new issue