summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <greg@kroah.com>2003-09-04 19:49:13 -0700
committerGreg Kroah-Hartman <greg@kroah.com>2003-09-04 19:49:13 -0700
commit24467ec6c2fa857c332d4bfdd2c92f2507d16a86 (patch)
treee9b561d5c7fb0b1dd7af2b4c6ec778b82002ae11 /include/linux
parent7c9481c3d31dab43cf053ebeab556264e608b4ae (diff)
parent863003968458edf00e2ebdad49f68040203d886d (diff)
Merge kroah.com:/home/linux/BK/bleed-2.5
into kroah.com:/home/linux/BK/gregkh-2.6
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/blkdev.h11
-rw-r--r--include/linux/device.h5
-rw-r--r--include/linux/elevator.h16
-rw-r--r--include/linux/fs.h4
-rw-r--r--include/linux/genhd.h2
-rw-r--r--include/linux/hiddev.h2
-rw-r--r--include/linux/ide.h1
-rw-r--r--include/linux/if_frad.h4
-rw-r--r--include/linux/initrd.h2
-rw-r--r--include/linux/isdn.h9
-rw-r--r--include/linux/isdn/capilli.h2
-rw-r--r--include/linux/kernel.h2
-rw-r--r--include/linux/kmod.h2
-rw-r--r--include/linux/miscdevice.h5
-rw-r--r--include/linux/mm.h1
-rw-r--r--include/linux/netdevice.h4
-rw-r--r--include/linux/page-flags.h2
-rw-r--r--include/linux/rtc.h1
-rw-r--r--include/linux/rtnetlink.h3
-rw-r--r--include/linux/sctp.h9
-rw-r--r--include/linux/skbuff.h2
-rw-r--r--include/linux/sysctl.h8
-rw-r--r--include/linux/tty_ldisc.h3
-rw-r--r--include/linux/usb.h2
-rw-r--r--include/linux/vcache.h26
25 files changed, 71 insertions, 57 deletions
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
index 99dbf0d24eaf..285fd86e2b48 100644
--- a/include/linux/blkdev.h
+++ b/include/linux/blkdev.h
@@ -12,6 +12,8 @@
#include <linux/wait.h>
#include <linux/mempool.h>
#include <linux/bio.h>
+#include <linux/module.h>
+#include <linux/stringify.h>
#include <asm/scatterlist.h>
@@ -268,7 +270,7 @@ struct request_queue
* Together with queue_head for cacheline sharing
*/
struct list_head queue_head;
- struct list_head *last_merge;
+ struct request *last_merge;
elevator_t elevator;
/*
@@ -671,6 +673,11 @@ void kblockd_flush(void);
} \
)
#endif
-
+
+#define MODULE_ALIAS_BLOCKDEV(major,minor) \
+ MODULE_ALIAS("block-major-" __stringify(major) "-" __stringify(minor))
+#define MODULE_ALIAS_BLOCKDEV_MAJOR(major) \
+ MODULE_ALIAS("block-major-" __stringify(major) "-*")
+
#endif
diff --git a/include/linux/device.h b/include/linux/device.h
index 8d6266f2e3c3..96043c0f46c5 100644
--- a/include/linux/device.h
+++ b/include/linux/device.h
@@ -398,4 +398,9 @@ extern void firmware_unregister(struct subsystem *);
#define dev_warn(dev, format, arg...) \
dev_printk(KERN_WARNING , dev , format , ## arg)
+/* Create alias, so I can be autoloaded. */
+#define MODULE_ALIAS_CHARDEV(major,minor) \
+ MODULE_ALIAS("char-major-" __stringify(major) "-" __stringify(minor))
+#define MODULE_ALIAS_CHARDEV_MAJOR(major) \
+ MODULE_ALIAS("char-major-" __stringify(major) "-*")
#endif /* _DEVICE_H_ */
diff --git a/include/linux/elevator.h b/include/linux/elevator.h
index ac30ae089069..e43d670c1371 100644
--- a/include/linux/elevator.h
+++ b/include/linux/elevator.h
@@ -1,7 +1,7 @@
#ifndef _LINUX_ELEVATOR_H
#define _LINUX_ELEVATOR_H
-typedef int (elevator_merge_fn) (request_queue_t *, struct list_head **,
+typedef int (elevator_merge_fn) (request_queue_t *, struct request **,
struct bio *);
typedef void (elevator_merge_req_fn) (request_queue_t *, struct request *, struct request *);
@@ -10,7 +10,7 @@ typedef void (elevator_merged_fn) (request_queue_t *, struct request *);
typedef struct request *(elevator_next_req_fn) (request_queue_t *);
-typedef void (elevator_add_req_fn) (request_queue_t *, struct request *, struct list_head *);
+typedef void (elevator_add_req_fn) (request_queue_t *, struct request *, int);
typedef int (elevator_queue_empty_fn) (request_queue_t *);
typedef void (elevator_remove_req_fn) (request_queue_t *, struct request *);
typedef void (elevator_requeue_req_fn) (request_queue_t *, struct request *);
@@ -62,7 +62,7 @@ struct elevator_s
*/
extern void elv_add_request(request_queue_t *, struct request *, int, int);
extern void __elv_add_request(request_queue_t *, struct request *, int, int);
-extern int elv_merge(request_queue_t *, struct list_head **, struct bio *);
+extern int elv_merge(request_queue_t *, struct request **, struct bio *);
extern void elv_merge_requests(request_queue_t *, struct request *,
struct request *);
extern void elv_merged_request(request_queue_t *, struct request *);
@@ -79,9 +79,6 @@ extern void elv_completed_request(request_queue_t *, struct request *);
extern int elv_set_request(request_queue_t *, struct request *, int);
extern void elv_put_request(request_queue_t *, struct request *);
-#define __elv_add_request_pos(q, rq, pos) \
- (q)->elevator.elevator_add_req_fn((q), (rq), (pos))
-
/*
* noop I/O scheduler. always merges, always inserts new request at tail
*/
@@ -111,4 +108,11 @@ extern inline int elv_try_last_merge(request_queue_t *, struct bio *);
#define ELEVATOR_FRONT_MERGE 1
#define ELEVATOR_BACK_MERGE 2
+/*
+ * Insertion selection
+ */
+#define ELEVATOR_INSERT_FRONT 1
+#define ELEVATOR_INSERT_BACK 2
+#define ELEVATOR_INSERT_SORT 3
+
#endif
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 936f34c469dd..87ae270bf96c 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -1391,10 +1391,6 @@ extern int simple_fill_super(struct super_block *, int, struct tree_descr *);
extern int simple_pin_fs(char *name, struct vfsmount **mount, int *count);
extern void simple_release_fs(struct vfsmount **mount, int *count);
-#ifdef CONFIG_BLK_DEV_INITRD
-extern unsigned int real_root_dev;
-#endif
-
extern int inode_change_ok(struct inode *, struct iattr *);
extern int inode_setattr(struct inode *, struct iattr *);
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index 460ef0362ab5..13e0933ccbc7 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -75,7 +75,6 @@ struct disk_stats {
unsigned read_merges, write_merges;
unsigned read_ticks, write_ticks;
unsigned io_ticks;
- int in_flight;
unsigned time_in_queue;
};
@@ -101,6 +100,7 @@ struct gendisk {
unsigned sync_io; /* RAID */
unsigned long stamp, stamp_idle;
+ int in_flight;
#ifdef CONFIG_SMP
struct disk_stats *dkstats;
#else
diff --git a/include/linux/hiddev.h b/include/linux/hiddev.h
index dc6d8dd843b5..9e6d27476a74 100644
--- a/include/linux/hiddev.h
+++ b/include/linux/hiddev.h
@@ -207,7 +207,7 @@ void hiddev_hid_event(struct hid_device *hid, struct hid_field *field,
struct hid_usage *usage, __s32 value, struct pt_regs *regs);
void hiddev_report_event(struct hid_device *hid, struct hid_report *report);
int __init hiddev_init(void);
-void __exit hiddev_exit(void);
+void hiddev_exit(void);
#else
static inline int hiddev_connect(struct hid_device *hid) { return -1; }
static inline void hiddev_disconnect(struct hid_device *hid) { }
diff --git a/include/linux/ide.h b/include/linux/ide.h
index 4664fd44a986..e7c50528e10e 100644
--- a/include/linux/ide.h
+++ b/include/linux/ide.h
@@ -1218,7 +1218,6 @@ typedef struct ide_driver_s {
const char *version;
u8 media;
unsigned busy : 1;
- unsigned supports_dma : 1;
unsigned supports_dsc_overlap : 1;
int (*cleanup)(ide_drive_t *);
int (*shutdown)(ide_drive_t *);
diff --git a/include/linux/if_frad.h b/include/linux/if_frad.h
index 975aad03d762..3d9fc5d43803 100644
--- a/include/linux/if_frad.h
+++ b/include/linux/if_frad.h
@@ -155,9 +155,11 @@ struct frhdr
struct dlci_local
{
struct net_device_stats stats;
- struct net_device *slave;
+ struct net_device *master;
+ struct net_device *slave;
struct dlci_conf config;
int configured;
+ struct list_head list;
/* callback function */
void (*receive)(struct sk_buff *skb, struct net_device *);
diff --git a/include/linux/initrd.h b/include/linux/initrd.h
index 32452d53dac3..55289d261b4f 100644
--- a/include/linux/initrd.h
+++ b/include/linux/initrd.h
@@ -16,3 +16,5 @@ extern int initrd_below_start_ok;
/* free_initrd_mem always gets called with the next two as arguments.. */
extern unsigned long initrd_start, initrd_end;
extern void free_initrd_mem(unsigned long, unsigned long);
+
+extern unsigned int real_root_dev;
diff --git a/include/linux/isdn.h b/include/linux/isdn.h
index ecd0f5394e9e..35a2ef6e2452 100644
--- a/include/linux/isdn.h
+++ b/include/linux/isdn.h
@@ -258,13 +258,13 @@ typedef struct {
* variables. Of course, we need to check skb_headroom prior to
* any access.
*/
-typedef struct isdn_audio_skb {
+typedef struct _isdnaudio_header {
unsigned short dle_count;
unsigned char lock;
-} isdn_audio_skb;
+} isdnaudio_header;
-#define ISDN_AUDIO_SKB_DLECOUNT(skb) (((isdn_audio_skb*)skb->head)->dle_count)
-#define ISDN_AUDIO_SKB_LOCK(skb) (((isdn_audio_skb*)skb->head)->lock)
+#define ISDN_AUDIO_SKB_DLECOUNT(skb) (((isdnaudio_header*)skb->head)->dle_count)
+#define ISDN_AUDIO_SKB_LOCK(skb) (((isdnaudio_header*)skb->head)->lock)
#endif
/* Private data of AT-command-interpreter */
@@ -291,6 +291,7 @@ typedef struct atemu {
/* Private data (similar to async_struct in <linux/serial.h>) */
typedef struct modem_info {
int magic;
+ struct module *owner;
int flags; /* defined in tty.h */
int x_char; /* xon/xoff character */
int mcr; /* Modem control register */
diff --git a/include/linux/isdn/capilli.h b/include/linux/isdn/capilli.h
index cf501356aba4..d4747a9cee9c 100644
--- a/include/linux/isdn/capilli.h
+++ b/include/linux/isdn/capilli.h
@@ -54,7 +54,7 @@ struct capi_ctr {
int count, int *eof, struct capi_ctr *card);
/* filled in before calling ready callback */
- u8 manu[CAPI_MANUFACTURER_LEN]; /* CAPI_GET_MANUFACTURER */
+ u8 manu[CAPI_MANUFACTURER_LEN]; /* CAPI_GET_MANUFACTURER */
capi_version version; /* CAPI_GET_VERSION */
capi_profile profile; /* CAPI_GET_PROFILE */
u8 serial[CAPI_SERIAL_LEN]; /* CAPI_GET_SERIAL */
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index b0aebfeda888..b2d17ea0dac0 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -52,8 +52,10 @@ struct completion;
#ifdef CONFIG_DEBUG_SPINLOCK_SLEEP
void __might_sleep(char *file, int line);
#define might_sleep() __might_sleep(__FILE__, __LINE__)
+#define might_sleep_if(cond) do { if (unlikely(cond)) might_sleep(); } while (0)
#else
#define might_sleep() do {} while(0)
+#define might_sleep_if(cond) do {} while (0)
#endif
extern struct notifier_block *panic_notifier_list;
diff --git a/include/linux/kmod.h b/include/linux/kmod.h
index 7fa02a737518..8412faeea0f7 100644
--- a/include/linux/kmod.h
+++ b/include/linux/kmod.h
@@ -29,7 +29,7 @@ extern int request_module(const char * name, ...) __attribute__ ((format (printf
static inline int request_module(const char * name, ...) { return -ENOSYS; }
#endif
-#define try_then_request_module(x, mod...) ((x) ?: request_module(mod), (x))
+#define try_then_request_module(x, mod...) ((x) ?: (request_module(mod), (x)))
extern int call_usermodehelper(char *path, char *argv[], char *envp[], int wait);
#ifdef CONFIG_HOTPLUG
diff --git a/include/linux/miscdevice.h b/include/linux/miscdevice.h
index 159f8ab3df80..23b095889111 100644
--- a/include/linux/miscdevice.h
+++ b/include/linux/miscdevice.h
@@ -1,5 +1,7 @@
#ifndef _LINUX_MISCDEVICE_H
#define _LINUX_MISCDEVICE_H
+#include <linux/module.h>
+#include <linux/major.h>
#define BUSMOUSE_MINOR 0
#define PSMOUSE_MINOR 1
@@ -48,4 +50,7 @@ struct miscdevice
extern int misc_register(struct miscdevice * misc);
extern int misc_deregister(struct miscdevice * misc);
+#define MODULE_ALIAS_MISCDEV(minor) \
+ MODULE_ALIAS("char-major-" __stringify(MISC_MAJOR) \
+ "-" __stringify(minor))
#endif
diff --git a/include/linux/mm.h b/include/linux/mm.h
index 445fc58751c7..9f9743146b54 100644
--- a/include/linux/mm.h
+++ b/include/linux/mm.h
@@ -110,6 +110,7 @@ struct vm_area_struct {
#define VM_RESERVED 0x00080000 /* Don't unmap it from swap_out */
#define VM_ACCOUNT 0x00100000 /* Is a VM accounted object */
#define VM_HUGETLB 0x00400000 /* Huge TLB Page VM */
+#define VM_NONLINEAR 0x00800000 /* Is non-linear (remap_file_pages) */
#ifndef VM_STACK_DEFAULT_FLAGS /* arch can override this */
#define VM_STACK_DEFAULT_FLAGS VM_DATA_DEFAULT_FLAGS
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index dfc1aa47f35c..c99e53fed30e 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -37,9 +37,6 @@
#ifdef __KERNEL__
#include <linux/config.h>
-#ifdef CONFIG_NET_PROFILE
-#include <net/profile.h>
-#endif
struct divert_blk;
struct vlan_group;
@@ -498,6 +495,7 @@ extern struct net_device loopback_dev; /* The loopback */
extern struct net_device *dev_base; /* All devices */
extern rwlock_t dev_base_lock; /* Device list lock */
+extern void probe_old_netdevs(void);
extern int netdev_boot_setup_add(char *name, struct ifmap *map);
extern int netdev_boot_setup_check(struct net_device *dev);
extern struct net_device *dev_getbyhwaddr(unsigned short type, char *hwaddr);
diff --git a/include/linux/page-flags.h b/include/linux/page-flags.h
index d4fd6bb3ca43..006fde0295d5 100644
--- a/include/linux/page-flags.h
+++ b/include/linux/page-flags.h
@@ -191,6 +191,8 @@ extern void get_full_page_state(struct page_state *ret);
#define PageSlab(page) test_bit(PG_slab, &(page)->flags)
#define SetPageSlab(page) set_bit(PG_slab, &(page)->flags)
#define ClearPageSlab(page) clear_bit(PG_slab, &(page)->flags)
+#define TestClearPageSlab(page) test_and_clear_bit(PG_slab, &(page)->flags)
+#define TestSetPageSlab(page) test_and_set_bit(PG_slab, &(page)->flags)
#ifdef CONFIG_HIGHMEM
#define PageHighMem(page) test_bit(PG_highmem, &(page)->flags)
diff --git a/include/linux/rtc.h b/include/linux/rtc.h
index 27c38b240736..e1aaf1fac8e0 100644
--- a/include/linux/rtc.h
+++ b/include/linux/rtc.h
@@ -101,6 +101,7 @@ typedef struct rtc_task {
int rtc_register(rtc_task_t *task);
int rtc_unregister(rtc_task_t *task);
int rtc_control(rtc_task_t *t, unsigned int cmd, unsigned long arg);
+void rtc_get_rtc_time(struct rtc_time *rtc_tm);
#endif /* __KERNEL__ */
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h
index 3e3a26916a12..fd8b35209ccc 100644
--- a/include/linux/rtnetlink.h
+++ b/include/linux/rtnetlink.h
@@ -3,9 +3,6 @@
#include <linux/netlink.h>
-#define RTNL_DEBUG 1
-
-
/****
* Routing/neighbour discovery messages.
****/
diff --git a/include/linux/sctp.h b/include/linux/sctp.h
index 6ebaff34570c..6131e3c9aa45 100644
--- a/include/linux/sctp.h
+++ b/include/linux/sctp.h
@@ -1,7 +1,7 @@
/* SCTP kernel reference Implementation
+ * (C) Copyright IBM Corp. 2001, 2003
* Copyright (c) 1999-2000 Cisco, Inc.
* Copyright (c) 1999-2001 Motorola, Inc.
- * Copyright (c) 2001-2002 International Business Machines, Corp.
* Copyright (c) 2001 Intel Corp.
* Copyright (c) 2001 Nokia, Inc.
* Copyright (c) 2001 La Monte H.P. Yarroll
@@ -42,6 +42,8 @@
* randall@sctp.chicago.il.us
* kmorneau@cisco.com
* qxie1@email.mot.com
+ * Sridhar Samudrala <sri@us.ibm.com>
+ * Kevin Gao <kevin.gao@intel.com>
*
* Any bugs reported given to us we will try to fix... any fixes shared will
* be incorporated into the next SCTP release.
@@ -507,6 +509,11 @@ typedef struct sctp_cwr_chunk {
* The ASCONF Parameter Response is used in the ASCONF-ACK to
* report status of ASCONF processing.
*/
+typedef struct sctp_addip_param {
+ sctp_paramhdr_t param_hdr;
+ __u32 crr_id;
+}sctp_addip_param_t __attribute__((packed));
+
typedef struct sctp_addiphdr {
__u32 serial;
__u8 params[0];
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index a372186cb6d6..4b5f057f8bfb 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -389,6 +389,7 @@ static inline int skb_shared(struct sk_buff *skb)
*/
static inline struct sk_buff *skb_share_check(struct sk_buff *skb, int pri)
{
+ might_sleep_if(pri & __GFP_WAIT);
if (skb_shared(skb)) {
struct sk_buff *nskb = skb_clone(skb, pri);
kfree_skb(skb);
@@ -419,6 +420,7 @@ static inline struct sk_buff *skb_share_check(struct sk_buff *skb, int pri)
*/
static inline struct sk_buff *skb_unshare(struct sk_buff *skb, int pri)
{
+ might_sleep_if(pri & __GFP_WAIT);
if (skb_cloned(skb)) {
struct sk_buff *nskb = skb_copy(skb, pri);
kfree_skb(skb); /* Free our shared copy */
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h
index c48edf4a551e..38c43d95a616 100644
--- a/include/linux/sysctl.h
+++ b/include/linux/sysctl.h
@@ -603,7 +603,8 @@ enum {
DEV_HWMON=2,
DEV_PARPORT=3,
DEV_RAID=4,
- DEV_MAC_HID=5
+ DEV_MAC_HID=5,
+ DEV_SCSI=6,
};
/* /proc/sys/dev/cdrom */
@@ -664,6 +665,11 @@ enum {
DEV_MAC_HID_ADB_MOUSE_SENDS_KEYCODES=6
};
+/* /proc/sys/dev/scsi */
+enum {
+ DEV_SCSI_LOGGING_LEVEL=1,
+};
+
/* /proc/sys/abi */
enum
{
diff --git a/include/linux/tty_ldisc.h b/include/linux/tty_ldisc.h
index ac8ac46845ba..c851b7dc997e 100644
--- a/include/linux/tty_ldisc.h
+++ b/include/linux/tty_ldisc.h
@@ -138,4 +138,7 @@ struct tty_ldisc {
#define LDISC_FLAG_DEFINED 0x00000001
+#define MODULE_ALIAS_LDISC(ldisc) \
+ MODULE_ALIAS("tty-ldisc-" __stringify(ldisc))
+
#endif /* _LINUX_TTY_LDISC_H */
diff --git a/include/linux/usb.h b/include/linux/usb.h
index 471c37f5188b..a20b33d953aa 100644
--- a/include/linux/usb.h
+++ b/include/linux/usb.h
@@ -329,7 +329,7 @@ static inline int usb_make_path (struct usb_device *dev, char *buf, size_t size)
{
int actual;
actual = snprintf (buf, size, "usb-%s-%s", dev->bus->bus_name, dev->devpath);
- return (actual >= size) ? -1 : actual;
+ return (actual >= (int)size) ? -1 : actual;
}
/*-------------------------------------------------------------------------*/
diff --git a/include/linux/vcache.h b/include/linux/vcache.h
deleted file mode 100644
index 5708fe6a908a..000000000000
--- a/include/linux/vcache.h
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * virtual => physical mapping cache support.
- */
-#ifndef _LINUX_VCACHE_H
-#define _LINUX_VCACHE_H
-
-typedef struct vcache_s {
- unsigned long address;
- struct mm_struct *mm;
- struct list_head hash_entry;
- void (*callback)(struct vcache_s *data, struct page *new_page);
-} vcache_t;
-
-extern spinlock_t vcache_lock;
-
-extern void __attach_vcache(vcache_t *vcache,
- unsigned long address,
- struct mm_struct *mm,
- void (*callback)(struct vcache_s *data, struct page *new_page));
-
-extern void __detach_vcache(vcache_t *vcache);
-
-extern void invalidate_vcache(unsigned long address, struct mm_struct *mm,
- struct page *new_page);
-
-#endif