summaryrefslogtreecommitdiff
path: root/include/linux
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <greg@kroah.com>2003-05-07 11:10:22 -0700
committerGreg Kroah-Hartman <greg@kroah.com>2003-05-07 11:10:22 -0700
commit2f2a2dd085f6abd2a875401a99523a172108f496 (patch)
treeef751436a2ce57daf48d4ae8cf44126ba0f66cab /include/linux
parent29abb650987802c94d7464d0af20ec5d9f641284 (diff)
parentc495aaaf4d5dddc7e626e7e305bb7dac5e166b29 (diff)
Merge gregkh@kernel.bkbits.net:/home/gregkh/linux/linus-2.5
into kroah.com:/home/linux/linux/BK/gregkh-2.5
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/atm_he.h20
-rw-r--r--include/linux/atmbr2684.h101
-rw-r--r--include/linux/atmdev.h7
-rw-r--r--include/linux/blkpg.h6
-rw-r--r--include/linux/devfs_fs_kernel.h6
-rw-r--r--include/linux/file.h8
-rw-r--r--include/linux/fs.h6
-rw-r--r--include/linux/input.h3
-rw-r--r--include/linux/major.h1
-rw-r--r--include/linux/raid/md.h15
-rw-r--r--include/linux/rtnetlink.h12
-rw-r--r--include/linux/sched.h5
-rw-r--r--include/linux/security.h15
-rw-r--r--include/linux/slab.h1
-rw-r--r--include/linux/sunrpc/svc.h6
-rw-r--r--include/linux/swap.h8
-rw-r--r--include/linux/sysrq.h18
-rw-r--r--include/linux/tty.h3
18 files changed, 197 insertions, 44 deletions
diff --git a/include/linux/atm_he.h b/include/linux/atm_he.h
new file mode 100644
index 000000000000..2a7713b597cf
--- /dev/null
+++ b/include/linux/atm_he.h
@@ -0,0 +1,20 @@
+/* atm_he.h */
+
+#ifndef LINUX_ATM_HE_H
+#define LINUX_ATM_HE_H
+
+#include <linux/atmioc.h>
+
+#define HE_GET_REG _IOW('a', ATMIOC_SARPRV, struct atmif_sioc)
+
+#define HE_REGTYPE_PCI 1
+#define HE_REGTYPE_RCM 2
+#define HE_REGTYPE_TCM 3
+#define HE_REGTYPE_MBOX 4
+
+struct he_ioctl_reg {
+ unsigned addr, val;
+ char type;
+};
+
+#endif /* LINUX_ATM_HE_H */
diff --git a/include/linux/atmbr2684.h b/include/linux/atmbr2684.h
new file mode 100644
index 000000000000..7981b733f1ef
--- /dev/null
+++ b/include/linux/atmbr2684.h
@@ -0,0 +1,101 @@
+#ifndef _LINUX_ATMBR2684_H
+#define _LINUX_ATMBR2684_H
+
+#include <linux/atm.h>
+#include <linux/if.h> /* For IFNAMSIZ */
+
+/*
+ * Type of media we're bridging (ethernet, token ring, etc) Currently only
+ * ethernet is supported
+ */
+#define BR2684_MEDIA_ETHERNET (0) /* 802.3 */
+#define BR2684_MEDIA_802_4 (1) /* 802.4 */
+#define BR2684_MEDIA_TR (2) /* 802.5 - token ring */
+#define BR2684_MEDIA_FDDI (3)
+#define BR2684_MEDIA_802_6 (4) /* 802.6 */
+
+/*
+ * Is there FCS inbound on this VC? This currently isn't supported.
+ */
+#define BR2684_FCSIN_NO (0)
+#define BR2684_FCSIN_IGNORE (1)
+#define BR2684_FCSIN_VERIFY (2)
+
+/*
+ * Is there FCS outbound on this VC? This currently isn't supported.
+ */
+#define BR2684_FCSOUT_NO (0)
+#define BR2684_FCSOUT_SENDZERO (1)
+#define BR2684_FCSOUT_GENERATE (2)
+
+/*
+ * Does this VC include LLC encapsulation?
+ */
+#define BR2684_ENCAPS_VC (0) /* VC-mux */
+#define BR2684_ENCAPS_LLC (1)
+#define BR2684_ENCAPS_AUTODETECT (2) /* Unsuported */
+
+/*
+ * This is for the ATM_NEWBACKENDIF call - these are like socket families:
+ * the first element of the structure is the backend number and the rest
+ * is per-backend specific
+ */
+struct atm_newif_br2684 {
+ atm_backend_t backend_num; /* ATM_BACKEND_BR2684 */
+ int media; /* BR2684_MEDIA_* */
+ char ifname[IFNAMSIZ];
+ int mtu;
+};
+
+/*
+ * This structure is used to specify a br2684 interface - either by a
+ * positive integer (returned by ATM_NEWBACKENDIF) or the interfaces name
+ */
+#define BR2684_FIND_BYNOTHING (0)
+#define BR2684_FIND_BYNUM (1)
+#define BR2684_FIND_BYIFNAME (2)
+struct br2684_if_spec {
+ int method; /* BR2684_FIND_* */
+ union {
+ char ifname[IFNAMSIZ];
+ int devnum;
+ } spec;
+};
+
+/*
+ * This is for the ATM_SETBACKEND call - these are like socket families:
+ * the first element of the structure is the backend number and the rest
+ * is per-backend specific
+ */
+struct atm_backend_br2684 {
+ atm_backend_t backend_num; /* ATM_BACKEND_BR2684 */
+ struct br2684_if_spec ifspec;
+ int fcs_in; /* BR2684_FCSIN_* */
+ int fcs_out; /* BR2684_FCSOUT_* */
+ int fcs_auto; /* 1: fcs_{in,out} disabled if no FCS rx'ed */
+ int encaps; /* BR2684_ENCAPS_* */
+ int has_vpiid; /* 1: use vpn_id - Unsupported */
+ __u8 vpn_id[7];
+ int send_padding; /* unsupported */
+ int min_size; /* we will pad smaller packets than this */
+};
+
+/*
+ * The BR2684_SETFILT ioctl is an experimental mechanism for folks
+ * terminating a large number of IP-only vcc's. When netfilter allows
+ * efficient per-if in/out filters, this support will be removed
+ */
+struct br2684_filter {
+ __u32 prefix; /* network byte order */
+ __u32 netmask; /* 0 = disable filter */
+};
+
+struct br2684_filter_set {
+ struct br2684_if_spec ifspec;
+ struct br2684_filter filter;
+};
+
+#define BR2684_SETFILT _IOW( 'a', ATMIOC_BACKEND + 0, \
+ struct br2684_filter_set)
+
+#endif /* _LINUX_ATMBR2684_H */
diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h
index d6dce90537bf..d564eb34e7ce 100644
--- a/include/linux/atmdev.h
+++ b/include/linux/atmdev.h
@@ -96,6 +96,8 @@ struct atm_dev_stats {
/* enable or disable single-copy */
#define ATM_SETBACKEND _IOW('a',ATMIOC_SPECIAL+2,atm_backend_t)
/* set backend handler */
+#define ATM_NEWBACKENDIF _IOW('a',ATMIOC_SPECIAL+3,atm_backend_t)
+ /* use backend to make new if */
/*
* These are backend handkers that can be set via the ATM_SETBACKEND call
@@ -104,7 +106,7 @@ struct atm_dev_stats {
*/
#define ATM_BACKEND_RAW 0
#define ATM_BACKEND_PPP 1 /* PPPoATM - RFC2364 */
-#define ATM_BACKEND_BR_2684 2 /* Bridged RFC1483/2684 */
+#define ATM_BACKEND_BR2684 2 /* Bridged RFC1483/2684 */
/* for ATM_GETTYPE */
#define ATM_ITFTYP_LEN 8 /* maximum length of interface type name */
@@ -304,9 +306,6 @@ struct atm_vcc {
struct sockaddr_atmsvc local;
struct sockaddr_atmsvc remote;
void (*callback)(struct atm_vcc *vcc);
- struct sk_buff_head listenq;
- int backlog_quota; /* number of connection requests we */
- /* can still accept */
int reply; /* also used by ATMTCP */
/* Multipoint part ------------------------------------------------- */
struct atm_vcc *session; /* session VCC descriptor */
diff --git a/include/linux/blkpg.h b/include/linux/blkpg.h
index 571618972e30..15b61f7bf0b5 100644
--- a/include/linux/blkpg.h
+++ b/include/linux/blkpg.h
@@ -54,10 +54,4 @@ struct blkpg_partition {
char volname[BLKPG_VOLNAMELTH]; /* volume label */
};
-#ifdef __KERNEL__
-
-extern char * partition_name(dev_t dev);
-
-#endif /* __KERNEL__ */
-
#endif /* _LINUX_BLKPG_H */
diff --git a/include/linux/devfs_fs_kernel.h b/include/linux/devfs_fs_kernel.h
index 8ee76799308c..34ebe93c6194 100644
--- a/include/linux/devfs_fs_kernel.h
+++ b/include/linux/devfs_fs_kernel.h
@@ -27,6 +27,8 @@ extern devfs_handle_t devfs_register (devfs_handle_t dir, const char *name,
umode_t mode, void *ops, void *info);
extern int devfs_mk_bdev(dev_t dev, umode_t mode, const char *fmt, ...)
__attribute__((format (printf, 3, 4)));
+extern int devfs_mk_cdev(dev_t dev, umode_t mode, const char *fmt, ...)
+ __attribute__((format (printf, 3, 4)));
extern int devfs_mk_symlink(const char *name, const char *link);
extern int devfs_mk_dir(const char *fmt, ...)
__attribute__((format (printf, 1, 2)));
@@ -51,6 +53,10 @@ static inline int devfs_mk_bdev(dev_t dev, umode_t mode, const char *fmt, ...)
{
return 0;
}
+static inline int devfs_mk_cdev(dev_t dev, umode_t mode, const char *fmt, ...)
+{
+ return 0;
+}
static inline int devfs_mk_symlink (const char *name, const char *link)
{
return 0;
diff --git a/include/linux/file.h b/include/linux/file.h
index 6fbd27f755d5..a488f738f9f0 100644
--- a/include/linux/file.h
+++ b/include/linux/file.h
@@ -35,7 +35,15 @@ struct files_struct {
extern void FASTCALL(__fput(struct file *));
extern void FASTCALL(fput(struct file *));
+
+static inline void fput_light(struct file *file, int fput_needed)
+{
+ if (unlikely(fput_needed))
+ fput(file);
+}
+
extern struct file * FASTCALL(fget(unsigned int fd));
+extern struct file * FASTCALL(fget_light(unsigned int fd, int *fput_needed));
extern void FASTCALL(set_close_on_exec(unsigned int fd, int flag));
extern void put_filp(struct file *);
extern int get_unused_fd(void);
diff --git a/include/linux/fs.h b/include/linux/fs.h
index b9b2cf5b69e8..8d618555e772 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -206,8 +206,8 @@ extern int leases_enable, dir_notify_enable, lease_break_time;
#include <asm/semaphore.h>
#include <asm/byteorder.h>
+/* Used to be a macro which just called the function, now just a function */
extern void update_atime (struct inode *);
-#define UPDATE_ATIME(inode) update_atime (inode)
extern void inode_init(unsigned long);
extern void mnt_init(unsigned long);
@@ -1113,6 +1113,10 @@ extern int filemap_flush(struct address_space *);
extern int filemap_fdatawait(struct address_space *);
extern void sync_supers(void);
extern void sync_filesystems(int wait);
+extern void emergency_sync(void);
+extern void emergency_remount(void);
+extern int do_remount_sb(struct super_block *sb, int flags,
+ void *data, int force);
extern sector_t bmap(struct inode *, sector_t);
extern int setattr_mask(unsigned int);
extern int notify_change(struct dentry *, struct iattr *);
diff --git a/include/linux/input.h b/include/linux/input.h
index 9df2e226a1f2..ae71e3ea453e 100644
--- a/include/linux/input.h
+++ b/include/linux/input.h
@@ -894,9 +894,6 @@ void input_close_device(struct input_handle *);
int input_accept_process(struct input_handle *handle, struct file *file);
int input_flush_device(struct input_handle* handle, struct file* file);
-/* will go away once devfs_register gets sanitized */
-void input_register_minor(char *name, int minor, int minor_base);
-
void input_event(struct input_dev *dev, unsigned int type, unsigned int code, int value);
#define input_report_key(a,b,c) input_event(a, EV_KEY, b, !!(c))
diff --git a/include/linux/major.h b/include/linux/major.h
index 200e3653181b..0e2d112c89e5 100644
--- a/include/linux/major.h
+++ b/include/linux/major.h
@@ -27,6 +27,7 @@
#define MUX_MAJOR 11 /* PA-RISC only */
#define QIC02_TAPE_MAJOR 12
#define XT_DISK_MAJOR 13
+#define INPUT_MAJOR 13
#define SOUND_MAJOR 14
#define CDU31A_CDROM_MAJOR 15
#define JOYSTICK_MAJOR 15
diff --git a/include/linux/raid/md.h b/include/linux/raid/md.h
index 02ff30e5a187..98f0d1e27c4c 100644
--- a/include/linux/raid/md.h
+++ b/include/linux/raid/md.h
@@ -61,9 +61,20 @@
#define MD_MINOR_VERSION 90
#define MD_PATCHLEVEL_VERSION 0
-extern inline char * bdev_partition_name (struct block_device *bdev)
+/*
+ * XXX(hch): This function is broken. Someone who understands the md
+ * code needs to go through all callers, check whether bdev could
+ * be NULL and replace it with direct calls to bdevmame.
+ *
+ * This would also fix the returns buffer on stack issue nicely :)
+ */
+static inline const char *bdev_partition_name (struct block_device *bdev)
{
- return partition_name(bdev ? bdev->bd_dev : 0);
+ char b[BDEVNAME_SIZE];
+
+ if (!bdev)
+ return __bdevname(0, b);
+ return bdevname(bdev, b);
}
extern int register_md_personality (int p_num, mdk_personality_t *p);
extern int unregister_md_personality (int p_num);
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h
index 64b443d136a9..36573ba3c202 100644
--- a/include/linux/rtnetlink.h
+++ b/include/linux/rtnetlink.h
@@ -78,7 +78,7 @@ struct rtattr
/******************************************************************************
- * Definitions used in routing table administation.
+ * Definitions used in routing table administration.
****/
struct rtmsg
@@ -129,14 +129,14 @@ enum
#define RTPROT_STATIC 4 /* Route installed by administrator */
/* Values of protocol >= RTPROT_STATIC are not interpreted by kernel;
- they just passed from user and back as is.
+ they are just passed from user and back as is.
It will be used by hypothetical multiple routing daemons.
Note that protocol values should be standardized in order to
avoid conflicts.
*/
#define RTPROT_GATED 8 /* Apparently, GateD */
-#define RTPROT_RA 9 /* RDISC/ND router advertisments */
+#define RTPROT_RA 9 /* RDISC/ND router advertisements */
#define RTPROT_MRT 10 /* Merit MRT */
#define RTPROT_ZEBRA 11 /* Zebra */
#define RTPROT_BIRD 12 /* BIRD */
@@ -210,8 +210,8 @@ enum rtattr_type_t
/* RTM_MULTIPATH --- array of struct rtnexthop.
*
- * "struct rtnexthop" describres all necessary nexthop information,
- * i.e. parameters of path to a destination via this nextop.
+ * "struct rtnexthop" describes all necessary nexthop information,
+ * i.e. parameters of path to a destination via this nexthop.
*
* At the moment it is impossible to set different prefsrc, mtu, window
* and rtt for different paths from multipath.
@@ -485,7 +485,7 @@ enum
Comments:
- Combination IFF_BROADCAST|IFF_POINTOPOINT is invalid
- - If neiher of these three flags are set;
+ - If neither of these three flags are set;
the interface is NBMA.
- IFF_MULTICAST does not mean anything special:
diff --git a/include/linux/sched.h b/include/linux/sched.h
index ca3c22f974c2..01ea66352c74 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -294,6 +294,7 @@ extern struct user_struct root_user;
typedef struct prio_array prio_array_t;
struct backing_dev_info;
+struct reclaim_state;
/* POSIX.1b interval timer structure. */
struct k_itimer {
@@ -433,6 +434,10 @@ struct task_struct {
/* journalling filesystem info */
void *journal_info;
+
+/* VM state */
+ struct reclaim_state *reclaim_state;
+
struct dentry *proc_dentry;
struct backing_dev_info *backing_dev_info;
diff --git a/include/linux/security.h b/include/linux/security.h
index 6a98cb692bf8..4d052ad9759d 100644
--- a/include/linux/security.h
+++ b/include/linux/security.h
@@ -361,6 +361,9 @@ struct swap_info_struct;
* Check permission before setting the extended attributes
* @value identified by @name for @dentry.
* Return 0 if permission is granted.
+ * @inode_post_setxattr:
+ * Update inode security field after successful setxattr operation.
+ * @value identified by @name for @dentry.
* @inode_getxattr:
* Check permission before obtaining the extended attributes
* identified by @name for @dentry.
@@ -1036,6 +1039,8 @@ struct security_operations {
void (*inode_delete) (struct inode *inode);
int (*inode_setxattr) (struct dentry *dentry, char *name, void *value,
size_t size, int flags);
+ void (*inode_post_setxattr) (struct dentry *dentry, char *name, void *value,
+ size_t size, int flags);
int (*inode_getxattr) (struct dentry *dentry, char *name);
int (*inode_listxattr) (struct dentry *dentry);
int (*inode_removexattr) (struct dentry *dentry, char *name);
@@ -1464,6 +1469,12 @@ static inline int security_inode_setxattr (struct dentry *dentry, char *name,
return security_ops->inode_setxattr (dentry, name, value, size, flags);
}
+static inline void security_inode_post_setxattr (struct dentry *dentry, char *name,
+ void *value, size_t size, int flags)
+{
+ security_ops->inode_post_setxattr (dentry, name, value, size, flags);
+}
+
static inline int security_inode_getxattr (struct dentry *dentry, char *name)
{
return security_ops->inode_getxattr (dentry, name);
@@ -2063,6 +2074,10 @@ static inline int security_inode_setxattr (struct dentry *dentry, char *name,
return 0;
}
+static inline void security_inode_post_setxattr (struct dentry *dentry, char *name,
+ void *value, size_t size, int flags)
+{ }
+
static inline int security_inode_getxattr (struct dentry *dentry, char *name)
{
return 0;
diff --git a/include/linux/slab.h b/include/linux/slab.h
index 49374df2d450..b2b6f0498e2a 100644
--- a/include/linux/slab.h
+++ b/include/linux/slab.h
@@ -49,7 +49,6 @@ typedef struct kmem_cache_s kmem_cache_t;
/* prototypes */
extern void kmem_cache_init(void);
-extern void kmem_cache_sizes_init(void);
extern kmem_cache_t *kmem_find_general_cachep(size_t, int gfpflags);
extern kmem_cache_t *kmem_cache_create(const char *, size_t, size_t, unsigned long,
diff --git a/include/linux/sunrpc/svc.h b/include/linux/sunrpc/svc.h
index 6553637b70ee..09f7d54052eb 100644
--- a/include/linux/sunrpc/svc.h
+++ b/include/linux/sunrpc/svc.h
@@ -176,8 +176,10 @@ static inline int svc_take_page(struct svc_rqst *rqstp)
{
if (rqstp->rq_arghi <= rqstp->rq_argused)
return -ENOMEM;
- rqstp->rq_respages[rqstp->rq_resused++] =
- rqstp->rq_argpages[--rqstp->rq_arghi];
+ rqstp->rq_arghi--;
+ rqstp->rq_respages[rqstp->rq_resused] =
+ rqstp->rq_argpages[rqstp->rq_arghi];
+ rqstp->rq_resused++;
return 0;
}
diff --git a/include/linux/swap.h b/include/linux/swap.h
index 50f651d752cc..147e5bf40cbf 100644
--- a/include/linux/swap.h
+++ b/include/linux/swap.h
@@ -66,6 +66,14 @@ typedef struct {
unsigned long val;
} swp_entry_t;
+/*
+ * current->reclaim_state points to one of these when a task is running
+ * memory reclaim
+ */
+struct reclaim_state {
+ unsigned long reclaimed_slab;
+};
+
#ifdef __KERNEL__
struct address_space;
diff --git a/include/linux/sysrq.h b/include/linux/sysrq.h
index ee340cd26eaf..1acdb0bd4689 100644
--- a/include/linux/sysrq.h
+++ b/include/linux/sysrq.h
@@ -92,21 +92,3 @@ static inline int __reterr(void)
#define unregister_sysrq_key(ig,nore) __reterr()
#endif
-
-
-/* Deferred actions */
-
-extern int emergency_sync_scheduled;
-
-#define EMERG_SYNC 1
-#define EMERG_REMOUNT 2
-
-void do_emergency_sync(void);
-
-#ifdef CONFIG_MAGIC_SYSRQ
-#define CHECK_EMERGENCY_SYNC \
- if (emergency_sync_scheduled) \
- do_emergency_sync();
-#else
-#define CHECK_EMERGENCY_SYNC
-#endif
diff --git a/include/linux/tty.h b/include/linux/tty.h
index d7948e7ad0eb..fa5529ad5c6e 100644
--- a/include/linux/tty.h
+++ b/include/linux/tty.h
@@ -243,6 +243,7 @@ struct tty_flip_buffer {
#define L_PENDIN(tty) _L_FLAG((tty),PENDIN)
#define L_IEXTEN(tty) _L_FLAG((tty),IEXTEN)
+struct device;
/*
* Where all of the state associated with a tty is kept while the tty
* is open. Since the termios state should be kept even if the tty
@@ -380,7 +381,7 @@ extern void start_tty(struct tty_struct * tty);
extern int tty_register_ldisc(int disc, struct tty_ldisc *new_ldisc);
extern int tty_register_driver(struct tty_driver *driver);
extern int tty_unregister_driver(struct tty_driver *driver);
-extern void tty_register_device(struct tty_driver *driver, unsigned index);
+extern void tty_register_device(struct tty_driver *driver, unsigned index, struct device *dev);
extern void tty_unregister_device(struct tty_driver *driver, unsigned index);
extern int tty_read_raw_data(struct tty_struct *tty, unsigned char *bufp,
int buflen);