summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/compiler-gcc+.h1
-rw-r--r--include/linux/compiler-gcc3.h3
-rw-r--r--include/linux/compiler.h4
-rw-r--r--include/linux/dcookies.h2
-rw-r--r--include/linux/fb.h1
-rw-r--r--include/linux/fs.h2
-rw-r--r--include/linux/ftape.h1
-rw-r--r--include/linux/kallsyms.h2
-rw-r--r--include/linux/miscdevice.h8
-rw-r--r--include/linux/pci.h45
-rw-r--r--include/linux/pci_ids.h3
-rw-r--r--include/linux/pm.h2
-rw-r--r--include/linux/pnpbios.h1
-rw-r--r--include/linux/posix-timers.h22
-rw-r--r--include/linux/sched.h2
-rw-r--r--include/linux/suspend.h27
16 files changed, 98 insertions, 28 deletions
diff --git a/include/linux/compiler-gcc+.h b/include/linux/compiler-gcc+.h
index 94e6778873a7..5629cf5cd9c9 100644
--- a/include/linux/compiler-gcc+.h
+++ b/include/linux/compiler-gcc+.h
@@ -13,3 +13,4 @@
#define __attribute_used__ __attribute__((__used__))
#define __attribute_pure__ __attribute__((pure))
#define __attribute_const__ __attribute__((__const__))
+#define __must_check __attribute__((warn_unused_result))
diff --git a/include/linux/compiler-gcc3.h b/include/linux/compiler-gcc3.h
index 265dad4c3cb4..7965ae53d986 100644
--- a/include/linux/compiler-gcc3.h
+++ b/include/linux/compiler-gcc3.h
@@ -25,3 +25,6 @@
#if __GNUC_MINOR__ >= 1
#define noinline __attribute__((noinline))
#endif
+#if __GNUC_MINOR__ >= 4
+#define __must_check __attribute__((warn_unused_result))
+#endif
diff --git a/include/linux/compiler.h b/include/linux/compiler.h
index 151ab34a5b5f..22d83706f4b2 100644
--- a/include/linux/compiler.h
+++ b/include/linux/compiler.h
@@ -69,6 +69,10 @@ extern void __chk_user_ptr(void __user *);
# define __deprecated /* unimplemented */
#endif
+#ifndef __must_check
+#define __must_check
+#endif
+
/*
* Allow us to avoid 'defined but not used' warnings on functions and data,
* as well as force them to be emitted to the assembly file.
diff --git a/include/linux/dcookies.h b/include/linux/dcookies.h
index b2ae9692dc05..c28050136164 100644
--- a/include/linux/dcookies.h
+++ b/include/linux/dcookies.h
@@ -50,7 +50,7 @@ int get_dcookie(struct dentry * dentry, struct vfsmount * vfsmnt,
struct dcookie_user * dcookie_register(void)
{
- return 0;
+ return NULL;
}
void dcookie_unregister(struct dcookie_user * user)
diff --git a/include/linux/fb.h b/include/linux/fb.h
index 4e5f196258c8..67d506883572 100644
--- a/include/linux/fb.h
+++ b/include/linux/fb.h
@@ -532,6 +532,7 @@ struct fb_ops {
#define FBINFO_MISC_MODECHANGEUSER 0x10000 /* mode change request
from userspace */
+#define FBINFO_MISC_MODESWITCH 0x20000 /* mode switch */
struct fb_info {
int node;
diff --git a/include/linux/fs.h b/include/linux/fs.h
index f20e583bb41e..16ed87c94ce5 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1521,7 +1521,7 @@ extern int simple_pin_fs(char *name, struct vfsmount **mount, int *count);
extern void simple_release_fs(struct vfsmount **mount, int *count);
extern int inode_change_ok(struct inode *, struct iattr *);
-extern int inode_setattr(struct inode *, struct iattr *);
+extern int __must_check inode_setattr(struct inode *, struct iattr *);
extern void inode_update_time(struct inode *inode, int ctime_too);
diff --git a/include/linux/ftape.h b/include/linux/ftape.h
index 5774b1bfc045..c6b38d5b9186 100644
--- a/include/linux/ftape.h
+++ b/include/linux/ftape.h
@@ -195,7 +195,6 @@ typedef union {
/* some useful macro's
*/
-#define ABS(a) ((a) < 0 ? -(a) : (a))
#define NR_ITEMS(x) (int)(sizeof(x)/ sizeof(*x))
#endif /* __KERNEL__ */
diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h
index 87b9bbbb485e..1a5dce8f9346 100644
--- a/include/linux/kallsyms.h
+++ b/include/linux/kallsyms.h
@@ -7,6 +7,8 @@
#include <linux/config.h>
+#define KSYM_NAME_LEN 127
+
#ifdef CONFIG_KALLSYMS
/* Lookup the address for a symbol. Returns 0 if not found. */
unsigned long kallsyms_lookup_name(const char *name);
diff --git a/include/linux/miscdevice.h b/include/linux/miscdevice.h
index f62586335e48..041263ab10d9 100644
--- a/include/linux/miscdevice.h
+++ b/include/linux/miscdevice.h
@@ -26,14 +26,6 @@
#define MPT_MINOR 220
#define MISC_DYNAMIC_MINOR 255
-#define SGI_GRAPHICS_MINOR 146
-#define SGI_OPENGL_MINOR 147
-#define SGI_GFX_MINOR 148
-#define SGI_STREAMS_MOUSE 149
-#define SGI_STREAMS_KEYBOARD 150
-/* drivers/sgi/char/usema.c */
-#define SGI_USEMACLONE 151
-
#define TUN_MINOR 200
#define HPET_MINOR 228
diff --git a/include/linux/pci.h b/include/linux/pci.h
index 2662f462b7e6..abfb688bde5f 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -321,6 +321,50 @@
#define PCI_X_STATUS_266MHZ 0x40000000 /* 266 MHz capable */
#define PCI_X_STATUS_533MHZ 0x80000000 /* 533 MHz capable */
+/* PCI Express capability registers */
+
+#define PCI_EXP_FLAGS 2 /* Capabilities register */
+#define PCI_EXP_FLAGS_VERS 0x000f /* Capability version */
+#define PCI_EXP_FLAGS_TYPE 0x00f0 /* Device/Port type */
+#define PCI_EXP_TYPE_ENDPOINT 0x0 /* Express Endpoint */
+#define PCI_EXP_TYPE_LEG_END 0x1 /* Legacy Endpoint */
+#define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */
+#define PCI_EXP_TYPE_UPSTREAM 0x5 /* Upstream Port */
+#define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */
+#define PCI_EXP_TYPE_PCI_BRIDGE 0x7 /* PCI/PCI-X Bridge */
+#define PCI_EXP_FLAGS_SLOT 0x0100 /* Slot implemented */
+#define PCI_EXP_FLAGS_IRQ 0x3e00 /* Interrupt message number */
+#define PCI_EXP_DEVCAP 4 /* Device capabilities */
+#define PCI_EXP_DEVCAP_PAYLOAD 0x07 /* Max_Payload_Size */
+#define PCI_EXP_DEVCAP_PHANTOM 0x18 /* Phantom functions */
+#define PCI_EXP_DEVCAP_EXT_TAG 0x20 /* Extended tags */
+#define PCI_EXP_DEVCAP_L0S 0x1c0 /* L0s Acceptable Latency */
+#define PCI_EXP_DEVCAP_L1 0xe00 /* L1 Acceptable Latency */
+#define PCI_EXP_DEVCAP_ATN_BUT 0x1000 /* Attention Button Present */
+#define PCI_EXP_DEVCAP_ATN_IND 0x2000 /* Attention Indicator Present */
+#define PCI_EXP_DEVCAP_PWR_IND 0x4000 /* Power Indicator Present */
+#define PCI_EXP_DEVCAP_PWR_VAL 0x3fc0000 /* Slot Power Limit Value */
+#define PCI_EXP_DEVCAP_PWR_SCL 0xc000000 /* Slot Power Limit Scale */
+#define PCI_EXP_DEVCTL 8 /* Device Control */
+#define PCI_EXP_DEVCTL_CERE 0x0001 /* Correctable Error Reporting En. */
+#define PCI_EXP_DEVCTL_NFERE 0x0002 /* Non-Fatal Error Reporting Enable */
+#define PCI_EXP_DEVCTL_FERE 0x0004 /* Fatal Error Reporting Enable */
+#define PCI_EXP_DEVCTL_URRE 0x0008 /* Unsupported Request Reporting En. */
+#define PCI_EXP_DEVCTL_RELAX_EN 0x0010 /* Enable relaxed ordering */
+#define PCI_EXP_DEVCTL_PAYLOAD 0x00e0 /* Max_Payload_Size */
+#define PCI_EXP_DEVCTL_EXT_TAG 0x0100 /* Extended Tag Field Enable */
+#define PCI_EXP_DEVCTL_PHANTOM 0x0200 /* Phantom Functions Enable */
+#define PCI_EXP_DEVCTL_AUX_PME 0x0400 /* Auxiliary Power PM Enable */
+#define PCI_EXP_DEVCTL_NOSNOOP_EN 0x0800 /* Enable No Snoop */
+#define PCI_EXP_DEVCTL_READRQ 0x7000 /* Max_Read_Request_Size */
+#define PCI_EXP_DEVSTA 10 /* Device Status */
+#define PCI_EXP_DEVSTA_CED 0x01 /* Correctable Error Detected */
+#define PCI_EXP_DEVSTA_NFED 0x02 /* Non-Fatal Error Detected */
+#define PCI_EXP_DEVSTA_FED 0x04 /* Fatal Error Detected */
+#define PCI_EXP_DEVSTA_URD 0x08 /* Unsupported Request Detected */
+#define PCI_EXP_DEVSTA_AUXPD 0x10 /* AUX Power Detected */
+#define PCI_EXP_DEVSTA_TRPND 0x20 /* Transactions Pending */
+
/* Extended Capabilities (PCI-X 2.0 and Express) */
#define PCI_EXT_CAP_ID(header) (header & 0x0000ffff)
#define PCI_EXT_CAP_VER(header) ((header >> 16) & 0xf)
@@ -659,6 +703,7 @@ static inline struct pci_bus *pci_scan_bus(int bus, struct pci_ops *ops, void *s
}
int pci_scan_slot(struct pci_bus *bus, int devfn);
struct pci_dev * pci_scan_single_device(struct pci_bus *bus, int devfn);
+unsigned int pci_scan_child_bus(struct pci_bus *bus);
void pci_bus_add_devices(struct pci_bus *bus);
void pci_name_device(struct pci_dev *dev);
char *pci_class_name(u32 class);
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h
index 0a73d0d2c271..519ffaca6cf0 100644
--- a/include/linux/pci_ids.h
+++ b/include/linux/pci_ids.h
@@ -1711,6 +1711,9 @@
#define PCI_DEVICE_ID_SIIG_2S1P_20x_650 0x2061
#define PCI_DEVICE_ID_SIIG_2S1P_20x_850 0x2062
+#define PCI_VENDOR_ID_RADISYS 0x1331
+#define PCI_DEVICE_ID_RADISYS_ENP2611 0x0030
+
#define PCI_VENDOR_ID_DOMEX 0x134a
#define PCI_DEVICE_ID_DOMEX_DMX3191D 0x0001
diff --git a/include/linux/pm.h b/include/linux/pm.h
index 66e62c0df19c..d54bc441daff 100644
--- a/include/linux/pm.h
+++ b/include/linux/pm.h
@@ -159,7 +159,7 @@ static inline struct pm_dev *pm_register(pm_dev_t type,
unsigned long id,
pm_callback callback)
{
- return 0;
+ return NULL;
}
static inline void pm_unregister(struct pm_dev *dev) {}
diff --git a/include/linux/pnpbios.h b/include/linux/pnpbios.h
index 0720cd72d63a..0a282ac1f6b2 100644
--- a/include/linux/pnpbios.h
+++ b/include/linux/pnpbios.h
@@ -141,6 +141,7 @@ extern int pnp_bios_isapnp_config (struct pnp_isa_config_struc *data);
extern int pnp_bios_escd_info (struct escd_info_struc *data);
extern int pnp_bios_read_escd (char *data, u32 nvram_base);
extern int pnp_bios_dock_station_info(struct pnp_docking_station_info *data);
+#define needed 0
#if needed
extern int pnp_bios_get_event (u16 *message);
extern int pnp_bios_send_message (u16 message);
diff --git a/include/linux/posix-timers.h b/include/linux/posix-timers.h
index 637d2fb19012..ec4910e37c65 100644
--- a/include/linux/posix-timers.h
+++ b/include/linux/posix-timers.h
@@ -1,8 +1,16 @@
#ifndef _linux_POSIX_TIMERS_H
#define _linux_POSIX_TIMERS_H
+#include <linux/spinlock.h>
+#include <linux/list.h>
+
+struct k_clock_abs {
+ struct list_head list;
+ spinlock_t lock;
+};
struct k_clock {
int res; /* in nano seconds */
+ struct k_clock_abs *abs_struct;
int (*clock_set) (struct timespec * tp);
int (*clock_get) (struct timespec * tp);
int (*nsleep) (int flags,
@@ -23,8 +31,14 @@ struct now_struct {
#define posix_time_before(timer, now) \
time_before((timer)->expires, (now)->jiffies)
-#define posix_bump_timer(timr) do { \
- (timr)->it_timer.expires += (timr)->it_incr; \
- (timr)->it_overrun++; \
- }while (0)
+#define posix_bump_timer(timr, now) \
+ do { \
+ long delta, orun; \
+ delta = now.jiffies - (timr)->it_timer.expires; \
+ if (delta >= 0) { \
+ orun = 1 + (delta / (timr)->it_incr); \
+ (timr)->it_timer.expires += orun * (timr)->it_incr; \
+ (timr)->it_overrun += orun; \
+ } \
+ }while (0)
#endif
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 6eb3b3afa1a6..4dcbe972d5b5 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -343,6 +343,8 @@ struct k_itimer {
struct task_struct *it_process; /* process to send signal to */
struct timer_list it_timer;
struct sigqueue *sigq; /* signal queue entry. */
+ struct list_head abs_timer_entry; /* clock abs_timer_list */
+ struct timespec wall_to_prev; /* wall_to_monotonic used when set */
};
diff --git a/include/linux/suspend.h b/include/linux/suspend.h
index 7e4409b7c55b..d0955f06c9b4 100644
--- a/include/linux/suspend.h
+++ b/include/linux/suspend.h
@@ -67,24 +67,27 @@ extern int pm_prepare_console(void);
extern void pm_restore_console(void);
#else
-static inline void refrigerator(unsigned long flag)
-{
-
-}
-static inline int freeze_processes(void)
-{
- return 0;
-}
-static inline void thaw_processes(void)
-{
-
-}
+static inline void refrigerator(unsigned long flag) {}
#endif /* CONFIG_PM */
+#ifdef CONFIG_SMP
+extern void disable_nonboot_cpus(void);
+extern void enable_nonboot_cpus(void);
+#else
+static inline void disable_nonboot_cpus(void) {}
+static inline void enable_nonboot_cpus(void) {}
+#endif
+
asmlinkage void do_magic(int is_resume);
asmlinkage void do_magic_resume_1(void);
asmlinkage void do_magic_resume_2(void);
asmlinkage void do_magic_suspend_1(void);
asmlinkage void do_magic_suspend_2(void);
+void save_processor_state(void);
+void restore_processor_state(void);
+struct saved_context;
+void __save_processor_state(struct saved_context *ctxt);
+void __restore_processor_state(struct saved_context *ctxt);
+
#endif /* _LINUX_SWSUSP_H */