diff options
author | Tejun Heo <tj@kernel.org> | 2011-05-24 03:59:36 -0400 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2011-05-24 03:59:36 -0400 |
commit | 6988f20fe04e9ef3aea488cb8ab57fbeb78e12f0 (patch) | |
tree | c9d7fc50a2e2147a5ca07e3096e7eeb916ad2da9 /include/linux | |
parent | 0415b00d175e0d8945e6785aad21b5f157976ce0 (diff) | |
parent | 6ea0c34dac89611126455537552cffe6c7e832ad (diff) |
Merge branch 'fixes-2.6.39' into for-2.6.40
Diffstat (limited to 'include/linux')
49 files changed, 702 insertions, 67 deletions
diff --git a/include/linux/bch.h b/include/linux/bch.h new file mode 100644 index 000000000000..295b4ef153bb --- /dev/null +++ b/include/linux/bch.h | |||
@@ -0,0 +1,79 @@ | |||
1 | /* | ||
2 | * Generic binary BCH encoding/decoding library | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify it | ||
5 | * under the terms of the GNU General Public License version 2 as published by | ||
6 | * the Free Software Foundation. | ||
7 | * | ||
8 | * This program is distributed in the hope that it will be useful, but WITHOUT | ||
9 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
10 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
11 | * more details. | ||
12 | * | ||
13 | * You should have received a copy of the GNU General Public License along with | ||
14 | * this program; if not, write to the Free Software Foundation, Inc., 51 | ||
15 | * Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. | ||
16 | * | ||
17 | * Copyright © 2011 Parrot S.A. | ||
18 | * | ||
19 | * Author: Ivan Djelic <ivan.djelic@parrot.com> | ||
20 | * | ||
21 | * Description: | ||
22 | * | ||
23 | * This library provides runtime configurable encoding/decoding of binary | ||
24 | * Bose-Chaudhuri-Hocquenghem (BCH) codes. | ||
25 | */ | ||
26 | #ifndef _BCH_H | ||
27 | #define _BCH_H | ||
28 | |||
29 | #include <linux/types.h> | ||
30 | |||
31 | /** | ||
32 | * struct bch_control - BCH control structure | ||
33 | * @m: Galois field order | ||
34 | * @n: maximum codeword size in bits (= 2^m-1) | ||
35 | * @t: error correction capability in bits | ||
36 | * @ecc_bits: ecc exact size in bits, i.e. generator polynomial degree (<=m*t) | ||
37 | * @ecc_bytes: ecc max size (m*t bits) in bytes | ||
38 | * @a_pow_tab: Galois field GF(2^m) exponentiation lookup table | ||
39 | * @a_log_tab: Galois field GF(2^m) log lookup table | ||
40 | * @mod8_tab: remainder generator polynomial lookup tables | ||
41 | * @ecc_buf: ecc parity words buffer | ||
42 | * @ecc_buf2: ecc parity words buffer | ||
43 | * @xi_tab: GF(2^m) base for solving degree 2 polynomial roots | ||
44 | * @syn: syndrome buffer | ||
45 | * @cache: log-based polynomial representation buffer | ||
46 | * @elp: error locator polynomial | ||
47 | * @poly_2t: temporary polynomials of degree 2t | ||
48 | */ | ||
49 | struct bch_control { | ||
50 | unsigned int m; | ||
51 | unsigned int n; | ||
52 | unsigned int t; | ||
53 | unsigned int ecc_bits; | ||
54 | unsigned int ecc_bytes; | ||
55 | /* private: */ | ||
56 | uint16_t *a_pow_tab; | ||
57 | uint16_t *a_log_tab; | ||
58 | uint32_t *mod8_tab; | ||
59 | uint32_t *ecc_buf; | ||
60 | uint32_t *ecc_buf2; | ||
61 | unsigned int *xi_tab; | ||
62 | unsigned int *syn; | ||
63 | int *cache; | ||
64 | struct gf_poly *elp; | ||
65 | struct gf_poly *poly_2t[4]; | ||
66 | }; | ||
67 | |||
68 | struct bch_control *init_bch(int m, int t, unsigned int prim_poly); | ||
69 | |||
70 | void free_bch(struct bch_control *bch); | ||
71 | |||
72 | void encode_bch(struct bch_control *bch, const uint8_t *data, | ||
73 | unsigned int len, uint8_t *ecc); | ||
74 | |||
75 | int decode_bch(struct bch_control *bch, const uint8_t *data, unsigned int len, | ||
76 | const uint8_t *recv_ecc, const uint8_t *calc_ecc, | ||
77 | const unsigned int *syn, unsigned int *errloc); | ||
78 | |||
79 | #endif /* _BCH_H */ | ||
diff --git a/include/linux/davinci_emac.h b/include/linux/davinci_emac.h index 5dd428532f79..542888504994 100644 --- a/include/linux/davinci_emac.h +++ b/include/linux/davinci_emac.h | |||
@@ -36,6 +36,7 @@ struct emac_platform_data { | |||
36 | 36 | ||
37 | u8 rmii_en; | 37 | u8 rmii_en; |
38 | u8 version; | 38 | u8 version; |
39 | bool no_bd_ram; | ||
39 | void (*interrupt_enable) (void); | 40 | void (*interrupt_enable) (void); |
40 | void (*interrupt_disable) (void); | 41 | void (*interrupt_disable) (void); |
41 | }; | 42 | }; |
diff --git a/include/linux/device.h b/include/linux/device.h index 144ec135875f..ab8dfc095709 100644 --- a/include/linux/device.h +++ b/include/linux/device.h | |||
@@ -633,8 +633,12 @@ static inline int devtmpfs_mount(const char *mountpoint) { return 0; } | |||
633 | /* drivers/base/power/shutdown.c */ | 633 | /* drivers/base/power/shutdown.c */ |
634 | extern void device_shutdown(void); | 634 | extern void device_shutdown(void); |
635 | 635 | ||
636 | #ifndef CONFIG_ARCH_NO_SYSDEV_OPS | ||
636 | /* drivers/base/sys.c */ | 637 | /* drivers/base/sys.c */ |
637 | extern void sysdev_shutdown(void); | 638 | extern void sysdev_shutdown(void); |
639 | #else | ||
640 | static inline void sysdev_shutdown(void) { } | ||
641 | #endif | ||
638 | 642 | ||
639 | /* debugging and troubleshooting/diagnostic helpers. */ | 643 | /* debugging and troubleshooting/diagnostic helpers. */ |
640 | extern const char *dev_driver_string(const struct device *dev); | 644 | extern const char *dev_driver_string(const struct device *dev); |
diff --git a/include/linux/dm-ioctl.h b/include/linux/dm-ioctl.h index 78bbf47bbb96..3708455ee6c3 100644 --- a/include/linux/dm-ioctl.h +++ b/include/linux/dm-ioctl.h | |||
@@ -267,9 +267,9 @@ enum { | |||
267 | #define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl) | 267 | #define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl) |
268 | 268 | ||
269 | #define DM_VERSION_MAJOR 4 | 269 | #define DM_VERSION_MAJOR 4 |
270 | #define DM_VERSION_MINOR 19 | 270 | #define DM_VERSION_MINOR 20 |
271 | #define DM_VERSION_PATCHLEVEL 1 | 271 | #define DM_VERSION_PATCHLEVEL 0 |
272 | #define DM_VERSION_EXTRA "-ioctl (2011-01-07)" | 272 | #define DM_VERSION_EXTRA "-ioctl (2011-02-02)" |
273 | 273 | ||
274 | /* Status bits */ | 274 | /* Status bits */ |
275 | #define DM_READONLY_FLAG (1 << 0) /* In/Out */ | 275 | #define DM_READONLY_FLAG (1 << 0) /* In/Out */ |
@@ -328,4 +328,10 @@ enum { | |||
328 | */ | 328 | */ |
329 | #define DM_UUID_FLAG (1 << 14) /* In */ | 329 | #define DM_UUID_FLAG (1 << 14) /* In */ |
330 | 330 | ||
331 | /* | ||
332 | * If set, all buffers are wiped after use. Use when sending | ||
333 | * or requesting sensitive data such as an encryption key. | ||
334 | */ | ||
335 | #define DM_SECURE_DATA_FLAG (1 << 15) /* In */ | ||
336 | |||
331 | #endif /* _LINUX_DM_IOCTL_H */ | 337 | #endif /* _LINUX_DM_IOCTL_H */ |
diff --git a/include/linux/drbd.h b/include/linux/drbd.h index ef44c7a0638c..d18d673ebc78 100644 --- a/include/linux/drbd.h +++ b/include/linux/drbd.h | |||
@@ -53,10 +53,10 @@ | |||
53 | 53 | ||
54 | 54 | ||
55 | extern const char *drbd_buildtag(void); | 55 | extern const char *drbd_buildtag(void); |
56 | #define REL_VERSION "8.3.9" | 56 | #define REL_VERSION "8.3.10" |
57 | #define API_VERSION 88 | 57 | #define API_VERSION 88 |
58 | #define PRO_VERSION_MIN 86 | 58 | #define PRO_VERSION_MIN 86 |
59 | #define PRO_VERSION_MAX 95 | 59 | #define PRO_VERSION_MAX 96 |
60 | 60 | ||
61 | 61 | ||
62 | enum drbd_io_error_p { | 62 | enum drbd_io_error_p { |
@@ -96,8 +96,14 @@ enum drbd_on_no_data { | |||
96 | OND_SUSPEND_IO | 96 | OND_SUSPEND_IO |
97 | }; | 97 | }; |
98 | 98 | ||
99 | enum drbd_on_congestion { | ||
100 | OC_BLOCK, | ||
101 | OC_PULL_AHEAD, | ||
102 | OC_DISCONNECT, | ||
103 | }; | ||
104 | |||
99 | /* KEEP the order, do not delete or insert. Only append. */ | 105 | /* KEEP the order, do not delete or insert. Only append. */ |
100 | enum drbd_ret_codes { | 106 | enum drbd_ret_code { |
101 | ERR_CODE_BASE = 100, | 107 | ERR_CODE_BASE = 100, |
102 | NO_ERROR = 101, | 108 | NO_ERROR = 101, |
103 | ERR_LOCAL_ADDR = 102, | 109 | ERR_LOCAL_ADDR = 102, |
@@ -146,6 +152,9 @@ enum drbd_ret_codes { | |||
146 | ERR_PERM = 152, | 152 | ERR_PERM = 152, |
147 | ERR_NEED_APV_93 = 153, | 153 | ERR_NEED_APV_93 = 153, |
148 | ERR_STONITH_AND_PROT_A = 154, | 154 | ERR_STONITH_AND_PROT_A = 154, |
155 | ERR_CONG_NOT_PROTO_A = 155, | ||
156 | ERR_PIC_AFTER_DEP = 156, | ||
157 | ERR_PIC_PEER_DEP = 157, | ||
149 | 158 | ||
150 | /* insert new ones above this line */ | 159 | /* insert new ones above this line */ |
151 | AFTER_LAST_ERR_CODE | 160 | AFTER_LAST_ERR_CODE |
@@ -199,6 +208,10 @@ enum drbd_conns { | |||
199 | C_VERIFY_T, | 208 | C_VERIFY_T, |
200 | C_PAUSED_SYNC_S, | 209 | C_PAUSED_SYNC_S, |
201 | C_PAUSED_SYNC_T, | 210 | C_PAUSED_SYNC_T, |
211 | |||
212 | C_AHEAD, | ||
213 | C_BEHIND, | ||
214 | |||
202 | C_MASK = 31 | 215 | C_MASK = 31 |
203 | }; | 216 | }; |
204 | 217 | ||
@@ -259,7 +272,7 @@ union drbd_state { | |||
259 | unsigned int i; | 272 | unsigned int i; |
260 | }; | 273 | }; |
261 | 274 | ||
262 | enum drbd_state_ret_codes { | 275 | enum drbd_state_rv { |
263 | SS_CW_NO_NEED = 4, | 276 | SS_CW_NO_NEED = 4, |
264 | SS_CW_SUCCESS = 3, | 277 | SS_CW_SUCCESS = 3, |
265 | SS_NOTHING_TO_DO = 2, | 278 | SS_NOTHING_TO_DO = 2, |
@@ -290,7 +303,7 @@ enum drbd_state_ret_codes { | |||
290 | extern const char *drbd_conn_str(enum drbd_conns); | 303 | extern const char *drbd_conn_str(enum drbd_conns); |
291 | extern const char *drbd_role_str(enum drbd_role); | 304 | extern const char *drbd_role_str(enum drbd_role); |
292 | extern const char *drbd_disk_str(enum drbd_disk_state); | 305 | extern const char *drbd_disk_str(enum drbd_disk_state); |
293 | extern const char *drbd_set_st_err_str(enum drbd_state_ret_codes); | 306 | extern const char *drbd_set_st_err_str(enum drbd_state_rv); |
294 | 307 | ||
295 | #define SHARED_SECRET_MAX 64 | 308 | #define SHARED_SECRET_MAX 64 |
296 | 309 | ||
diff --git a/include/linux/drbd_limits.h b/include/linux/drbd_limits.h index 4ac33f34b77e..bb264a5732de 100644 --- a/include/linux/drbd_limits.h +++ b/include/linux/drbd_limits.h | |||
@@ -16,7 +16,8 @@ | |||
16 | #define DEBUG_RANGE_CHECK 0 | 16 | #define DEBUG_RANGE_CHECK 0 |
17 | 17 | ||
18 | #define DRBD_MINOR_COUNT_MIN 1 | 18 | #define DRBD_MINOR_COUNT_MIN 1 |
19 | #define DRBD_MINOR_COUNT_MAX 255 | 19 | #define DRBD_MINOR_COUNT_MAX 256 |
20 | #define DRBD_MINOR_COUNT_DEF 32 | ||
20 | 21 | ||
21 | #define DRBD_DIALOG_REFRESH_MIN 0 | 22 | #define DRBD_DIALOG_REFRESH_MIN 0 |
22 | #define DRBD_DIALOG_REFRESH_MAX 600 | 23 | #define DRBD_DIALOG_REFRESH_MAX 600 |
@@ -129,6 +130,7 @@ | |||
129 | #define DRBD_AFTER_SB_2P_DEF ASB_DISCONNECT | 130 | #define DRBD_AFTER_SB_2P_DEF ASB_DISCONNECT |
130 | #define DRBD_RR_CONFLICT_DEF ASB_DISCONNECT | 131 | #define DRBD_RR_CONFLICT_DEF ASB_DISCONNECT |
131 | #define DRBD_ON_NO_DATA_DEF OND_IO_ERROR | 132 | #define DRBD_ON_NO_DATA_DEF OND_IO_ERROR |
133 | #define DRBD_ON_CONGESTION_DEF OC_BLOCK | ||
132 | 134 | ||
133 | #define DRBD_MAX_BIO_BVECS_MIN 0 | 135 | #define DRBD_MAX_BIO_BVECS_MIN 0 |
134 | #define DRBD_MAX_BIO_BVECS_MAX 128 | 136 | #define DRBD_MAX_BIO_BVECS_MAX 128 |
@@ -154,5 +156,13 @@ | |||
154 | #define DRBD_C_MIN_RATE_MAX (4 << 20) | 156 | #define DRBD_C_MIN_RATE_MAX (4 << 20) |
155 | #define DRBD_C_MIN_RATE_DEF 4096 | 157 | #define DRBD_C_MIN_RATE_DEF 4096 |
156 | 158 | ||
159 | #define DRBD_CONG_FILL_MIN 0 | ||
160 | #define DRBD_CONG_FILL_MAX (10<<21) /* 10GByte in sectors */ | ||
161 | #define DRBD_CONG_FILL_DEF 0 | ||
162 | |||
163 | #define DRBD_CONG_EXTENTS_MIN DRBD_AL_EXTENTS_MIN | ||
164 | #define DRBD_CONG_EXTENTS_MAX DRBD_AL_EXTENTS_MAX | ||
165 | #define DRBD_CONG_EXTENTS_DEF DRBD_AL_EXTENTS_DEF | ||
166 | |||
157 | #undef RANGE | 167 | #undef RANGE |
158 | #endif | 168 | #endif |
diff --git a/include/linux/drbd_nl.h b/include/linux/drbd_nl.h index ade91107c9a5..ab6159e4fcf0 100644 --- a/include/linux/drbd_nl.h +++ b/include/linux/drbd_nl.h | |||
@@ -56,6 +56,9 @@ NL_PACKET(net_conf, 5, | |||
56 | NL_INTEGER( 39, T_MAY_IGNORE, rr_conflict) | 56 | NL_INTEGER( 39, T_MAY_IGNORE, rr_conflict) |
57 | NL_INTEGER( 40, T_MAY_IGNORE, ping_timeo) | 57 | NL_INTEGER( 40, T_MAY_IGNORE, ping_timeo) |
58 | NL_INTEGER( 67, T_MAY_IGNORE, rcvbuf_size) | 58 | NL_INTEGER( 67, T_MAY_IGNORE, rcvbuf_size) |
59 | NL_INTEGER( 81, T_MAY_IGNORE, on_congestion) | ||
60 | NL_INTEGER( 82, T_MAY_IGNORE, cong_fill) | ||
61 | NL_INTEGER( 83, T_MAY_IGNORE, cong_extents) | ||
59 | /* 59 addr_family was available in GIT, never released */ | 62 | /* 59 addr_family was available in GIT, never released */ |
60 | NL_BIT( 60, T_MANDATORY, mind_af) | 63 | NL_BIT( 60, T_MANDATORY, mind_af) |
61 | NL_BIT( 27, T_MAY_IGNORE, want_lose) | 64 | NL_BIT( 27, T_MAY_IGNORE, want_lose) |
@@ -66,7 +69,9 @@ NL_PACKET(net_conf, 5, | |||
66 | NL_BIT( 70, T_MANDATORY, dry_run) | 69 | NL_BIT( 70, T_MANDATORY, dry_run) |
67 | ) | 70 | ) |
68 | 71 | ||
69 | NL_PACKET(disconnect, 6, ) | 72 | NL_PACKET(disconnect, 6, |
73 | NL_BIT( 84, T_MAY_IGNORE, force) | ||
74 | ) | ||
70 | 75 | ||
71 | NL_PACKET(resize, 7, | 76 | NL_PACKET(resize, 7, |
72 | NL_INT64( 29, T_MAY_IGNORE, resize_size) | 77 | NL_INT64( 29, T_MAY_IGNORE, resize_size) |
@@ -143,9 +148,13 @@ NL_PACKET(new_c_uuid, 26, | |||
143 | NL_BIT( 63, T_MANDATORY, clear_bm) | 148 | NL_BIT( 63, T_MANDATORY, clear_bm) |
144 | ) | 149 | ) |
145 | 150 | ||
151 | #ifdef NL_RESPONSE | ||
152 | NL_RESPONSE(return_code_only, 27) | ||
153 | #endif | ||
154 | |||
146 | #undef NL_PACKET | 155 | #undef NL_PACKET |
147 | #undef NL_INTEGER | 156 | #undef NL_INTEGER |
148 | #undef NL_INT64 | 157 | #undef NL_INT64 |
149 | #undef NL_BIT | 158 | #undef NL_BIT |
150 | #undef NL_STRING | 159 | #undef NL_STRING |
151 | 160 | #undef NL_RESPONSE | |
diff --git a/include/linux/drbd_tag_magic.h b/include/linux/drbd_tag_magic.h index fcdff8410e99..f14a165e82dc 100644 --- a/include/linux/drbd_tag_magic.h +++ b/include/linux/drbd_tag_magic.h | |||
@@ -7,6 +7,7 @@ | |||
7 | /* declare packet_type enums */ | 7 | /* declare packet_type enums */ |
8 | enum packet_types { | 8 | enum packet_types { |
9 | #define NL_PACKET(name, number, fields) P_ ## name = number, | 9 | #define NL_PACKET(name, number, fields) P_ ## name = number, |
10 | #define NL_RESPONSE(name, number) P_ ## name = number, | ||
10 | #define NL_INTEGER(pn, pr, member) | 11 | #define NL_INTEGER(pn, pr, member) |
11 | #define NL_INT64(pn, pr, member) | 12 | #define NL_INT64(pn, pr, member) |
12 | #define NL_BIT(pn, pr, member) | 13 | #define NL_BIT(pn, pr, member) |
diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h index b297f288f6eb..ae757bcf1280 100644 --- a/include/linux/ethtool.h +++ b/include/linux/ethtool.h | |||
@@ -648,6 +648,9 @@ enum ethtool_sfeatures_retval_bits { | |||
648 | 648 | ||
649 | #include <linux/rculist.h> | 649 | #include <linux/rculist.h> |
650 | 650 | ||
651 | /* needed by dev_disable_lro() */ | ||
652 | extern int __ethtool_set_flags(struct net_device *dev, u32 flags); | ||
653 | |||
651 | struct ethtool_rx_ntuple_flow_spec_container { | 654 | struct ethtool_rx_ntuple_flow_spec_container { |
652 | struct ethtool_rx_ntuple_flow_spec fs; | 655 | struct ethtool_rx_ntuple_flow_spec fs; |
653 | struct list_head list; | 656 | struct list_head list; |
diff --git a/include/linux/fs.h b/include/linux/fs.h index ce7e18555197..b677bd77f2d6 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -1636,7 +1636,7 @@ struct super_operations { | |||
1636 | }; | 1636 | }; |
1637 | 1637 | ||
1638 | /* | 1638 | /* |
1639 | * Inode state bits. Protected by inode_lock. | 1639 | * Inode state bits. Protected by inode->i_lock |
1640 | * | 1640 | * |
1641 | * Three bits determine the dirty state of the inode, I_DIRTY_SYNC, | 1641 | * Three bits determine the dirty state of the inode, I_DIRTY_SYNC, |
1642 | * I_DIRTY_DATASYNC and I_DIRTY_PAGES. | 1642 | * I_DIRTY_DATASYNC and I_DIRTY_PAGES. |
diff --git a/include/linux/irq.h b/include/linux/irq.h index 1d3577f30d45..5d876c9b3a3d 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -28,6 +28,7 @@ | |||
28 | #include <asm/ptrace.h> | 28 | #include <asm/ptrace.h> |
29 | #include <asm/irq_regs.h> | 29 | #include <asm/irq_regs.h> |
30 | 30 | ||
31 | struct seq_file; | ||
31 | struct irq_desc; | 32 | struct irq_desc; |
32 | struct irq_data; | 33 | struct irq_data; |
33 | typedef void (*irq_flow_handler_t)(unsigned int irq, | 34 | typedef void (*irq_flow_handler_t)(unsigned int irq, |
@@ -270,6 +271,7 @@ static inline bool irqd_can_move_in_process_context(struct irq_data *d) | |||
270 | * @irq_set_wake: enable/disable power-management wake-on of an IRQ | 271 | * @irq_set_wake: enable/disable power-management wake-on of an IRQ |
271 | * @irq_bus_lock: function to lock access to slow bus (i2c) chips | 272 | * @irq_bus_lock: function to lock access to slow bus (i2c) chips |
272 | * @irq_bus_sync_unlock:function to sync and unlock slow bus (i2c) chips | 273 | * @irq_bus_sync_unlock:function to sync and unlock slow bus (i2c) chips |
274 | * @irq_print_chip: optional to print special chip info in show_interrupts | ||
273 | * @flags: chip specific flags | 275 | * @flags: chip specific flags |
274 | * | 276 | * |
275 | * @release: release function solely used by UML | 277 | * @release: release function solely used by UML |
@@ -317,6 +319,8 @@ struct irq_chip { | |||
317 | void (*irq_bus_lock)(struct irq_data *data); | 319 | void (*irq_bus_lock)(struct irq_data *data); |
318 | void (*irq_bus_sync_unlock)(struct irq_data *data); | 320 | void (*irq_bus_sync_unlock)(struct irq_data *data); |
319 | 321 | ||
322 | void (*irq_print_chip)(struct irq_data *data, struct seq_file *p); | ||
323 | |||
320 | unsigned long flags; | 324 | unsigned long flags; |
321 | 325 | ||
322 | /* Currently used only by UML, might disappear one day.*/ | 326 | /* Currently used only by UML, might disappear one day.*/ |
diff --git a/include/linux/irqdesc.h b/include/linux/irqdesc.h index 00218371518b..15e6c3905f41 100644 --- a/include/linux/irqdesc.h +++ b/include/linux/irqdesc.h | |||
@@ -100,13 +100,6 @@ struct irq_desc { | |||
100 | extern struct irq_desc irq_desc[NR_IRQS]; | 100 | extern struct irq_desc irq_desc[NR_IRQS]; |
101 | #endif | 101 | #endif |
102 | 102 | ||
103 | /* Will be removed once the last users in power and sh are gone */ | ||
104 | extern struct irq_desc *irq_to_desc_alloc_node(unsigned int irq, int node); | ||
105 | static inline struct irq_desc *move_irq_desc(struct irq_desc *desc, int node) | ||
106 | { | ||
107 | return desc; | ||
108 | } | ||
109 | |||
110 | #ifdef CONFIG_GENERIC_HARDIRQS | 103 | #ifdef CONFIG_GENERIC_HARDIRQS |
111 | 104 | ||
112 | static inline struct irq_data *irq_desc_get_irq_data(struct irq_desc *desc) | 105 | static inline struct irq_data *irq_desc_get_irq_data(struct irq_desc *desc) |
@@ -178,24 +171,52 @@ static inline int irq_has_action(unsigned int irq) | |||
178 | return desc->action != NULL; | 171 | return desc->action != NULL; |
179 | } | 172 | } |
180 | 173 | ||
181 | #ifndef CONFIG_GENERIC_HARDIRQS_NO_COMPAT | 174 | /* caller has locked the irq_desc and both params are valid */ |
182 | static inline int irq_balancing_disabled(unsigned int irq) | 175 | static inline void __irq_set_handler_locked(unsigned int irq, |
176 | irq_flow_handler_t handler) | ||
183 | { | 177 | { |
184 | struct irq_desc *desc; | 178 | struct irq_desc *desc; |
185 | 179 | ||
186 | desc = irq_to_desc(irq); | 180 | desc = irq_to_desc(irq); |
187 | return desc->status & IRQ_NO_BALANCING_MASK; | 181 | desc->handle_irq = handler; |
188 | } | 182 | } |
189 | #endif | ||
190 | 183 | ||
191 | /* caller has locked the irq_desc and both params are valid */ | 184 | /* caller has locked the irq_desc and both params are valid */ |
185 | static inline void | ||
186 | __irq_set_chip_handler_name_locked(unsigned int irq, struct irq_chip *chip, | ||
187 | irq_flow_handler_t handler, const char *name) | ||
188 | { | ||
189 | struct irq_desc *desc; | ||
190 | |||
191 | desc = irq_to_desc(irq); | ||
192 | irq_desc_get_irq_data(desc)->chip = chip; | ||
193 | desc->handle_irq = handler; | ||
194 | desc->name = name; | ||
195 | } | ||
196 | |||
197 | #ifndef CONFIG_GENERIC_HARDIRQS_NO_COMPAT | ||
192 | static inline void __set_irq_handler_unlocked(int irq, | 198 | static inline void __set_irq_handler_unlocked(int irq, |
193 | irq_flow_handler_t handler) | 199 | irq_flow_handler_t handler) |
194 | { | 200 | { |
201 | __irq_set_handler_locked(irq, handler); | ||
202 | } | ||
203 | |||
204 | static inline int irq_balancing_disabled(unsigned int irq) | ||
205 | { | ||
195 | struct irq_desc *desc; | 206 | struct irq_desc *desc; |
196 | 207 | ||
197 | desc = irq_to_desc(irq); | 208 | desc = irq_to_desc(irq); |
198 | desc->handle_irq = handler; | 209 | return desc->status & IRQ_NO_BALANCING_MASK; |
210 | } | ||
211 | #endif | ||
212 | |||
213 | static inline void | ||
214 | irq_set_lockdep_class(unsigned int irq, struct lock_class_key *class) | ||
215 | { | ||
216 | struct irq_desc *desc = irq_to_desc(irq); | ||
217 | |||
218 | if (desc) | ||
219 | lockdep_set_class(&desc->lock, class); | ||
199 | } | 220 | } |
200 | 221 | ||
201 | #ifdef CONFIG_IRQ_PREFLOW_FASTEOI | 222 | #ifdef CONFIG_IRQ_PREFLOW_FASTEOI |
diff --git a/include/linux/jbd2.h b/include/linux/jbd2.h index 27e79c27ba08..a32dcaec04e1 100644 --- a/include/linux/jbd2.h +++ b/include/linux/jbd2.h | |||
@@ -432,13 +432,35 @@ struct jbd2_journal_handle | |||
432 | int h_err; | 432 | int h_err; |
433 | 433 | ||
434 | /* Flags [no locking] */ | 434 | /* Flags [no locking] */ |
435 | unsigned int h_sync: 1; /* sync-on-close */ | 435 | unsigned int h_sync:1; /* sync-on-close */ |
436 | unsigned int h_jdata: 1; /* force data journaling */ | 436 | unsigned int h_jdata:1; /* force data journaling */ |
437 | unsigned int h_aborted: 1; /* fatal error on handle */ | 437 | unsigned int h_aborted:1; /* fatal error on handle */ |
438 | unsigned int h_cowing:1; /* COWing block to snapshot */ | ||
439 | |||
440 | /* Number of buffers requested by user: | ||
441 | * (before adding the COW credits factor) */ | ||
442 | unsigned int h_base_credits:14; | ||
443 | |||
444 | /* Number of buffers the user is allowed to dirty: | ||
445 | * (counts only buffers dirtied when !h_cowing) */ | ||
446 | unsigned int h_user_credits:14; | ||
447 | |||
438 | 448 | ||
439 | #ifdef CONFIG_DEBUG_LOCK_ALLOC | 449 | #ifdef CONFIG_DEBUG_LOCK_ALLOC |
440 | struct lockdep_map h_lockdep_map; | 450 | struct lockdep_map h_lockdep_map; |
441 | #endif | 451 | #endif |
452 | |||
453 | #ifdef CONFIG_JBD2_DEBUG | ||
454 | /* COW debugging counters: */ | ||
455 | unsigned int h_cow_moved; /* blocks moved to snapshot */ | ||
456 | unsigned int h_cow_copied; /* blocks copied to snapshot */ | ||
457 | unsigned int h_cow_ok_jh; /* blocks already COWed during current | ||
458 | transaction */ | ||
459 | unsigned int h_cow_ok_bitmap; /* blocks not set in COW bitmap */ | ||
460 | unsigned int h_cow_ok_mapped;/* blocks already mapped in snapshot */ | ||
461 | unsigned int h_cow_bitmaps; /* COW bitmaps created */ | ||
462 | unsigned int h_cow_excluded; /* blocks set in exclude bitmap */ | ||
463 | #endif | ||
442 | }; | 464 | }; |
443 | 465 | ||
444 | 466 | ||
diff --git a/include/linux/journal-head.h b/include/linux/journal-head.h index 525aac3c97df..44e95d0a721f 100644 --- a/include/linux/journal-head.h +++ b/include/linux/journal-head.h | |||
@@ -41,6 +41,13 @@ struct journal_head { | |||
41 | unsigned b_modified; | 41 | unsigned b_modified; |
42 | 42 | ||
43 | /* | 43 | /* |
44 | * This feild tracks the last transaction id in which this buffer | ||
45 | * has been cowed | ||
46 | * [jbd_lock_bh_state()] | ||
47 | */ | ||
48 | unsigned b_cow_tid; | ||
49 | |||
50 | /* | ||
44 | * Copy of the buffer data frozen for writing to the log. | 51 | * Copy of the buffer data frozen for writing to the log. |
45 | * [jbd_lock_bh_state()] | 52 | * [jbd_lock_bh_state()] |
46 | */ | 53 | */ |
diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h index d8e9b3d1c23c..0df513b7a9f8 100644 --- a/include/linux/kallsyms.h +++ b/include/linux/kallsyms.h | |||
@@ -36,6 +36,7 @@ const char *kallsyms_lookup(unsigned long addr, | |||
36 | 36 | ||
37 | /* Look up a kernel symbol and return it in a text buffer. */ | 37 | /* Look up a kernel symbol and return it in a text buffer. */ |
38 | extern int sprint_symbol(char *buffer, unsigned long address); | 38 | extern int sprint_symbol(char *buffer, unsigned long address); |
39 | extern int sprint_backtrace(char *buffer, unsigned long address); | ||
39 | 40 | ||
40 | /* Look up a kernel symbol and print it to the kernel messages. */ | 41 | /* Look up a kernel symbol and print it to the kernel messages. */ |
41 | extern void __print_symbol(const char *fmt, unsigned long address); | 42 | extern void __print_symbol(const char *fmt, unsigned long address); |
@@ -79,6 +80,12 @@ static inline int sprint_symbol(char *buffer, unsigned long addr) | |||
79 | return 0; | 80 | return 0; |
80 | } | 81 | } |
81 | 82 | ||
83 | static inline int sprint_backtrace(char *buffer, unsigned long addr) | ||
84 | { | ||
85 | *buffer = '\0'; | ||
86 | return 0; | ||
87 | } | ||
88 | |||
82 | static inline int lookup_symbol_name(unsigned long addr, char *symname) | 89 | static inline int lookup_symbol_name(unsigned long addr, char *symname) |
83 | { | 90 | { |
84 | return -ERANGE; | 91 | return -ERANGE; |
diff --git a/include/linux/leds.h b/include/linux/leds.h index 383811d9af83..61e0340a4b77 100644 --- a/include/linux/leds.h +++ b/include/linux/leds.h | |||
@@ -145,6 +145,9 @@ extern void led_trigger_register_simple(const char *name, | |||
145 | extern void led_trigger_unregister_simple(struct led_trigger *trigger); | 145 | extern void led_trigger_unregister_simple(struct led_trigger *trigger); |
146 | extern void led_trigger_event(struct led_trigger *trigger, | 146 | extern void led_trigger_event(struct led_trigger *trigger, |
147 | enum led_brightness event); | 147 | enum led_brightness event); |
148 | extern void led_trigger_blink(struct led_trigger *trigger, | ||
149 | unsigned long *delay_on, | ||
150 | unsigned long *delay_off); | ||
148 | 151 | ||
149 | #else | 152 | #else |
150 | 153 | ||
diff --git a/include/linux/mfd/ab8500.h b/include/linux/mfd/ab8500.h index 56f8dea72152..6e4f77ef4d20 100644 --- a/include/linux/mfd/ab8500.h +++ b/include/linux/mfd/ab8500.h | |||
@@ -139,17 +139,23 @@ struct ab8500 { | |||
139 | u8 oldmask[AB8500_NUM_IRQ_REGS]; | 139 | u8 oldmask[AB8500_NUM_IRQ_REGS]; |
140 | }; | 140 | }; |
141 | 141 | ||
142 | struct regulator_reg_init; | ||
142 | struct regulator_init_data; | 143 | struct regulator_init_data; |
143 | 144 | ||
144 | /** | 145 | /** |
145 | * struct ab8500_platform_data - AB8500 platform data | 146 | * struct ab8500_platform_data - AB8500 platform data |
146 | * @irq_base: start of AB8500 IRQs, AB8500_NR_IRQS will be used | 147 | * @irq_base: start of AB8500 IRQs, AB8500_NR_IRQS will be used |
147 | * @init: board-specific initialization after detection of ab8500 | 148 | * @init: board-specific initialization after detection of ab8500 |
149 | * @num_regulator_reg_init: number of regulator init registers | ||
150 | * @regulator_reg_init: regulator init registers | ||
151 | * @num_regulator: number of regulators | ||
148 | * @regulator: machine-specific constraints for regulators | 152 | * @regulator: machine-specific constraints for regulators |
149 | */ | 153 | */ |
150 | struct ab8500_platform_data { | 154 | struct ab8500_platform_data { |
151 | int irq_base; | 155 | int irq_base; |
152 | void (*init) (struct ab8500 *); | 156 | void (*init) (struct ab8500 *); |
157 | int num_regulator_reg_init; | ||
158 | struct ab8500_regulator_reg_init *regulator_reg_init; | ||
153 | int num_regulator; | 159 | int num_regulator; |
154 | struct regulator_init_data *regulator; | 160 | struct regulator_init_data *regulator; |
155 | }; | 161 | }; |
diff --git a/include/linux/mfd/core.h b/include/linux/mfd/core.h index 1408bf8eed5f..ad1b19aa6508 100644 --- a/include/linux/mfd/core.h +++ b/include/linux/mfd/core.h | |||
@@ -63,6 +63,24 @@ extern int mfd_cell_enable(struct platform_device *pdev); | |||
63 | extern int mfd_cell_disable(struct platform_device *pdev); | 63 | extern int mfd_cell_disable(struct platform_device *pdev); |
64 | 64 | ||
65 | /* | 65 | /* |
66 | * "Clone" multiple platform devices for a single cell. This is to be used | ||
67 | * for devices that have multiple users of a cell. For example, if an mfd | ||
68 | * driver wants the cell "foo" to be used by a GPIO driver, an MTD driver, | ||
69 | * and a platform driver, the following bit of code would be use after first | ||
70 | * calling mfd_add_devices(): | ||
71 | * | ||
72 | * const char *fclones[] = { "foo-gpio", "foo-mtd" }; | ||
73 | * err = mfd_clone_cells("foo", fclones, ARRAY_SIZE(fclones)); | ||
74 | * | ||
75 | * Each driver (MTD, GPIO, and platform driver) would then register | ||
76 | * platform_drivers for "foo-mtd", "foo-gpio", and "foo", respectively. | ||
77 | * The cell's .enable/.disable hooks should be used to deal with hardware | ||
78 | * resource contention. | ||
79 | */ | ||
80 | extern int mfd_clone_cell(const char *cell, const char **clones, | ||
81 | size_t n_clones); | ||
82 | |||
83 | /* | ||
66 | * Given a platform device that's been created by mfd_add_devices(), fetch | 84 | * Given a platform device that's been created by mfd_add_devices(), fetch |
67 | * the mfd_cell that created it. | 85 | * the mfd_cell that created it. |
68 | */ | 86 | */ |
@@ -87,13 +105,4 @@ extern int mfd_add_devices(struct device *parent, int id, | |||
87 | 105 | ||
88 | extern void mfd_remove_devices(struct device *parent); | 106 | extern void mfd_remove_devices(struct device *parent); |
89 | 107 | ||
90 | /* | ||
91 | * For MFD drivers with clients sharing access to resources, these create | ||
92 | * multiple platform devices per cell. Contention handling must still be | ||
93 | * handled via drivers (ie, with enable/disable hooks). | ||
94 | */ | ||
95 | extern int mfd_shared_platform_driver_register(struct platform_driver *drv, | ||
96 | const char *cellname); | ||
97 | extern void mfd_shared_platform_driver_unregister(struct platform_driver *drv); | ||
98 | |||
99 | #endif | 108 | #endif |
diff --git a/include/linux/mfd/max8997-private.h b/include/linux/mfd/max8997-private.h index 93a9477e075f..69d1010e2e51 100644 --- a/include/linux/mfd/max8997-private.h +++ b/include/linux/mfd/max8997-private.h | |||
@@ -24,6 +24,8 @@ | |||
24 | 24 | ||
25 | #include <linux/i2c.h> | 25 | #include <linux/i2c.h> |
26 | 26 | ||
27 | #define MAX8997_REG_INVALID (0xff) | ||
28 | |||
27 | enum max8997_pmic_reg { | 29 | enum max8997_pmic_reg { |
28 | MAX8997_REG_PMIC_ID0 = 0x00, | 30 | MAX8997_REG_PMIC_ID0 = 0x00, |
29 | MAX8997_REG_PMIC_ID1 = 0x01, | 31 | MAX8997_REG_PMIC_ID1 = 0x01, |
@@ -313,6 +315,7 @@ enum max8997_irq { | |||
313 | #define MAX8997_REG_BUCK2DVS(x) (MAX8997_REG_BUCK2DVS1 + (x) - 1) | 315 | #define MAX8997_REG_BUCK2DVS(x) (MAX8997_REG_BUCK2DVS1 + (x) - 1) |
314 | #define MAX8997_REG_BUCK5DVS(x) (MAX8997_REG_BUCK5DVS1 + (x) - 1) | 316 | #define MAX8997_REG_BUCK5DVS(x) (MAX8997_REG_BUCK5DVS1 + (x) - 1) |
315 | 317 | ||
318 | #define MAX8997_NUM_GPIO 12 | ||
316 | struct max8997_dev { | 319 | struct max8997_dev { |
317 | struct device *dev; | 320 | struct device *dev; |
318 | struct i2c_client *i2c; /* 0xcc / PMIC, Battery Control, and FLASH */ | 321 | struct i2c_client *i2c; /* 0xcc / PMIC, Battery Control, and FLASH */ |
@@ -324,11 +327,19 @@ struct max8997_dev { | |||
324 | int type; | 327 | int type; |
325 | struct platform_device *battery; /* battery control (not fuel gauge) */ | 328 | struct platform_device *battery; /* battery control (not fuel gauge) */ |
326 | 329 | ||
330 | int irq; | ||
331 | int ono; | ||
332 | int irq_base; | ||
327 | bool wakeup; | 333 | bool wakeup; |
334 | struct mutex irqlock; | ||
335 | int irq_masks_cur[MAX8997_IRQ_GROUP_NR]; | ||
336 | int irq_masks_cache[MAX8997_IRQ_GROUP_NR]; | ||
328 | 337 | ||
329 | /* For hibernation */ | 338 | /* For hibernation */ |
330 | u8 reg_dump[MAX8997_REG_PMIC_END + MAX8997_MUIC_REG_END + | 339 | u8 reg_dump[MAX8997_REG_PMIC_END + MAX8997_MUIC_REG_END + |
331 | MAX8997_HAPTIC_REG_END]; | 340 | MAX8997_HAPTIC_REG_END]; |
341 | |||
342 | bool gpio_status[MAX8997_NUM_GPIO]; | ||
332 | }; | 343 | }; |
333 | 344 | ||
334 | enum max8997_types { | 345 | enum max8997_types { |
@@ -336,6 +347,10 @@ enum max8997_types { | |||
336 | TYPE_MAX8966, | 347 | TYPE_MAX8966, |
337 | }; | 348 | }; |
338 | 349 | ||
350 | extern int max8997_irq_init(struct max8997_dev *max8997); | ||
351 | extern void max8997_irq_exit(struct max8997_dev *max8997); | ||
352 | extern int max8997_irq_resume(struct max8997_dev *max8997); | ||
353 | |||
339 | extern int max8997_read_reg(struct i2c_client *i2c, u8 reg, u8 *dest); | 354 | extern int max8997_read_reg(struct i2c_client *i2c, u8 reg, u8 *dest); |
340 | extern int max8997_bulk_read(struct i2c_client *i2c, u8 reg, int count, | 355 | extern int max8997_bulk_read(struct i2c_client *i2c, u8 reg, int count, |
341 | u8 *buf); | 356 | u8 *buf); |
@@ -344,4 +359,10 @@ extern int max8997_bulk_write(struct i2c_client *i2c, u8 reg, int count, | |||
344 | u8 *buf); | 359 | u8 *buf); |
345 | extern int max8997_update_reg(struct i2c_client *i2c, u8 reg, u8 val, u8 mask); | 360 | extern int max8997_update_reg(struct i2c_client *i2c, u8 reg, u8 val, u8 mask); |
346 | 361 | ||
362 | #define MAX8997_GPIO_INT_BOTH (0x3 << 4) | ||
363 | #define MAX8997_GPIO_INT_RISE (0x2 << 4) | ||
364 | #define MAX8997_GPIO_INT_FALL (0x1 << 4) | ||
365 | |||
366 | #define MAX8997_GPIO_INT_MASK (0x3 << 4) | ||
367 | #define MAX8997_GPIO_DATA_MASK (0x1 << 2) | ||
347 | #endif /* __LINUX_MFD_MAX8997_PRIV_H */ | 368 | #endif /* __LINUX_MFD_MAX8997_PRIV_H */ |
diff --git a/include/linux/mfd/max8997.h b/include/linux/mfd/max8997.h index cb671b3451bf..60931d089422 100644 --- a/include/linux/mfd/max8997.h +++ b/include/linux/mfd/max8997.h | |||
@@ -78,8 +78,11 @@ struct max8997_regulator_data { | |||
78 | }; | 78 | }; |
79 | 79 | ||
80 | struct max8997_platform_data { | 80 | struct max8997_platform_data { |
81 | bool wakeup; | 81 | /* IRQ */ |
82 | /* IRQ: Not implemented */ | 82 | int irq_base; |
83 | int ono; | ||
84 | int wakeup; | ||
85 | |||
83 | /* ---- PMIC ---- */ | 86 | /* ---- PMIC ---- */ |
84 | struct max8997_regulator_data *regulators; | 87 | struct max8997_regulator_data *regulators; |
85 | int num_regulators; | 88 | int num_regulators; |
diff --git a/include/linux/mlx4/device.h b/include/linux/mlx4/device.h index 049214642036..8985768e2c0d 100644 --- a/include/linux/mlx4/device.h +++ b/include/linux/mlx4/device.h | |||
@@ -39,6 +39,11 @@ | |||
39 | 39 | ||
40 | #include <asm/atomic.h> | 40 | #include <asm/atomic.h> |
41 | 41 | ||
42 | #define MAX_MSIX_P_PORT 17 | ||
43 | #define MAX_MSIX 64 | ||
44 | #define MSIX_LEGACY_SZ 4 | ||
45 | #define MIN_MSIX_P_PORT 5 | ||
46 | |||
42 | enum { | 47 | enum { |
43 | MLX4_FLAG_MSI_X = 1 << 0, | 48 | MLX4_FLAG_MSI_X = 1 << 0, |
44 | MLX4_FLAG_OLD_PORT_CMDS = 1 << 1, | 49 | MLX4_FLAG_OLD_PORT_CMDS = 1 << 1, |
@@ -145,8 +150,10 @@ enum { | |||
145 | }; | 150 | }; |
146 | 151 | ||
147 | enum mlx4_protocol { | 152 | enum mlx4_protocol { |
148 | MLX4_PROTOCOL_IB, | 153 | MLX4_PROT_IB_IPV6 = 0, |
149 | MLX4_PROTOCOL_EN, | 154 | MLX4_PROT_ETH, |
155 | MLX4_PROT_IB_IPV4, | ||
156 | MLX4_PROT_FCOE | ||
150 | }; | 157 | }; |
151 | 158 | ||
152 | enum { | 159 | enum { |
@@ -173,6 +180,12 @@ enum mlx4_special_vlan_idx { | |||
173 | MLX4_VLAN_REGULAR | 180 | MLX4_VLAN_REGULAR |
174 | }; | 181 | }; |
175 | 182 | ||
183 | enum mlx4_steer_type { | ||
184 | MLX4_MC_STEER = 0, | ||
185 | MLX4_UC_STEER, | ||
186 | MLX4_NUM_STEERS | ||
187 | }; | ||
188 | |||
176 | enum { | 189 | enum { |
177 | MLX4_NUM_FEXCH = 64 * 1024, | 190 | MLX4_NUM_FEXCH = 64 * 1024, |
178 | }; | 191 | }; |
@@ -223,6 +236,7 @@ struct mlx4_caps { | |||
223 | int num_eqs; | 236 | int num_eqs; |
224 | int reserved_eqs; | 237 | int reserved_eqs; |
225 | int num_comp_vectors; | 238 | int num_comp_vectors; |
239 | int comp_pool; | ||
226 | int num_mpts; | 240 | int num_mpts; |
227 | int num_mtt_segs; | 241 | int num_mtt_segs; |
228 | int mtts_per_seg; | 242 | int mtts_per_seg; |
@@ -245,6 +259,9 @@ struct mlx4_caps { | |||
245 | u16 stat_rate_support; | 259 | u16 stat_rate_support; |
246 | int udp_rss; | 260 | int udp_rss; |
247 | int loopback_support; | 261 | int loopback_support; |
262 | int vep_uc_steering; | ||
263 | int vep_mc_steering; | ||
264 | int wol; | ||
248 | u8 port_width_cap[MLX4_MAX_PORTS + 1]; | 265 | u8 port_width_cap[MLX4_MAX_PORTS + 1]; |
249 | int max_gso_sz; | 266 | int max_gso_sz; |
250 | int reserved_qps_cnt[MLX4_NUM_QP_REGION]; | 267 | int reserved_qps_cnt[MLX4_NUM_QP_REGION]; |
@@ -334,6 +351,17 @@ struct mlx4_fmr { | |||
334 | struct mlx4_uar { | 351 | struct mlx4_uar { |
335 | unsigned long pfn; | 352 | unsigned long pfn; |
336 | int index; | 353 | int index; |
354 | struct list_head bf_list; | ||
355 | unsigned free_bf_bmap; | ||
356 | void __iomem *map; | ||
357 | void __iomem *bf_map; | ||
358 | }; | ||
359 | |||
360 | struct mlx4_bf { | ||
361 | unsigned long offset; | ||
362 | int buf_size; | ||
363 | struct mlx4_uar *uar; | ||
364 | void __iomem *reg; | ||
337 | }; | 365 | }; |
338 | 366 | ||
339 | struct mlx4_cq { | 367 | struct mlx4_cq { |
@@ -415,7 +443,7 @@ struct mlx4_dev { | |||
415 | unsigned long flags; | 443 | unsigned long flags; |
416 | struct mlx4_caps caps; | 444 | struct mlx4_caps caps; |
417 | struct radix_tree_root qp_table_tree; | 445 | struct radix_tree_root qp_table_tree; |
418 | u32 rev_id; | 446 | u8 rev_id; |
419 | char board_id[MLX4_BOARD_ID_LEN]; | 447 | char board_id[MLX4_BOARD_ID_LEN]; |
420 | }; | 448 | }; |
421 | 449 | ||
@@ -461,6 +489,8 @@ void mlx4_pd_free(struct mlx4_dev *dev, u32 pdn); | |||
461 | 489 | ||
462 | int mlx4_uar_alloc(struct mlx4_dev *dev, struct mlx4_uar *uar); | 490 | int mlx4_uar_alloc(struct mlx4_dev *dev, struct mlx4_uar *uar); |
463 | void mlx4_uar_free(struct mlx4_dev *dev, struct mlx4_uar *uar); | 491 | void mlx4_uar_free(struct mlx4_dev *dev, struct mlx4_uar *uar); |
492 | int mlx4_bf_alloc(struct mlx4_dev *dev, struct mlx4_bf *bf); | ||
493 | void mlx4_bf_free(struct mlx4_dev *dev, struct mlx4_bf *bf); | ||
464 | 494 | ||
465 | int mlx4_mtt_init(struct mlx4_dev *dev, int npages, int page_shift, | 495 | int mlx4_mtt_init(struct mlx4_dev *dev, int npages, int page_shift, |
466 | struct mlx4_mtt *mtt); | 496 | struct mlx4_mtt *mtt); |
@@ -508,9 +538,15 @@ int mlx4_multicast_attach(struct mlx4_dev *dev, struct mlx4_qp *qp, u8 gid[16], | |||
508 | int block_mcast_loopback, enum mlx4_protocol protocol); | 538 | int block_mcast_loopback, enum mlx4_protocol protocol); |
509 | int mlx4_multicast_detach(struct mlx4_dev *dev, struct mlx4_qp *qp, u8 gid[16], | 539 | int mlx4_multicast_detach(struct mlx4_dev *dev, struct mlx4_qp *qp, u8 gid[16], |
510 | enum mlx4_protocol protocol); | 540 | enum mlx4_protocol protocol); |
541 | int mlx4_multicast_promisc_add(struct mlx4_dev *dev, u32 qpn, u8 port); | ||
542 | int mlx4_multicast_promisc_remove(struct mlx4_dev *dev, u32 qpn, u8 port); | ||
543 | int mlx4_unicast_promisc_add(struct mlx4_dev *dev, u32 qpn, u8 port); | ||
544 | int mlx4_unicast_promisc_remove(struct mlx4_dev *dev, u32 qpn, u8 port); | ||
545 | int mlx4_SET_MCAST_FLTR(struct mlx4_dev *dev, u8 port, u64 mac, u64 clear, u8 mode); | ||
511 | 546 | ||
512 | int mlx4_register_mac(struct mlx4_dev *dev, u8 port, u64 mac, int *index); | 547 | int mlx4_register_mac(struct mlx4_dev *dev, u8 port, u64 mac, int *qpn, u8 wrap); |
513 | void mlx4_unregister_mac(struct mlx4_dev *dev, u8 port, int index); | 548 | void mlx4_unregister_mac(struct mlx4_dev *dev, u8 port, int qpn); |
549 | int mlx4_replace_mac(struct mlx4_dev *dev, u8 port, int qpn, u64 new_mac, u8 wrap); | ||
514 | 550 | ||
515 | int mlx4_find_cached_vlan(struct mlx4_dev *dev, u8 port, u16 vid, int *idx); | 551 | int mlx4_find_cached_vlan(struct mlx4_dev *dev, u8 port, u16 vid, int *idx); |
516 | int mlx4_register_vlan(struct mlx4_dev *dev, u8 port, u16 vlan, int *index); | 552 | int mlx4_register_vlan(struct mlx4_dev *dev, u8 port, u16 vlan, int *index); |
@@ -526,5 +562,10 @@ void mlx4_fmr_unmap(struct mlx4_dev *dev, struct mlx4_fmr *fmr, | |||
526 | int mlx4_fmr_free(struct mlx4_dev *dev, struct mlx4_fmr *fmr); | 562 | int mlx4_fmr_free(struct mlx4_dev *dev, struct mlx4_fmr *fmr); |
527 | int mlx4_SYNC_TPT(struct mlx4_dev *dev); | 563 | int mlx4_SYNC_TPT(struct mlx4_dev *dev); |
528 | int mlx4_test_interrupts(struct mlx4_dev *dev); | 564 | int mlx4_test_interrupts(struct mlx4_dev *dev); |
565 | int mlx4_assign_eq(struct mlx4_dev *dev, char* name , int* vector); | ||
566 | void mlx4_release_eq(struct mlx4_dev *dev, int vec); | ||
567 | |||
568 | int mlx4_wol_read(struct mlx4_dev *dev, u64 *config, int port); | ||
569 | int mlx4_wol_write(struct mlx4_dev *dev, u64 config, int port); | ||
529 | 570 | ||
530 | #endif /* MLX4_DEVICE_H */ | 571 | #endif /* MLX4_DEVICE_H */ |
diff --git a/include/linux/mlx4/qp.h b/include/linux/mlx4/qp.h index 0eeb2a1a867c..9e9eb21056ca 100644 --- a/include/linux/mlx4/qp.h +++ b/include/linux/mlx4/qp.h | |||
@@ -303,6 +303,7 @@ struct mlx4_wqe_data_seg { | |||
303 | 303 | ||
304 | enum { | 304 | enum { |
305 | MLX4_INLINE_ALIGN = 64, | 305 | MLX4_INLINE_ALIGN = 64, |
306 | MLX4_INLINE_SEG = 1 << 31, | ||
306 | }; | 307 | }; |
307 | 308 | ||
308 | struct mlx4_wqe_inline_seg { | 309 | struct mlx4_wqe_inline_seg { |
diff --git a/include/linux/mm.h b/include/linux/mm.h index f9535b2c9558..7606d7db96c9 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
@@ -861,7 +861,7 @@ extern void pagefault_out_of_memory(void); | |||
861 | #define offset_in_page(p) ((unsigned long)(p) & ~PAGE_MASK) | 861 | #define offset_in_page(p) ((unsigned long)(p) & ~PAGE_MASK) |
862 | 862 | ||
863 | /* | 863 | /* |
864 | * Flags passed to __show_mem() and __show_free_areas() to suppress output in | 864 | * Flags passed to show_mem() and __show_free_areas() to suppress output in |
865 | * various contexts. | 865 | * various contexts. |
866 | */ | 866 | */ |
867 | #define SHOW_MEM_FILTER_NODES (0x0001u) /* filter disallowed nodes */ | 867 | #define SHOW_MEM_FILTER_NODES (0x0001u) /* filter disallowed nodes */ |
@@ -1360,8 +1360,7 @@ extern void setup_per_zone_wmarks(void); | |||
1360 | extern void calculate_zone_inactive_ratio(struct zone *zone); | 1360 | extern void calculate_zone_inactive_ratio(struct zone *zone); |
1361 | extern void mem_init(void); | 1361 | extern void mem_init(void); |
1362 | extern void __init mmap_init(void); | 1362 | extern void __init mmap_init(void); |
1363 | extern void show_mem(void); | 1363 | extern void show_mem(unsigned int flags); |
1364 | extern void __show_mem(unsigned int flags); | ||
1365 | extern void si_meminfo(struct sysinfo * val); | 1364 | extern void si_meminfo(struct sysinfo * val); |
1366 | extern void si_meminfo_node(struct sysinfo *val, int nid); | 1365 | extern void si_meminfo_node(struct sysinfo *val, int nid); |
1367 | extern int after_bootmem; | 1366 | extern int after_bootmem; |
diff --git a/include/linux/mtd/blktrans.h b/include/linux/mtd/blktrans.h index 26529ebd59cc..1bbd9f289245 100644 --- a/include/linux/mtd/blktrans.h +++ b/include/linux/mtd/blktrans.h | |||
@@ -36,6 +36,7 @@ struct mtd_blktrans_dev { | |||
36 | struct mtd_info *mtd; | 36 | struct mtd_info *mtd; |
37 | struct mutex lock; | 37 | struct mutex lock; |
38 | int devnum; | 38 | int devnum; |
39 | bool bg_stop; | ||
39 | unsigned long size; | 40 | unsigned long size; |
40 | int readonly; | 41 | int readonly; |
41 | int open; | 42 | int open; |
@@ -62,6 +63,7 @@ struct mtd_blktrans_ops { | |||
62 | unsigned long block, char *buffer); | 63 | unsigned long block, char *buffer); |
63 | int (*discard)(struct mtd_blktrans_dev *dev, | 64 | int (*discard)(struct mtd_blktrans_dev *dev, |
64 | unsigned long block, unsigned nr_blocks); | 65 | unsigned long block, unsigned nr_blocks); |
66 | void (*background)(struct mtd_blktrans_dev *dev); | ||
65 | 67 | ||
66 | /* Block layer ioctls */ | 68 | /* Block layer ioctls */ |
67 | int (*getgeo)(struct mtd_blktrans_dev *dev, struct hd_geometry *geo); | 69 | int (*getgeo)(struct mtd_blktrans_dev *dev, struct hd_geometry *geo); |
@@ -85,6 +87,7 @@ extern int register_mtd_blktrans(struct mtd_blktrans_ops *tr); | |||
85 | extern int deregister_mtd_blktrans(struct mtd_blktrans_ops *tr); | 87 | extern int deregister_mtd_blktrans(struct mtd_blktrans_ops *tr); |
86 | extern int add_mtd_blktrans_dev(struct mtd_blktrans_dev *dev); | 88 | extern int add_mtd_blktrans_dev(struct mtd_blktrans_dev *dev); |
87 | extern int del_mtd_blktrans_dev(struct mtd_blktrans_dev *dev); | 89 | extern int del_mtd_blktrans_dev(struct mtd_blktrans_dev *dev); |
90 | extern int mtd_blktrans_cease_background(struct mtd_blktrans_dev *dev); | ||
88 | 91 | ||
89 | 92 | ||
90 | #endif /* __MTD_TRANS_H__ */ | 93 | #endif /* __MTD_TRANS_H__ */ |
diff --git a/include/linux/mtd/cfi.h b/include/linux/mtd/cfi.h index a9baee6864af..0d823f2dd667 100644 --- a/include/linux/mtd/cfi.h +++ b/include/linux/mtd/cfi.h | |||
@@ -535,6 +535,7 @@ struct cfi_fixup { | |||
535 | #define CFI_MFR_CONTINUATION 0x007F | 535 | #define CFI_MFR_CONTINUATION 0x007F |
536 | 536 | ||
537 | #define CFI_MFR_AMD 0x0001 | 537 | #define CFI_MFR_AMD 0x0001 |
538 | #define CFI_MFR_AMIC 0x0037 | ||
538 | #define CFI_MFR_ATMEL 0x001F | 539 | #define CFI_MFR_ATMEL 0x001F |
539 | #define CFI_MFR_EON 0x001C | 540 | #define CFI_MFR_EON 0x001C |
540 | #define CFI_MFR_FUJITSU 0x0004 | 541 | #define CFI_MFR_FUJITSU 0x0004 |
diff --git a/include/linux/mtd/latch-addr-flash.h b/include/linux/mtd/latch-addr-flash.h new file mode 100644 index 000000000000..e94b8e128074 --- /dev/null +++ b/include/linux/mtd/latch-addr-flash.h | |||
@@ -0,0 +1,29 @@ | |||
1 | /* | ||
2 | * Interface for NOR flash driver whose high address lines are latched | ||
3 | * | ||
4 | * Copyright © 2008 MontaVista Software, Inc. <source@mvista.com> | ||
5 | * | ||
6 | * This file is licensed under the terms of the GNU General Public License | ||
7 | * version 2. This program is licensed "as is" without any warranty of any | ||
8 | * kind, whether express or implied. | ||
9 | */ | ||
10 | #ifndef __LATCH_ADDR_FLASH__ | ||
11 | #define __LATCH_ADDR_FLASH__ | ||
12 | |||
13 | struct map_info; | ||
14 | struct mtd_partition; | ||
15 | |||
16 | struct latch_addr_flash_data { | ||
17 | unsigned int width; | ||
18 | unsigned int size; | ||
19 | |||
20 | int (*init)(void *data, int cs); | ||
21 | void (*done)(void *data); | ||
22 | void (*set_window)(unsigned long offset, void *data); | ||
23 | void *data; | ||
24 | |||
25 | unsigned int nr_parts; | ||
26 | struct mtd_partition *parts; | ||
27 | }; | ||
28 | |||
29 | #endif | ||
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h index 1f489b247a29..ae67ef56a8f5 100644 --- a/include/linux/mtd/nand.h +++ b/include/linux/mtd/nand.h | |||
@@ -140,6 +140,7 @@ typedef enum { | |||
140 | NAND_ECC_HW, | 140 | NAND_ECC_HW, |
141 | NAND_ECC_HW_SYNDROME, | 141 | NAND_ECC_HW_SYNDROME, |
142 | NAND_ECC_HW_OOB_FIRST, | 142 | NAND_ECC_HW_OOB_FIRST, |
143 | NAND_ECC_SOFT_BCH, | ||
143 | } nand_ecc_modes_t; | 144 | } nand_ecc_modes_t; |
144 | 145 | ||
145 | /* | 146 | /* |
@@ -339,6 +340,7 @@ struct nand_hw_control { | |||
339 | * @prepad: padding information for syndrome based ecc generators | 340 | * @prepad: padding information for syndrome based ecc generators |
340 | * @postpad: padding information for syndrome based ecc generators | 341 | * @postpad: padding information for syndrome based ecc generators |
341 | * @layout: ECC layout control struct pointer | 342 | * @layout: ECC layout control struct pointer |
343 | * @priv: pointer to private ecc control data | ||
342 | * @hwctl: function to control hardware ecc generator. Must only | 344 | * @hwctl: function to control hardware ecc generator. Must only |
343 | * be provided if an hardware ECC is available | 345 | * be provided if an hardware ECC is available |
344 | * @calculate: function for ecc calculation or readback from ecc hardware | 346 | * @calculate: function for ecc calculation or readback from ecc hardware |
@@ -362,6 +364,7 @@ struct nand_ecc_ctrl { | |||
362 | int prepad; | 364 | int prepad; |
363 | int postpad; | 365 | int postpad; |
364 | struct nand_ecclayout *layout; | 366 | struct nand_ecclayout *layout; |
367 | void *priv; | ||
365 | void (*hwctl)(struct mtd_info *mtd, int mode); | 368 | void (*hwctl)(struct mtd_info *mtd, int mode); |
366 | int (*calculate)(struct mtd_info *mtd, const uint8_t *dat, | 369 | int (*calculate)(struct mtd_info *mtd, const uint8_t *dat, |
367 | uint8_t *ecc_code); | 370 | uint8_t *ecc_code); |
diff --git a/include/linux/mtd/nand_bch.h b/include/linux/mtd/nand_bch.h new file mode 100644 index 000000000000..74acf5367556 --- /dev/null +++ b/include/linux/mtd/nand_bch.h | |||
@@ -0,0 +1,72 @@ | |||
1 | /* | ||
2 | * Copyright © 2011 Ivan Djelic <ivan.djelic@parrot.com> | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify | ||
5 | * it under the terms of the GNU General Public License version 2 as | ||
6 | * published by the Free Software Foundation. | ||
7 | * | ||
8 | * This file is the header for the NAND BCH ECC implementation. | ||
9 | */ | ||
10 | |||
11 | #ifndef __MTD_NAND_BCH_H__ | ||
12 | #define __MTD_NAND_BCH_H__ | ||
13 | |||
14 | struct mtd_info; | ||
15 | struct nand_bch_control; | ||
16 | |||
17 | #if defined(CONFIG_MTD_NAND_ECC_BCH) | ||
18 | |||
19 | static inline int mtd_nand_has_bch(void) { return 1; } | ||
20 | |||
21 | /* | ||
22 | * Calculate BCH ecc code | ||
23 | */ | ||
24 | int nand_bch_calculate_ecc(struct mtd_info *mtd, const u_char *dat, | ||
25 | u_char *ecc_code); | ||
26 | |||
27 | /* | ||
28 | * Detect and correct bit errors | ||
29 | */ | ||
30 | int nand_bch_correct_data(struct mtd_info *mtd, u_char *dat, u_char *read_ecc, | ||
31 | u_char *calc_ecc); | ||
32 | /* | ||
33 | * Initialize BCH encoder/decoder | ||
34 | */ | ||
35 | struct nand_bch_control * | ||
36 | nand_bch_init(struct mtd_info *mtd, unsigned int eccsize, | ||
37 | unsigned int eccbytes, struct nand_ecclayout **ecclayout); | ||
38 | /* | ||
39 | * Release BCH encoder/decoder resources | ||
40 | */ | ||
41 | void nand_bch_free(struct nand_bch_control *nbc); | ||
42 | |||
43 | #else /* !CONFIG_MTD_NAND_ECC_BCH */ | ||
44 | |||
45 | static inline int mtd_nand_has_bch(void) { return 0; } | ||
46 | |||
47 | static inline int | ||
48 | nand_bch_calculate_ecc(struct mtd_info *mtd, const u_char *dat, | ||
49 | u_char *ecc_code) | ||
50 | { | ||
51 | return -1; | ||
52 | } | ||
53 | |||
54 | static inline int | ||
55 | nand_bch_correct_data(struct mtd_info *mtd, unsigned char *buf, | ||
56 | unsigned char *read_ecc, unsigned char *calc_ecc) | ||
57 | { | ||
58 | return -1; | ||
59 | } | ||
60 | |||
61 | static inline struct nand_bch_control * | ||
62 | nand_bch_init(struct mtd_info *mtd, unsigned int eccsize, | ||
63 | unsigned int eccbytes, struct nand_ecclayout **ecclayout) | ||
64 | { | ||
65 | return NULL; | ||
66 | } | ||
67 | |||
68 | static inline void nand_bch_free(struct nand_bch_control *nbc) {} | ||
69 | |||
70 | #endif /* CONFIG_MTD_NAND_ECC_BCH */ | ||
71 | |||
72 | #endif /* __MTD_NAND_BCH_H__ */ | ||
diff --git a/include/linux/mtd/onenand.h b/include/linux/mtd/onenand.h index ae418e41d8f5..52b6f187bf49 100644 --- a/include/linux/mtd/onenand.h +++ b/include/linux/mtd/onenand.h | |||
@@ -198,6 +198,7 @@ struct onenand_chip { | |||
198 | #define ONENAND_SKIP_UNLOCK_CHECK (0x0100) | 198 | #define ONENAND_SKIP_UNLOCK_CHECK (0x0100) |
199 | #define ONENAND_PAGEBUF_ALLOC (0x1000) | 199 | #define ONENAND_PAGEBUF_ALLOC (0x1000) |
200 | #define ONENAND_OOBBUF_ALLOC (0x2000) | 200 | #define ONENAND_OOBBUF_ALLOC (0x2000) |
201 | #define ONENAND_SKIP_INITIAL_UNLOCKING (0x4000) | ||
201 | 202 | ||
202 | #define ONENAND_IS_4KB_PAGE(this) \ | 203 | #define ONENAND_IS_4KB_PAGE(this) \ |
203 | (this->options & ONENAND_HAS_4KB_PAGE) | 204 | (this->options & ONENAND_HAS_4KB_PAGE) |
diff --git a/include/linux/nfs4.h b/include/linux/nfs4.h index 134716e5e350..b528f6d4b860 100644 --- a/include/linux/nfs4.h +++ b/include/linux/nfs4.h | |||
@@ -550,6 +550,7 @@ enum { | |||
550 | NFSPROC4_CLNT_SETACL, | 550 | NFSPROC4_CLNT_SETACL, |
551 | NFSPROC4_CLNT_FS_LOCATIONS, | 551 | NFSPROC4_CLNT_FS_LOCATIONS, |
552 | NFSPROC4_CLNT_RELEASE_LOCKOWNER, | 552 | NFSPROC4_CLNT_RELEASE_LOCKOWNER, |
553 | NFSPROC4_CLNT_SECINFO, | ||
553 | 554 | ||
554 | /* nfs41 */ | 555 | /* nfs41 */ |
555 | NFSPROC4_CLNT_EXCHANGE_ID, | 556 | NFSPROC4_CLNT_EXCHANGE_ID, |
@@ -560,6 +561,7 @@ enum { | |||
560 | NFSPROC4_CLNT_RECLAIM_COMPLETE, | 561 | NFSPROC4_CLNT_RECLAIM_COMPLETE, |
561 | NFSPROC4_CLNT_LAYOUTGET, | 562 | NFSPROC4_CLNT_LAYOUTGET, |
562 | NFSPROC4_CLNT_GETDEVICEINFO, | 563 | NFSPROC4_CLNT_GETDEVICEINFO, |
564 | NFSPROC4_CLNT_LAYOUTCOMMIT, | ||
563 | }; | 565 | }; |
564 | 566 | ||
565 | /* nfs41 types */ | 567 | /* nfs41 types */ |
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index f88522b10a38..1b93b9c60e55 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h | |||
@@ -33,6 +33,8 @@ | |||
33 | #define FLUSH_STABLE 4 /* commit to stable storage */ | 33 | #define FLUSH_STABLE 4 /* commit to stable storage */ |
34 | #define FLUSH_LOWPRI 8 /* low priority background flush */ | 34 | #define FLUSH_LOWPRI 8 /* low priority background flush */ |
35 | #define FLUSH_HIGHPRI 16 /* high priority memory reclaim flush */ | 35 | #define FLUSH_HIGHPRI 16 /* high priority memory reclaim flush */ |
36 | #define FLUSH_COND_STABLE 32 /* conditional stable write - only stable | ||
37 | * if everything fits in one RPC */ | ||
36 | 38 | ||
37 | #ifdef __KERNEL__ | 39 | #ifdef __KERNEL__ |
38 | 40 | ||
@@ -93,8 +95,13 @@ struct nfs_open_context { | |||
93 | int error; | 95 | int error; |
94 | 96 | ||
95 | struct list_head list; | 97 | struct list_head list; |
98 | }; | ||
96 | 99 | ||
100 | struct nfs_open_dir_context { | ||
101 | struct rpc_cred *cred; | ||
97 | __u64 dir_cookie; | 102 | __u64 dir_cookie; |
103 | __u64 dup_cookie; | ||
104 | int duped; | ||
98 | }; | 105 | }; |
99 | 106 | ||
100 | /* | 107 | /* |
@@ -191,6 +198,7 @@ struct nfs_inode { | |||
191 | 198 | ||
192 | /* pNFS layout information */ | 199 | /* pNFS layout information */ |
193 | struct pnfs_layout_hdr *layout; | 200 | struct pnfs_layout_hdr *layout; |
201 | atomic_t commits_outstanding; | ||
194 | #endif /* CONFIG_NFS_V4*/ | 202 | #endif /* CONFIG_NFS_V4*/ |
195 | #ifdef CONFIG_NFS_FSCACHE | 203 | #ifdef CONFIG_NFS_FSCACHE |
196 | struct fscache_cookie *fscache; | 204 | struct fscache_cookie *fscache; |
@@ -219,6 +227,8 @@ struct nfs_inode { | |||
219 | #define NFS_INO_FSCACHE (5) /* inode can be cached by FS-Cache */ | 227 | #define NFS_INO_FSCACHE (5) /* inode can be cached by FS-Cache */ |
220 | #define NFS_INO_FSCACHE_LOCK (6) /* FS-Cache cookie management lock */ | 228 | #define NFS_INO_FSCACHE_LOCK (6) /* FS-Cache cookie management lock */ |
221 | #define NFS_INO_COMMIT (7) /* inode is committing unstable writes */ | 229 | #define NFS_INO_COMMIT (7) /* inode is committing unstable writes */ |
230 | #define NFS_INO_PNFS_COMMIT (8) /* use pnfs code for commit */ | ||
231 | #define NFS_INO_LAYOUTCOMMIT (9) /* layoutcommit required */ | ||
222 | 232 | ||
223 | static inline struct nfs_inode *NFS_I(const struct inode *inode) | 233 | static inline struct nfs_inode *NFS_I(const struct inode *inode) |
224 | { | 234 | { |
diff --git a/include/linux/nfs_page.h b/include/linux/nfs_page.h index 90907ada6d52..8023e4e25133 100644 --- a/include/linux/nfs_page.h +++ b/include/linux/nfs_page.h | |||
@@ -33,11 +33,15 @@ enum { | |||
33 | PG_CLEAN, | 33 | PG_CLEAN, |
34 | PG_NEED_COMMIT, | 34 | PG_NEED_COMMIT, |
35 | PG_NEED_RESCHED, | 35 | PG_NEED_RESCHED, |
36 | PG_PNFS_COMMIT, | ||
36 | }; | 37 | }; |
37 | 38 | ||
38 | struct nfs_inode; | 39 | struct nfs_inode; |
39 | struct nfs_page { | 40 | struct nfs_page { |
40 | struct list_head wb_list; /* Defines state of page: */ | 41 | union { |
42 | struct list_head wb_list; /* Defines state of page: */ | ||
43 | struct pnfs_layout_segment *wb_commit_lseg; /* Used when PG_PNFS_COMMIT set */ | ||
44 | }; | ||
41 | struct page *wb_page; /* page to read in/write out */ | 45 | struct page *wb_page; /* page to read in/write out */ |
42 | struct nfs_open_context *wb_context; /* File state context info */ | 46 | struct nfs_open_context *wb_context; /* File state context info */ |
43 | struct nfs_lock_context *wb_lock_context; /* lock context info */ | 47 | struct nfs_lock_context *wb_lock_context; /* lock context info */ |
@@ -57,6 +61,7 @@ struct nfs_pageio_descriptor { | |||
57 | size_t pg_count; | 61 | size_t pg_count; |
58 | size_t pg_bsize; | 62 | size_t pg_bsize; |
59 | unsigned int pg_base; | 63 | unsigned int pg_base; |
64 | char pg_moreio; | ||
60 | 65 | ||
61 | struct inode *pg_inode; | 66 | struct inode *pg_inode; |
62 | int (*pg_doio)(struct nfs_pageio_descriptor *); | 67 | int (*pg_doio)(struct nfs_pageio_descriptor *); |
diff --git a/include/linux/nfs_xdr.h b/include/linux/nfs_xdr.h index 2c2c67d2eb42..78b101e487ea 100644 --- a/include/linux/nfs_xdr.h +++ b/include/linux/nfs_xdr.h | |||
@@ -3,6 +3,7 @@ | |||
3 | 3 | ||
4 | #include <linux/nfsacl.h> | 4 | #include <linux/nfsacl.h> |
5 | #include <linux/nfs3.h> | 5 | #include <linux/nfs3.h> |
6 | #include <linux/sunrpc/gss_api.h> | ||
6 | 7 | ||
7 | /* | 8 | /* |
8 | * To change the maximum rsize and wsize supported by the NFS client, adjust | 9 | * To change the maximum rsize and wsize supported by the NFS client, adjust |
@@ -14,6 +15,9 @@ | |||
14 | #define NFS_DEF_FILE_IO_SIZE (4096U) | 15 | #define NFS_DEF_FILE_IO_SIZE (4096U) |
15 | #define NFS_MIN_FILE_IO_SIZE (1024U) | 16 | #define NFS_MIN_FILE_IO_SIZE (1024U) |
16 | 17 | ||
18 | /* Forward declaration for NFS v3 */ | ||
19 | struct nfs4_secinfo_flavors; | ||
20 | |||
17 | struct nfs_fsid { | 21 | struct nfs_fsid { |
18 | uint64_t major; | 22 | uint64_t major; |
19 | uint64_t minor; | 23 | uint64_t minor; |
@@ -78,6 +82,7 @@ struct nfs_fattr { | |||
78 | #define NFS_ATTR_FATTR_CHANGE (1U << 17) | 82 | #define NFS_ATTR_FATTR_CHANGE (1U << 17) |
79 | #define NFS_ATTR_FATTR_PRECHANGE (1U << 18) | 83 | #define NFS_ATTR_FATTR_PRECHANGE (1U << 18) |
80 | #define NFS_ATTR_FATTR_V4_REFERRAL (1U << 19) /* NFSv4 referral */ | 84 | #define NFS_ATTR_FATTR_V4_REFERRAL (1U << 19) /* NFSv4 referral */ |
85 | #define NFS_ATTR_FATTR_MOUNTPOINT (1U << 20) /* Treat as mountpoint */ | ||
81 | 86 | ||
82 | #define NFS_ATTR_FATTR (NFS_ATTR_FATTR_TYPE \ | 87 | #define NFS_ATTR_FATTR (NFS_ATTR_FATTR_TYPE \ |
83 | | NFS_ATTR_FATTR_MODE \ | 88 | | NFS_ATTR_FATTR_MODE \ |
@@ -190,8 +195,9 @@ struct nfs4_get_lease_time_res { | |||
190 | #define PNFS_LAYOUT_MAXSIZE 4096 | 195 | #define PNFS_LAYOUT_MAXSIZE 4096 |
191 | 196 | ||
192 | struct nfs4_layoutdriver_data { | 197 | struct nfs4_layoutdriver_data { |
198 | struct page **pages; | ||
199 | __u32 pglen; | ||
193 | __u32 len; | 200 | __u32 len; |
194 | void *buf; | ||
195 | }; | 201 | }; |
196 | 202 | ||
197 | struct pnfs_layout_range { | 203 | struct pnfs_layout_range { |
@@ -209,6 +215,7 @@ struct nfs4_layoutget_args { | |||
209 | struct nfs_open_context *ctx; | 215 | struct nfs_open_context *ctx; |
210 | struct nfs4_sequence_args seq_args; | 216 | struct nfs4_sequence_args seq_args; |
211 | nfs4_stateid stateid; | 217 | nfs4_stateid stateid; |
218 | struct nfs4_layoutdriver_data layout; | ||
212 | }; | 219 | }; |
213 | 220 | ||
214 | struct nfs4_layoutget_res { | 221 | struct nfs4_layoutget_res { |
@@ -216,8 +223,8 @@ struct nfs4_layoutget_res { | |||
216 | struct pnfs_layout_range range; | 223 | struct pnfs_layout_range range; |
217 | __u32 type; | 224 | __u32 type; |
218 | nfs4_stateid stateid; | 225 | nfs4_stateid stateid; |
219 | struct nfs4_layoutdriver_data layout; | ||
220 | struct nfs4_sequence_res seq_res; | 226 | struct nfs4_sequence_res seq_res; |
227 | struct nfs4_layoutdriver_data *layoutp; | ||
221 | }; | 228 | }; |
222 | 229 | ||
223 | struct nfs4_layoutget { | 230 | struct nfs4_layoutget { |
@@ -236,6 +243,29 @@ struct nfs4_getdeviceinfo_res { | |||
236 | struct nfs4_sequence_res seq_res; | 243 | struct nfs4_sequence_res seq_res; |
237 | }; | 244 | }; |
238 | 245 | ||
246 | struct nfs4_layoutcommit_args { | ||
247 | nfs4_stateid stateid; | ||
248 | __u64 lastbytewritten; | ||
249 | struct inode *inode; | ||
250 | const u32 *bitmask; | ||
251 | struct nfs4_sequence_args seq_args; | ||
252 | }; | ||
253 | |||
254 | struct nfs4_layoutcommit_res { | ||
255 | struct nfs_fattr *fattr; | ||
256 | const struct nfs_server *server; | ||
257 | struct nfs4_sequence_res seq_res; | ||
258 | }; | ||
259 | |||
260 | struct nfs4_layoutcommit_data { | ||
261 | struct rpc_task task; | ||
262 | struct nfs_fattr fattr; | ||
263 | struct pnfs_layout_segment *lseg; | ||
264 | struct rpc_cred *cred; | ||
265 | struct nfs4_layoutcommit_args args; | ||
266 | struct nfs4_layoutcommit_res res; | ||
267 | }; | ||
268 | |||
239 | /* | 269 | /* |
240 | * Arguments to the open call. | 270 | * Arguments to the open call. |
241 | */ | 271 | */ |
@@ -936,6 +966,38 @@ struct nfs4_fs_locations_res { | |||
936 | struct nfs4_sequence_res seq_res; | 966 | struct nfs4_sequence_res seq_res; |
937 | }; | 967 | }; |
938 | 968 | ||
969 | struct nfs4_secinfo_oid { | ||
970 | unsigned int len; | ||
971 | char data[GSS_OID_MAX_LEN]; | ||
972 | }; | ||
973 | |||
974 | struct nfs4_secinfo_gss { | ||
975 | struct nfs4_secinfo_oid sec_oid4; | ||
976 | unsigned int qop4; | ||
977 | unsigned int service; | ||
978 | }; | ||
979 | |||
980 | struct nfs4_secinfo_flavor { | ||
981 | unsigned int flavor; | ||
982 | struct nfs4_secinfo_gss gss; | ||
983 | }; | ||
984 | |||
985 | struct nfs4_secinfo_flavors { | ||
986 | unsigned int num_flavors; | ||
987 | struct nfs4_secinfo_flavor flavors[0]; | ||
988 | }; | ||
989 | |||
990 | struct nfs4_secinfo_arg { | ||
991 | const struct nfs_fh *dir_fh; | ||
992 | const struct qstr *name; | ||
993 | struct nfs4_sequence_args seq_args; | ||
994 | }; | ||
995 | |||
996 | struct nfs4_secinfo_res { | ||
997 | struct nfs4_secinfo_flavors *flavors; | ||
998 | struct nfs4_sequence_res seq_res; | ||
999 | }; | ||
1000 | |||
939 | #endif /* CONFIG_NFS_V4 */ | 1001 | #endif /* CONFIG_NFS_V4 */ |
940 | 1002 | ||
941 | struct nfstime4 { | 1003 | struct nfstime4 { |
@@ -1040,6 +1102,7 @@ struct nfs_write_data { | |||
1040 | struct nfs_writeres res; /* result struct */ | 1102 | struct nfs_writeres res; /* result struct */ |
1041 | struct pnfs_layout_segment *lseg; | 1103 | struct pnfs_layout_segment *lseg; |
1042 | struct nfs_client *ds_clp; /* pNFS data server */ | 1104 | struct nfs_client *ds_clp; /* pNFS data server */ |
1105 | int ds_commit_index; | ||
1043 | const struct rpc_call_ops *mds_ops; | 1106 | const struct rpc_call_ops *mds_ops; |
1044 | int (*write_done_cb) (struct rpc_task *task, struct nfs_write_data *data); | 1107 | int (*write_done_cb) (struct rpc_task *task, struct nfs_write_data *data); |
1045 | #ifdef CONFIG_NFS_V4 | 1108 | #ifdef CONFIG_NFS_V4 |
@@ -1071,7 +1134,7 @@ struct nfs_rpc_ops { | |||
1071 | struct nfs_fattr *); | 1134 | struct nfs_fattr *); |
1072 | int (*setattr) (struct dentry *, struct nfs_fattr *, | 1135 | int (*setattr) (struct dentry *, struct nfs_fattr *, |
1073 | struct iattr *); | 1136 | struct iattr *); |
1074 | int (*lookup) (struct inode *, struct qstr *, | 1137 | int (*lookup) (struct rpc_clnt *clnt, struct inode *, struct qstr *, |
1075 | struct nfs_fh *, struct nfs_fattr *); | 1138 | struct nfs_fh *, struct nfs_fattr *); |
1076 | int (*access) (struct inode *, struct nfs_access_entry *); | 1139 | int (*access) (struct inode *, struct nfs_access_entry *); |
1077 | int (*readlink)(struct inode *, struct page *, unsigned int, | 1140 | int (*readlink)(struct inode *, struct page *, unsigned int, |
@@ -1118,6 +1181,7 @@ struct nfs_rpc_ops { | |||
1118 | struct iattr *iattr); | 1181 | struct iattr *iattr); |
1119 | int (*init_client) (struct nfs_client *, const struct rpc_timeout *, | 1182 | int (*init_client) (struct nfs_client *, const struct rpc_timeout *, |
1120 | const char *, rpc_authflavor_t, int); | 1183 | const char *, rpc_authflavor_t, int); |
1184 | int (*secinfo)(struct inode *, const struct qstr *, struct nfs4_secinfo_flavors *); | ||
1121 | }; | 1185 | }; |
1122 | 1186 | ||
1123 | /* | 1187 | /* |
diff --git a/include/linux/pci-aspm.h b/include/linux/pci-aspm.h index ce6810512c66..67cb3ae38016 100644 --- a/include/linux/pci-aspm.h +++ b/include/linux/pci-aspm.h | |||
@@ -26,6 +26,7 @@ | |||
26 | extern void pcie_aspm_init_link_state(struct pci_dev *pdev); | 26 | extern void pcie_aspm_init_link_state(struct pci_dev *pdev); |
27 | extern void pcie_aspm_exit_link_state(struct pci_dev *pdev); | 27 | extern void pcie_aspm_exit_link_state(struct pci_dev *pdev); |
28 | extern void pcie_aspm_pm_state_change(struct pci_dev *pdev); | 28 | extern void pcie_aspm_pm_state_change(struct pci_dev *pdev); |
29 | extern void pcie_aspm_powersave_config_link(struct pci_dev *pdev); | ||
29 | extern void pci_disable_link_state(struct pci_dev *pdev, int state); | 30 | extern void pci_disable_link_state(struct pci_dev *pdev, int state); |
30 | extern void pcie_clear_aspm(void); | 31 | extern void pcie_clear_aspm(void); |
31 | extern void pcie_no_aspm(void); | 32 | extern void pcie_no_aspm(void); |
@@ -39,6 +40,9 @@ static inline void pcie_aspm_exit_link_state(struct pci_dev *pdev) | |||
39 | static inline void pcie_aspm_pm_state_change(struct pci_dev *pdev) | 40 | static inline void pcie_aspm_pm_state_change(struct pci_dev *pdev) |
40 | { | 41 | { |
41 | } | 42 | } |
43 | static inline void pcie_aspm_powersave_config_link(struct pci_dev *pdev) | ||
44 | { | ||
45 | } | ||
42 | static inline void pci_disable_link_state(struct pci_dev *pdev, int state) | 46 | static inline void pci_disable_link_state(struct pci_dev *pdev, int state) |
43 | { | 47 | { |
44 | } | 48 | } |
diff --git a/include/linux/pci.h b/include/linux/pci.h index 16c9f2e61977..96f70d7e058d 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -1002,12 +1002,11 @@ extern bool pcie_ports_auto; | |||
1002 | #endif | 1002 | #endif |
1003 | 1003 | ||
1004 | #ifndef CONFIG_PCIEASPM | 1004 | #ifndef CONFIG_PCIEASPM |
1005 | static inline int pcie_aspm_enabled(void) | 1005 | static inline int pcie_aspm_enabled(void) { return 0; } |
1006 | { | 1006 | static inline bool pcie_aspm_support_enabled(void) { return false; } |
1007 | return 0; | ||
1008 | } | ||
1009 | #else | 1007 | #else |
1010 | extern int pcie_aspm_enabled(void); | 1008 | extern int pcie_aspm_enabled(void); |
1009 | extern bool pcie_aspm_support_enabled(void); | ||
1011 | #endif | 1010 | #endif |
1012 | 1011 | ||
1013 | #ifdef CONFIG_PCIEAER | 1012 | #ifdef CONFIG_PCIEAER |
diff --git a/include/linux/perf_event.h b/include/linux/perf_event.h index f495c0147240..311b4dc785a1 100644 --- a/include/linux/perf_event.h +++ b/include/linux/perf_event.h | |||
@@ -938,9 +938,7 @@ struct perf_cpu_context { | |||
938 | struct list_head rotation_list; | 938 | struct list_head rotation_list; |
939 | int jiffies_interval; | 939 | int jiffies_interval; |
940 | struct pmu *active_pmu; | 940 | struct pmu *active_pmu; |
941 | #ifdef CONFIG_CGROUP_PERF | ||
942 | struct perf_cgroup *cgrp; | 941 | struct perf_cgroup *cgrp; |
943 | #endif | ||
944 | }; | 942 | }; |
945 | 943 | ||
946 | struct perf_output_handle { | 944 | struct perf_output_handle { |
diff --git a/include/linux/pm.h b/include/linux/pm.h index 6618216bb973..512e09177e57 100644 --- a/include/linux/pm.h +++ b/include/linux/pm.h | |||
@@ -529,13 +529,19 @@ struct dev_power_domain { | |||
529 | */ | 529 | */ |
530 | 530 | ||
531 | #ifdef CONFIG_PM_SLEEP | 531 | #ifdef CONFIG_PM_SLEEP |
532 | extern void device_pm_lock(void); | 532 | #ifndef CONFIG_ARCH_NO_SYSDEV_OPS |
533 | extern int sysdev_suspend(pm_message_t state); | ||
533 | extern int sysdev_resume(void); | 534 | extern int sysdev_resume(void); |
535 | #else | ||
536 | static inline int sysdev_suspend(pm_message_t state) { return 0; } | ||
537 | static inline int sysdev_resume(void) { return 0; } | ||
538 | #endif | ||
539 | |||
540 | extern void device_pm_lock(void); | ||
534 | extern void dpm_resume_noirq(pm_message_t state); | 541 | extern void dpm_resume_noirq(pm_message_t state); |
535 | extern void dpm_resume_end(pm_message_t state); | 542 | extern void dpm_resume_end(pm_message_t state); |
536 | 543 | ||
537 | extern void device_pm_unlock(void); | 544 | extern void device_pm_unlock(void); |
538 | extern int sysdev_suspend(pm_message_t state); | ||
539 | extern int dpm_suspend_noirq(pm_message_t state); | 545 | extern int dpm_suspend_noirq(pm_message_t state); |
540 | extern int dpm_suspend_start(pm_message_t state); | 546 | extern int dpm_suspend_start(pm_message_t state); |
541 | 547 | ||
diff --git a/include/linux/power/bq20z75.h b/include/linux/power/bq20z75.h new file mode 100644 index 000000000000..b0843b68af92 --- /dev/null +++ b/include/linux/power/bq20z75.h | |||
@@ -0,0 +1,39 @@ | |||
1 | /* | ||
2 | * Gas Gauge driver for TI's BQ20Z75 | ||
3 | * | ||
4 | * Copyright (c) 2010, NVIDIA 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, but WITHOUT | ||
12 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
13 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
14 | * more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License along | ||
17 | * with this program; if not, write to the Free Software Foundation, Inc., | ||
18 | * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. | ||
19 | */ | ||
20 | |||
21 | #ifndef __LINUX_POWER_BQ20Z75_H_ | ||
22 | #define __LINUX_POWER_BQ20Z75_H_ | ||
23 | |||
24 | #include <linux/power_supply.h> | ||
25 | #include <linux/types.h> | ||
26 | |||
27 | /** | ||
28 | * struct bq20z75_platform_data - platform data for bq20z75 devices | ||
29 | * @battery_detect: GPIO which is used to detect battery presence | ||
30 | * @battery_detect_present: gpio state when battery is present (0 / 1) | ||
31 | * @i2c_retry_count: # of times to retry on i2c IO failure | ||
32 | */ | ||
33 | struct bq20z75_platform_data { | ||
34 | int battery_detect; | ||
35 | int battery_detect_present; | ||
36 | int i2c_retry_count; | ||
37 | }; | ||
38 | |||
39 | #endif | ||
diff --git a/include/linux/power/bq27x00_battery.h b/include/linux/power/bq27x00_battery.h new file mode 100644 index 000000000000..a857f719bf40 --- /dev/null +++ b/include/linux/power/bq27x00_battery.h | |||
@@ -0,0 +1,19 @@ | |||
1 | #ifndef __LINUX_BQ27X00_BATTERY_H__ | ||
2 | #define __LINUX_BQ27X00_BATTERY_H__ | ||
3 | |||
4 | /** | ||
5 | * struct bq27000_plaform_data - Platform data for bq27000 devices | ||
6 | * @name: Name of the battery. If NULL the driver will fallback to "bq27000". | ||
7 | * @read: HDQ read callback. | ||
8 | * This function should provide access to the HDQ bus the battery is | ||
9 | * connected to. | ||
10 | * The first parameter is a pointer to the battery device, the second the | ||
11 | * register to be read. The return value should either be the content of | ||
12 | * the passed register or an error value. | ||
13 | */ | ||
14 | struct bq27000_platform_data { | ||
15 | const char *name; | ||
16 | int (*read)(struct device *dev, unsigned int); | ||
17 | }; | ||
18 | |||
19 | #endif | ||
diff --git a/include/linux/power_supply.h b/include/linux/power_supply.h index 7d7325685c42..204c18dfdc9e 100644 --- a/include/linux/power_supply.h +++ b/include/linux/power_supply.h | |||
@@ -173,6 +173,8 @@ struct power_supply { | |||
173 | char *full_trig_name; | 173 | char *full_trig_name; |
174 | struct led_trigger *online_trig; | 174 | struct led_trigger *online_trig; |
175 | char *online_trig_name; | 175 | char *online_trig_name; |
176 | struct led_trigger *charging_blink_full_solid_trig; | ||
177 | char *charging_blink_full_solid_trig_name; | ||
176 | #endif | 178 | #endif |
177 | }; | 179 | }; |
178 | 180 | ||
@@ -213,4 +215,49 @@ extern void power_supply_unregister(struct power_supply *psy); | |||
213 | /* For APM emulation, think legacy userspace. */ | 215 | /* For APM emulation, think legacy userspace. */ |
214 | extern struct class *power_supply_class; | 216 | extern struct class *power_supply_class; |
215 | 217 | ||
218 | static inline bool power_supply_is_amp_property(enum power_supply_property psp) | ||
219 | { | ||
220 | switch (psp) { | ||
221 | case POWER_SUPPLY_PROP_CHARGE_FULL_DESIGN: | ||
222 | case POWER_SUPPLY_PROP_CHARGE_EMPTY_DESIGN: | ||
223 | case POWER_SUPPLY_PROP_CHARGE_FULL: | ||
224 | case POWER_SUPPLY_PROP_CHARGE_EMPTY: | ||
225 | case POWER_SUPPLY_PROP_CHARGE_NOW: | ||
226 | case POWER_SUPPLY_PROP_CHARGE_AVG: | ||
227 | case POWER_SUPPLY_PROP_CHARGE_COUNTER: | ||
228 | case POWER_SUPPLY_PROP_CURRENT_MAX: | ||
229 | case POWER_SUPPLY_PROP_CURRENT_NOW: | ||
230 | case POWER_SUPPLY_PROP_CURRENT_AVG: | ||
231 | return 1; | ||
232 | default: | ||
233 | break; | ||
234 | } | ||
235 | |||
236 | return 0; | ||
237 | } | ||
238 | |||
239 | static inline bool power_supply_is_watt_property(enum power_supply_property psp) | ||
240 | { | ||
241 | switch (psp) { | ||
242 | case POWER_SUPPLY_PROP_ENERGY_FULL_DESIGN: | ||
243 | case POWER_SUPPLY_PROP_ENERGY_EMPTY_DESIGN: | ||
244 | case POWER_SUPPLY_PROP_ENERGY_FULL: | ||
245 | case POWER_SUPPLY_PROP_ENERGY_EMPTY: | ||
246 | case POWER_SUPPLY_PROP_ENERGY_NOW: | ||
247 | case POWER_SUPPLY_PROP_ENERGY_AVG: | ||
248 | case POWER_SUPPLY_PROP_VOLTAGE_MAX: | ||
249 | case POWER_SUPPLY_PROP_VOLTAGE_MIN: | ||
250 | case POWER_SUPPLY_PROP_VOLTAGE_MAX_DESIGN: | ||
251 | case POWER_SUPPLY_PROP_VOLTAGE_MIN_DESIGN: | ||
252 | case POWER_SUPPLY_PROP_VOLTAGE_NOW: | ||
253 | case POWER_SUPPLY_PROP_VOLTAGE_AVG: | ||
254 | case POWER_SUPPLY_PROP_POWER_NOW: | ||
255 | return 1; | ||
256 | default: | ||
257 | break; | ||
258 | } | ||
259 | |||
260 | return 0; | ||
261 | } | ||
262 | |||
216 | #endif /* __LINUX_POWER_SUPPLY_H__ */ | 263 | #endif /* __LINUX_POWER_SUPPLY_H__ */ |
diff --git a/include/linux/quotaops.h b/include/linux/quotaops.h index eb354f6f26b3..26f9e3612e0f 100644 --- a/include/linux/quotaops.h +++ b/include/linux/quotaops.h | |||
@@ -277,7 +277,7 @@ static inline int dquot_alloc_space(struct inode *inode, qsize_t nr) | |||
277 | /* | 277 | /* |
278 | * Mark inode fully dirty. Since we are allocating blocks, inode | 278 | * Mark inode fully dirty. Since we are allocating blocks, inode |
279 | * would become fully dirty soon anyway and it reportedly | 279 | * would become fully dirty soon anyway and it reportedly |
280 | * reduces inode_lock contention. | 280 | * reduces lock contention. |
281 | */ | 281 | */ |
282 | mark_inode_dirty(inode); | 282 | mark_inode_dirty(inode); |
283 | } | 283 | } |
diff --git a/include/linux/regulator/ab8500.h b/include/linux/regulator/ab8500.h index 6a210f1511fc..76579f964a29 100644 --- a/include/linux/regulator/ab8500.h +++ b/include/linux/regulator/ab8500.h | |||
@@ -3,8 +3,8 @@ | |||
3 | * | 3 | * |
4 | * License Terms: GNU General Public License v2 | 4 | * License Terms: GNU General Public License v2 |
5 | * | 5 | * |
6 | * Author: Sundar Iyer <sundar.iyer@stericsson.com> for ST-Ericsson | 6 | * Authors: Sundar Iyer <sundar.iyer@stericsson.com> for ST-Ericsson |
7 | * | 7 | * Bengt Jonsson <bengt.g.jonsson@stericsson.com> for ST-Ericsson |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #ifndef __LINUX_MFD_AB8500_REGULATOR_H | 10 | #ifndef __LINUX_MFD_AB8500_REGULATOR_H |
@@ -17,6 +17,7 @@ enum ab8500_regulator_id { | |||
17 | AB8500_LDO_AUX3, | 17 | AB8500_LDO_AUX3, |
18 | AB8500_LDO_INTCORE, | 18 | AB8500_LDO_INTCORE, |
19 | AB8500_LDO_TVOUT, | 19 | AB8500_LDO_TVOUT, |
20 | AB8500_LDO_USB, | ||
20 | AB8500_LDO_AUDIO, | 21 | AB8500_LDO_AUDIO, |
21 | AB8500_LDO_ANAMIC1, | 22 | AB8500_LDO_ANAMIC1, |
22 | AB8500_LDO_ANAMIC2, | 23 | AB8500_LDO_ANAMIC2, |
@@ -24,4 +25,50 @@ enum ab8500_regulator_id { | |||
24 | AB8500_LDO_ANA, | 25 | AB8500_LDO_ANA, |
25 | AB8500_NUM_REGULATORS, | 26 | AB8500_NUM_REGULATORS, |
26 | }; | 27 | }; |
28 | |||
29 | /* AB8500 register initialization */ | ||
30 | struct ab8500_regulator_reg_init { | ||
31 | int id; | ||
32 | u8 value; | ||
33 | }; | ||
34 | |||
35 | #define INIT_REGULATOR_REGISTER(_id, _value) \ | ||
36 | { \ | ||
37 | .id = _id, \ | ||
38 | .value = _value, \ | ||
39 | } | ||
40 | |||
41 | /* AB8500 registers */ | ||
42 | enum ab8500_regulator_reg { | ||
43 | AB8500_REGUREQUESTCTRL2, | ||
44 | AB8500_REGUREQUESTCTRL3, | ||
45 | AB8500_REGUREQUESTCTRL4, | ||
46 | AB8500_REGUSYSCLKREQ1HPVALID1, | ||
47 | AB8500_REGUSYSCLKREQ1HPVALID2, | ||
48 | AB8500_REGUHWHPREQ1VALID1, | ||
49 | AB8500_REGUHWHPREQ1VALID2, | ||
50 | AB8500_REGUHWHPREQ2VALID1, | ||
51 | AB8500_REGUHWHPREQ2VALID2, | ||
52 | AB8500_REGUSWHPREQVALID1, | ||
53 | AB8500_REGUSWHPREQVALID2, | ||
54 | AB8500_REGUSYSCLKREQVALID1, | ||
55 | AB8500_REGUSYSCLKREQVALID2, | ||
56 | AB8500_REGUMISC1, | ||
57 | AB8500_VAUDIOSUPPLY, | ||
58 | AB8500_REGUCTRL1VAMIC, | ||
59 | AB8500_VPLLVANAREGU, | ||
60 | AB8500_VREFDDR, | ||
61 | AB8500_EXTSUPPLYREGU, | ||
62 | AB8500_VAUX12REGU, | ||
63 | AB8500_VRF1VAUX3REGU, | ||
64 | AB8500_VAUX1SEL, | ||
65 | AB8500_VAUX2SEL, | ||
66 | AB8500_VRF1VAUX3SEL, | ||
67 | AB8500_REGUCTRL2SPARE, | ||
68 | AB8500_REGUCTRLDISCH, | ||
69 | AB8500_REGUCTRLDISCH2, | ||
70 | AB8500_VSMPS1SEL1, | ||
71 | AB8500_NUM_REGULATOR_REGISTERS, | ||
72 | }; | ||
73 | |||
27 | #endif | 74 | #endif |
diff --git a/include/linux/regulator/consumer.h b/include/linux/regulator/consumer.h index 7954f6bd7edb..9e87c1cb7270 100644 --- a/include/linux/regulator/consumer.h +++ b/include/linux/regulator/consumer.h | |||
@@ -153,6 +153,8 @@ int regulator_list_voltage(struct regulator *regulator, unsigned selector); | |||
153 | int regulator_is_supported_voltage(struct regulator *regulator, | 153 | int regulator_is_supported_voltage(struct regulator *regulator, |
154 | int min_uV, int max_uV); | 154 | int min_uV, int max_uV); |
155 | int regulator_set_voltage(struct regulator *regulator, int min_uV, int max_uV); | 155 | int regulator_set_voltage(struct regulator *regulator, int min_uV, int max_uV); |
156 | int regulator_set_voltage_time(struct regulator *regulator, | ||
157 | int old_uV, int new_uV); | ||
156 | int regulator_get_voltage(struct regulator *regulator); | 158 | int regulator_get_voltage(struct regulator *regulator); |
157 | int regulator_sync_voltage(struct regulator *regulator); | 159 | int regulator_sync_voltage(struct regulator *regulator); |
158 | int regulator_set_current_limit(struct regulator *regulator, | 160 | int regulator_set_current_limit(struct regulator *regulator, |
diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h index b8ed16a33c47..6c433b89c80d 100644 --- a/include/linux/regulator/driver.h +++ b/include/linux/regulator/driver.h | |||
@@ -63,7 +63,11 @@ enum regulator_status { | |||
63 | * when running with the specified parameters. | 63 | * when running with the specified parameters. |
64 | * | 64 | * |
65 | * @enable_time: Time taken for the regulator voltage output voltage to | 65 | * @enable_time: Time taken for the regulator voltage output voltage to |
66 | * stabalise after being enabled, in microseconds. | 66 | * stabilise after being enabled, in microseconds. |
67 | * @set_voltage_time_sel: Time taken for the regulator voltage output voltage | ||
68 | * to stabilise after being set to a new value, in microseconds. | ||
69 | * The function provides the from and to voltage selector, the | ||
70 | * function should return the worst case. | ||
67 | * | 71 | * |
68 | * @set_suspend_voltage: Set the voltage for the regulator when the system | 72 | * @set_suspend_voltage: Set the voltage for the regulator when the system |
69 | * is suspended. | 73 | * is suspended. |
@@ -103,8 +107,11 @@ struct regulator_ops { | |||
103 | int (*set_mode) (struct regulator_dev *, unsigned int mode); | 107 | int (*set_mode) (struct regulator_dev *, unsigned int mode); |
104 | unsigned int (*get_mode) (struct regulator_dev *); | 108 | unsigned int (*get_mode) (struct regulator_dev *); |
105 | 109 | ||
106 | /* Time taken to enable the regulator */ | 110 | /* Time taken to enable or set voltage on the regulator */ |
107 | int (*enable_time) (struct regulator_dev *); | 111 | int (*enable_time) (struct regulator_dev *); |
112 | int (*set_voltage_time_sel) (struct regulator_dev *, | ||
113 | unsigned int old_selector, | ||
114 | unsigned int new_selector); | ||
108 | 115 | ||
109 | /* report regulator status ... most other accessors report | 116 | /* report regulator status ... most other accessors report |
110 | * control inputs, this reports results of combining inputs | 117 | * control inputs, this reports results of combining inputs |
diff --git a/include/linux/regulator/machine.h b/include/linux/regulator/machine.h index 761c745b9c24..c4c4fc45f856 100644 --- a/include/linux/regulator/machine.h +++ b/include/linux/regulator/machine.h | |||
@@ -186,6 +186,7 @@ struct regulator_init_data { | |||
186 | }; | 186 | }; |
187 | 187 | ||
188 | int regulator_suspend_prepare(suspend_state_t state); | 188 | int regulator_suspend_prepare(suspend_state_t state); |
189 | int regulator_suspend_finish(void); | ||
189 | 190 | ||
190 | #ifdef CONFIG_REGULATOR | 191 | #ifdef CONFIG_REGULATOR |
191 | void regulator_has_full_constraints(void); | 192 | void regulator_has_full_constraints(void); |
diff --git a/include/linux/sched.h b/include/linux/sched.h index b8369d522bf8..83bd2e2982fc 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -517,7 +517,7 @@ struct thread_group_cputimer { | |||
517 | struct autogroup; | 517 | struct autogroup; |
518 | 518 | ||
519 | /* | 519 | /* |
520 | * NOTE! "signal_struct" does not have it's own | 520 | * NOTE! "signal_struct" does not have its own |
521 | * locking, because a shared signal_struct always | 521 | * locking, because a shared signal_struct always |
522 | * implies a shared sighand_struct, so locking | 522 | * implies a shared sighand_struct, so locking |
523 | * sighand_struct is always a proper superset of | 523 | * sighand_struct is always a proper superset of |
diff --git a/include/linux/sunrpc/gss_api.h b/include/linux/sunrpc/gss_api.h index 5d8048beb051..332da61cf8b7 100644 --- a/include/linux/sunrpc/gss_api.h +++ b/include/linux/sunrpc/gss_api.h | |||
@@ -126,6 +126,9 @@ struct gss_api_mech *gss_mech_get_by_name(const char *); | |||
126 | /* Similar, but get by pseudoflavor. */ | 126 | /* Similar, but get by pseudoflavor. */ |
127 | struct gss_api_mech *gss_mech_get_by_pseudoflavor(u32); | 127 | struct gss_api_mech *gss_mech_get_by_pseudoflavor(u32); |
128 | 128 | ||
129 | /* Fill in an array with a list of supported pseudoflavors */ | ||
130 | int gss_mech_list_pseudoflavors(u32 *); | ||
131 | |||
129 | /* Just increments the mechanism's reference count and returns its input: */ | 132 | /* Just increments the mechanism's reference count and returns its input: */ |
130 | struct gss_api_mech * gss_mech_get(struct gss_api_mech *); | 133 | struct gss_api_mech * gss_mech_get(struct gss_api_mech *); |
131 | 134 | ||
diff --git a/include/linux/sysdev.h b/include/linux/sysdev.h index 1154c29f4101..8a75da551e4e 100644 --- a/include/linux/sysdev.h +++ b/include/linux/sysdev.h | |||
@@ -33,12 +33,13 @@ struct sysdev_class { | |||
33 | const char *name; | 33 | const char *name; |
34 | struct list_head drivers; | 34 | struct list_head drivers; |
35 | struct sysdev_class_attribute **attrs; | 35 | struct sysdev_class_attribute **attrs; |
36 | 36 | struct kset kset; | |
37 | #ifndef CONFIG_ARCH_NO_SYSDEV_OPS | ||
37 | /* Default operations for these types of devices */ | 38 | /* Default operations for these types of devices */ |
38 | int (*shutdown)(struct sys_device *); | 39 | int (*shutdown)(struct sys_device *); |
39 | int (*suspend)(struct sys_device *, pm_message_t state); | 40 | int (*suspend)(struct sys_device *, pm_message_t state); |
40 | int (*resume)(struct sys_device *); | 41 | int (*resume)(struct sys_device *); |
41 | struct kset kset; | 42 | #endif |
42 | }; | 43 | }; |
43 | 44 | ||
44 | struct sysdev_class_attribute { | 45 | struct sysdev_class_attribute { |
@@ -76,9 +77,11 @@ struct sysdev_driver { | |||
76 | struct list_head entry; | 77 | struct list_head entry; |
77 | int (*add)(struct sys_device *); | 78 | int (*add)(struct sys_device *); |
78 | int (*remove)(struct sys_device *); | 79 | int (*remove)(struct sys_device *); |
80 | #ifndef CONFIG_ARCH_NO_SYSDEV_OPS | ||
79 | int (*shutdown)(struct sys_device *); | 81 | int (*shutdown)(struct sys_device *); |
80 | int (*suspend)(struct sys_device *, pm_message_t state); | 82 | int (*suspend)(struct sys_device *, pm_message_t state); |
81 | int (*resume)(struct sys_device *); | 83 | int (*resume)(struct sys_device *); |
84 | #endif | ||
82 | }; | 85 | }; |
83 | 86 | ||
84 | 87 | ||
diff --git a/include/linux/writeback.h b/include/linux/writeback.h index 0ead399e08b5..17e7ccc322a5 100644 --- a/include/linux/writeback.h +++ b/include/linux/writeback.h | |||
@@ -9,7 +9,7 @@ | |||
9 | 9 | ||
10 | struct backing_dev_info; | 10 | struct backing_dev_info; |
11 | 11 | ||
12 | extern spinlock_t inode_lock; | 12 | extern spinlock_t inode_wb_list_lock; |
13 | 13 | ||
14 | /* | 14 | /* |
15 | * fs/fs-writeback.c | 15 | * fs/fs-writeback.c |