aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/bitops.h4
-rw-r--r--include/linux/cgroup.h13
-rw-r--r--include/linux/cgroup_subsys.h6
-rw-r--r--include/linux/crash_dump.h5
-rw-r--r--include/linux/cred.h2
-rw-r--r--include/linux/flex_array.h2
-rw-r--r--include/linux/if_ether.h4
-rw-r--r--include/linux/init_task.h9
-rw-r--r--include/linux/ipmi_smi.h2
-rw-r--r--include/linux/key.h2
-rw-r--r--include/linux/memcontrol.h24
-rw-r--r--include/linux/mfd/max8997-private.h4
-rw-r--r--include/linux/mfd/tps65910.h800
-rw-r--r--include/linux/mm.h10
-rw-r--r--include/linux/mm_types.h2
-rw-r--r--include/linux/mmzone.h7
-rw-r--r--include/linux/mtd/mtd.h17
-rw-r--r--include/linux/mtd/nand.h4
-rw-r--r--include/linux/mtd/partitions.h16
-rw-r--r--include/linux/mtd/physmap.h4
-rw-r--r--include/linux/net.h6
-rw-r--r--include/linux/netfilter.h1
-rw-r--r--include/linux/netfilter/ipset/ip_set_ahash.h4
-rw-r--r--include/linux/netfilter/ipset/ip_set_timeout.h18
-rw-r--r--include/linux/nsproxy.h9
-rw-r--r--include/linux/pid.h2
-rw-r--r--include/linux/power/isp1704_charger.h29
-rw-r--r--include/linux/power/max8903_charger.h57
-rw-r--r--include/linux/proc_fs.h19
-rw-r--r--include/linux/ratelimit.h40
-rw-r--r--include/linux/regulator/machine.h7
-rw-r--r--include/linux/rtc.h8
-rw-r--r--include/linux/sched.h36
-rw-r--r--include/linux/swap.h3
-rw-r--r--include/linux/vm_event_item.h64
-rw-r--r--include/linux/vmstat.h62
36 files changed, 1116 insertions, 186 deletions
diff --git a/include/linux/bitops.h b/include/linux/bitops.h
index 2184c6b97aeb..a3ef66a2a083 100644
--- a/include/linux/bitops.h
+++ b/include/linux/bitops.h
@@ -148,7 +148,7 @@ static inline unsigned long __ffs64(u64 word)
148 148
149#ifdef __KERNEL__ 149#ifdef __KERNEL__
150 150
151#ifdef CONFIG_GENERIC_FIND_LAST_BIT 151#ifndef find_last_bit
152/** 152/**
153 * find_last_bit - find the last set bit in a memory region 153 * find_last_bit - find the last set bit in a memory region
154 * @addr: The address to start the search at 154 * @addr: The address to start the search at
@@ -158,7 +158,7 @@ static inline unsigned long __ffs64(u64 word)
158 */ 158 */
159extern unsigned long find_last_bit(const unsigned long *addr, 159extern unsigned long find_last_bit(const unsigned long *addr,
160 unsigned long size); 160 unsigned long size);
161#endif /* CONFIG_GENERIC_FIND_LAST_BIT */ 161#endif
162 162
163#endif /* __KERNEL__ */ 163#endif /* __KERNEL__ */
164#endif 164#endif
diff --git a/include/linux/cgroup.h b/include/linux/cgroup.h
index 5ac7ebc36dbb..ab4ac0ccb857 100644
--- a/include/linux/cgroup.h
+++ b/include/linux/cgroup.h
@@ -467,12 +467,14 @@ struct cgroup_subsys {
467 int (*pre_destroy)(struct cgroup_subsys *ss, struct cgroup *cgrp); 467 int (*pre_destroy)(struct cgroup_subsys *ss, struct cgroup *cgrp);
468 void (*destroy)(struct cgroup_subsys *ss, struct cgroup *cgrp); 468 void (*destroy)(struct cgroup_subsys *ss, struct cgroup *cgrp);
469 int (*can_attach)(struct cgroup_subsys *ss, struct cgroup *cgrp, 469 int (*can_attach)(struct cgroup_subsys *ss, struct cgroup *cgrp,
470 struct task_struct *tsk, bool threadgroup); 470 struct task_struct *tsk);
471 int (*can_attach_task)(struct cgroup *cgrp, struct task_struct *tsk);
471 void (*cancel_attach)(struct cgroup_subsys *ss, struct cgroup *cgrp, 472 void (*cancel_attach)(struct cgroup_subsys *ss, struct cgroup *cgrp,
472 struct task_struct *tsk, bool threadgroup); 473 struct task_struct *tsk);
474 void (*pre_attach)(struct cgroup *cgrp);
475 void (*attach_task)(struct cgroup *cgrp, struct task_struct *tsk);
473 void (*attach)(struct cgroup_subsys *ss, struct cgroup *cgrp, 476 void (*attach)(struct cgroup_subsys *ss, struct cgroup *cgrp,
474 struct cgroup *old_cgrp, struct task_struct *tsk, 477 struct cgroup *old_cgrp, struct task_struct *tsk);
475 bool threadgroup);
476 void (*fork)(struct cgroup_subsys *ss, struct task_struct *task); 478 void (*fork)(struct cgroup_subsys *ss, struct task_struct *task);
477 void (*exit)(struct cgroup_subsys *ss, struct cgroup *cgrp, 479 void (*exit)(struct cgroup_subsys *ss, struct cgroup *cgrp,
478 struct cgroup *old_cgrp, struct task_struct *task); 480 struct cgroup *old_cgrp, struct task_struct *task);
@@ -553,9 +555,6 @@ static inline struct cgroup* task_cgroup(struct task_struct *task,
553 return task_subsys_state(task, subsys_id)->cgroup; 555 return task_subsys_state(task, subsys_id)->cgroup;
554} 556}
555 557
556int cgroup_clone(struct task_struct *tsk, struct cgroup_subsys *ss,
557 char *nodename);
558
559/* A cgroup_iter should be treated as an opaque object */ 558/* A cgroup_iter should be treated as an opaque object */
560struct cgroup_iter { 559struct cgroup_iter {
561 struct list_head *cg_link; 560 struct list_head *cg_link;
diff --git a/include/linux/cgroup_subsys.h b/include/linux/cgroup_subsys.h
index cdbfcb8780ec..ac663c18776c 100644
--- a/include/linux/cgroup_subsys.h
+++ b/include/linux/cgroup_subsys.h
@@ -19,12 +19,6 @@ SUBSYS(debug)
19 19
20/* */ 20/* */
21 21
22#ifdef CONFIG_CGROUP_NS
23SUBSYS(ns)
24#endif
25
26/* */
27
28#ifdef CONFIG_CGROUP_SCHED 22#ifdef CONFIG_CGROUP_SCHED
29SUBSYS(cpu_cgroup) 23SUBSYS(cpu_cgroup)
30#endif 24#endif
diff --git a/include/linux/crash_dump.h b/include/linux/crash_dump.h
index 088cd4ace4ef..74054074e876 100644
--- a/include/linux/crash_dump.h
+++ b/include/linux/crash_dump.h
@@ -66,6 +66,11 @@ static inline void vmcore_unusable(void)
66 if (is_kdump_kernel()) 66 if (is_kdump_kernel())
67 elfcorehdr_addr = ELFCORE_ADDR_ERR; 67 elfcorehdr_addr = ELFCORE_ADDR_ERR;
68} 68}
69
70#define HAVE_OLDMEM_PFN_IS_RAM 1
71extern int register_oldmem_pfn_is_ram(int (*fn)(unsigned long pfn));
72extern void unregister_oldmem_pfn_is_ram(void);
73
69#else /* !CONFIG_CRASH_DUMP */ 74#else /* !CONFIG_CRASH_DUMP */
70static inline int is_kdump_kernel(void) { return 0; } 75static inline int is_kdump_kernel(void) { return 0; }
71#endif /* CONFIG_CRASH_DUMP */ 76#endif /* CONFIG_CRASH_DUMP */
diff --git a/include/linux/cred.h b/include/linux/cred.h
index be16b61283cc..82607992f308 100644
--- a/include/linux/cred.h
+++ b/include/linux/cred.h
@@ -1,4 +1,4 @@
1/* Credentials management - see Documentation/credentials.txt 1/* Credentials management - see Documentation/security/credentials.txt
2 * 2 *
3 * Copyright (C) 2008 Red Hat, Inc. All Rights Reserved. 3 * Copyright (C) 2008 Red Hat, Inc. All Rights Reserved.
4 * Written by David Howells (dhowells@redhat.com) 4 * Written by David Howells (dhowells@redhat.com)
diff --git a/include/linux/flex_array.h b/include/linux/flex_array.h
index ebeb2f3ad068..6843cf193a44 100644
--- a/include/linux/flex_array.h
+++ b/include/linux/flex_array.h
@@ -21,6 +21,8 @@ struct flex_array {
21 struct { 21 struct {
22 int element_size; 22 int element_size;
23 int total_nr_elements; 23 int total_nr_elements;
24 int elems_per_part;
25 u32 reciprocal_elems;
24 struct flex_array_part *parts[]; 26 struct flex_array_part *parts[];
25 }; 27 };
26 /* 28 /*
diff --git a/include/linux/if_ether.h b/include/linux/if_ether.h
index 0f1325d98295..0065ffd3226b 100644
--- a/include/linux/if_ether.h
+++ b/include/linux/if_ether.h
@@ -132,10 +132,6 @@ static inline struct ethhdr *eth_hdr(const struct sk_buff *skb)
132 132
133int eth_header_parse(const struct sk_buff *skb, unsigned char *haddr); 133int eth_header_parse(const struct sk_buff *skb, unsigned char *haddr);
134 134
135#ifdef CONFIG_SYSCTL
136extern struct ctl_table ether_table[];
137#endif
138
139int mac_pton(const char *s, u8 *mac); 135int mac_pton(const char *s, u8 *mac);
140extern ssize_t sysfs_format_mac(char *buf, const unsigned char *addr, int len); 136extern ssize_t sysfs_format_mac(char *buf, const unsigned char *addr, int len);
141 137
diff --git a/include/linux/init_task.h b/include/linux/init_task.h
index bafc58c00fc3..580f70c02391 100644
--- a/include/linux/init_task.h
+++ b/include/linux/init_task.h
@@ -22,6 +22,14 @@
22extern struct files_struct init_files; 22extern struct files_struct init_files;
23extern struct fs_struct init_fs; 23extern struct fs_struct init_fs;
24 24
25#ifdef CONFIG_CGROUPS
26#define INIT_THREADGROUP_FORK_LOCK(sig) \
27 .threadgroup_fork_lock = \
28 __RWSEM_INITIALIZER(sig.threadgroup_fork_lock),
29#else
30#define INIT_THREADGROUP_FORK_LOCK(sig)
31#endif
32
25#define INIT_SIGNALS(sig) { \ 33#define INIT_SIGNALS(sig) { \
26 .nr_threads = 1, \ 34 .nr_threads = 1, \
27 .wait_chldexit = __WAIT_QUEUE_HEAD_INITIALIZER(sig.wait_chldexit),\ 35 .wait_chldexit = __WAIT_QUEUE_HEAD_INITIALIZER(sig.wait_chldexit),\
@@ -38,6 +46,7 @@ extern struct fs_struct init_fs;
38 }, \ 46 }, \
39 .cred_guard_mutex = \ 47 .cred_guard_mutex = \
40 __MUTEX_INITIALIZER(sig.cred_guard_mutex), \ 48 __MUTEX_INITIALIZER(sig.cred_guard_mutex), \
49 INIT_THREADGROUP_FORK_LOCK(sig) \
41} 50}
42 51
43extern struct nsproxy init_nsproxy; 52extern struct nsproxy init_nsproxy;
diff --git a/include/linux/ipmi_smi.h b/include/linux/ipmi_smi.h
index 906590aa6907..204f9cd26c16 100644
--- a/include/linux/ipmi_smi.h
+++ b/include/linux/ipmi_smi.h
@@ -236,7 +236,7 @@ static inline void ipmi_free_smi_msg(struct ipmi_smi_msg *msg)
236 directory for this interface. Note that the entry will 236 directory for this interface. Note that the entry will
237 automatically be dstroyed when the interface is destroyed. */ 237 automatically be dstroyed when the interface is destroyed. */
238int ipmi_smi_add_proc_entry(ipmi_smi_t smi, char *name, 238int ipmi_smi_add_proc_entry(ipmi_smi_t smi, char *name,
239 read_proc_t *read_proc, 239 const struct file_operations *proc_ops,
240 void *data); 240 void *data);
241 241
242#endif /* __LINUX_IPMI_SMI_H */ 242#endif /* __LINUX_IPMI_SMI_H */
diff --git a/include/linux/key.h b/include/linux/key.h
index ef19b99aff98..6ea4eebd3467 100644
--- a/include/linux/key.h
+++ b/include/linux/key.h
@@ -9,7 +9,7 @@
9 * 2 of the License, or (at your option) any later version. 9 * 2 of the License, or (at your option) any later version.
10 * 10 *
11 * 11 *
12 * See Documentation/keys.txt for information on keys/keyrings. 12 * See Documentation/security/keys.txt for information on keys/keyrings.
13 */ 13 */
14 14
15#ifndef _LINUX_KEY_H 15#ifndef _LINUX_KEY_H
diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h
index 5e9840f50980..9724a38ee69d 100644
--- a/include/linux/memcontrol.h
+++ b/include/linux/memcontrol.h
@@ -20,6 +20,8 @@
20#ifndef _LINUX_MEMCONTROL_H 20#ifndef _LINUX_MEMCONTROL_H
21#define _LINUX_MEMCONTROL_H 21#define _LINUX_MEMCONTROL_H
22#include <linux/cgroup.h> 22#include <linux/cgroup.h>
23#include <linux/vm_event_item.h>
24
23struct mem_cgroup; 25struct mem_cgroup;
24struct page_cgroup; 26struct page_cgroup;
25struct page; 27struct page;
@@ -106,9 +108,10 @@ extern void mem_cgroup_end_migration(struct mem_cgroup *mem,
106 */ 108 */
107int mem_cgroup_inactive_anon_is_low(struct mem_cgroup *memcg); 109int mem_cgroup_inactive_anon_is_low(struct mem_cgroup *memcg);
108int mem_cgroup_inactive_file_is_low(struct mem_cgroup *memcg); 110int mem_cgroup_inactive_file_is_low(struct mem_cgroup *memcg);
109unsigned long mem_cgroup_zone_nr_pages(struct mem_cgroup *memcg, 111int mem_cgroup_select_victim_node(struct mem_cgroup *memcg);
110 struct zone *zone, 112unsigned long mem_cgroup_zone_nr_lru_pages(struct mem_cgroup *memcg,
111 enum lru_list lru); 113 struct zone *zone,
114 enum lru_list lru);
112struct zone_reclaim_stat *mem_cgroup_get_reclaim_stat(struct mem_cgroup *memcg, 115struct zone_reclaim_stat *mem_cgroup_get_reclaim_stat(struct mem_cgroup *memcg,
113 struct zone *zone); 116 struct zone *zone);
114struct zone_reclaim_stat* 117struct zone_reclaim_stat*
@@ -144,9 +147,11 @@ static inline void mem_cgroup_dec_page_stat(struct page *page,
144} 147}
145 148
146unsigned long mem_cgroup_soft_limit_reclaim(struct zone *zone, int order, 149unsigned long mem_cgroup_soft_limit_reclaim(struct zone *zone, int order,
147 gfp_t gfp_mask); 150 gfp_t gfp_mask,
151 unsigned long *total_scanned);
148u64 mem_cgroup_get_limit(struct mem_cgroup *mem); 152u64 mem_cgroup_get_limit(struct mem_cgroup *mem);
149 153
154void mem_cgroup_count_vm_event(struct mm_struct *mm, enum vm_event_item idx);
150#ifdef CONFIG_TRANSPARENT_HUGEPAGE 155#ifdef CONFIG_TRANSPARENT_HUGEPAGE
151void mem_cgroup_split_huge_fixup(struct page *head, struct page *tail); 156void mem_cgroup_split_huge_fixup(struct page *head, struct page *tail);
152#endif 157#endif
@@ -302,8 +307,8 @@ mem_cgroup_inactive_file_is_low(struct mem_cgroup *memcg)
302} 307}
303 308
304static inline unsigned long 309static inline unsigned long
305mem_cgroup_zone_nr_pages(struct mem_cgroup *memcg, struct zone *zone, 310mem_cgroup_zone_nr_lru_pages(struct mem_cgroup *memcg, struct zone *zone,
306 enum lru_list lru) 311 enum lru_list lru)
307{ 312{
308 return 0; 313 return 0;
309} 314}
@@ -338,7 +343,8 @@ static inline void mem_cgroup_dec_page_stat(struct page *page,
338 343
339static inline 344static inline
340unsigned long mem_cgroup_soft_limit_reclaim(struct zone *zone, int order, 345unsigned long mem_cgroup_soft_limit_reclaim(struct zone *zone, int order,
341 gfp_t gfp_mask) 346 gfp_t gfp_mask,
347 unsigned long *total_scanned)
342{ 348{
343 return 0; 349 return 0;
344} 350}
@@ -354,6 +360,10 @@ static inline void mem_cgroup_split_huge_fixup(struct page *head,
354{ 360{
355} 361}
356 362
363static inline
364void mem_cgroup_count_vm_event(struct mm_struct *mm, enum vm_event_item idx)
365{
366}
357#endif /* CONFIG_CGROUP_MEM_CONT */ 367#endif /* CONFIG_CGROUP_MEM_CONT */
358 368
359#if !defined(CONFIG_CGROUP_MEM_RES_CTLR) || !defined(CONFIG_DEBUG_VM) 369#if !defined(CONFIG_CGROUP_MEM_RES_CTLR) || !defined(CONFIG_DEBUG_VM)
diff --git a/include/linux/mfd/max8997-private.h b/include/linux/mfd/max8997-private.h
index 69d1010e2e51..5ff2400ad46c 100644
--- a/include/linux/mfd/max8997-private.h
+++ b/include/linux/mfd/max8997-private.h
@@ -311,10 +311,6 @@ enum max8997_irq {
311 MAX8997_IRQ_NR, 311 MAX8997_IRQ_NR,
312}; 312};
313 313
314#define MAX8997_REG_BUCK1DVS(x) (MAX8997_REG_BUCK1DVS1 + (x) - 1)
315#define MAX8997_REG_BUCK2DVS(x) (MAX8997_REG_BUCK2DVS1 + (x) - 1)
316#define MAX8997_REG_BUCK5DVS(x) (MAX8997_REG_BUCK5DVS1 + (x) - 1)
317
318#define MAX8997_NUM_GPIO 12 314#define MAX8997_NUM_GPIO 12
319struct max8997_dev { 315struct max8997_dev {
320 struct device *dev; 316 struct device *dev;
diff --git a/include/linux/mfd/tps65910.h b/include/linux/mfd/tps65910.h
new file mode 100644
index 000000000000..8bb85b930c07
--- /dev/null
+++ b/include/linux/mfd/tps65910.h
@@ -0,0 +1,800 @@
1/*
2 * tps65910.h -- TI TPS6591x
3 *
4 * Copyright 2010-2011 Texas Instruments Inc.
5 *
6 * Author: Graeme Gregory <gg@slimlogic.co.uk>
7 * Author: Jorge Eduardo Candelaria <jedu@slimlogic.co.uk>
8 * Author: Arnaud Deconinck <a-deconinck@ti.com>
9 *
10 * This program is free software; you can redistribute it and/or modify it
11 * under the terms of the GNU General Public License as published by the
12 * Free Software Foundation; either version 2 of the License, or (at your
13 * option) any later version.
14 *
15 */
16
17#ifndef __LINUX_MFD_TPS65910_H
18#define __LINUX_MFD_TPS65910_H
19
20/* TPS chip id list */
21#define TPS65910 0
22#define TPS65911 1
23
24/* TPS regulator type list */
25#define REGULATOR_LDO 0
26#define REGULATOR_DCDC 1
27
28/*
29 * List of registers for component TPS65910
30 *
31 */
32
33#define TPS65910_SECONDS 0x0
34#define TPS65910_MINUTES 0x1
35#define TPS65910_HOURS 0x2
36#define TPS65910_DAYS 0x3
37#define TPS65910_MONTHS 0x4
38#define TPS65910_YEARS 0x5
39#define TPS65910_WEEKS 0x6
40#define TPS65910_ALARM_SECONDS 0x8
41#define TPS65910_ALARM_MINUTES 0x9
42#define TPS65910_ALARM_HOURS 0xA
43#define TPS65910_ALARM_DAYS 0xB
44#define TPS65910_ALARM_MONTHS 0xC
45#define TPS65910_ALARM_YEARS 0xD
46#define TPS65910_RTC_CTRL 0x10
47#define TPS65910_RTC_STATUS 0x11
48#define TPS65910_RTC_INTERRUPTS 0x12
49#define TPS65910_RTC_COMP_LSB 0x13
50#define TPS65910_RTC_COMP_MSB 0x14
51#define TPS65910_RTC_RES_PROG 0x15
52#define TPS65910_RTC_RESET_STATUS 0x16
53#define TPS65910_BCK1 0x17
54#define TPS65910_BCK2 0x18
55#define TPS65910_BCK3 0x19
56#define TPS65910_BCK4 0x1A
57#define TPS65910_BCK5 0x1B
58#define TPS65910_PUADEN 0x1C
59#define TPS65910_REF 0x1D
60#define TPS65910_VRTC 0x1E
61#define TPS65910_VIO 0x20
62#define TPS65910_VDD1 0x21
63#define TPS65910_VDD1_OP 0x22
64#define TPS65910_VDD1_SR 0x23
65#define TPS65910_VDD2 0x24
66#define TPS65910_VDD2_OP 0x25
67#define TPS65910_VDD2_SR 0x26
68#define TPS65910_VDD3 0x27
69#define TPS65910_VDIG1 0x30
70#define TPS65910_VDIG2 0x31
71#define TPS65910_VAUX1 0x32
72#define TPS65910_VAUX2 0x33
73#define TPS65910_VAUX33 0x34
74#define TPS65910_VMMC 0x35
75#define TPS65910_VPLL 0x36
76#define TPS65910_VDAC 0x37
77#define TPS65910_THERM 0x38
78#define TPS65910_BBCH 0x39
79#define TPS65910_DCDCCTRL 0x3E
80#define TPS65910_DEVCTRL 0x3F
81#define TPS65910_DEVCTRL2 0x40
82#define TPS65910_SLEEP_KEEP_LDO_ON 0x41
83#define TPS65910_SLEEP_KEEP_RES_ON 0x42
84#define TPS65910_SLEEP_SET_LDO_OFF 0x43
85#define TPS65910_SLEEP_SET_RES_OFF 0x44
86#define TPS65910_EN1_LDO_ASS 0x45
87#define TPS65910_EN1_SMPS_ASS 0x46
88#define TPS65910_EN2_LDO_ASS 0x47
89#define TPS65910_EN2_SMPS_ASS 0x48
90#define TPS65910_EN3_LDO_ASS 0x49
91#define TPS65910_SPARE 0x4A
92#define TPS65910_INT_STS 0x50
93#define TPS65910_INT_MSK 0x51
94#define TPS65910_INT_STS2 0x52
95#define TPS65910_INT_MSK2 0x53
96#define TPS65910_INT_STS3 0x54
97#define TPS65910_INT_MSK3 0x55
98#define TPS65910_GPIO0 0x60
99#define TPS65910_GPIO1 0x61
100#define TPS65910_GPIO2 0x62
101#define TPS65910_GPIO3 0x63
102#define TPS65910_GPIO4 0x64
103#define TPS65910_GPIO5 0x65
104#define TPS65910_GPIO6 0x66
105#define TPS65910_GPIO7 0x67
106#define TPS65910_GPIO8 0x68
107#define TPS65910_JTAGVERNUM 0x80
108#define TPS65910_MAX_REGISTER 0x80
109
110/*
111 * List of registers specific to TPS65911
112 */
113#define TPS65911_VDDCTRL 0x27
114#define TPS65911_VDDCTRL_OP 0x28
115#define TPS65911_VDDCTRL_SR 0x29
116#define TPS65911_LDO1 0x30
117#define TPS65911_LDO2 0x31
118#define TPS65911_LDO5 0x32
119#define TPS65911_LDO8 0x33
120#define TPS65911_LDO7 0x34
121#define TPS65911_LDO6 0x35
122#define TPS65911_LDO4 0x36
123#define TPS65911_LDO3 0x37
124#define TPS65911_VMBCH 0x6A
125#define TPS65911_VMBCH2 0x6B
126
127/*
128 * List of register bitfields for component TPS65910
129 *
130 */
131
132
133/*Register BCK1 (0x80) register.RegisterDescription */
134#define BCK1_BCKUP_MASK 0xFF
135#define BCK1_BCKUP_SHIFT 0
136
137
138/*Register BCK2 (0x80) register.RegisterDescription */
139#define BCK2_BCKUP_MASK 0xFF
140#define BCK2_BCKUP_SHIFT 0
141
142
143/*Register BCK3 (0x80) register.RegisterDescription */
144#define BCK3_BCKUP_MASK 0xFF
145#define BCK3_BCKUP_SHIFT 0
146
147
148/*Register BCK4 (0x80) register.RegisterDescription */
149#define BCK4_BCKUP_MASK 0xFF
150#define BCK4_BCKUP_SHIFT 0
151
152
153/*Register BCK5 (0x80) register.RegisterDescription */
154#define BCK5_BCKUP_MASK 0xFF
155#define BCK5_BCKUP_SHIFT 0
156
157
158/*Register PUADEN (0x80) register.RegisterDescription */
159#define PUADEN_EN3P_MASK 0x80
160#define PUADEN_EN3P_SHIFT 7
161#define PUADEN_I2CCTLP_MASK 0x40
162#define PUADEN_I2CCTLP_SHIFT 6
163#define PUADEN_I2CSRP_MASK 0x20
164#define PUADEN_I2CSRP_SHIFT 5
165#define PUADEN_PWRONP_MASK 0x10
166#define PUADEN_PWRONP_SHIFT 4
167#define PUADEN_SLEEPP_MASK 0x08
168#define PUADEN_SLEEPP_SHIFT 3
169#define PUADEN_PWRHOLDP_MASK 0x04
170#define PUADEN_PWRHOLDP_SHIFT 2
171#define PUADEN_BOOT1P_MASK 0x02
172#define PUADEN_BOOT1P_SHIFT 1
173#define PUADEN_BOOT0P_MASK 0x01
174#define PUADEN_BOOT0P_SHIFT 0
175
176
177/*Register REF (0x80) register.RegisterDescription */
178#define REF_VMBCH_SEL_MASK 0x0C
179#define REF_VMBCH_SEL_SHIFT 2
180#define REF_ST_MASK 0x03
181#define REF_ST_SHIFT 0
182
183
184/*Register VRTC (0x80) register.RegisterDescription */
185#define VRTC_VRTC_OFFMASK_MASK 0x08
186#define VRTC_VRTC_OFFMASK_SHIFT 3
187#define VRTC_ST_MASK 0x03
188#define VRTC_ST_SHIFT 0
189
190
191/*Register VIO (0x80) register.RegisterDescription */
192#define VIO_ILMAX_MASK 0xC0
193#define VIO_ILMAX_SHIFT 6
194#define VIO_SEL_MASK 0x0C
195#define VIO_SEL_SHIFT 2
196#define VIO_ST_MASK 0x03
197#define VIO_ST_SHIFT 0
198
199
200/*Register VDD1 (0x80) register.RegisterDescription */
201#define VDD1_VGAIN_SEL_MASK 0xC0
202#define VDD1_VGAIN_SEL_SHIFT 6
203#define VDD1_ILMAX_MASK 0x20
204#define VDD1_ILMAX_SHIFT 5
205#define VDD1_TSTEP_MASK 0x1C
206#define VDD1_TSTEP_SHIFT 2
207#define VDD1_ST_MASK 0x03
208#define VDD1_ST_SHIFT 0
209
210
211/*Register VDD1_OP (0x80) register.RegisterDescription */
212#define VDD1_OP_CMD_MASK 0x80
213#define VDD1_OP_CMD_SHIFT 7
214#define VDD1_OP_SEL_MASK 0x7F
215#define VDD1_OP_SEL_SHIFT 0
216
217
218/*Register VDD1_SR (0x80) register.RegisterDescription */
219#define VDD1_SR_SEL_MASK 0x7F
220#define VDD1_SR_SEL_SHIFT 0
221
222
223/*Register VDD2 (0x80) register.RegisterDescription */
224#define VDD2_VGAIN_SEL_MASK 0xC0
225#define VDD2_VGAIN_SEL_SHIFT 6
226#define VDD2_ILMAX_MASK 0x20
227#define VDD2_ILMAX_SHIFT 5
228#define VDD2_TSTEP_MASK 0x1C
229#define VDD2_TSTEP_SHIFT 2
230#define VDD2_ST_MASK 0x03
231#define VDD2_ST_SHIFT 0
232
233
234/*Register VDD2_OP (0x80) register.RegisterDescription */
235#define VDD2_OP_CMD_MASK 0x80
236#define VDD2_OP_CMD_SHIFT 7
237#define VDD2_OP_SEL_MASK 0x7F
238#define VDD2_OP_SEL_SHIFT 0
239
240/*Register VDD2_SR (0x80) register.RegisterDescription */
241#define VDD2_SR_SEL_MASK 0x7F
242#define VDD2_SR_SEL_SHIFT 0
243
244
245/*Registers VDD1, VDD2 voltage values definitions */
246#define VDD1_2_NUM_VOLTS 73
247#define VDD1_2_MIN_VOLT 6000
248#define VDD1_2_OFFSET 125
249
250
251/*Register VDD3 (0x80) register.RegisterDescription */
252#define VDD3_CKINEN_MASK 0x04
253#define VDD3_CKINEN_SHIFT 2
254#define VDD3_ST_MASK 0x03
255#define VDD3_ST_SHIFT 0
256#define VDDCTRL_MIN_VOLT 6000
257#define VDDCTRL_OFFSET 125
258
259/*Registers VDIG (0x80) to VDAC register.RegisterDescription */
260#define LDO_SEL_MASK 0x0C
261#define LDO_SEL_SHIFT 2
262#define LDO_ST_MASK 0x03
263#define LDO_ST_SHIFT 0
264#define LDO_ST_ON_BIT 0x01
265#define LDO_ST_MODE_BIT 0x02
266
267
268/* Registers LDO1 to LDO8 in tps65910 */
269#define LDO1_SEL_MASK 0xFC
270#define LDO3_SEL_MASK 0x7C
271#define LDO_MIN_VOLT 1000
272#define LDO_MAX_VOLT 3300;
273
274
275/*Register VDIG1 (0x80) register.RegisterDescription */
276#define VDIG1_SEL_MASK 0x0C
277#define VDIG1_SEL_SHIFT 2
278#define VDIG1_ST_MASK 0x03
279#define VDIG1_ST_SHIFT 0
280
281
282/*Register VDIG2 (0x80) register.RegisterDescription */
283#define VDIG2_SEL_MASK 0x0C
284#define VDIG2_SEL_SHIFT 2
285#define VDIG2_ST_MASK 0x03
286#define VDIG2_ST_SHIFT 0
287
288
289/*Register VAUX1 (0x80) register.RegisterDescription */
290#define VAUX1_SEL_MASK 0x0C
291#define VAUX1_SEL_SHIFT 2
292#define VAUX1_ST_MASK 0x03
293#define VAUX1_ST_SHIFT 0
294
295
296/*Register VAUX2 (0x80) register.RegisterDescription */
297#define VAUX2_SEL_MASK 0x0C
298#define VAUX2_SEL_SHIFT 2
299#define VAUX2_ST_MASK 0x03
300#define VAUX2_ST_SHIFT 0
301
302
303/*Register VAUX33 (0x80) register.RegisterDescription */
304#define VAUX33_SEL_MASK 0x0C
305#define VAUX33_SEL_SHIFT 2
306#define VAUX33_ST_MASK 0x03
307#define VAUX33_ST_SHIFT 0
308
309
310/*Register VMMC (0x80) register.RegisterDescription */
311#define VMMC_SEL_MASK 0x0C
312#define VMMC_SEL_SHIFT 2
313#define VMMC_ST_MASK 0x03
314#define VMMC_ST_SHIFT 0
315
316
317/*Register VPLL (0x80) register.RegisterDescription */
318#define VPLL_SEL_MASK 0x0C
319#define VPLL_SEL_SHIFT 2
320#define VPLL_ST_MASK 0x03
321#define VPLL_ST_SHIFT 0
322
323
324/*Register VDAC (0x80) register.RegisterDescription */
325#define VDAC_SEL_MASK 0x0C
326#define VDAC_SEL_SHIFT 2
327#define VDAC_ST_MASK 0x03
328#define VDAC_ST_SHIFT 0
329
330
331/*Register THERM (0x80) register.RegisterDescription */
332#define THERM_THERM_HD_MASK 0x20
333#define THERM_THERM_HD_SHIFT 5
334#define THERM_THERM_TS_MASK 0x10
335#define THERM_THERM_TS_SHIFT 4
336#define THERM_THERM_HDSEL_MASK 0x0C
337#define THERM_THERM_HDSEL_SHIFT 2
338#define THERM_RSVD1_MASK 0x02
339#define THERM_RSVD1_SHIFT 1
340#define THERM_THERM_STATE_MASK 0x01
341#define THERM_THERM_STATE_SHIFT 0
342
343
344/*Register BBCH (0x80) register.RegisterDescription */
345#define BBCH_BBSEL_MASK 0x06
346#define BBCH_BBSEL_SHIFT 1
347#define BBCH_BBCHEN_MASK 0x01
348#define BBCH_BBCHEN_SHIFT 0
349
350
351/*Register DCDCCTRL (0x80) register.RegisterDescription */
352#define DCDCCTRL_VDD2_PSKIP_MASK 0x20
353#define DCDCCTRL_VDD2_PSKIP_SHIFT 5
354#define DCDCCTRL_VDD1_PSKIP_MASK 0x10
355#define DCDCCTRL_VDD1_PSKIP_SHIFT 4
356#define DCDCCTRL_VIO_PSKIP_MASK 0x08
357#define DCDCCTRL_VIO_PSKIP_SHIFT 3
358#define DCDCCTRL_DCDCCKEXT_MASK 0x04
359#define DCDCCTRL_DCDCCKEXT_SHIFT 2
360#define DCDCCTRL_DCDCCKSYNC_MASK 0x03
361#define DCDCCTRL_DCDCCKSYNC_SHIFT 0
362
363
364/*Register DEVCTRL (0x80) register.RegisterDescription */
365#define DEVCTRL_RTC_PWDN_MASK 0x40
366#define DEVCTRL_RTC_PWDN_SHIFT 6
367#define DEVCTRL_CK32K_CTRL_MASK 0x20
368#define DEVCTRL_CK32K_CTRL_SHIFT 5
369#define DEVCTRL_SR_CTL_I2C_SEL_MASK 0x10
370#define DEVCTRL_SR_CTL_I2C_SEL_SHIFT 4
371#define DEVCTRL_DEV_OFF_RST_MASK 0x08
372#define DEVCTRL_DEV_OFF_RST_SHIFT 3
373#define DEVCTRL_DEV_ON_MASK 0x04
374#define DEVCTRL_DEV_ON_SHIFT 2
375#define DEVCTRL_DEV_SLP_MASK 0x02
376#define DEVCTRL_DEV_SLP_SHIFT 1
377#define DEVCTRL_DEV_OFF_MASK 0x01
378#define DEVCTRL_DEV_OFF_SHIFT 0
379
380
381/*Register DEVCTRL2 (0x80) register.RegisterDescription */
382#define DEVCTRL2_TSLOT_LENGTH_MASK 0x30
383#define DEVCTRL2_TSLOT_LENGTH_SHIFT 4
384#define DEVCTRL2_SLEEPSIG_POL_MASK 0x08
385#define DEVCTRL2_SLEEPSIG_POL_SHIFT 3
386#define DEVCTRL2_PWON_LP_OFF_MASK 0x04
387#define DEVCTRL2_PWON_LP_OFF_SHIFT 2
388#define DEVCTRL2_PWON_LP_RST_MASK 0x02
389#define DEVCTRL2_PWON_LP_RST_SHIFT 1
390#define DEVCTRL2_IT_POL_MASK 0x01
391#define DEVCTRL2_IT_POL_SHIFT 0
392
393
394/*Register SLEEP_KEEP_LDO_ON (0x80) register.RegisterDescription */
395#define SLEEP_KEEP_LDO_ON_VDAC_KEEPON_MASK 0x80
396#define SLEEP_KEEP_LDO_ON_VDAC_KEEPON_SHIFT 7
397#define SLEEP_KEEP_LDO_ON_VPLL_KEEPON_MASK 0x40
398#define SLEEP_KEEP_LDO_ON_VPLL_KEEPON_SHIFT 6
399#define SLEEP_KEEP_LDO_ON_VAUX33_KEEPON_MASK 0x20
400#define SLEEP_KEEP_LDO_ON_VAUX33_KEEPON_SHIFT 5
401#define SLEEP_KEEP_LDO_ON_VAUX2_KEEPON_MASK 0x10
402#define SLEEP_KEEP_LDO_ON_VAUX2_KEEPON_SHIFT 4
403#define SLEEP_KEEP_LDO_ON_VAUX1_KEEPON_MASK 0x08
404#define SLEEP_KEEP_LDO_ON_VAUX1_KEEPON_SHIFT 3
405#define SLEEP_KEEP_LDO_ON_VDIG2_KEEPON_MASK 0x04
406#define SLEEP_KEEP_LDO_ON_VDIG2_KEEPON_SHIFT 2
407#define SLEEP_KEEP_LDO_ON_VDIG1_KEEPON_MASK 0x02
408#define SLEEP_KEEP_LDO_ON_VDIG1_KEEPON_SHIFT 1
409#define SLEEP_KEEP_LDO_ON_VMMC_KEEPON_MASK 0x01
410#define SLEEP_KEEP_LDO_ON_VMMC_KEEPON_SHIFT 0
411
412
413/*Register SLEEP_KEEP_RES_ON (0x80) register.RegisterDescription */
414#define SLEEP_KEEP_RES_ON_THERM_KEEPON_MASK 0x80
415#define SLEEP_KEEP_RES_ON_THERM_KEEPON_SHIFT 7
416#define SLEEP_KEEP_RES_ON_CLKOUT32K_KEEPON_MASK 0x40
417#define SLEEP_KEEP_RES_ON_CLKOUT32K_KEEPON_SHIFT 6
418#define SLEEP_KEEP_RES_ON_VRTC_KEEPON_MASK 0x20
419#define SLEEP_KEEP_RES_ON_VRTC_KEEPON_SHIFT 5
420#define SLEEP_KEEP_RES_ON_I2CHS_KEEPON_MASK 0x10
421#define SLEEP_KEEP_RES_ON_I2CHS_KEEPON_SHIFT 4
422#define SLEEP_KEEP_RES_ON_VDD3_KEEPON_MASK 0x08
423#define SLEEP_KEEP_RES_ON_VDD3_KEEPON_SHIFT 3
424#define SLEEP_KEEP_RES_ON_VDD2_KEEPON_MASK 0x04
425#define SLEEP_KEEP_RES_ON_VDD2_KEEPON_SHIFT 2
426#define SLEEP_KEEP_RES_ON_VDD1_KEEPON_MASK 0x02
427#define SLEEP_KEEP_RES_ON_VDD1_KEEPON_SHIFT 1
428#define SLEEP_KEEP_RES_ON_VIO_KEEPON_MASK 0x01
429#define SLEEP_KEEP_RES_ON_VIO_KEEPON_SHIFT 0
430
431
432/*Register SLEEP_SET_LDO_OFF (0x80) register.RegisterDescription */
433#define SLEEP_SET_LDO_OFF_VDAC_SETOFF_MASK 0x80
434#define SLEEP_SET_LDO_OFF_VDAC_SETOFF_SHIFT 7
435#define SLEEP_SET_LDO_OFF_VPLL_SETOFF_MASK 0x40
436#define SLEEP_SET_LDO_OFF_VPLL_SETOFF_SHIFT 6
437#define SLEEP_SET_LDO_OFF_VAUX33_SETOFF_MASK 0x20
438#define SLEEP_SET_LDO_OFF_VAUX33_SETOFF_SHIFT 5
439#define SLEEP_SET_LDO_OFF_VAUX2_SETOFF_MASK 0x10
440#define SLEEP_SET_LDO_OFF_VAUX2_SETOFF_SHIFT 4
441#define SLEEP_SET_LDO_OFF_VAUX1_SETOFF_MASK 0x08
442#define SLEEP_SET_LDO_OFF_VAUX1_SETOFF_SHIFT 3
443#define SLEEP_SET_LDO_OFF_VDIG2_SETOFF_MASK 0x04
444#define SLEEP_SET_LDO_OFF_VDIG2_SETOFF_SHIFT 2
445#define SLEEP_SET_LDO_OFF_VDIG1_SETOFF_MASK 0x02
446#define SLEEP_SET_LDO_OFF_VDIG1_SETOFF_SHIFT 1
447#define SLEEP_SET_LDO_OFF_VMMC_SETOFF_MASK 0x01
448#define SLEEP_SET_LDO_OFF_VMMC_SETOFF_SHIFT 0
449
450
451/*Register SLEEP_SET_RES_OFF (0x80) register.RegisterDescription */
452#define SLEEP_SET_RES_OFF_DEFAULT_VOLT_MASK 0x80
453#define SLEEP_SET_RES_OFF_DEFAULT_VOLT_SHIFT 7
454#define SLEEP_SET_RES_OFF_RSVD_MASK 0x60
455#define SLEEP_SET_RES_OFF_RSVD_SHIFT 5
456#define SLEEP_SET_RES_OFF_SPARE_SETOFF_MASK 0x10
457#define SLEEP_SET_RES_OFF_SPARE_SETOFF_SHIFT 4
458#define SLEEP_SET_RES_OFF_VDD3_SETOFF_MASK 0x08
459#define SLEEP_SET_RES_OFF_VDD3_SETOFF_SHIFT 3
460#define SLEEP_SET_RES_OFF_VDD2_SETOFF_MASK 0x04
461#define SLEEP_SET_RES_OFF_VDD2_SETOFF_SHIFT 2
462#define SLEEP_SET_RES_OFF_VDD1_SETOFF_MASK 0x02
463#define SLEEP_SET_RES_OFF_VDD1_SETOFF_SHIFT 1
464#define SLEEP_SET_RES_OFF_VIO_SETOFF_MASK 0x01
465#define SLEEP_SET_RES_OFF_VIO_SETOFF_SHIFT 0
466
467
468/*Register EN1_LDO_ASS (0x80) register.RegisterDescription */
469#define EN1_LDO_ASS_VDAC_EN1_MASK 0x80
470#define EN1_LDO_ASS_VDAC_EN1_SHIFT 7
471#define EN1_LDO_ASS_VPLL_EN1_MASK 0x40
472#define EN1_LDO_ASS_VPLL_EN1_SHIFT 6
473#define EN1_LDO_ASS_VAUX33_EN1_MASK 0x20
474#define EN1_LDO_ASS_VAUX33_EN1_SHIFT 5
475#define EN1_LDO_ASS_VAUX2_EN1_MASK 0x10
476#define EN1_LDO_ASS_VAUX2_EN1_SHIFT 4
477#define EN1_LDO_ASS_VAUX1_EN1_MASK 0x08
478#define EN1_LDO_ASS_VAUX1_EN1_SHIFT 3
479#define EN1_LDO_ASS_VDIG2_EN1_MASK 0x04
480#define EN1_LDO_ASS_VDIG2_EN1_SHIFT 2
481#define EN1_LDO_ASS_VDIG1_EN1_MASK 0x02
482#define EN1_LDO_ASS_VDIG1_EN1_SHIFT 1
483#define EN1_LDO_ASS_VMMC_EN1_MASK 0x01
484#define EN1_LDO_ASS_VMMC_EN1_SHIFT 0
485
486
487/*Register EN1_SMPS_ASS (0x80) register.RegisterDescription */
488#define EN1_SMPS_ASS_RSVD_MASK 0xE0
489#define EN1_SMPS_ASS_RSVD_SHIFT 5
490#define EN1_SMPS_ASS_SPARE_EN1_MASK 0x10
491#define EN1_SMPS_ASS_SPARE_EN1_SHIFT 4
492#define EN1_SMPS_ASS_VDD3_EN1_MASK 0x08
493#define EN1_SMPS_ASS_VDD3_EN1_SHIFT 3
494#define EN1_SMPS_ASS_VDD2_EN1_MASK 0x04
495#define EN1_SMPS_ASS_VDD2_EN1_SHIFT 2
496#define EN1_SMPS_ASS_VDD1_EN1_MASK 0x02
497#define EN1_SMPS_ASS_VDD1_EN1_SHIFT 1
498#define EN1_SMPS_ASS_VIO_EN1_MASK 0x01
499#define EN1_SMPS_ASS_VIO_EN1_SHIFT 0
500
501
502/*Register EN2_LDO_ASS (0x80) register.RegisterDescription */
503#define EN2_LDO_ASS_VDAC_EN2_MASK 0x80
504#define EN2_LDO_ASS_VDAC_EN2_SHIFT 7
505#define EN2_LDO_ASS_VPLL_EN2_MASK 0x40
506#define EN2_LDO_ASS_VPLL_EN2_SHIFT 6
507#define EN2_LDO_ASS_VAUX33_EN2_MASK 0x20
508#define EN2_LDO_ASS_VAUX33_EN2_SHIFT 5
509#define EN2_LDO_ASS_VAUX2_EN2_MASK 0x10
510#define EN2_LDO_ASS_VAUX2_EN2_SHIFT 4
511#define EN2_LDO_ASS_VAUX1_EN2_MASK 0x08
512#define EN2_LDO_ASS_VAUX1_EN2_SHIFT 3
513#define EN2_LDO_ASS_VDIG2_EN2_MASK 0x04
514#define EN2_LDO_ASS_VDIG2_EN2_SHIFT 2
515#define EN2_LDO_ASS_VDIG1_EN2_MASK 0x02
516#define EN2_LDO_ASS_VDIG1_EN2_SHIFT 1
517#define EN2_LDO_ASS_VMMC_EN2_MASK 0x01
518#define EN2_LDO_ASS_VMMC_EN2_SHIFT 0
519
520
521/*Register EN2_SMPS_ASS (0x80) register.RegisterDescription */
522#define EN2_SMPS_ASS_RSVD_MASK 0xE0
523#define EN2_SMPS_ASS_RSVD_SHIFT 5
524#define EN2_SMPS_ASS_SPARE_EN2_MASK 0x10
525#define EN2_SMPS_ASS_SPARE_EN2_SHIFT 4
526#define EN2_SMPS_ASS_VDD3_EN2_MASK 0x08
527#define EN2_SMPS_ASS_VDD3_EN2_SHIFT 3
528#define EN2_SMPS_ASS_VDD2_EN2_MASK 0x04
529#define EN2_SMPS_ASS_VDD2_EN2_SHIFT 2
530#define EN2_SMPS_ASS_VDD1_EN2_MASK 0x02
531#define EN2_SMPS_ASS_VDD1_EN2_SHIFT 1
532#define EN2_SMPS_ASS_VIO_EN2_MASK 0x01
533#define EN2_SMPS_ASS_VIO_EN2_SHIFT 0
534
535
536/*Register EN3_LDO_ASS (0x80) register.RegisterDescription */
537#define EN3_LDO_ASS_VDAC_EN3_MASK 0x80
538#define EN3_LDO_ASS_VDAC_EN3_SHIFT 7
539#define EN3_LDO_ASS_VPLL_EN3_MASK 0x40
540#define EN3_LDO_ASS_VPLL_EN3_SHIFT 6
541#define EN3_LDO_ASS_VAUX33_EN3_MASK 0x20
542#define EN3_LDO_ASS_VAUX33_EN3_SHIFT 5
543#define EN3_LDO_ASS_VAUX2_EN3_MASK 0x10
544#define EN3_LDO_ASS_VAUX2_EN3_SHIFT 4
545#define EN3_LDO_ASS_VAUX1_EN3_MASK 0x08
546#define EN3_LDO_ASS_VAUX1_EN3_SHIFT 3
547#define EN3_LDO_ASS_VDIG2_EN3_MASK 0x04
548#define EN3_LDO_ASS_VDIG2_EN3_SHIFT 2
549#define EN3_LDO_ASS_VDIG1_EN3_MASK 0x02
550#define EN3_LDO_ASS_VDIG1_EN3_SHIFT 1
551#define EN3_LDO_ASS_VMMC_EN3_MASK 0x01
552#define EN3_LDO_ASS_VMMC_EN3_SHIFT 0
553
554
555/*Register SPARE (0x80) register.RegisterDescription */
556#define SPARE_SPARE_MASK 0xFF
557#define SPARE_SPARE_SHIFT 0
558
559
560/*Register INT_STS (0x80) register.RegisterDescription */
561#define INT_STS_RTC_PERIOD_IT_MASK 0x80
562#define INT_STS_RTC_PERIOD_IT_SHIFT 7
563#define INT_STS_RTC_ALARM_IT_MASK 0x40
564#define INT_STS_RTC_ALARM_IT_SHIFT 6
565#define INT_STS_HOTDIE_IT_MASK 0x20
566#define INT_STS_HOTDIE_IT_SHIFT 5
567#define INT_STS_PWRHOLD_IT_MASK 0x10
568#define INT_STS_PWRHOLD_IT_SHIFT 4
569#define INT_STS_PWRON_LP_IT_MASK 0x08
570#define INT_STS_PWRON_LP_IT_SHIFT 3
571#define INT_STS_PWRON_IT_MASK 0x04
572#define INT_STS_PWRON_IT_SHIFT 2
573#define INT_STS_VMBHI_IT_MASK 0x02
574#define INT_STS_VMBHI_IT_SHIFT 1
575#define INT_STS_VMBDCH_IT_MASK 0x01
576#define INT_STS_VMBDCH_IT_SHIFT 0
577
578
579/*Register INT_MSK (0x80) register.RegisterDescription */
580#define INT_MSK_RTC_PERIOD_IT_MSK_MASK 0x80
581#define INT_MSK_RTC_PERIOD_IT_MSK_SHIFT 7
582#define INT_MSK_RTC_ALARM_IT_MSK_MASK 0x40
583#define INT_MSK_RTC_ALARM_IT_MSK_SHIFT 6
584#define INT_MSK_HOTDIE_IT_MSK_MASK 0x20
585#define INT_MSK_HOTDIE_IT_MSK_SHIFT 5
586#define INT_MSK_PWRHOLD_IT_MSK_MASK 0x10
587#define INT_MSK_PWRHOLD_IT_MSK_SHIFT 4
588#define INT_MSK_PWRON_LP_IT_MSK_MASK 0x08
589#define INT_MSK_PWRON_LP_IT_MSK_SHIFT 3
590#define INT_MSK_PWRON_IT_MSK_MASK 0x04
591#define INT_MSK_PWRON_IT_MSK_SHIFT 2
592#define INT_MSK_VMBHI_IT_MSK_MASK 0x02
593#define INT_MSK_VMBHI_IT_MSK_SHIFT 1
594#define INT_MSK_VMBDCH_IT_MSK_MASK 0x01
595#define INT_MSK_VMBDCH_IT_MSK_SHIFT 0
596
597
598/*Register INT_STS2 (0x80) register.RegisterDescription */
599#define INT_STS2_GPIO3_F_IT_MASK 0x80
600#define INT_STS2_GPIO3_F_IT_SHIFT 7
601#define INT_STS2_GPIO3_R_IT_MASK 0x40
602#define INT_STS2_GPIO3_R_IT_SHIFT 6
603#define INT_STS2_GPIO2_F_IT_MASK 0x20
604#define INT_STS2_GPIO2_F_IT_SHIFT 5
605#define INT_STS2_GPIO2_R_IT_MASK 0x10
606#define INT_STS2_GPIO2_R_IT_SHIFT 4
607#define INT_STS2_GPIO1_F_IT_MASK 0x08
608#define INT_STS2_GPIO1_F_IT_SHIFT 3
609#define INT_STS2_GPIO1_R_IT_MASK 0x04
610#define INT_STS2_GPIO1_R_IT_SHIFT 2
611#define INT_STS2_GPIO0_F_IT_MASK 0x02
612#define INT_STS2_GPIO0_F_IT_SHIFT 1
613#define INT_STS2_GPIO0_R_IT_MASK 0x01
614#define INT_STS2_GPIO0_R_IT_SHIFT 0
615
616
617/*Register INT_MSK2 (0x80) register.RegisterDescription */
618#define INT_MSK2_GPIO3_F_IT_MSK_MASK 0x80
619#define INT_MSK2_GPIO3_F_IT_MSK_SHIFT 7
620#define INT_MSK2_GPIO3_R_IT_MSK_MASK 0x40
621#define INT_MSK2_GPIO3_R_IT_MSK_SHIFT 6
622#define INT_MSK2_GPIO2_F_IT_MSK_MASK 0x20
623#define INT_MSK2_GPIO2_F_IT_MSK_SHIFT 5
624#define INT_MSK2_GPIO2_R_IT_MSK_MASK 0x10
625#define INT_MSK2_GPIO2_R_IT_MSK_SHIFT 4
626#define INT_MSK2_GPIO1_F_IT_MSK_MASK 0x08
627#define INT_MSK2_GPIO1_F_IT_MSK_SHIFT 3
628#define INT_MSK2_GPIO1_R_IT_MSK_MASK 0x04
629#define INT_MSK2_GPIO1_R_IT_MSK_SHIFT 2
630#define INT_MSK2_GPIO0_F_IT_MSK_MASK 0x02
631#define INT_MSK2_GPIO0_F_IT_MSK_SHIFT 1
632#define INT_MSK2_GPIO0_R_IT_MSK_MASK 0x01
633#define INT_MSK2_GPIO0_R_IT_MSK_SHIFT 0
634
635
636/*Register INT_STS3 (0x80) register.RegisterDescription */
637#define INT_STS3_GPIO5_F_IT_MASK 0x08
638#define INT_STS3_GPIO5_F_IT_SHIFT 3
639#define INT_STS3_GPIO5_R_IT_MASK 0x04
640#define INT_STS3_GPIO5_R_IT_SHIFT 2
641#define INT_STS3_GPIO4_F_IT_MASK 0x02
642#define INT_STS3_GPIO4_F_IT_SHIFT 1
643#define INT_STS3_GPIO4_R_IT_MASK 0x01
644#define INT_STS3_GPIO4_R_IT_SHIFT 0
645
646
647/*Register INT_MSK3 (0x80) register.RegisterDescription */
648#define INT_MSK3_GPIO5_F_IT_MSK_MASK 0x08
649#define INT_MSK3_GPIO5_F_IT_MSK_SHIFT 3
650#define INT_MSK3_GPIO5_R_IT_MSK_MASK 0x04
651#define INT_MSK3_GPIO5_R_IT_MSK_SHIFT 2
652#define INT_MSK3_GPIO4_F_IT_MSK_MASK 0x02
653#define INT_MSK3_GPIO4_F_IT_MSK_SHIFT 1
654#define INT_MSK3_GPIO4_R_IT_MSK_MASK 0x01
655#define INT_MSK3_GPIO4_R_IT_MSK_SHIFT 0
656
657
658/*Register GPIO (0x80) register.RegisterDescription */
659#define GPIO_DEB_MASK 0x10
660#define GPIO_DEB_SHIFT 4
661#define GPIO_PUEN_MASK 0x08
662#define GPIO_PUEN_SHIFT 3
663#define GPIO_CFG_MASK 0x04
664#define GPIO_CFG_SHIFT 2
665#define GPIO_STS_MASK 0x02
666#define GPIO_STS_SHIFT 1
667#define GPIO_SET_MASK 0x01
668#define GPIO_SET_SHIFT 0
669
670
671/*Register JTAGVERNUM (0x80) register.RegisterDescription */
672#define JTAGVERNUM_VERNUM_MASK 0x0F
673#define JTAGVERNUM_VERNUM_SHIFT 0
674
675
676/* Register VDDCTRL (0x27) bit definitions */
677#define VDDCTRL_ST_MASK 0x03
678#define VDDCTRL_ST_SHIFT 0
679
680
681/*Register VDDCTRL_OP (0x28) bit definitios */
682#define VDDCTRL_OP_CMD_MASK 0x80
683#define VDDCTRL_OP_CMD_SHIFT 7
684#define VDDCTRL_OP_SEL_MASK 0x7F
685#define VDDCTRL_OP_SEL_SHIFT 0
686
687
688/*Register VDDCTRL_SR (0x29) bit definitions */
689#define VDDCTRL_SR_SEL_MASK 0x7F
690#define VDDCTRL_SR_SEL_SHIFT 0
691
692
693/* IRQ Definitions */
694#define TPS65910_IRQ_VBAT_VMBDCH 0
695#define TPS65910_IRQ_VBAT_VMHI 1
696#define TPS65910_IRQ_PWRON 2
697#define TPS65910_IRQ_PWRON_LP 3
698#define TPS65910_IRQ_PWRHOLD 4
699#define TPS65910_IRQ_HOTDIE 5
700#define TPS65910_IRQ_RTC_ALARM 6
701#define TPS65910_IRQ_RTC_PERIOD 7
702#define TPS65910_IRQ_GPIO_R 8
703#define TPS65910_IRQ_GPIO_F 9
704#define TPS65910_NUM_IRQ 10
705
706#define TPS65911_IRQ_VBAT_VMBDCH 0
707#define TPS65911_IRQ_VBAT_VMBDCH2L 1
708#define TPS65911_IRQ_VBAT_VMBDCH2H 2
709#define TPS65911_IRQ_VBAT_VMHI 3
710#define TPS65911_IRQ_PWRON 4
711#define TPS65911_IRQ_PWRON_LP 5
712#define TPS65911_IRQ_PWRHOLD_F 6
713#define TPS65911_IRQ_PWRHOLD_R 7
714#define TPS65911_IRQ_HOTDIE 8
715#define TPS65911_IRQ_RTC_ALARM 9
716#define TPS65911_IRQ_RTC_PERIOD 10
717#define TPS65911_IRQ_GPIO0_R 11
718#define TPS65911_IRQ_GPIO0_F 12
719#define TPS65911_IRQ_GPIO1_R 13
720#define TPS65911_IRQ_GPIO1_F 14
721#define TPS65911_IRQ_GPIO2_R 15
722#define TPS65911_IRQ_GPIO2_F 16
723#define TPS65911_IRQ_GPIO3_R 17
724#define TPS65911_IRQ_GPIO3_F 18
725#define TPS65911_IRQ_GPIO4_R 19
726#define TPS65911_IRQ_GPIO4_F 20
727#define TPS65911_IRQ_GPIO5_R 21
728#define TPS65911_IRQ_GPIO5_F 22
729#define TPS65911_IRQ_WTCHDG 23
730#define TPS65911_IRQ_PWRDN 24
731
732#define TPS65911_NUM_IRQ 25
733
734
735/* GPIO Register Definitions */
736#define TPS65910_GPIO_DEB BIT(2)
737#define TPS65910_GPIO_PUEN BIT(3)
738#define TPS65910_GPIO_CFG BIT(2)
739#define TPS65910_GPIO_STS BIT(1)
740#define TPS65910_GPIO_SET BIT(0)
741
742/**
743 * struct tps65910_board
744 * Board platform data may be used to initialize regulators.
745 */
746
747struct tps65910_board {
748 int gpio_base;
749 int irq;
750 int irq_base;
751 int vmbch_threshold;
752 int vmbch2_threshold;
753 struct regulator_init_data *tps65910_pmic_init_data;
754};
755
756/**
757 * struct tps65910 - tps65910 sub-driver chip access routines
758 */
759
760struct tps65910 {
761 struct device *dev;
762 struct i2c_client *i2c_client;
763 struct mutex io_mutex;
764 unsigned int id;
765 int (*read)(struct tps65910 *tps65910, u8 reg, int size, void *dest);
766 int (*write)(struct tps65910 *tps65910, u8 reg, int size, void *src);
767
768 /* Client devices */
769 struct tps65910_pmic *pmic;
770 struct tps65910_rtc *rtc;
771 struct tps65910_power *power;
772
773 /* GPIO Handling */
774 struct gpio_chip gpio;
775
776 /* IRQ Handling */
777 struct mutex irq_lock;
778 int chip_irq;
779 int irq_base;
780 int irq_num;
781 u32 irq_mask;
782};
783
784struct tps65910_platform_data {
785 int irq;
786 int irq_base;
787};
788
789int tps65910_set_bits(struct tps65910 *tps65910, u8 reg, u8 mask);
790int tps65910_clear_bits(struct tps65910 *tps65910, u8 reg, u8 mask);
791void tps65910_gpio_init(struct tps65910 *tps65910, int gpio_base);
792int tps65910_irq_init(struct tps65910 *tps65910, int irq,
793 struct tps65910_platform_data *pdata);
794
795static inline int tps65910_chip_id(struct tps65910 *tps65910)
796{
797 return tps65910->id;
798}
799
800#endif /* __LINUX_MFD_TPS65910_H */
diff --git a/include/linux/mm.h b/include/linux/mm.h
index fb8e814f78dc..9670f71d7be9 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -1408,17 +1408,11 @@ extern void exit_mmap(struct mm_struct *);
1408extern int mm_take_all_locks(struct mm_struct *mm); 1408extern int mm_take_all_locks(struct mm_struct *mm);
1409extern void mm_drop_all_locks(struct mm_struct *mm); 1409extern void mm_drop_all_locks(struct mm_struct *mm);
1410 1410
1411#ifdef CONFIG_PROC_FS
1412/* From fs/proc/base.c. callers must _not_ hold the mm's exe_file_lock */ 1411/* From fs/proc/base.c. callers must _not_ hold the mm's exe_file_lock */
1413extern void added_exe_file_vma(struct mm_struct *mm); 1412extern void added_exe_file_vma(struct mm_struct *mm);
1414extern void removed_exe_file_vma(struct mm_struct *mm); 1413extern void removed_exe_file_vma(struct mm_struct *mm);
1415#else 1414extern void set_mm_exe_file(struct mm_struct *mm, struct file *new_exe_file);
1416static inline void added_exe_file_vma(struct mm_struct *mm) 1415extern struct file *get_mm_exe_file(struct mm_struct *mm);
1417{}
1418
1419static inline void removed_exe_file_vma(struct mm_struct *mm)
1420{}
1421#endif /* CONFIG_PROC_FS */
1422 1416
1423extern int may_expand_vm(struct mm_struct *mm, unsigned long npages); 1417extern int may_expand_vm(struct mm_struct *mm, unsigned long npages);
1424extern int install_special_mapping(struct mm_struct *mm, 1418extern int install_special_mapping(struct mm_struct *mm,
diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
index 6fe96c19f85e..2a78aae78c69 100644
--- a/include/linux/mm_types.h
+++ b/include/linux/mm_types.h
@@ -302,11 +302,9 @@ struct mm_struct {
302 struct task_struct __rcu *owner; 302 struct task_struct __rcu *owner;
303#endif 303#endif
304 304
305#ifdef CONFIG_PROC_FS
306 /* store ref to file /proc/<pid>/exe symlink points to */ 305 /* store ref to file /proc/<pid>/exe symlink points to */
307 struct file *exe_file; 306 struct file *exe_file;
308 unsigned long num_exe_file_vmas; 307 unsigned long num_exe_file_vmas;
309#endif
310#ifdef CONFIG_MMU_NOTIFIER 308#ifdef CONFIG_MMU_NOTIFIER
311 struct mmu_notifier_mm *mmu_notifier_mm; 309 struct mmu_notifier_mm *mmu_notifier_mm;
312#endif 310#endif
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h
index 217bcf6bca77..c928dac6cad0 100644
--- a/include/linux/mmzone.h
+++ b/include/linux/mmzone.h
@@ -273,11 +273,6 @@ struct zone_reclaim_stat {
273 */ 273 */
274 unsigned long recent_rotated[2]; 274 unsigned long recent_rotated[2];
275 unsigned long recent_scanned[2]; 275 unsigned long recent_scanned[2];
276
277 /*
278 * accumulated for batching
279 */
280 unsigned long nr_saved_scan[NR_LRU_LISTS];
281}; 276};
282 277
283struct zone { 278struct zone {
@@ -1056,12 +1051,14 @@ static inline struct mem_section *__pfn_to_section(unsigned long pfn)
1056 return __nr_to_section(pfn_to_section_nr(pfn)); 1051 return __nr_to_section(pfn_to_section_nr(pfn));
1057} 1052}
1058 1053
1054#ifndef CONFIG_HAVE_ARCH_PFN_VALID
1059static inline int pfn_valid(unsigned long pfn) 1055static inline int pfn_valid(unsigned long pfn)
1060{ 1056{
1061 if (pfn_to_section_nr(pfn) >= NR_MEM_SECTIONS) 1057 if (pfn_to_section_nr(pfn) >= NR_MEM_SECTIONS)
1062 return 0; 1058 return 0;
1063 return valid_section(__nr_to_section(pfn_to_section_nr(pfn))); 1059 return valid_section(__nr_to_section(pfn_to_section_nr(pfn)));
1064} 1060}
1061#endif
1065 1062
1066static inline int pfn_present(unsigned long pfn) 1063static inline int pfn_present(unsigned long pfn)
1067{ 1064{
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h
index 9d5306bad117..2541fb848daa 100644
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -322,9 +322,12 @@ static inline uint32_t mtd_mod_by_ws(uint64_t sz, struct mtd_info *mtd)
322 322
323 /* Kernel-side ioctl definitions */ 323 /* Kernel-side ioctl definitions */
324 324
325extern int add_mtd_device(struct mtd_info *mtd); 325struct mtd_partition;
326extern int del_mtd_device (struct mtd_info *mtd);
327 326
327extern int mtd_device_register(struct mtd_info *master,
328 const struct mtd_partition *parts,
329 int nr_parts);
330extern int mtd_device_unregister(struct mtd_info *master);
328extern struct mtd_info *get_mtd_device(struct mtd_info *mtd, int num); 331extern struct mtd_info *get_mtd_device(struct mtd_info *mtd, int num);
329extern int __get_mtd_device(struct mtd_info *mtd); 332extern int __get_mtd_device(struct mtd_info *mtd);
330extern void __put_mtd_device(struct mtd_info *mtd); 333extern void __put_mtd_device(struct mtd_info *mtd);
@@ -348,15 +351,9 @@ int default_mtd_writev(struct mtd_info *mtd, const struct kvec *vecs,
348int default_mtd_readv(struct mtd_info *mtd, struct kvec *vecs, 351int default_mtd_readv(struct mtd_info *mtd, struct kvec *vecs,
349 unsigned long count, loff_t from, size_t *retlen); 352 unsigned long count, loff_t from, size_t *retlen);
350 353
351#ifdef CONFIG_MTD_PARTITIONS 354void *mtd_kmalloc_up_to(const struct mtd_info *mtd, size_t *size);
355
352void mtd_erase_callback(struct erase_info *instr); 356void mtd_erase_callback(struct erase_info *instr);
353#else
354static inline void mtd_erase_callback(struct erase_info *instr)
355{
356 if (instr->callback)
357 instr->callback(instr);
358}
359#endif
360 357
361/* 358/*
362 * Debugging macro and defines 359 * Debugging macro and defines
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h
index d44192740f6f..c2b9ac4fbc4a 100644
--- a/include/linux/mtd/nand.h
+++ b/include/linux/mtd/nand.h
@@ -237,9 +237,9 @@ typedef enum {
237 * If passed additionally to NAND_USE_FLASH_BBT then BBT code will not touch 237 * If passed additionally to NAND_USE_FLASH_BBT then BBT code will not touch
238 * the OOB area. 238 * the OOB area.
239 */ 239 */
240#define NAND_USE_FLASH_BBT_NO_OOB 0x00100000 240#define NAND_USE_FLASH_BBT_NO_OOB 0x00800000
241/* Create an empty BBT with no vendor information if the BBT is available */ 241/* Create an empty BBT with no vendor information if the BBT is available */
242#define NAND_CREATE_EMPTY_BBT 0x00200000 242#define NAND_CREATE_EMPTY_BBT 0x01000000
243 243
244/* Options set by nand scan */ 244/* Options set by nand scan */
245/* Nand scan has allocated controller struct */ 245/* Nand scan has allocated controller struct */
diff --git a/include/linux/mtd/partitions.h b/include/linux/mtd/partitions.h
index 4a0a8ba90a72..3a6f0372fc96 100644
--- a/include/linux/mtd/partitions.h
+++ b/include/linux/mtd/partitions.h
@@ -16,7 +16,7 @@
16 * Partition definition structure: 16 * Partition definition structure:
17 * 17 *
18 * An array of struct partition is passed along with a MTD object to 18 * An array of struct partition is passed along with a MTD object to
19 * add_mtd_partitions() to create them. 19 * mtd_device_register() to create them.
20 * 20 *
21 * For each partition, these fields are available: 21 * For each partition, these fields are available:
22 * name: string that will be used to label the partition's MTD device. 22 * name: string that will be used to label the partition's MTD device.
@@ -49,9 +49,6 @@ struct mtd_partition {
49 49
50struct mtd_info; 50struct mtd_info;
51 51
52int add_mtd_partitions(struct mtd_info *, const struct mtd_partition *, int);
53int del_mtd_partitions(struct mtd_info *);
54
55/* 52/*
56 * Functions dealing with the various ways of partitioning the space 53 * Functions dealing with the various ways of partitioning the space
57 */ 54 */
@@ -73,14 +70,17 @@ extern int parse_mtd_partitions(struct mtd_info *master, const char **types,
73struct device; 70struct device;
74struct device_node; 71struct device_node;
75 72
73#ifdef CONFIG_MTD_OF_PARTS
76int __devinit of_mtd_parse_partitions(struct device *dev, 74int __devinit of_mtd_parse_partitions(struct device *dev,
77 struct device_node *node, 75 struct device_node *node,
78 struct mtd_partition **pparts); 76 struct mtd_partition **pparts);
79
80#ifdef CONFIG_MTD_PARTITIONS
81static inline int mtd_has_partitions(void) { return 1; }
82#else 77#else
83static inline int mtd_has_partitions(void) { return 0; } 78static inline int of_mtd_parse_partitions(struct device *dev,
79 struct device_node *node,
80 struct mtd_partition **pparts)
81{
82 return 0;
83}
84#endif 84#endif
85 85
86#ifdef CONFIG_MTD_CMDLINE_PARTS 86#ifdef CONFIG_MTD_CMDLINE_PARTS
diff --git a/include/linux/mtd/physmap.h b/include/linux/mtd/physmap.h
index 49b959029417..d40bfa1d9c91 100644
--- a/include/linux/mtd/physmap.h
+++ b/include/linux/mtd/physmap.h
@@ -37,8 +37,6 @@ struct physmap_flash_data {
37void physmap_configure(unsigned long addr, unsigned long size, 37void physmap_configure(unsigned long addr, unsigned long size,
38 int bankwidth, void (*set_vpp)(struct map_info *, int) ); 38 int bankwidth, void (*set_vpp)(struct map_info *, int) );
39 39
40#ifdef CONFIG_MTD_PARTITIONS
41
42/* 40/*
43 * Machines that wish to do flash partition may want to call this function in 41 * Machines that wish to do flash partition may want to call this function in
44 * their setup routine. 42 * their setup routine.
@@ -50,6 +48,4 @@ void physmap_configure(unsigned long addr, unsigned long size,
50 */ 48 */
51void physmap_set_partitions(struct mtd_partition *parts, int num_parts); 49void physmap_set_partitions(struct mtd_partition *parts, int num_parts);
52 50
53#endif /* defined(CONFIG_MTD_PARTITIONS) */
54
55#endif /* __LINUX_MTD_PHYSMAP__ */ 51#endif /* __LINUX_MTD_PHYSMAP__ */
diff --git a/include/linux/net.h b/include/linux/net.h
index 1da55e9b6f01..b29923006b11 100644
--- a/include/linux/net.h
+++ b/include/linux/net.h
@@ -289,11 +289,5 @@ extern int kernel_sock_shutdown(struct socket *sock,
289 MODULE_ALIAS("net-pf-" __stringify(pf) "-proto-" __stringify(proto) \ 289 MODULE_ALIAS("net-pf-" __stringify(pf) "-proto-" __stringify(proto) \
290 "-type-" __stringify(type)) 290 "-type-" __stringify(type))
291 291
292#ifdef CONFIG_SYSCTL
293#include <linux/sysctl.h>
294#include <linux/ratelimit.h>
295extern struct ratelimit_state net_ratelimit_state;
296#endif
297
298#endif /* __KERNEL__ */ 292#endif /* __KERNEL__ */
299#endif /* _LINUX_NET_H */ 293#endif /* _LINUX_NET_H */
diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h
index 7fa95df60146..857f5026ced6 100644
--- a/include/linux/netfilter.h
+++ b/include/linux/netfilter.h
@@ -13,6 +13,7 @@
13#endif 13#endif
14#include <linux/types.h> 14#include <linux/types.h>
15#include <linux/compiler.h> 15#include <linux/compiler.h>
16#include <linux/sysctl.h>
16 17
17/* Responses from hook functions. */ 18/* Responses from hook functions. */
18#define NF_DROP 0 19#define NF_DROP 0
diff --git a/include/linux/netfilter/ipset/ip_set_ahash.h b/include/linux/netfilter/ipset/ip_set_ahash.h
index a0196ac79051..ac3c822eb39a 100644
--- a/include/linux/netfilter/ipset/ip_set_ahash.h
+++ b/include/linux/netfilter/ipset/ip_set_ahash.h
@@ -839,7 +839,7 @@ type_pf_tdel(struct ip_set *set, void *value, u32 timeout)
839 struct htable *t = h->table; 839 struct htable *t = h->table;
840 const struct type_pf_elem *d = value; 840 const struct type_pf_elem *d = value;
841 struct hbucket *n; 841 struct hbucket *n;
842 int i, ret = 0; 842 int i;
843 struct type_pf_elem *data; 843 struct type_pf_elem *data;
844 u32 key; 844 u32 key;
845 845
@@ -850,7 +850,7 @@ type_pf_tdel(struct ip_set *set, void *value, u32 timeout)
850 if (!type_pf_data_equal(data, d)) 850 if (!type_pf_data_equal(data, d))
851 continue; 851 continue;
852 if (type_pf_data_expired(data)) 852 if (type_pf_data_expired(data))
853 ret = -IPSET_ERR_EXIST; 853 return -IPSET_ERR_EXIST;
854 if (i != n->pos - 1) 854 if (i != n->pos - 1)
855 /* Not last one */ 855 /* Not last one */
856 type_pf_data_copy(data, ahash_tdata(n, n->pos - 1)); 856 type_pf_data_copy(data, ahash_tdata(n, n->pos - 1));
diff --git a/include/linux/netfilter/ipset/ip_set_timeout.h b/include/linux/netfilter/ipset/ip_set_timeout.h
index 9f30c5f2ec1c..bcdd40ad39ed 100644
--- a/include/linux/netfilter/ipset/ip_set_timeout.h
+++ b/include/linux/netfilter/ipset/ip_set_timeout.h
@@ -45,7 +45,7 @@ ip_set_timeout_test(unsigned long timeout)
45{ 45{
46 return timeout != IPSET_ELEM_UNSET && 46 return timeout != IPSET_ELEM_UNSET &&
47 (timeout == IPSET_ELEM_PERMANENT || 47 (timeout == IPSET_ELEM_PERMANENT ||
48 time_after(timeout, jiffies)); 48 time_is_after_jiffies(timeout));
49} 49}
50 50
51static inline bool 51static inline bool
@@ -53,7 +53,7 @@ ip_set_timeout_expired(unsigned long timeout)
53{ 53{
54 return timeout != IPSET_ELEM_UNSET && 54 return timeout != IPSET_ELEM_UNSET &&
55 timeout != IPSET_ELEM_PERMANENT && 55 timeout != IPSET_ELEM_PERMANENT &&
56 time_before(timeout, jiffies); 56 time_is_before_jiffies(timeout);
57} 57}
58 58
59static inline unsigned long 59static inline unsigned long
@@ -64,7 +64,7 @@ ip_set_timeout_set(u32 timeout)
64 if (!timeout) 64 if (!timeout)
65 return IPSET_ELEM_PERMANENT; 65 return IPSET_ELEM_PERMANENT;
66 66
67 t = timeout * HZ + jiffies; 67 t = msecs_to_jiffies(timeout * 1000) + jiffies;
68 if (t == IPSET_ELEM_UNSET || t == IPSET_ELEM_PERMANENT) 68 if (t == IPSET_ELEM_UNSET || t == IPSET_ELEM_PERMANENT)
69 /* Bingo! */ 69 /* Bingo! */
70 t++; 70 t++;
@@ -75,7 +75,8 @@ ip_set_timeout_set(u32 timeout)
75static inline u32 75static inline u32
76ip_set_timeout_get(unsigned long timeout) 76ip_set_timeout_get(unsigned long timeout)
77{ 77{
78 return timeout == IPSET_ELEM_PERMANENT ? 0 : (timeout - jiffies)/HZ; 78 return timeout == IPSET_ELEM_PERMANENT ? 0 :
79 jiffies_to_msecs(timeout - jiffies)/1000;
79} 80}
80 81
81#else 82#else
@@ -89,14 +90,14 @@ static inline bool
89ip_set_timeout_test(unsigned long timeout) 90ip_set_timeout_test(unsigned long timeout)
90{ 91{
91 return timeout == IPSET_ELEM_PERMANENT || 92 return timeout == IPSET_ELEM_PERMANENT ||
92 time_after(timeout, jiffies); 93 time_is_after_jiffies(timeout);
93} 94}
94 95
95static inline bool 96static inline bool
96ip_set_timeout_expired(unsigned long timeout) 97ip_set_timeout_expired(unsigned long timeout)
97{ 98{
98 return timeout != IPSET_ELEM_PERMANENT && 99 return timeout != IPSET_ELEM_PERMANENT &&
99 time_before(timeout, jiffies); 100 time_is_before_jiffies(timeout);
100} 101}
101 102
102static inline unsigned long 103static inline unsigned long
@@ -107,7 +108,7 @@ ip_set_timeout_set(u32 timeout)
107 if (!timeout) 108 if (!timeout)
108 return IPSET_ELEM_PERMANENT; 109 return IPSET_ELEM_PERMANENT;
109 110
110 t = timeout * HZ + jiffies; 111 t = msecs_to_jiffies(timeout * 1000) + jiffies;
111 if (t == IPSET_ELEM_PERMANENT) 112 if (t == IPSET_ELEM_PERMANENT)
112 /* Bingo! :-) */ 113 /* Bingo! :-) */
113 t++; 114 t++;
@@ -118,7 +119,8 @@ ip_set_timeout_set(u32 timeout)
118static inline u32 119static inline u32
119ip_set_timeout_get(unsigned long timeout) 120ip_set_timeout_get(unsigned long timeout)
120{ 121{
121 return timeout == IPSET_ELEM_PERMANENT ? 0 : (timeout - jiffies)/HZ; 122 return timeout == IPSET_ELEM_PERMANENT ? 0 :
123 jiffies_to_msecs(timeout - jiffies)/1000;
122} 124}
123#endif /* ! IP_SET_BITMAP_TIMEOUT */ 125#endif /* ! IP_SET_BITMAP_TIMEOUT */
124 126
diff --git a/include/linux/nsproxy.h b/include/linux/nsproxy.h
index 7b370c7cfeff..50d20aba57d3 100644
--- a/include/linux/nsproxy.h
+++ b/include/linux/nsproxy.h
@@ -81,13 +81,4 @@ static inline void get_nsproxy(struct nsproxy *ns)
81 atomic_inc(&ns->count); 81 atomic_inc(&ns->count);
82} 82}
83 83
84#ifdef CONFIG_CGROUP_NS
85int ns_cgroup_clone(struct task_struct *tsk, struct pid *pid);
86#else
87static inline int ns_cgroup_clone(struct task_struct *tsk, struct pid *pid)
88{
89 return 0;
90}
91#endif
92
93#endif 84#endif
diff --git a/include/linux/pid.h b/include/linux/pid.h
index cdced84261d7..b152d44fb181 100644
--- a/include/linux/pid.h
+++ b/include/linux/pid.h
@@ -105,7 +105,7 @@ extern struct pid_namespace init_pid_ns;
105 * or rcu_read_lock() held. 105 * or rcu_read_lock() held.
106 * 106 *
107 * find_pid_ns() finds the pid in the namespace specified 107 * find_pid_ns() finds the pid in the namespace specified
108 * find_vpid() finr the pid by its virtual id, i.e. in the current namespace 108 * find_vpid() finds the pid by its virtual id, i.e. in the current namespace
109 * 109 *
110 * see also find_task_by_vpid() set in include/linux/sched.h 110 * see also find_task_by_vpid() set in include/linux/sched.h
111 */ 111 */
diff --git a/include/linux/power/isp1704_charger.h b/include/linux/power/isp1704_charger.h
new file mode 100644
index 000000000000..68096a6aa2d7
--- /dev/null
+++ b/include/linux/power/isp1704_charger.h
@@ -0,0 +1,29 @@
1/*
2 * ISP1704 USB Charger Detection driver
3 *
4 * Copyright (C) 2011 Nokia Corporation
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19 */
20
21
22#ifndef __ISP1704_CHARGER_H
23#define __ISP1704_CHARGER_H
24
25struct isp1704_charger_data {
26 void (*set_power)(bool on);
27};
28
29#endif
diff --git a/include/linux/power/max8903_charger.h b/include/linux/power/max8903_charger.h
new file mode 100644
index 000000000000..24f51db8a83f
--- /dev/null
+++ b/include/linux/power/max8903_charger.h
@@ -0,0 +1,57 @@
1/*
2 * max8903_charger.h - Maxim 8903 USB/Adapter Charger Driver
3 *
4 * Copyright (C) 2011 Samsung Electronics
5 * MyungJoo Ham <myungjoo.ham@samsung.com>
6 *
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.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
20 *
21 */
22
23#ifndef __MAX8903_CHARGER_H__
24#define __MAX8903_CHARGER_H__
25
26struct max8903_pdata {
27 /*
28 * GPIOs
29 * cen, chg, flt, and usus are optional.
30 * dok, dcm, and uok are not optional depending on the status of
31 * dc_valid and usb_valid.
32 */
33 int cen; /* Charger Enable input */
34 int dok; /* DC(Adapter) Power OK output */
35 int uok; /* USB Power OK output */
36 int chg; /* Charger status output */
37 int flt; /* Fault output */
38 int dcm; /* Current-Limit Mode input (1: DC, 2: USB) */
39 int usus; /* USB Suspend Input (1: suspended) */
40
41 /*
42 * DC(Adapter/TA) is wired
43 * When dc_valid is true,
44 * dok and dcm should be valid.
45 *
46 * At least one of dc_valid or usb_valid should be true.
47 */
48 bool dc_valid;
49 /*
50 * USB is wired
51 * When usb_valid is true,
52 * uok should be valid.
53 */
54 bool usb_valid;
55};
56
57#endif /* __MAX8903_CHARGER_H__ */
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h
index 648c9c58add7..e7576cf9e32d 100644
--- a/include/linux/proc_fs.h
+++ b/include/linux/proc_fs.h
@@ -173,12 +173,6 @@ extern void proc_net_remove(struct net *net, const char *name);
173extern struct proc_dir_entry *proc_net_mkdir(struct net *net, const char *name, 173extern struct proc_dir_entry *proc_net_mkdir(struct net *net, const char *name,
174 struct proc_dir_entry *parent); 174 struct proc_dir_entry *parent);
175 175
176/* While the {get|set|dup}_mm_exe_file functions are for mm_structs, they are
177 * only needed to implement /proc/<pid>|self/exe so we define them here. */
178extern void set_mm_exe_file(struct mm_struct *mm, struct file *new_exe_file);
179extern struct file *get_mm_exe_file(struct mm_struct *mm);
180extern void dup_mm_exe_file(struct mm_struct *oldmm, struct mm_struct *newmm);
181
182extern struct file *proc_ns_fget(int fd); 176extern struct file *proc_ns_fget(int fd);
183 177
184#else 178#else
@@ -230,19 +224,6 @@ static inline void pid_ns_release_proc(struct pid_namespace *ns)
230{ 224{
231} 225}
232 226
233static inline void set_mm_exe_file(struct mm_struct *mm,
234 struct file *new_exe_file)
235{}
236
237static inline struct file *get_mm_exe_file(struct mm_struct *mm)
238{
239 return NULL;
240}
241
242static inline void dup_mm_exe_file(struct mm_struct *oldmm,
243 struct mm_struct *newmm)
244{}
245
246static inline struct file *proc_ns_fget(int fd) 227static inline struct file *proc_ns_fget(int fd)
247{ 228{
248 return ERR_PTR(-EINVAL); 229 return ERR_PTR(-EINVAL);
diff --git a/include/linux/ratelimit.h b/include/linux/ratelimit.h
index 03ff67b0cdf5..2f007157fab9 100644
--- a/include/linux/ratelimit.h
+++ b/include/linux/ratelimit.h
@@ -41,4 +41,44 @@ extern struct ratelimit_state printk_ratelimit_state;
41extern int ___ratelimit(struct ratelimit_state *rs, const char *func); 41extern int ___ratelimit(struct ratelimit_state *rs, const char *func);
42#define __ratelimit(state) ___ratelimit(state, __func__) 42#define __ratelimit(state) ___ratelimit(state, __func__)
43 43
44#ifdef CONFIG_PRINTK
45
46#define WARN_ON_RATELIMIT(condition, state) \
47 WARN_ON((condition) && __ratelimit(state))
48
49#define __WARN_RATELIMIT(condition, state, format...) \
50({ \
51 int rtn = 0; \
52 if (unlikely(__ratelimit(state))) \
53 rtn = WARN(condition, format); \
54 rtn; \
55})
56
57#define WARN_RATELIMIT(condition, format...) \
58({ \
59 static DEFINE_RATELIMIT_STATE(_rs, \
60 DEFAULT_RATELIMIT_INTERVAL, \
61 DEFAULT_RATELIMIT_BURST); \
62 __WARN_RATELIMIT(condition, &_rs, format); \
63})
64
65#else
66
67#define WARN_ON_RATELIMIT(condition, state) \
68 WARN_ON(condition)
69
70#define __WARN_RATELIMIT(condition, state, format...) \
71({ \
72 int rtn = WARN(condition, format); \
73 rtn; \
74})
75
76#define WARN_RATELIMIT(condition, format...) \
77({ \
78 int rtn = WARN(condition, format); \
79 rtn; \
80})
81
82#endif
83
44#endif /* _LINUX_RATELIMIT_H */ 84#endif /* _LINUX_RATELIMIT_H */
diff --git a/include/linux/regulator/machine.h b/include/linux/regulator/machine.h
index c4c4fc45f856..ce3127a75c88 100644
--- a/include/linux/regulator/machine.h
+++ b/include/linux/regulator/machine.h
@@ -68,6 +68,8 @@ struct regulator_state {
68 * 68 *
69 * @min_uV: Smallest voltage consumers may set. 69 * @min_uV: Smallest voltage consumers may set.
70 * @max_uV: Largest voltage consumers may set. 70 * @max_uV: Largest voltage consumers may set.
71 * @uV_offset: Offset applied to voltages from consumer to compensate for
72 * voltage drops.
71 * 73 *
72 * @min_uA: Smallest consumers consumers may set. 74 * @min_uA: Smallest consumers consumers may set.
73 * @max_uA: Largest current consumers may set. 75 * @max_uA: Largest current consumers may set.
@@ -99,6 +101,8 @@ struct regulation_constraints {
99 int min_uV; 101 int min_uV;
100 int max_uV; 102 int max_uV;
101 103
104 int uV_offset;
105
102 /* current output range (inclusive) - for current control */ 106 /* current output range (inclusive) - for current control */
103 int min_uA; 107 int min_uA;
104 int max_uA; 108 int max_uA;
@@ -160,8 +164,6 @@ struct regulator_consumer_supply {
160 * @supply_regulator: Parent regulator. Specified using the regulator name 164 * @supply_regulator: Parent regulator. Specified using the regulator name
161 * as it appears in the name field in sysfs, which can 165 * as it appears in the name field in sysfs, which can
162 * be explicitly set using the constraints field 'name'. 166 * be explicitly set using the constraints field 'name'.
163 * @supply_regulator_dev: Parent regulator (if any) - DEPRECATED in favour
164 * of supply_regulator.
165 * 167 *
166 * @constraints: Constraints. These must be specified for the regulator to 168 * @constraints: Constraints. These must be specified for the regulator to
167 * be usable. 169 * be usable.
@@ -173,7 +175,6 @@ struct regulator_consumer_supply {
173 */ 175 */
174struct regulator_init_data { 176struct regulator_init_data {
175 const char *supply_regulator; /* or NULL for system supply */ 177 const char *supply_regulator; /* or NULL for system supply */
176 struct device *supply_regulator_dev; /* or NULL for system supply */
177 178
178 struct regulation_constraints constraints; 179 struct regulation_constraints constraints;
179 180
diff --git a/include/linux/rtc.h b/include/linux/rtc.h
index 877ece45426f..b27ebea25660 100644
--- a/include/linux/rtc.h
+++ b/include/linux/rtc.h
@@ -92,10 +92,10 @@ struct rtc_pll_info {
92#define RTC_PLL_SET _IOW('p', 0x12, struct rtc_pll_info) /* Set PLL correction */ 92#define RTC_PLL_SET _IOW('p', 0x12, struct rtc_pll_info) /* Set PLL correction */
93 93
94/* interrupt flags */ 94/* interrupt flags */
95#define RTC_IRQF 0x80 /* any of the following is active */ 95#define RTC_IRQF 0x80 /* Any of the following is active */
96#define RTC_PF 0x40 96#define RTC_PF 0x40 /* Periodic interrupt */
97#define RTC_AF 0x20 97#define RTC_AF 0x20 /* Alarm interrupt */
98#define RTC_UF 0x10 98#define RTC_UF 0x10 /* Update interrupt for 1Hz RTC */
99 99
100#ifdef __KERNEL__ 100#ifdef __KERNEL__
101 101
diff --git a/include/linux/sched.h b/include/linux/sched.h
index f18300eddfcb..dc8871295a5a 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -513,6 +513,7 @@ struct thread_group_cputimer {
513 spinlock_t lock; 513 spinlock_t lock;
514}; 514};
515 515
516#include <linux/rwsem.h>
516struct autogroup; 517struct autogroup;
517 518
518/* 519/*
@@ -632,6 +633,16 @@ struct signal_struct {
632 unsigned audit_tty; 633 unsigned audit_tty;
633 struct tty_audit_buf *tty_audit_buf; 634 struct tty_audit_buf *tty_audit_buf;
634#endif 635#endif
636#ifdef CONFIG_CGROUPS
637 /*
638 * The threadgroup_fork_lock prevents threads from forking with
639 * CLONE_THREAD while held for writing. Use this for fork-sensitive
640 * threadgroup-wide operations. It's taken for reading in fork.c in
641 * copy_process().
642 * Currently only needed write-side by cgroups.
643 */
644 struct rw_semaphore threadgroup_fork_lock;
645#endif
635 646
636 int oom_adj; /* OOM kill score adjustment (bit shift) */ 647 int oom_adj; /* OOM kill score adjustment (bit shift) */
637 int oom_score_adj; /* OOM kill score adjustment */ 648 int oom_score_adj; /* OOM kill score adjustment */
@@ -2323,6 +2334,31 @@ static inline void unlock_task_sighand(struct task_struct *tsk,
2323 spin_unlock_irqrestore(&tsk->sighand->siglock, *flags); 2334 spin_unlock_irqrestore(&tsk->sighand->siglock, *flags);
2324} 2335}
2325 2336
2337/* See the declaration of threadgroup_fork_lock in signal_struct. */
2338#ifdef CONFIG_CGROUPS
2339static inline void threadgroup_fork_read_lock(struct task_struct *tsk)
2340{
2341 down_read(&tsk->signal->threadgroup_fork_lock);
2342}
2343static inline void threadgroup_fork_read_unlock(struct task_struct *tsk)
2344{
2345 up_read(&tsk->signal->threadgroup_fork_lock);
2346}
2347static inline void threadgroup_fork_write_lock(struct task_struct *tsk)
2348{
2349 down_write(&tsk->signal->threadgroup_fork_lock);
2350}
2351static inline void threadgroup_fork_write_unlock(struct task_struct *tsk)
2352{
2353 up_write(&tsk->signal->threadgroup_fork_lock);
2354}
2355#else
2356static inline void threadgroup_fork_read_lock(struct task_struct *tsk) {}
2357static inline void threadgroup_fork_read_unlock(struct task_struct *tsk) {}
2358static inline void threadgroup_fork_write_lock(struct task_struct *tsk) {}
2359static inline void threadgroup_fork_write_unlock(struct task_struct *tsk) {}
2360#endif
2361
2326#ifndef __HAVE_THREAD_FUNCTIONS 2362#ifndef __HAVE_THREAD_FUNCTIONS
2327 2363
2328#define task_thread_info(task) ((struct thread_info *)(task)->stack) 2364#define task_thread_info(task) ((struct thread_info *)(task)->stack)
diff --git a/include/linux/swap.h b/include/linux/swap.h
index a5c6da5d8df8..384eb5fe530b 100644
--- a/include/linux/swap.h
+++ b/include/linux/swap.h
@@ -257,7 +257,8 @@ extern unsigned long try_to_free_mem_cgroup_pages(struct mem_cgroup *mem,
257extern unsigned long mem_cgroup_shrink_node_zone(struct mem_cgroup *mem, 257extern unsigned long mem_cgroup_shrink_node_zone(struct mem_cgroup *mem,
258 gfp_t gfp_mask, bool noswap, 258 gfp_t gfp_mask, bool noswap,
259 unsigned int swappiness, 259 unsigned int swappiness,
260 struct zone *zone); 260 struct zone *zone,
261 unsigned long *nr_scanned);
261extern int __isolate_lru_page(struct page *page, int mode, int file); 262extern int __isolate_lru_page(struct page *page, int mode, int file);
262extern unsigned long shrink_all_memory(unsigned long nr_pages); 263extern unsigned long shrink_all_memory(unsigned long nr_pages);
263extern int vm_swappiness; 264extern int vm_swappiness;
diff --git a/include/linux/vm_event_item.h b/include/linux/vm_event_item.h
new file mode 100644
index 000000000000..03b90cdc1921
--- /dev/null
+++ b/include/linux/vm_event_item.h
@@ -0,0 +1,64 @@
1#ifndef VM_EVENT_ITEM_H_INCLUDED
2#define VM_EVENT_ITEM_H_INCLUDED
3
4#ifdef CONFIG_ZONE_DMA
5#define DMA_ZONE(xx) xx##_DMA,
6#else
7#define DMA_ZONE(xx)
8#endif
9
10#ifdef CONFIG_ZONE_DMA32
11#define DMA32_ZONE(xx) xx##_DMA32,
12#else
13#define DMA32_ZONE(xx)
14#endif
15
16#ifdef CONFIG_HIGHMEM
17#define HIGHMEM_ZONE(xx) , xx##_HIGH
18#else
19#define HIGHMEM_ZONE(xx)
20#endif
21
22#define FOR_ALL_ZONES(xx) DMA_ZONE(xx) DMA32_ZONE(xx) xx##_NORMAL HIGHMEM_ZONE(xx) , xx##_MOVABLE
23
24enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT,
25 FOR_ALL_ZONES(PGALLOC),
26 PGFREE, PGACTIVATE, PGDEACTIVATE,
27 PGFAULT, PGMAJFAULT,
28 FOR_ALL_ZONES(PGREFILL),
29 FOR_ALL_ZONES(PGSTEAL),
30 FOR_ALL_ZONES(PGSCAN_KSWAPD),
31 FOR_ALL_ZONES(PGSCAN_DIRECT),
32#ifdef CONFIG_NUMA
33 PGSCAN_ZONE_RECLAIM_FAILED,
34#endif
35 PGINODESTEAL, SLABS_SCANNED, KSWAPD_STEAL, KSWAPD_INODESTEAL,
36 KSWAPD_LOW_WMARK_HIT_QUICKLY, KSWAPD_HIGH_WMARK_HIT_QUICKLY,
37 KSWAPD_SKIP_CONGESTION_WAIT,
38 PAGEOUTRUN, ALLOCSTALL, PGROTATED,
39#ifdef CONFIG_COMPACTION
40 COMPACTBLOCKS, COMPACTPAGES, COMPACTPAGEFAILED,
41 COMPACTSTALL, COMPACTFAIL, COMPACTSUCCESS,
42#endif
43#ifdef CONFIG_HUGETLB_PAGE
44 HTLB_BUDDY_PGALLOC, HTLB_BUDDY_PGALLOC_FAIL,
45#endif
46 UNEVICTABLE_PGCULLED, /* culled to noreclaim list */
47 UNEVICTABLE_PGSCANNED, /* scanned for reclaimability */
48 UNEVICTABLE_PGRESCUED, /* rescued from noreclaim list */
49 UNEVICTABLE_PGMLOCKED,
50 UNEVICTABLE_PGMUNLOCKED,
51 UNEVICTABLE_PGCLEARED, /* on COW, page truncate */
52 UNEVICTABLE_PGSTRANDED, /* unable to isolate on unlock */
53 UNEVICTABLE_MLOCKFREED,
54#ifdef CONFIG_TRANSPARENT_HUGEPAGE
55 THP_FAULT_ALLOC,
56 THP_FAULT_FALLBACK,
57 THP_COLLAPSE_ALLOC,
58 THP_COLLAPSE_ALLOC_FAILED,
59 THP_SPLIT,
60#endif
61 NR_VM_EVENT_ITEMS
62};
63
64#endif /* VM_EVENT_ITEM_H_INCLUDED */
diff --git a/include/linux/vmstat.h b/include/linux/vmstat.h
index 51359837511a..bcd942fa611c 100644
--- a/include/linux/vmstat.h
+++ b/include/linux/vmstat.h
@@ -5,69 +5,9 @@
5#include <linux/percpu.h> 5#include <linux/percpu.h>
6#include <linux/mm.h> 6#include <linux/mm.h>
7#include <linux/mmzone.h> 7#include <linux/mmzone.h>
8#include <linux/vm_event_item.h>
8#include <asm/atomic.h> 9#include <asm/atomic.h>
9 10
10#ifdef CONFIG_ZONE_DMA
11#define DMA_ZONE(xx) xx##_DMA,
12#else
13#define DMA_ZONE(xx)
14#endif
15
16#ifdef CONFIG_ZONE_DMA32
17#define DMA32_ZONE(xx) xx##_DMA32,
18#else
19#define DMA32_ZONE(xx)
20#endif
21
22#ifdef CONFIG_HIGHMEM
23#define HIGHMEM_ZONE(xx) , xx##_HIGH
24#else
25#define HIGHMEM_ZONE(xx)
26#endif
27
28
29#define FOR_ALL_ZONES(xx) DMA_ZONE(xx) DMA32_ZONE(xx) xx##_NORMAL HIGHMEM_ZONE(xx) , xx##_MOVABLE
30
31enum vm_event_item { PGPGIN, PGPGOUT, PSWPIN, PSWPOUT,
32 FOR_ALL_ZONES(PGALLOC),
33 PGFREE, PGACTIVATE, PGDEACTIVATE,
34 PGFAULT, PGMAJFAULT,
35 FOR_ALL_ZONES(PGREFILL),
36 FOR_ALL_ZONES(PGSTEAL),
37 FOR_ALL_ZONES(PGSCAN_KSWAPD),
38 FOR_ALL_ZONES(PGSCAN_DIRECT),
39#ifdef CONFIG_NUMA
40 PGSCAN_ZONE_RECLAIM_FAILED,
41#endif
42 PGINODESTEAL, SLABS_SCANNED, KSWAPD_STEAL, KSWAPD_INODESTEAL,
43 KSWAPD_LOW_WMARK_HIT_QUICKLY, KSWAPD_HIGH_WMARK_HIT_QUICKLY,
44 KSWAPD_SKIP_CONGESTION_WAIT,
45 PAGEOUTRUN, ALLOCSTALL, PGROTATED,
46#ifdef CONFIG_COMPACTION
47 COMPACTBLOCKS, COMPACTPAGES, COMPACTPAGEFAILED,
48 COMPACTSTALL, COMPACTFAIL, COMPACTSUCCESS,
49#endif
50#ifdef CONFIG_HUGETLB_PAGE
51 HTLB_BUDDY_PGALLOC, HTLB_BUDDY_PGALLOC_FAIL,
52#endif
53 UNEVICTABLE_PGCULLED, /* culled to noreclaim list */
54 UNEVICTABLE_PGSCANNED, /* scanned for reclaimability */
55 UNEVICTABLE_PGRESCUED, /* rescued from noreclaim list */
56 UNEVICTABLE_PGMLOCKED,
57 UNEVICTABLE_PGMUNLOCKED,
58 UNEVICTABLE_PGCLEARED, /* on COW, page truncate */
59 UNEVICTABLE_PGSTRANDED, /* unable to isolate on unlock */
60 UNEVICTABLE_MLOCKFREED,
61#ifdef CONFIG_TRANSPARENT_HUGEPAGE
62 THP_FAULT_ALLOC,
63 THP_FAULT_FALLBACK,
64 THP_COLLAPSE_ALLOC,
65 THP_COLLAPSE_ALLOC_FAILED,
66 THP_SPLIT,
67#endif
68 NR_VM_EVENT_ITEMS
69};
70
71extern int sysctl_stat_interval; 11extern int sysctl_stat_interval;
72 12
73#ifdef CONFIG_VM_EVENT_COUNTERS 13#ifdef CONFIG_VM_EVENT_COUNTERS