summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/adfs_fs_fs.h177
-rw-r--r--include/linux/byteorder/generic.h11
-rw-r--r--include/linux/byteorder/swab.h9
-rw-r--r--include/linux/byteorder/swabb.h4
-rw-r--r--include/linux/coda.h6
-rw-r--r--include/linux/coda_fs_i.h2
-rw-r--r--include/linux/coda_linux.h6
-rw-r--r--include/linux/cyclades.h7
-rw-r--r--include/linux/file.h8
-rw-r--r--include/linux/fs.h20
-rw-r--r--include/linux/genhd.h2
-rw-r--r--include/linux/head.h28
-rw-r--r--include/linux/if.h2
-rw-r--r--include/linux/if_packet.h7
-rw-r--r--include/linux/in6.h32
-rw-r--r--include/linux/ipv6.h44
-rw-r--r--include/linux/ipv6_route.h1
-rw-r--r--include/linux/iso_fs_sb.h1
-rw-r--r--include/linux/kbd_ll.h5
-rw-r--r--include/linux/nbd.h3
-rw-r--r--include/linux/netdevice.h3
-rw-r--r--include/linux/netlink.h47
-rw-r--r--include/linux/nfsd/nfsfh.h23
-rw-r--r--include/linux/notifier.h1
-rw-r--r--include/linux/pci.h7
-rw-r--r--include/linux/proc_fs.h2
-rw-r--r--include/linux/qnx4_fs.h123
-rw-r--r--include/linux/qnx4_fs_i.h38
-rw-r--r--include/linux/qnx4_fs_sb.h27
-rw-r--r--include/linux/qnxtypes.h28
-rw-r--r--include/linux/rtnetlink.h65
-rw-r--r--include/linux/sched.h1
-rw-r--r--include/linux/shm.h1
-rw-r--r--include/linux/skbuff.h13
-rw-r--r--include/linux/smb_fs.h1
-rw-r--r--include/linux/smb_mount.h11
-rw-r--r--include/linux/socket.h19
-rw-r--r--include/linux/sockios.h1
-rw-r--r--include/linux/sound.h2
-rw-r--r--include/linux/string.h1
-rw-r--r--include/linux/sunrpc/clnt.h3
-rw-r--r--include/linux/sunrpc/sched.h2
-rw-r--r--include/linux/sunrpc/xprt.h10
-rw-r--r--include/linux/swap.h42
-rw-r--r--include/linux/sysctl.h144
-rw-r--r--include/linux/ufs_fs.h13
-rw-r--r--include/linux/umsdos_fs.h29
-rw-r--r--include/linux/umsdos_fs.p109
-rw-r--r--include/linux/videodev.h59
49 files changed, 677 insertions, 523 deletions
diff --git a/include/linux/adfs_fs_fs.h b/include/linux/adfs_fs_fs.h
deleted file mode 100644
index 7fff6be19..000000000
--- a/include/linux/adfs_fs_fs.h
+++ /dev/null
@@ -1,177 +0,0 @@
-#ifndef _ADFS_FS_H
-#define _ADFS_FS_H
-
-#include <linux/types.h>
-/*
- * Structures of data on the disk
- */
-
-/*
- * Disc Record at disc address 0xc00
- */
-struct adfs_discrecord {
- unsigned char log2secsize;
- unsigned char secspertrack;
- unsigned char heads;
- unsigned char density;
- unsigned char idlen;
- unsigned char log2bpmb;
- unsigned char skew;
- unsigned char bootoption;
- unsigned char lowsector;
- unsigned char nzones;
- unsigned short zone_spare;
- unsigned long root;
- unsigned long disc_size;
- unsigned short disc_id;
- unsigned char disc_name[10];
- unsigned long disc_type;
- unsigned long disc_size_high;
- unsigned char log2sharesize:4;
- unsigned char unused:4;
- unsigned char big_flag:1;
-};
-
-#define ADFS_DISCRECORD (0xc00)
-#define ADFS_DR_OFFSET (0x1c0)
-#define ADFS_DR_SIZE 60
-#define ADFS_SUPER_MAGIC 0xadf5
-#define ADFS_FREE_FRAG 0
-#define ADFS_BAD_FRAG 1
-#define ADFS_ROOT_FRAG 2
-
-/*
- * Directory header
- */
-struct adfs_dirheader {
- unsigned char startmasseq;
- unsigned char startname[4];
-};
-
-#define ADFS_NEWDIR_SIZE 2048
-#define ADFS_OLDDIR_SIZE 1024
-#define ADFS_NUM_DIR_ENTRIES 77
-
-/*
- * Directory entries
- */
-struct adfs_direntry {
- char dirobname[10];
-#define ADFS_NAME_LEN 10
- __u8 dirload[4];
- __u8 direxec[4];
- __u8 dirlen[4];
- __u8 dirinddiscadd[3];
- __u8 newdiratts;
-#define ADFS_NDA_OWNER_READ (1 << 0)
-#define ADFS_NDA_OWNER_WRITE (1 << 1)
-#define ADFS_NDA_LOCKED (1 << 2)
-#define ADFS_NDA_DIRECTORY (1 << 3)
-#define ADFS_NDA_EXECUTE (1 << 4)
-#define ADFS_NDA_PUBLIC_READ (1 << 5)
-#define ADFS_NDA_PUBLIC_WRITE (1 << 6)
-};
-
-#define ADFS_MAX_NAME_LEN 255
-struct adfs_idir_entry {
- __u32 inode_no; /* Address */
- __u32 file_id; /* file id */
- __u32 name_len; /* name length */
- __u32 size; /* size */
- __u32 mtime; /* modification time */
- __u32 filetype; /* RiscOS file type */
- __u8 mode; /* internal mode */
- char name[ADFS_MAX_NAME_LEN]; /* file name */
-};
-
-/*
- * Directory tail
- */
-union adfs_dirtail {
- struct {
- unsigned char dirlastmask;
- char dirname[10];
- unsigned char dirparent[3];
- char dirtitle[19];
- unsigned char reserved[14];
- unsigned char endmasseq;
- unsigned char endname[4];
- unsigned char dircheckbyte;
- } old;
- struct {
- unsigned char dirlastmask;
- unsigned char reserved[2];
- unsigned char dirparent[3];
- char dirtitle[19];
- char dirname[10];
- unsigned char endmasseq;
- unsigned char endname[4];
- unsigned char dircheckbyte;
- } new;
-};
-
-#ifdef __KERNEL__
-/*
- * Calculate the boot block checksum on an ADFS drive. Note that this will
- * appear to be correct if the sector contains all zeros, so also check that
- * the disk size is non-zero!!!
- */
-extern inline int adfs_checkbblk (unsigned char *ptr)
-{
- unsigned int result = 0;
- unsigned char *p = ptr + 511;
-
- do {
- result = (result & 0xff) + (result >> 8);
- result = result + *--p;
- } while (p != ptr);
-
- return (result & 0xff) != ptr[511];
-}
-
-/* dir.c */
-extern unsigned int adfs_val (unsigned char *p, int len);
-extern int adfs_dir_read_parent (struct inode *inode, struct buffer_head **bhp);
-extern int adfs_dir_read (struct inode *inode, struct buffer_head **bhp);
-extern int adfs_dir_check (struct inode *inode, struct buffer_head **bhp,
- int buffers, union adfs_dirtail *dtp);
-extern void adfs_dir_free (struct buffer_head **bhp, int buffers);
-extern int adfs_dir_get (struct super_block *sb, struct buffer_head **bhp,
- int buffers, int pos, unsigned long parent_object_id,
- struct adfs_idir_entry *ide);
-extern int adfs_dir_find_entry (struct super_block *sb, struct buffer_head **bhp,
- int buffers, unsigned int index,
- struct adfs_idir_entry *ide);
-
-/* inode.c */
-extern int adfs_inode_validate (struct inode *inode);
-extern unsigned long adfs_inode_generate (unsigned long parent_id, int diridx);
-extern unsigned long adfs_inode_objid (struct inode *inode);
-extern unsigned int adfs_parent_bmap (struct inode *inode, int block);
-extern int adfs_bmap (struct inode *inode, int block);
-extern void adfs_read_inode (struct inode *inode);
-
-/* map.c */
-extern int adfs_map_lookup (struct super_block *sb, int frag_id, int offset);
-
-/* namei.c */
-extern int adfs_lookup (struct inode * dir, const char * name, int len,
- struct inode ** result);
-
-/* super.c */
-extern int init_adfs_fs (void);
-extern void adfs_error (struct super_block *, const char *, const char *, ...);
-
-/*
- * Inodes and file operations
- */
-
-/* dir.c */
-extern struct inode_operations adfs_dir_inode_operations;
-
-/* file.c */
-extern struct inode_operations adfs_file_inode_operations;
-#endif
-
-#endif
-
diff --git a/include/linux/byteorder/generic.h b/include/linux/byteorder/generic.h
index 5200dc1ad..8fae0f0ef 100644
--- a/include/linux/byteorder/generic.h
+++ b/include/linux/byteorder/generic.h
@@ -5,18 +5,18 @@
* linux/byteorder_generic.h
* Generic Byte-reordering support
*
- * Francois-Rene Rideau <rideau@ens.fr> 19970707
+ * Francois-Rene Rideau <fare@tunes.org> 19970707
* gathered all the good ideas from all asm-foo/byteorder.h into one file,
* cleaned them up.
* I hope it is compliant with non-GCC compilers.
* I decided to put __BYTEORDER_HAS_U64__ in byteorder.h,
* because I wasn't sure it would be ok to put it in types.h
* Upgraded it to 2.1.43
- * Francois-Rene Rideau <rideau@ens.fr> 19971012
+ * Francois-Rene Rideau <fare@tunes.org> 19971012
* Upgraded it to 2.1.57
* to please Linus T., replaced huge #ifdef's between little/big endian
* by nestedly #include'd files.
- * Francois-Rene Rideau <rideau@ens.fr> 19971205
+ * Francois-Rene Rideau <fare@tunes.org> 19971205
* Made it to 2.1.71; now a facelift:
* Put files under include/linux/byteorder/
* Split swab from generic support.
@@ -31,6 +31,11 @@
* nybble swapping support...
* = every architecture could add their byteswap macro in asm/byteorder.h
* see how some architectures already do (i386, alpha, ppc, etc)
+ * = cpu_to_beXX and beXX_to_cpu might some day need to be well
+ * distinguished throughout the kernel. This is not the case currently,
+ * since little endian, big endian, and pdp endian machines needn't it.
+ * But this might be the case for, say, a port of Linux to 20/21 bit
+ * architectures (and F21 Linux addict around?).
*/
/*
diff --git a/include/linux/byteorder/swab.h b/include/linux/byteorder/swab.h
index 7c1f5c985..813df46c3 100644
--- a/include/linux/byteorder/swab.h
+++ b/include/linux/byteorder/swab.h
@@ -6,7 +6,7 @@
* Byte-swapping, independently from CPU endianness
* swabXX[ps]?(foo)
*
- * Francois-Rene Rideau <rideau@ens.fr> 19971205
+ * Francois-Rene Rideau <fare@tunes.org> 19971205
* separated swab functions from cpu_to_XX,
* to clean up support for bizarre-endian architectures.
*
@@ -15,10 +15,13 @@
*
*/
+/* casts are necessary for constants, because we never know how for sure
+ * how U/UL/ULL map to __u16, __u32, __u64. At least not in a portable way.
+ */
#define ___swab16(x) \
((__u16)( \
- (((__u16)(x) & 0x00ffU) << 8) | \
- (((__u16)(x) & 0xff00U) >> 8) ))
+ (((__u16)(x) & (__u16)0x00ffU) << 8) | \
+ (((__u16)(x) & (__u16)0xff00U) >> 8) ))
#define ___swab32(x) \
((__u32)( \
(((__u32)(x) & (__u32)0x000000ffUL) << 24) | \
diff --git a/include/linux/byteorder/swabb.h b/include/linux/byteorder/swabb.h
index 22407afdf..782db2e8e 100644
--- a/include/linux/byteorder/swabb.h
+++ b/include/linux/byteorder/swabb.h
@@ -8,8 +8,8 @@
*
* Support for obNUXIous pdp-endian and other bizarre architectures.
* Will Linux ever run on such ancient beasts? if not, this file
- * will be but a programming pearl. Still, it's a reminder that
- * cpu_to_beXX and beXX_to_cpu should be well distinguished.
+ * will be but a programming pearl. Still, it's a reminder that we
+ * shouldn't be making too many assumptions when trying to be portable.
*
*/
diff --git a/include/linux/coda.h b/include/linux/coda.h
index 9cdf0d04b..564b3933b 100644
--- a/include/linux/coda.h
+++ b/include/linux/coda.h
@@ -72,6 +72,7 @@ struct timespec {
#define C_O_WRITE 0x002
#define C_O_TRUNC 0x010
#define C_O_EXCL 0x100
+#define C_O_CREAT 0x200
/* these are to find mode bits in Venus */
#define C_M_READ 00400
@@ -80,6 +81,7 @@ struct timespec {
/* for access Venus will use */
#define C_A_R_OK 4 /* Test for read permission. */
#define C_A_W_OK 2 /* Test for write permission. */
+#define C_A_C_OK 8 /* Test for writing upon create. */
#define C_A_X_OK 1 /* Test for execute permission. */
#define C_A_F_OK 0 /* Test for existence. */
@@ -148,8 +150,8 @@ static inline ino_t coda_f2i(struct ViceFid *fid)
#ifndef _VUID_T_
#define _VUID_T_
-typedef unsigned int vuid_t;
-typedef unsigned int vgid_t;
+typedef u_int32_t vuid_t;
+typedef u_int32_t vgid_t;
#endif /*_VUID_T_ */
#ifndef _CODACRED_T_
diff --git a/include/linux/coda_fs_i.h b/include/linux/coda_fs_i.h
index d312013d5..83980b26e 100644
--- a/include/linux/coda_fs_i.h
+++ b/include/linux/coda_fs_i.h
@@ -43,7 +43,7 @@ struct coda_inode_info {
int coda_cnode_make(struct inode **, struct ViceFid *, struct super_block *);
int coda_cnode_makectl(struct inode **inode, struct super_block *sb);
struct inode *coda_fid_to_inode(ViceFid *fid, struct super_block *sb);
-
+void coda_replace_fid(struct inode *, ViceFid *, ViceFid *);
#endif
#endif
diff --git a/include/linux/coda_linux.h b/include/linux/coda_linux.h
index e867226ec..98407f73b 100644
--- a/include/linux/coda_linux.h
+++ b/include/linux/coda_linux.h
@@ -51,7 +51,6 @@ int coda_fid_is_volroot(struct ViceFid *);
int coda_fid_is_weird(struct ViceFid *fid);
int coda_iscontrol(const char *name, size_t length);
-
void coda_load_creds(struct coda_cred *cred);
int coda_mycred(struct coda_cred *);
void coda_vattr_to_iattr(struct inode *, struct coda_vattr *);
@@ -71,6 +70,11 @@ int coda_inode_grab(dev_t dev, ino_t ino, struct inode **ind);
#define NB_SFS_SIZ 0x895440
+/* cache.c */
+void coda_purge_children(struct inode *);
+void coda_purge_dentries(struct inode *);
+
+
/* debugging masks */
#define D_SUPER 1 /* print results returned by Venus */
#define D_INODE 2 /* print entry and exit into procedure */
diff --git a/include/linux/cyclades.h b/include/linux/cyclades.h
index 024104c31..e7c8a38f0 100644
--- a/include/linux/cyclades.h
+++ b/include/linux/cyclades.h
@@ -754,6 +754,13 @@ struct cyclades_port {
#define CyTBPR (0x72*2)
#define CyTCOR (0x76*2)
+/* Custom Registers */
+
+#define CyPLX_VER (0x3400)
+#define PLX_9050 0x11
+#define PLX_9060 0x12
+#define PLX_9080 0x13
+
/***************************************************************************/
#endif /* __KERNEL__ */
diff --git a/include/linux/file.h b/include/linux/file.h
index fe7ca60c9..0884fad2f 100644
--- a/include/linux/file.h
+++ b/include/linux/file.h
@@ -5,7 +5,7 @@
#ifndef __LINUX_FILE_H
#define __LINUX_FILE_H
-extern int __fput(struct file *);
+extern void __fput(struct file *);
extern void insert_file_free(struct file *file);
/*
@@ -58,20 +58,18 @@ extern inline void remove_filp(struct file *file)
*file->f_pprev = file->f_next;
}
-extern inline int fput(struct file *file)
+extern inline void fput(struct file *file)
{
int count = file->f_count-1;
- int error = 0;
if (!count) {
locks_remove_flock(file);
- error = __fput(file);
+ __fput(file);
file->f_count = 0;
remove_filp(file);
insert_file_free(file);
} else
file->f_count = count;
- return error;
}
extern inline void put_filp(struct file *file)
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 69fa35c3c..8a2b4478f 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -39,16 +39,17 @@ struct poll_table_struct;
#undef NR_OPEN
#define NR_OPEN 1024
-#define NR_SUPER 64
#define BLOCK_SIZE_BITS 10
#define BLOCK_SIZE (1<<BLOCK_SIZE_BITS)
/* And dynamically-tunable limits and defaults: */
extern int max_inodes;
extern int max_files, nr_files, nr_free_files;
+extern int max_super_blocks, nr_super_blocks;
#define NR_FILE 4096 /* this can well be larger on a larger system */
#define NR_RESERVED_FILES 10 /* reserved for root */
+#define NR_SUPER 256
#define MAY_EXEC 1
#define MAY_WRITE 2
@@ -271,6 +272,7 @@ static inline int buffer_protected(struct buffer_head * bh)
#include <linux/smb_fs_i.h>
#include <linux/hfs_fs_i.h>
#include <linux/adfs_fs_i.h>
+#include <linux/qnx4_fs_i.h>
#include <linux/efs_fs_i.h>
/*
@@ -381,6 +383,7 @@ struct inode {
struct smb_inode_info smbfs_i;
struct hfs_inode_info hfs_i;
struct adfs_inode_info adfs_i;
+ struct qnx4_inode_info qnx4_i;
struct efs_inode_info efs_i;
struct socket socket_i;
void *generic_ip;
@@ -402,6 +405,7 @@ static inline void mark_inode_dirty(struct inode *inode)
struct fown_struct {
int pid; /* pid or -pgrp where SIGIO should be sent */
uid_t uid, euid; /* uid/euid of process setting the owner */
+ int signum; /* posix.1b rt signal to be delivered on IO */
};
struct file {
@@ -511,13 +515,14 @@ extern inline int locks_verify_area(int read_write, struct inode *inode,
struct fasync_struct {
int magic;
+ int fa_fd;
struct fasync_struct *fa_next; /* singly linked list */
struct file *fa_file;
};
#define FASYNC_MAGIC 0x4601
-extern int fasync_helper(struct file *, int, struct fasync_struct **);
+extern int fasync_helper(int, struct file *, int, struct fasync_struct **);
#include <linux/minix_fs_sb.h>
#include <linux/ext2_fs_sb.h>
@@ -534,8 +539,13 @@ extern int fasync_helper(struct file *, int, struct fasync_struct **);
#include <linux/smb_fs_sb.h>
#include <linux/hfs_fs_sb.h>
#include <linux/adfs_fs_sb.h>
+#include <linux/qnx4_fs_sb.h>
+extern struct list_head super_blocks;
+
+#define sb_entry(list) list_entry((list), struct super_block, s_list)
struct super_block {
+ struct list_head s_list; /* Keep this first */
kdev_t s_dev;
unsigned long s_blocksize;
unsigned char s_blocksize_bits;
@@ -572,6 +582,7 @@ struct super_block {
struct smb_sb_info smbfs_sb;
struct hfs_sb_info hfs_sb;
struct adfs_sb_info adfs_sb;
+ struct qnx4_sb_info qnx4_sb;
void *generic_sbp;
} u;
};
@@ -593,9 +604,10 @@ struct file_operations {
int (*ioctl) (struct inode *, struct file *, unsigned int, unsigned long);
int (*mmap) (struct file *, struct vm_area_struct *);
int (*open) (struct inode *, struct file *);
+ int (*flush) (struct file *);
int (*release) (struct inode *, struct file *);
int (*fsync) (struct file *, struct dentry *);
- int (*fasync) (struct file *, int);
+ int (*fasync) (int, struct file *, int);
int (*check_media_change) (kdev_t dev);
int (*revalidate) (kdev_t dev);
int (*lock) (struct file *, int, struct file_lock *);
@@ -667,7 +679,6 @@ asmlinkage int sys_close(unsigned int); /* yes, it's really unsigned */
extern int do_truncate(struct dentry *, unsigned long);
extern int get_unused_fd(void);
extern void put_unused_fd(unsigned int);
-extern int __fput(struct file *);
extern int close_fp(struct file *, fl_owner_t id);
extern char * getname(const char * filename);
@@ -708,7 +719,6 @@ extern int fs_may_remount_ro(struct super_block *);
extern int fs_may_mount(kdev_t dev);
extern struct file *inuse_filps;
-extern struct super_block super_blocks[NR_SUPER];
extern void refile_buffer(struct buffer_head * buf);
extern void set_writetime(struct buffer_head * buf, int flag);
diff --git a/include/linux/genhd.h b/include/linux/genhd.h
index 868f490cb..fe89b7e7a 100644
--- a/include/linux/genhd.h
+++ b/include/linux/genhd.h
@@ -53,7 +53,7 @@ struct partition {
unsigned char end_cyl; /* end cylinder */
unsigned int start_sect; /* starting sector counting from 0 */
unsigned int nr_sects; /* nr of sectors in partition */
-};
+} __attribute__((packed));
struct hd_struct {
long start_sect;
diff --git a/include/linux/head.h b/include/linux/head.h
deleted file mode 100644
index e4e99b31d..000000000
--- a/include/linux/head.h
+++ /dev/null
@@ -1,28 +0,0 @@
-#ifndef _LINUX_HEAD_H
-#define _LINUX_HEAD_H
-
-struct desc_struct {
- unsigned long a,b;
-};
-
-extern struct desc_struct idt_table[],gdt_table[];
-extern struct desc_struct *idt, *gdt;
-
-struct Xgt_desc_struct {
- unsigned short size;
- unsigned long address __attribute__((packed));
-};
-
-#define idt_descr (*(struct Xgt_desc_struct *)((char *)&idt - 2))
-#define gdt_descr (*(struct Xgt_desc_struct *)((char *)&gdt - 2))
-
-#define GDT_NUL 0
-#define GDT_CODE 1
-#define GDT_DATA 2
-#define GDT_TMP 3
-
-#define LDT_NUL 0
-#define LDT_CODE 1
-#define LDT_DATA 2
-
-#endif
diff --git a/include/linux/if.h b/include/linux/if.h
index 87b6692c8..a5fdf3aed 100644
--- a/include/linux/if.h
+++ b/include/linux/if.h
@@ -114,6 +114,7 @@ struct ifreq
int ifru_mtu;
struct ifmap ifru_map;
char ifru_slave[IFNAMSIZ]; /* Just fits the size */
+ char ifru_newname[IFNAMSIZ];
__kernel_caddr_t ifru_data;
} ifr_ifru;
};
@@ -133,6 +134,7 @@ struct ifreq
#define ifr_ifindex ifr_ifru.ifru_ivalue /* interface index */
#define ifr_bandwidth ifr_ifru.ifru_ivalue /* link bandwidth */
#define ifr_qlen ifr_ifru.ifru_ivalue /* Queue length */
+#define ifr_newname ifr_ifru.ifru_newname /* New name */
/*
* Structure used in SIOCGIFCONF request.
diff --git a/include/linux/if_packet.h b/include/linux/if_packet.h
index 3bdeca342..ad5655cf1 100644
--- a/include/linux/if_packet.h
+++ b/include/linux/if_packet.h
@@ -25,9 +25,10 @@ struct sockaddr_ll
#define PACKET_BROADCAST 1 /* To all */
#define PACKET_MULTICAST 2 /* To group */
#define PACKET_OTHERHOST 3 /* To someone else */
-#define PACKET_OUTGOING 4 /* Originated by us */
-#define PACKET_LOOPBACK 5
-#define PACKET_FASTROUTE 6
+#define PACKET_OUTGOING 4 /* Outgoing of any type */
+/* These ones are invisible by user level */
+#define PACKET_LOOPBACK 5 /* MC/BRD frame looped back */
+#define PACKET_FASTROUTE 6 /* Fastrouted frame */
/* Packet socket options */
diff --git a/include/linux/in6.h b/include/linux/in6.h
index 37f0e066d..b63918419 100644
--- a/include/linux/in6.h
+++ b/include/linux/in6.h
@@ -35,8 +35,15 @@ struct in6_addr
__u16 u6_addr16[8];
__u32 u6_addr32[4];
#if (~0UL) > 0xffffffff
+#ifndef __RELAX_IN6_ADDR_ALIGNMENT
+ /* Alas, protocols do not respect 64bit alignmnet.
+ rsvp/pim/... are broken. However, it is good
+ idea to force correct alignment always, when
+ it is possible.
+ */
__u64 u6_addr64[2];
#endif
+#endif
} in6_u;
#define s6_addr in6_u.u6_addr8
#define s6_addr16 in6_u.u6_addr16
@@ -101,19 +108,34 @@ struct ipv6_mreq {
#define IPPROTO_DSTOPTS 60 /* IPv6 destination options */
/*
+ * IPv6 TLV options.
+ */
+#define IPV6_TLV_PAD0 0
+#define IPV6_TLV_PADN 1
+#define IPV6_TLV_ROUTERALERT 20
+#define IPV6_TLV_JUMBO 194
+
+/*
* IPV6 socket options
*/
#define IPV6_ADDRFORM 1
#define IPV6_PKTINFO 2
-#define IPV6_RXHOPOPTS 3 /* obsolete name */
-#define IPV6_RXDSTOPTS 4 /* obsolete name */
-#define IPV6_HOPOPTS IPV6_RXHOPOPTS /* new name */
-#define IPV6_DSTOPTS IPV6_RXDSTOPTS /* new name */
-#define IPV6_RXSRCRT 5
+#define IPV6_HOPOPTS 3
+#define IPV6_DSTOPTS 4
+#define IPV6_RTHDR 5
#define IPV6_PKTOPTIONS 6
#define IPV6_CHECKSUM 7
#define IPV6_HOPLIMIT 8
+#define IPV6_NEXTHOP 9
+#define IPV6_AUTHHDR 10
+
+#if 0
+/* Aliases for obsolete names */
+#define IPV6_RXHOPOPTS IPV6_HOPOPTS
+#define IPV6_RXDSTOPTS IPV6_DSTOPTS
+#define IPV6_RXSRCRT IPV6_RTHDR
+#endif
/*
* Alternative names
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h
index 391352418..84564bae7 100644
--- a/include/linux/ipv6.h
+++ b/include/linux/ipv6.h
@@ -4,6 +4,9 @@
#include <linux/in6.h>
#include <asm/byteorder.h>
+/* The latest drafts declared increase in minimal mtu up to 1280. */
+
+#define IPV6_MIN_MTU 1280
/*
* Advanced API
@@ -58,8 +61,6 @@ struct ipv6_opt_hdr {
#define ipv6_optlen(p) (((p)->hdrlen+1) << 3)
#endif
-
-
/*
* routing header type 0 (used in cmsghdr struct)
*/
@@ -72,10 +73,11 @@ struct rt0_hdr {
#define rt0_type rt_hdr.type;
};
-#ifdef __KERNEL__
-
/*
* IPv6 fixed header
+ *
+ * BEWARE, it is incorrect. The first 4 bits of flow_lbl
+ * are glued to priority now, forming "class".
*/
struct ipv6hdr {
@@ -87,7 +89,7 @@ struct ipv6hdr {
priority:4;
#else
#error "Please fix <asm/byteorder.h>"
-#endif
+#endif
__u8 flow_lbl[3];
__u16 payload_len;
@@ -98,28 +100,24 @@ struct ipv6hdr {
struct in6_addr daddr;
};
-/*
- * The length of this struct cannot be greater than the length of
- * the proto_priv field in a sk_buff which is currently
- * defined to be 16 bytes.
- * Pointers take upto 8 bytes (sizeof(void *) is 8 on the alpha).
- */
-struct ipv6_options
-{
- /* length of extension headers */
-
- __u16 opt_flen; /* after fragment hdr */
- __u16 opt_nflen; /* before fragment hdr */
+#ifdef __KERNEL__
- /*
- * protocol options
- * usually carried in IPv6 extension headers
- */
+/*
+ This structure contains results of exthdrs parsing
+ as offsets from skb->nh.
+ */
- struct ipv6_rt_hdr *srcrt; /* Routing Header */
+struct inet6_skb_parm
+{
+ int iif;
+ __u16 ra;
+ __u16 hop;
+ __u16 auth;
+ __u16 dst0;
+ __u16 srcrt;
+ __u16 dst1;
};
-
#endif
#endif
diff --git a/include/linux/ipv6_route.h b/include/linux/ipv6_route.h
index 7fc11c7ce..a4861d053 100644
--- a/include/linux/ipv6_route.h
+++ b/include/linux/ipv6_route.h
@@ -26,7 +26,6 @@ enum
#define RTF_ALLONLINK 0x00020000 /* fallback, no routers on link */
#define RTF_ADDRCONF 0x00040000 /* addrconf route - RA */
-#define RTF_LINKRT 0x00100000 /* link specific - device match */
#define RTF_NONEXTHOP 0x00200000 /* route with no nexthop */
#define RTF_EXPIRES 0x00400000
diff --git a/include/linux/iso_fs_sb.h b/include/linux/iso_fs_sb.h
index 879f8faf3..7bb55a504 100644
--- a/include/linux/iso_fs_sb.h
+++ b/include/linux/iso_fs_sb.h
@@ -16,7 +16,6 @@ struct isofs_sb_info {
unsigned char s_rock;
unsigned char s_joliet_level;
unsigned char s_utf8;
- unsigned char s_name_check; /* r = relaxed, s = strict */
unsigned char s_cruft; /* Broken disks with high
byte of length containing
junk */
diff --git a/include/linux/kbd_ll.h b/include/linux/kbd_ll.h
index d83f9ea8a..26a30c12a 100644
--- a/include/linux/kbd_ll.h
+++ b/include/linux/kbd_ll.h
@@ -9,4 +9,9 @@ extern struct pt_regs *kbd_pt_regs;
void handle_scancode(unsigned char scancode);
+/*
+ * Interface for to the host specific interupt setup code
+ */
+void keyboard_interrupt(int irq, void *dev_id, struct pt_regs *regs);
+
#endif /* _KBD_LL_H */
diff --git a/include/linux/nbd.h b/include/linux/nbd.h
index c2f2a4e08..0b3114431 100644
--- a/include/linux/nbd.h
+++ b/include/linux/nbd.h
@@ -12,6 +12,7 @@
#ifdef MAJOR_NR
#include <linux/locks.h>
+#include <asm/semaphore.h>
#define LOCAL_END_REQUEST
@@ -42,11 +43,13 @@ struct nbd_device {
int harderror; /* Code of hard error */
#define NBD_READ_ONLY 0x0001
#define NBD_WRITE_NOCHK 0x0002
+#define NBD_INITIALISED 0x0004
struct socket * sock;
struct file * file; /* If == NULL, device is not ready, yet */
int magic; /* FIXME: not if debugging is off */
struct request *head; /* Requests are added here... */
struct request *tail;
+ struct semaphore queue_lock;
};
/* This now IS in some kind of include file... */
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index c42e43d9d..41f6405ee 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -232,8 +232,7 @@ struct device
unsigned short flags; /* interface flags (a la BSD) */
unsigned short gflags;
- unsigned short metric; /* routing metric (not used) */
- unsigned short mtu; /* interface MTU value */
+ unsigned mtu; /* interface MTU value */
unsigned short type; /* interface hardware type */
unsigned short hard_header_len; /* hardware hdr length */
void *priv; /* pointer to private data */
diff --git a/include/linux/netlink.h b/include/linux/netlink.h
index bd4f9dd9b..59075b070 100644
--- a/include/linux/netlink.h
+++ b/include/linux/netlink.h
@@ -16,8 +16,8 @@ struct sockaddr_nl
{
sa_family_t nl_family; /* AF_NETLINK */
unsigned short nl_pad; /* zero */
- __kernel_pid_t nl_pid; /* process pid */
- unsigned nl_groups; /* multicast groups mask */
+ __u32 nl_pid; /* process pid */
+ __u32 nl_groups; /* multicast groups mask */
};
struct nlmsghdr
@@ -26,7 +26,7 @@ struct nlmsghdr
__u16 nlmsg_type; /* Message content */
__u16 nlmsg_flags; /* Additional flags */
__u32 nlmsg_seq; /* Sequence number */
- __kernel_pid_t nlmsg_pid; /* Sending process PID */
+ __u32 nlmsg_pid; /* Sending process PID */
};
/* Flags values */
@@ -64,7 +64,7 @@ struct nlmsghdr
#define NLMSG_DATA(nlh) ((void*)(((char*)nlh) + NLMSG_LENGTH(0)))
#define NLMSG_NEXT(nlh,len) ((len) -= NLMSG_ALIGN((nlh)->nlmsg_len), \
(struct nlmsghdr*)(((char*)(nlh)) + NLMSG_ALIGN((nlh)->nlmsg_len)))
-#define NLMSG_OK(nlh,len) ((nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \
+#define NLMSG_OK(nlh,len) ((len) > 0 && (nlh)->nlmsg_len >= sizeof(struct nlmsghdr) && \
(nlh)->nlmsg_len <= (len))
#define NLMSG_PAYLOAD(nlh,len) ((nlh)->nlmsg_len - NLMSG_SPACE((len)))
@@ -86,10 +86,11 @@ struct nlmsgerr
struct netlink_skb_parms
{
struct ucred creds; /* Skb credentials */
- pid_t pid;
- unsigned groups;
- pid_t dst_pid;
- unsigned dst_groups;
+ __u32 pid;
+ __u32 groups;
+ __u32 dst_pid;
+ __u32 dst_groups;
+ kernel_cap_t eff_cap;
};
#define NETLINK_CB(skb) (*(struct netlink_skb_parms*)&((skb)->cb))
@@ -102,10 +103,10 @@ extern int netlink_post(int unit, struct sk_buff *skb);
extern int init_netlink(void);
extern struct sock *netlink_kernel_create(int unit, void (*input)(struct sock *sk, int len));
extern void netlink_ack(struct sk_buff *in_skb, struct nlmsghdr *nlh, int err);
-extern int netlink_unicast(struct sock *ssk, struct sk_buff *skb, pid_t pid, int nonblock);
-extern void netlink_broadcast(struct sock *ssk, struct sk_buff *skb, pid_t pid,
- unsigned group, int allocation);
-extern void netlink_set_err(struct sock *ssk, pid_t pid, unsigned group, int code);
+extern int netlink_unicast(struct sock *ssk, struct sk_buff *skb, __u32 pid, int nonblock);
+extern void netlink_broadcast(struct sock *ssk, struct sk_buff *skb, __u32 pid,
+ __u32 group, int allocation);
+extern void netlink_set_err(struct sock *ssk, __u32 pid, __u32 group, int code);
/*
* skb should fit one page. This choice is good for headerless malloc.
@@ -125,28 +126,8 @@ struct netlink_callback
long args[4];
};
-#if 0
-
-void* nlmsg_broadcast(struct sock*, unsigned long type, int len, unsigned groups);
-struct skb_buff *nlmsg_alloc(unsigned long type, int len,
- unsigned long seq, unsigned long pid, int allocation);
-void __nlmsg_transmit(struct sock*, int allocation);
-
-extern __inline__ void nlmsg_release(struct sk_buff *skb)
-{
- atomic_dec(skb->users);
-}
-
-extern __inline__ void nlmsg_transmit(struct sk_buff *sk, int allocation)
-{
- if (sk->write_queue.qlen)
- __nlmsg_transmit(sk, allocation);
-}
-
-#endif
-
extern __inline__ struct nlmsghdr *
-__nlmsg_put(struct sk_buff *skb, pid_t pid, u32 seq, int type, int len)
+__nlmsg_put(struct sk_buff *skb, u32 pid, u32 seq, int type, int len)
{
struct nlmsghdr *nlh;
int size = NLMSG_LENGTH(len);
diff --git a/include/linux/nfsd/nfsfh.h b/include/linux/nfsd/nfsfh.h
index d11d8e0c3..e33eaa418 100644
--- a/include/linux/nfsd/nfsfh.h
+++ b/include/linux/nfsd/nfsfh.h
@@ -110,9 +110,9 @@ void nfsd_fh_free(void);
static __inline__ struct svc_fh *
fh_copy(struct svc_fh *dst, struct svc_fh *src)
{
- if (src->fh_dverified) {
+ if (src->fh_dverified || src->fh_locked) {
struct dentry *dentry = src->fh_dentry;
- printk("fh_copy: copying %s/%s, already verified!\n",
+ printk(KERN_ERR "fh_copy: copying %s/%s, already verified!\n",
dentry->d_parent->d_name.name, dentry->d_name.name);
}
@@ -133,18 +133,24 @@ fh_init(struct svc_fh *fhp)
static inline void
fh_lock(struct svc_fh *fhp)
{
- struct inode *inode = fhp->fh_dentry->d_inode;
+ struct dentry *dentry = fhp->fh_dentry;
+ struct inode *inode;
/*
dfprintk(FILEOP, "nfsd: fh_lock(%x/%ld) locked = %d\n",
SVCFH_DEV(fhp), SVCFH_INO(fhp), fhp->fh_locked);
*/
+ if (!fhp->fh_dverified) {
+ printk(KERN_ERR "fh_lock: fh not verified!\n");
+ return;
+ }
if (fhp->fh_locked) {
printk(KERN_WARNING "fh_lock: %s/%s already locked!\n",
- fhp->fh_dentry->d_parent->d_name.name,
- fhp->fh_dentry->d_name.name);
+ dentry->d_parent->d_name.name, dentry->d_name.name);
return;
}
+
+ inode = dentry->d_inode;
down(&inode->i_sem);
if (!fhp->fh_pre_mtime)
fhp->fh_pre_mtime = inode->i_mtime;
@@ -157,8 +163,13 @@ fh_lock(struct svc_fh *fhp)
static inline void
fh_unlock(struct svc_fh *fhp)
{
+ if (!fhp->fh_dverified)
+ printk(KERN_ERR "fh_unlock: fh not verified!\n");
+
if (fhp->fh_locked) {
- struct inode *inode = fhp->fh_dentry->d_inode;
+ struct dentry *dentry = fhp->fh_dentry;
+ struct inode *inode = dentry->d_inode;
+
if (!fhp->fh_post_version)
fhp->fh_post_version = inode->i_version;
fhp->fh_locked = 0;
diff --git a/include/linux/notifier.h b/include/linux/notifier.h
index a9842306e..42faceaa0 100644
--- a/include/linux/notifier.h
+++ b/include/linux/notifier.h
@@ -98,6 +98,7 @@ extern __inline__ int notifier_call_chain(struct notifier_block **n, unsigned lo
#define NETDEV_CHANGEMTU 0x0007
#define NETDEV_CHANGEADDR 0x0008
#define NETDEV_GOING_DOWN 0x0009
+#define NETDEV_CHANGENAME 0x000A
#define SYS_DOWN 0x0001 /* Notify of system down */
#define SYS_RESTART SYS_DOWN
diff --git a/include/linux/pci.h b/include/linux/pci.h
index 9217511f7..f2231c90a 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -1,5 +1,5 @@
/*
- * $Id: pci.h,v 1.80 1998/07/21 10:06:40 mj Exp $
+ * $Id: pci.h,v 1.84 1998/08/17 23:06:43 cort Exp $
*
* PCI defines and function prototypes
* Copyright 1994, Drew Eckhardt
@@ -381,7 +381,9 @@
#define PCI_DEVICE_ID_IBM_82351 0x0022
#define PCI_DEVICE_ID_IBM_SERVERAID 0x002e
#define PCI_DEVICE_ID_IBM_TR_WAKE 0x003e
+#define PCI_DEVICE_ID_IBM_MPIC 0x0046
#define PCI_DEVICE_ID_IBM_3780IDSP 0x007d
+#define PCI_DEVICE_ID_IBM_MPIC_2 0xffff
#define PCI_VENDOR_ID_WD 0x101c
#define PCI_DEVICE_ID_WD_7197 0x3296
@@ -599,6 +601,9 @@
#define PCI_DEVICE_ID_DATABOOK_87144 0xb106
#define PCI_VENDOR_ID_PLX 0x10b5
+#define PCI_DEVICE_ID_PLX_9060 0x9060
+#define PCI_DEVICE_ID_PLX_9060ES 0x906E
+#define PCI_DEVICE_ID_PLX_9060SD 0x906D
#define PCI_DEVICE_ID_PLX_9080 0x9080
#define PCI_VENDOR_ID_MADGE 0x10b6
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h
index 8cde8f833..7d4badcd0 100644
--- a/include/linux/proc_fs.h
+++ b/include/linux/proc_fs.h
@@ -119,7 +119,7 @@ enum net_directory_inos {
PROC_NET_AX25_BPQETHER,
PROC_NET_IP_MASQ_APP,
PROC_NET_RT6,
- PROC_NET_RT6_TREE,
+ PROC_NET_SNMP6,
PROC_NET_RT6_STATS,
PROC_NET_NDISC,
PROC_NET_STRIP_STATUS,
diff --git a/include/linux/qnx4_fs.h b/include/linux/qnx4_fs.h
new file mode 100644
index 000000000..eb2b3dc08
--- /dev/null
+++ b/include/linux/qnx4_fs.h
@@ -0,0 +1,123 @@
+/*
+ * Name : qnx4_fs.h
+ * Author : Richard Frowijn
+ * Function : qnx4 global filesystem definitions
+ * Version : 1.0
+ * Last modified : 23-03-1998
+ *
+ * History : 23-03-1998 created
+ */
+#ifndef _LINUX_QNX4_FS_H
+#define _LINUX_QNX4_FS_H
+
+#include <linux/qnxtypes.h>
+
+#define QNX4_ROOT_INO 1
+
+#define _MAX_XTNTS_PER_XBLK 60
+/* for di_status */
+#define QNX4_FILE_USED 0x01
+#define QNX4_FILE_MODIFIED 0x02
+#define QNX4_FILE_BUSY 0x04
+#define QNX4_FILE_LINK 0x08
+#define QNX4_FILE_INODE 0x10
+#define QNX4_FILE_FSYSCLEAN 0x20
+
+#define QNX4_I_MAP_SLOTS 8
+#define QNX4_Z_MAP_SLOTS 64
+#define QNX4_SUPER_MAGIC 0x002f /* qnx4 fs detection */
+#define QNX4_VALID_FS 0x0001 /* Clean fs. */
+#define QNX4_ERROR_FS 0x0002 /* fs has errors. */
+#define QNX4_BLOCK_SIZE 0x200 /* blocksize of 512 bytes */
+#define QNX4_DIR_ENTRY_SIZE 0x040 /* dir entry size */
+#define QNX4_XBLK_ENTRY_SIZE 0x200 /* xblk entry size */
+#define QNX4_INODES_PER_BLOCK 0x08 /* 512 / 64 */
+
+/* for filenames */
+#define _SHORT_NAME_MAX 16
+#define QNX4_NAME_MAX 48
+
+/*
+ * This is the original qnx4 inode layout on disk.
+ */
+struct qnx4_inode_entry {
+ char di_fname[16];
+ off_t di_size;
+ _xtnt_t di_first_xtnt;
+ long di_xblk;
+ time_t di_ftime;
+ time_t di_mtime;
+ time_t di_atime;
+ time_t di_ctime;
+ _nxtnt_t di_num_xtnts;
+ mode_t di_mode;
+ muid_t di_uid;
+ mgid_t di_gid;
+ nlink_t di_nlink;
+ char di_zero[4];
+ _ftype_t di_type;
+ unsigned char di_status;
+};
+
+struct qnx4_link_info {
+ char dl_fname[QNX4_NAME_MAX];
+ long dl_inode_blk;
+ unsigned char dl_inode_ndx;
+ unsigned char dl_spare[10];
+ unsigned char dl_status;
+};
+
+struct qnx4_xblk {
+ long xblk_next_xblk;
+ long xblk_prev_xblk;
+ unsigned char xblk_num_xtnts;
+ char xblk_spare[3];
+ long xblk_num_blocks;
+ _xtnt_t xblk_xnts[_MAX_XTNTS_PER_XBLK];
+ char xblk_signature[8];
+ _xtnt_t xblk_first_xtnt;
+};
+
+struct qnx4_super_block {
+ struct qnx4_inode_entry RootDir;
+ struct qnx4_inode_entry Inode;
+ struct qnx4_inode_entry Boot;
+ struct qnx4_inode_entry AltBoot;
+};
+
+#ifdef __KERNEL__
+
+#define QNX4_DEBUG 0
+
+#if QNX4_DEBUG
+#define QNX4DEBUG(X) printk X
+#else
+#define QNX4DEBUG(X) (void) 0
+#endif
+
+extern int qnx4_lookup(struct inode *dir, struct dentry *dentry);
+extern unsigned long qnx4_count_free_inodes(struct super_block *sb);
+extern unsigned long qnx4_count_free_blocks(struct super_block *sb);
+
+extern struct buffer_head *qnx4_getblk(struct inode *, int, int);
+extern struct buffer_head *qnx4_bread(struct inode *, int, int);
+
+extern int init_qnx4_fs(void);
+extern int qnx4_create(struct inode *dir, struct dentry *dentry, int mode);
+extern struct inode_operations qnx4_file_inode_operations;
+extern struct inode_operations qnx4_dir_inode_operations;
+extern struct inode_operations qnx4_symlink_inode_operations;
+extern int qnx4_is_free(struct super_block *sb, int block);
+extern int qnx4_set_bitmap(struct super_block *sb, int block, int busy);
+extern int qnx4_create(struct inode *inode, struct dentry *dentry, int mode);
+extern void qnx4_truncate(struct inode *inode);
+extern void qnx4_free_inode(struct inode *inode);
+extern int qnx4_unlink(struct inode *dir, struct dentry *dentry);
+extern int qnx4_rmdir(struct inode *dir, struct dentry *dentry);
+extern int qnx4_sync_file(struct file *file, struct dentry *dentry);
+extern int qnx4_sync_inode(struct inode *inode);
+extern int qnx4_bmap(struct inode *inode, int block);
+
+#endif /* __KERNEL__ */
+
+#endif
diff --git a/include/linux/qnx4_fs_i.h b/include/linux/qnx4_fs_i.h
new file mode 100644
index 000000000..83d53e529
--- /dev/null
+++ b/include/linux/qnx4_fs_i.h
@@ -0,0 +1,38 @@
+/*
+ * Name : qnx4_fs_i.h
+ * Author : Richard Frowijn
+ * Function : qnx4 inode definitions
+ * Version : 1.0
+ * Last modified : 25-05-1998
+ *
+ * History : 23-03-1998 created
+ *
+ */
+#ifndef _QNX4_FS_I
+#define _QNX4_FS_I
+
+#include <linux/qnxtypes.h>
+
+/*
+ * qnx4 fs inode entry
+ */
+struct qnx4_inode_info {
+ char i_reserved[16]; /* 16 */
+ off_t i_size; /* 4 */
+ _xtnt_t i_first_xtnt; /* 8 */
+ long i_xblk; /* 4 */
+ time_t i_ftime; /* 4 */
+ time_t i_mtime; /* 4 */
+ time_t i_atime; /* 4 */
+ time_t i_ctime; /* 4 */
+ _nxtnt_t i_num_xtnts; /* 2 */
+ mode_t i_mode; /* 2 */
+ muid_t i_uid; /* 2 */
+ mgid_t i_gid; /* 2 */
+ nlink_t i_nlink; /* 2 */
+ char i_zero[4]; /* 4 */
+ _ftype_t i_type; /* 1 */
+ unsigned char i_status; /* 1 */
+};
+
+#endif
diff --git a/include/linux/qnx4_fs_sb.h b/include/linux/qnx4_fs_sb.h
new file mode 100644
index 000000000..9f28d3cb0
--- /dev/null
+++ b/include/linux/qnx4_fs_sb.h
@@ -0,0 +1,27 @@
+/*
+ * Name : qnx4_fs_sb.h
+ * Author : Richard Frowijn
+ * Function : qnx4 superblock definitions
+ * Version : 1.0
+ * Last modified : 20-05-1998
+ *
+ * History : 23-03-1998 created
+ *
+ */
+#ifndef _QNX4_FS_SB
+#define _QNX4_FS_SB
+
+#include <linux/qnxtypes.h>
+
+/*
+ * qnx4 super-block data in memory
+ */
+
+struct qnx4_sb_info {
+ struct buffer_head *sb_buf; /* superblock buffer */
+ struct qnx4_super_block *sb; /* our superblock */
+ unsigned int Version; /* may be useful */
+ struct qnx4_inode_entry *BitMap; /* useful */
+};
+
+#endif
diff --git a/include/linux/qnxtypes.h b/include/linux/qnxtypes.h
new file mode 100644
index 000000000..054da0d1d
--- /dev/null
+++ b/include/linux/qnxtypes.h
@@ -0,0 +1,28 @@
+/*
+ * Name : qnxtypes.h
+ * Author : Richard Frowijn
+ * Function : standard qnx types
+ * Version : 1.0
+ * Last modified : 22-03-1998
+ *
+ * History : 22-03-1998 created
+ *
+ */
+
+#ifndef _QNX4TYPES_H
+#define _QNX4TYPES_H
+
+typedef unsigned short _nxtnt_t;
+typedef unsigned char _ftype_t;
+
+typedef struct {
+ long xtnt_blk;
+ long xtnt_size;
+} _xtnt_t;
+
+typedef unsigned short muid_t;
+typedef unsigned short mgid_t;
+typedef unsigned long qnx_off_t;
+typedef unsigned short qnx_nlink_t;
+
+#endif
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h
index 4c8adc508..be607392c 100644
--- a/include/linux/rtnetlink.h
+++ b/include/linux/rtnetlink.h
@@ -5,7 +5,6 @@
#include <linux/netlink.h>
#define RTNL_DEBUG 1
-/* #define CONFIG_RTNL_OLD_IFINFO 1 */
/****
@@ -66,14 +65,14 @@ struct rtattr
#define RTA_ALIGNTO 4
#define RTA_ALIGN(len) ( ((len)+RTA_ALIGNTO-1) & ~(RTA_ALIGNTO-1) )
-#define RTA_OK(rta,len) ((rta)->rta_len >= sizeof(struct rtattr) && \
+#define RTA_OK(rta,len) ((len) > 0 && (rta)->rta_len >= sizeof(struct rtattr) && \
(rta)->rta_len <= (len))
#define RTA_NEXT(rta,attrlen) ((attrlen) -= RTA_ALIGN((rta)->rta_len), \
(struct rtattr*)(((char*)(rta)) + RTA_ALIGN((rta)->rta_len)))
#define RTA_LENGTH(len) (RTA_ALIGN(sizeof(struct rtattr)) + (len))
#define RTA_SPACE(len) RTA_ALIGN(RTA_LENGTH(len))
#define RTA_DATA(rta) ((void*)(((char*)(rta)) + RTA_LENGTH(0)))
-#define RTA_PAYLOAD(rta) ((rta)->rta_len - RTA_LENGTH(0))
+#define RTA_PAYLOAD(rta) ((int)((rta)->rta_len) - RTA_LENGTH(0))
@@ -91,18 +90,9 @@ struct rtmsg
unsigned char rtm_table; /* Routing table id */
unsigned char rtm_protocol; /* Routing protocol; see below */
-#ifdef CONFIG_RTNL_OLD_IFINFO
- unsigned char rtm_nhs; /* Number of nexthops */
-#else
unsigned char rtm_scope; /* See below */
-#endif
unsigned char rtm_type; /* See below */
-#ifdef CONFIG_RTNL_OLD_IFINFO
- unsigned short rtm_optlen; /* Byte length of rtm_opt */
- unsigned char rtm_scope; /* See below */
- unsigned char rtm_whatsit; /* Unused byte */
-#endif
unsigned rtm_flags;
};
@@ -176,9 +166,6 @@ enum rt_scope_t
#define RTM_F_NOTIFY 0x100 /* Notify user of route change */
#define RTM_F_CLONED 0x200 /* This route is cloned */
#define RTM_F_EQUALIZE 0x400 /* Multipath equalizer: NI */
-#ifdef CONFIG_RTNL_OLD_IFINFO
-#define RTM_F_NOPMTUDISC 0x800 /* Do not make PMTU discovery */
-#endif
/* Reserved table identifiers */
@@ -206,17 +193,10 @@ enum rtattr_type_t
RTA_GATEWAY,
RTA_PRIORITY,
RTA_PREFSRC,
-#ifndef CONFIG_RTNL_OLD_IFINFO
RTA_METRICS,
RTA_MULTIPATH,
RTA_PROTOINFO,
RTA_FLOW,
-#else
- RTA_WINDOW,
- RTA_RTT,
- RTA_MTU,
- RTA_IFNAME,
-#endif
RTA_CACHEINFO
};
@@ -253,18 +233,12 @@ struct rtnexthop
#define RTNH_ALIGNTO 4
#define RTNH_ALIGN(len) ( ((len)+RTNH_ALIGNTO-1) & ~(RTNH_ALIGNTO-1) )
#define RTNH_OK(rtnh,len) ((rtnh)->rtnh_len >= sizeof(struct rtnexthop) && \
- (rtnh)->rtnh_len <= (len))
+ ((int)(rtnh)->rtnh_len) <= (len))
#define RTNH_NEXT(rtnh) ((struct rtnexthop*)(((char*)(rtnh)) + RTNH_ALIGN((rtnh)->rtnh_len)))
#define RTNH_LENGTH(len) (RTNH_ALIGN(sizeof(struct rtnexthop)) + (len))
#define RTNH_SPACE(len) RTNH_ALIGN(RTNH_LENGTH(len))
#define RTNH_DATA(rtnh) ((struct rtattr*)(((char*)(rtnh)) + RTNH_LENGTH(0)))
-#ifdef CONFIG_RTNL_OLD_IFINFO
-#define RTM_RTNH(r) ((struct rtnexthop*)(((char*)(r)) + NLMSG_ALIGN(sizeof(struct rtmsg)) \
- + NLMSG_ALIGN((r)->rtm_optlen)))
-#define RTM_NHLEN(nlh,r) ((nlh)->nlmsg_len - NLMSG_SPACE(sizeof(struct rtmsg)) - NLMSG_ALIGN((r)->rtm_optlen))
-#endif
-
/* RTM_CACHEINFO */
struct rta_cacheinfo
@@ -424,35 +398,6 @@ struct rtgenmsg
* on network protocol.
*/
-#ifdef CONFIG_RTNL_OLD_IFINFO
-struct ifinfomsg
-{
- unsigned char ifi_family; /* Dummy */
- unsigned char ifi_addrlen; /* Length of HW address */
- unsigned short ifi_pad__;
- int ifi_index; /* Link index */
- int ifi_link; /* Physical device */
- char ifi_name[IFNAMSIZ];
- struct sockaddr ifi_address; /* HW address */
- struct sockaddr ifi_broadcast; /* HW broadcast */
- unsigned ifi_flags; /* IFF_* flags */
- int ifi_mtu; /* Link mtu */
- char ifi_qdiscname[IFNAMSIZ];/* Id of packet scheduler */
- int ifi_qdisc; /* Packet scheduler handle */
-};
-
-enum
-{
- IFLA_UNSPEC,
- IFLA_ADDRESS,
- IFLA_BROADCAST,
- IFLA_IFNAME,
- IFLA_QDISC,
- IFLA_STATS
-};
-
-#else
-
struct ifinfomsg
{
unsigned char ifi_family;
@@ -475,8 +420,6 @@ enum
IFLA_STATS
};
-#endif
-
#define IFLA_MAX IFLA_STATS
@@ -588,7 +531,7 @@ struct rtnetlink_link
extern struct rtnetlink_link * rtnetlink_links[NPROTO];
extern int rtnetlink_dump_ifinfo(struct sk_buff *skb, struct netlink_callback *cb);
-extern int rtnetlink_send(struct sk_buff *skb, u32 pid, unsigned group, int echo);
+extern int rtnetlink_send(struct sk_buff *skb, u32 pid, u32 group, int echo);
extern void __rta_fill(struct sk_buff *skb, int attrtype, int attrlen, const void *data);
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 7c9112136..e46e22263 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -64,7 +64,6 @@ extern unsigned long avenrun[]; /* Load averages */
extern int nr_running, nr_tasks;
extern int last_pid;
-#include <linux/head.h>
#include <linux/fs.h>
#include <linux/signal.h>
#include <linux/time.h>
diff --git a/include/linux/shm.h b/include/linux/shm.h
index f890c7356..50a7b772c 100644
--- a/include/linux/shm.h
+++ b/include/linux/shm.h
@@ -64,6 +64,7 @@ asmlinkage int sys_shmget (key_t key, int size, int flag);
asmlinkage int sys_shmat (int shmid, char *shmaddr, int shmflg, unsigned long *addr);
asmlinkage int sys_shmdt (char *shmaddr);
asmlinkage int sys_shmctl (int shmid, int cmd, struct shmid_ds *buf);
+extern void shm_unuse(unsigned long entry, unsigned long page);
#endif /* __KERNEL__ */
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h
index ee6c79970..c242c0907 100644
--- a/include/linux/skbuff.h
+++ b/include/linux/skbuff.h
@@ -537,6 +537,19 @@ extern __inline__ struct sk_buff *dev_alloc_skb(unsigned int length)
return skb;
}
+extern __inline__ struct sk_buff *
+skb_cow(struct sk_buff *skb, unsigned int headroom)
+{
+ headroom = (headroom+15)&~15;
+
+ if ((unsigned)skb_headroom(skb) < headroom || skb_cloned(skb)) {
+ struct sk_buff *skb2 = skb_realloc_headroom(skb, headroom);
+ kfree_skb(skb);
+ skb = skb2;
+ }
+ return skb;
+}
+
extern struct sk_buff * skb_recv_datagram(struct sock *sk,unsigned flags,int noblock, int *err);
extern unsigned int datagram_poll(struct file *file, struct socket *sock, struct poll_table_struct *wait);
extern int skb_copy_datagram(struct sk_buff *from, int offset, char *to,int size);
diff --git a/include/linux/smb_fs.h b/include/linux/smb_fs.h
index 2e83cf446..35478fe4d 100644
--- a/include/linux/smb_fs.h
+++ b/include/linux/smb_fs.h
@@ -9,7 +9,6 @@
#ifndef _LINUX_SMB_FS_H
#define _LINUX_SMB_FS_H
-#include <linux/dirent.h>
#include <linux/smb.h>
/*
diff --git a/include/linux/smb_mount.h b/include/linux/smb_mount.h
index 0a8a10ee2..886d945d5 100644
--- a/include/linux/smb_mount.h
+++ b/include/linux/smb_mount.h
@@ -15,12 +15,11 @@
struct smb_mount_data {
int version;
- uid_t mounted_uid; /* Who may umount() this filesystem? */
-
- uid_t uid;
- gid_t gid;
- mode_t file_mode;
- mode_t dir_mode;
+ __kernel_uid_t mounted_uid; /* Who may umount() this filesystem? */
+ __kernel_uid_t uid;
+ __kernel_gid_t gid;
+ __kernel_mode_t file_mode;
+ __kernel_mode_t dir_mode;
};
#endif
diff --git a/include/linux/socket.h b/include/linux/socket.h
index e8f4202d5..511e92426 100644
--- a/include/linux/socket.h
+++ b/include/linux/socket.h
@@ -88,20 +88,27 @@ struct cmsghdr {
/*
* Get the next cmsg header
+ *
+ * PLEASE, do not touch this function. If you think, that it is
+ * incorrect, grep kernel sources and think about consequences
+ * before trying to improve it.
+ *
+ * Now it always returns valid, not truncated ancillary object
+ * HEADER. But caller still MUST check, that cmsg->cmsg_len is
+ * inside range, given by msg->msg_controllen before using
+ * ansillary object DATA. --ANK (980731)
*/
__KINLINE struct cmsghdr * __cmsg_nxthdr(void *__ctl, __kernel_size_t __size,
struct cmsghdr *__cmsg)
{
- unsigned char * __ptr;
+ struct cmsghdr * __ptr;
- if (__cmsg->cmsg_len < sizeof(struct cmsghdr))
- return NULL;
- __ptr = ((unsigned char *) __cmsg) + CMSG_ALIGN(__cmsg->cmsg_len);
- if (__ptr >= (unsigned char *) __ctl + __size)
+ __ptr = (struct cmsghdr*)(((unsigned char *) __cmsg) + CMSG_ALIGN(__cmsg->cmsg_len));
+ if ((unsigned long)((char*)(__ptr+1) - (char *) __ctl) > __size)
return NULL;
- return (struct cmsghdr *) __ptr;
+ return __ptr;
}
__KINLINE struct cmsghdr * cmsg_nxthdr (struct msghdr *__msg, struct cmsghdr *__cmsg)
diff --git a/include/linux/sockios.h b/include/linux/sockios.h
index 4f41001aa..995e43e9a 100644
--- a/include/linux/sockios.h
+++ b/include/linux/sockios.h
@@ -45,6 +45,7 @@
#define SIOCSIFMEM 0x8920 /* set memory address (BSD) */
#define SIOCGIFMTU 0x8921 /* get MTU size */
#define SIOCSIFMTU 0x8922 /* set MTU size */
+#define SIOCSIFNAME 0x8923 /* set interface name */
#define SIOCSIFHWADDR 0x8924 /* set hardware address */
#define SIOCGIFENCAP 0x8925 /* get/set encapsulations */
#define SIOCSIFENCAP 0x8926
diff --git a/include/linux/sound.h b/include/linux/sound.h
index 7dabc388c..bc9335801 100644
--- a/include/linux/sound.h
+++ b/include/linux/sound.h
@@ -6,8 +6,10 @@ extern int register_sound_special(struct file_operations *, int);
extern int register_sound_mixer(struct file_operations *fops);
extern int register_sound_midi(struct file_operations *fops);
extern int register_sound_dsp(struct file_operations *fops);
+extern int register_sound_synth(struct file_operations *fops);
extern void unregister_sound_special(int unit);
extern void unregister_sound_mixer(int unit);
extern void unregister_sound_midi(int unit);
extern void unregister_sound_dsp(int unit);
+extern void unregister_sound_synth(int unit);
diff --git a/include/linux/string.h b/include/linux/string.h
index 214503c20..1b3fa4e51 100644
--- a/include/linux/string.h
+++ b/include/linux/string.h
@@ -26,6 +26,7 @@ extern __kernel_size_t strnlen(const char *,__kernel_size_t);
extern __kernel_size_t strspn(const char *,const char *);
extern int strcmp(const char *,const char *);
extern int strncmp(const char *,const char *,__kernel_size_t);
+extern int strnicmp(const char *, const char *, __kernel_size_t);
extern void * memset(void *,int,__kernel_size_t);
extern void * memcpy(void *,const void *,__kernel_size_t);
diff --git a/include/linux/sunrpc/clnt.h b/include/linux/sunrpc/clnt.h
index 8553a05c5..98a250051 100644
--- a/include/linux/sunrpc/clnt.h
+++ b/include/linux/sunrpc/clnt.h
@@ -118,6 +118,9 @@ int rpc_do_call(struct rpc_clnt *clnt, u32 proc,
void *argp, void *resp, int flags,
rpc_action callback, void *clntdata);
void rpc_restart_call(struct rpc_task *);
+void rpc_clnt_sigmask(struct rpc_clnt *clnt, sigset_t *oldset);
+void rpc_clnt_sigunmask(struct rpc_clnt *clnt, sigset_t *oldset);
+
#define rpc_call(clnt, proc, argp, resp, flags) \
rpc_do_call(clnt, proc, argp, resp, flags, NULL, NULL)
diff --git a/include/linux/sunrpc/sched.h b/include/linux/sunrpc/sched.h
index 697950b2e..f0f8e0384 100644
--- a/include/linux/sunrpc/sched.h
+++ b/include/linux/sunrpc/sched.h
@@ -146,6 +146,8 @@ void * rpc_allocate(unsigned int flags, unsigned int);
void rpc_free(void *);
int rpciod_up(void);
void rpciod_down(void);
+void rpciod_wake_up(void);
+void rpciod_tcp_dispatcher(void);
#ifdef RPC_DEBUG
void rpc_show_tasks(void);
#endif
diff --git a/include/linux/sunrpc/xprt.h b/include/linux/sunrpc/xprt.h
index 0037b5738..df16576d7 100644
--- a/include/linux/sunrpc/xprt.h
+++ b/include/linux/sunrpc/xprt.h
@@ -36,7 +36,7 @@
* Note: on machines with low memory we should probably use a smaller
* MAXREQS value: At 32 outstanding reqs with 8 megs of RAM, fragment
* reassembly will frequently run out of memory.
- * Come Linux 2.1, we'll handle fragments directly.
+ * Come Linux 2.3, we'll handle fragments directly.
*/
#define RPC_MAXCONG 16
#define RPC_MAXREQS (RPC_MAXCONG + 1)
@@ -103,6 +103,12 @@ struct rpc_rqst {
* For authentication (e.g. auth_des)
*/
u32 rq_creddata[2];
+
+ /*
+ * Partial send handling
+ */
+
+ u32 rq_bytes_sent; /* Bytes we have sent */
#ifdef RPC_PROFILE
unsigned long rq_xtime; /* when transmitted */
@@ -166,6 +172,8 @@ struct rpc_xprt {
*/
struct rpc_iov snd_buf; /* send buffer */
struct rpc_task * snd_task; /* Task blocked in send */
+ u32 snd_sent; /* Bytes we have sent */
+
void (*old_data_ready)(struct sock *, int);
void (*old_state_change)(struct sock *);
diff --git a/include/linux/swap.h b/include/linux/swap.h
index 3b4d2c983..0bcb6f6ed 100644
--- a/include/linux/swap.h
+++ b/include/linux/swap.h
@@ -7,6 +7,23 @@
#define MAX_SWAPFILES 8
+union swap_header {
+ struct
+ {
+ char reserved[PAGE_SIZE - 10];
+ char magic[10];
+ } magic;
+ struct
+ {
+ char bootbits[1024]; /* Space for disklabel etc. */
+ unsigned int version;
+ unsigned int last_page;
+ unsigned int nr_badpages;
+ unsigned int padding[125];
+ unsigned int badpages[1];
+ } info;
+};
+
#ifdef __KERNEL__
#undef DEBUG_SWAP
@@ -18,11 +35,14 @@
#define SWAP_CLUSTER_MAX 32
+#define SWAP_MAP_MAX 0x7fff
+#define SWAP_MAP_BAD 0x8000
+
struct swap_info_struct {
unsigned int flags;
kdev_t swap_device;
struct dentry * swap_file;
- unsigned char * swap_map;
+ unsigned short * swap_map;
unsigned char * swap_lockmap;
unsigned int lowest_bit;
unsigned int highest_bit;
@@ -55,6 +75,7 @@ extern int try_to_free_pages(unsigned int gfp_mask, int count);
/* linux/mm/page_io.c */
extern void rw_swap_page(int, unsigned long, char *, int);
extern void rw_swap_page_nocache(int, unsigned long, char *);
+extern void swap_after_unlock_page (unsigned long entry);
/* linux/mm/page_alloc.c */
extern void swap_in(struct task_struct *, struct vm_area_struct *,
@@ -64,10 +85,15 @@ extern void swap_in(struct task_struct *, struct vm_area_struct *,
/* linux/mm/swap_state.c */
extern void show_swap_cache_info(void);
extern int add_to_swap_cache(struct page *, unsigned long);
-extern void swap_duplicate(unsigned long);
-extern void swap_after_unlock_page (unsigned long entry);
+extern int swap_duplicate(unsigned long);
+extern int swap_check_entry(unsigned long);
extern struct page * read_swap_cache_async(unsigned long, unsigned long, int);
#define read_swap_cache(entry, addr) read_swap_cache_async(entry, addr, 1);
+/*
+ * Make these inline later once they are working properly.
+ */
+extern void delete_from_swap_cache(struct page *page);
+extern void free_page_and_swap_cache(unsigned long addr);
/* linux/mm/swapfile.c */
extern unsigned int nr_swapfiles;
@@ -80,6 +106,8 @@ struct swap_list_t {
int next; /* swapfile to be used next */
};
extern struct swap_list_t swap_list;
+int sys_swapoff(const char *);
+int sys_swapon(const char *, int);
/*
* vm_ops not present page codes for shared memory.
@@ -128,14 +156,6 @@ static inline int is_page_shared(struct page *page)
return (count > 1);
}
-/*
- * Make these inline later once they are working properly.
- */
-extern long find_in_swap_cache(struct page *page);
-extern int delete_from_swap_cache(struct page *page);
-extern void remove_from_swap_cache(struct page *page);
-extern void free_page_and_swap_cache(unsigned long addr);
-
#endif /* __KERNEL__*/
#endif /* _LINUX_SWAP_H */
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h
index ef9044aa1..c310573ee 100644
--- a/include/linux/sysctl.h
+++ b/include/linux/sysctl.h
@@ -2,6 +2,23 @@
* sysctl.h: General linux system control interface
*
* Begun 24 March 1995, Stephen Tweedie
+ *
+ ****************************************************************
+ ****************************************************************
+ **
+ ** WARNING:
+ ** The values in this file are exported to user space via
+ ** the sysctl() binary interface. Do *NOT* change the
+ ** numbering of any existing values here, and do not change
+ ** any numbers within any one set of values. If you have
+ ** to redefine an existing interface, use a new number for it.
+ ** The kernel will then return ENOTDIR to any application using
+ ** the old binary interface.
+ **
+ ** --sct
+ **
+ ****************************************************************
+ ****************************************************************
*/
#include <linux/lists.h>
@@ -33,32 +50,32 @@ struct __sysctl_args {
enum
{
- CTL_KERN=1, /* General kernel info and control */
+/*1*/ CTL_KERN=1, /* General kernel info and control */
CTL_VM, /* VM management */
CTL_NET, /* Networking */
CTL_PROC, /* Process info */
CTL_FS, /* Filesystems */
CTL_DEBUG, /* Debugging */
- CTL_DEV, /* Devices */
+/*7*/ CTL_DEV, /* Devices */
};
/* CTL_KERN names: */
enum
{
- KERN_OSTYPE=1, /* string: system version */
+/*1*/ KERN_OSTYPE=1, /* string: system version */
KERN_OSRELEASE, /* string: system release */
KERN_OSREV, /* int: system revision */
KERN_VERSION, /* string: compile time info */
KERN_SECUREMASK, /* struct: maximum rights mask */
KERN_PROF, /* table: profiling information */
KERN_NODENAME,
- KERN_DOMAINNAME,
- KERN_SECURELVL, /* int: system security level */
+/*8*/ KERN_DOMAINNAME,
+/*14*/ KERN_SECURELVL=14, /* int: system security level */
KERN_PANIC, /* int: panic timeout */
- KERN_REALROOTDEV, /* real root device to mount after initrd */
- KERN_JAVA_INTERPRETER, /* path to Java(tm) interpreter */
- KERN_JAVA_APPLETVIEWER, /* path to Java(tm) appletviewer */
+/*16*/ KERN_REALROOTDEV, /* real root device to mount after initrd */
+/*19*/ KERN_JAVA_INTERPRETER=19,/* path to Java(tm) interpreter */
+/*20*/ KERN_JAVA_APPLETVIEWER, /* path to Java(tm) appletviewer */
KERN_SPARC_REBOOT, /* reboot command on Sparc */
KERN_CTLALTDEL, /* int: allow ctl-alt-del to reboot */
KERN_PRINTK, /* sturct: control printk logging parameters */
@@ -67,14 +84,14 @@ enum
KERN_PPC_ZEROPAGED, /* turn idle page zeroing on/off on PPC */
KERN_PPC_POWERSAVE_NAP, /* use nap mode for power saving */
KERN_MODPROBE,
- KERN_SG_BIG_BUFF
+/*29*/ KERN_SG_BIG_BUFF
};
/* CTL_VM names: */
enum
{
- VM_SWAPCTL=1, /* struct: Set vm swapping control */
+/*1*/ VM_SWAPCTL=1, /* struct: Set vm swapping control */
VM_SWAPOUT, /* int: Background pageout interval */
VM_FREEPG, /* struct: Set free page thresholds */
VM_BDFLUSH, /* struct: Control buffer cache flushing */
@@ -82,14 +99,14 @@ enum
VM_BUFFERMEM, /* struct: Set buffer memory thresholds */
VM_PAGECACHE, /* struct: Set cache memory thresholds */
VM_PAGERDAEMON, /* struct: Control kswapd behaviour */
- VM_PGT_CACHE /* struct: Set page table cache parameters */
+/*9*/ VM_PGT_CACHE /* struct: Set page table cache parameters */
};
/* CTL_NET names: */
enum
{
- NET_CORE=1,
+/*1*/ NET_CORE=1,
NET_ETHER,
NET_802,
NET_UNIX,
@@ -98,19 +115,19 @@ enum
NET_ATALK,
NET_NETROM,
NET_AX25,
- NET_BRIDGE,
- NET_IPV6,
+/*10*/ NET_BRIDGE,
NET_ROSE,
+ NET_IPV6,
NET_X25,
NET_TR,
- NET_DECNET
+/*15*/ NET_DECNET
};
/* /proc/sys/net/core */
enum
{
- NET_CORE_WMEM_MAX=1,
+/*1*/ NET_CORE_WMEM_MAX=1,
NET_CORE_RMEM_MAX,
NET_CORE_WMEM_DEFAULT,
NET_CORE_RMEM_DEFAULT,
@@ -119,7 +136,7 @@ enum
NET_CORE_FASTROUTE,
NET_CORE_MSG_COST,
NET_CORE_MSG_BURST,
- NET_CORE_OPTMEM_MAX,
+/*10*/ NET_CORE_OPTMEM_MAX,
};
/* /proc/sys/net/ethernet */
@@ -130,23 +147,23 @@ enum
enum
{
- NET_UNIX_DESTROY_DELAY=1,
- NET_UNIX_DELETE_DELAY,
+/*1*/ NET_UNIX_DESTROY_DELAY=1,
+/*2*/ NET_UNIX_DELETE_DELAY,
};
/* /proc/sys/net/ipv4 */
enum
{
/* v2.0 compatibile variables */
- NET_IPV4_FORWARD = 8,
+/*8*/ NET_IPV4_FORWARD = 8,
NET_IPV4_DYNADDR = 9,
- NET_IPV4_CONF = 16,
+/*16*/ NET_IPV4_CONF = 16,
NET_IPV4_NEIGH = 17,
NET_IPV4_ROUTE = 18,
NET_IPV4_FIB_HASH = 19,
- NET_IPV4_TCP_HOE_RETRANSMITS=32,
+/*32*/ NET_IPV4_TCP_HOE_RETRANSMITS=32,
NET_IPV4_TCP_TIMESTAMPS,
NET_IPV4_TCP_WINDOW_SCALING,
NET_IPV4_TCP_SACK,
@@ -154,7 +171,7 @@ enum
NET_IPV4_DEFAULT_TTL,
NET_IPV4_AUTOCONFIG,
NET_IPV4_NO_PMTU_DISC,
- NET_IPV4_TCP_SYN_RETRIES,
+/*40*/ NET_IPV4_TCP_SYN_RETRIES,
NET_IPV4_IPFRAG_HIGH_THRESH,
NET_IPV4_IPFRAG_LOW_THRESH,
NET_IPV4_IPFRAG_TIME,
@@ -164,7 +181,7 @@ enum
NET_IPV4_TCP_RETRIES1,
NET_IPV4_TCP_RETRIES2,
NET_IPV4_TCP_FIN_TIMEOUT,
- NET_IPV4_IP_MASQ_DEBUG,
+/*50*/ NET_IPV4_IP_MASQ_DEBUG,
NET_TCP_SYNCOOKIES,
NET_TCP_STDURG,
NET_TCP_RFC1337,
@@ -174,14 +191,14 @@ enum
NET_IPV4_ICMP_ECHO_IGNORE_ALL,
NET_IPV4_ICMP_ECHO_IGNORE_BROADCASTS,
NET_IPV4_ICMP_SOURCEQUENCH_RATE,
- NET_IPV4_ICMP_DESTUNREACH_RATE,
+/*60*/ NET_IPV4_ICMP_DESTUNREACH_RATE,
NET_IPV4_ICMP_TIMEEXCEED_RATE,
NET_IPV4_ICMP_PARAMPROB_RATE,
- NET_IPV4_ICMP_ECHOREPLY_RATE,
+/*63*/ NET_IPV4_ICMP_ECHOREPLY_RATE,
};
enum {
- NET_IPV4_ROUTE_FLUSH = 1,
+/*1*/ NET_IPV4_ROUTE_FLUSH = 1,
NET_IPV4_ROUTE_MIN_DELAY,
NET_IPV4_ROUTE_MAX_DELAY,
NET_IPV4_ROUTE_GC_THRESH,
@@ -190,24 +207,24 @@ enum {
NET_IPV4_ROUTE_GC_TIMEOUT,
NET_IPV4_ROUTE_GC_INTERVAL,
NET_IPV4_ROUTE_REDIRECT_LOAD,
- NET_IPV4_ROUTE_REDIRECT_NUMBER,
+/*10*/ NET_IPV4_ROUTE_REDIRECT_NUMBER,
NET_IPV4_ROUTE_REDIRECT_SILENCE,
NET_IPV4_ROUTE_ERROR_COST,
NET_IPV4_ROUTE_ERROR_BURST,
- NET_IPV4_ROUTE_GC_ELASTICITY,
+/*14*/ NET_IPV4_ROUTE_GC_ELASTICITY,
};
enum
{
- NET_PROTO_CONF_ALL = -2,
- NET_PROTO_CONF_DEFAULT = -3,
+/*-2*/ NET_PROTO_CONF_ALL = -2,
+/*-3*/ NET_PROTO_CONF_DEFAULT = -3,
/* And device ifindices ... */
};
enum
{
- NET_IPV4_CONF_FORWARDING = 1,
+/*1*/ NET_IPV4_CONF_FORWARDING = 1,
NET_IPV4_CONF_MC_FORWARDING,
NET_IPV4_CONF_PROXY_ARP,
NET_IPV4_CONF_ACCEPT_REDIRECTS,
@@ -216,29 +233,29 @@ enum
NET_IPV4_CONF_SHARED_MEDIA,
NET_IPV4_CONF_RP_FILTER,
NET_IPV4_CONF_ACCEPT_SOURCE_ROUTE,
- NET_IPV4_CONF_BOOTP_RELAY,
- NET_IPV4_CONF_LOG_MARTIANS,
+/*10*/ NET_IPV4_CONF_BOOTP_RELAY,
+/*11*/ NET_IPV4_CONF_LOG_MARTIANS,
};
/* /proc/sys/net/ipv6 */
enum {
- NET_IPV6_CONF = 16,
+/*16*/ NET_IPV6_CONF = 16,
NET_IPV6_NEIGH = 17,
- NET_IPV6_ROUTE = 18,
+/*18*/ NET_IPV6_ROUTE = 18,
};
enum {
- NET_IPV6_ROUTE_FLUSH = 1,
+/*1*/ NET_IPV6_ROUTE_FLUSH = 1,
NET_IPV6_ROUTE_GC_THRESH,
NET_IPV6_ROUTE_MAX_SIZE,
NET_IPV6_ROUTE_GC_MIN_INTERVAL,
NET_IPV6_ROUTE_GC_TIMEOUT,
NET_IPV6_ROUTE_GC_INTERVAL,
- NET_IPV6_ROUTE_GC_ELASTICITY,
+/*7*/ NET_IPV6_ROUTE_GC_ELASTICITY,
};
enum {
- NET_IPV6_FORWARDING = 1,
+/*1*/ NET_IPV6_FORWARDING = 1,
NET_IPV6_HOP_LIMIT,
NET_IPV6_MTU,
NET_IPV6_ACCEPT_RA,
@@ -247,12 +264,12 @@ enum {
NET_IPV6_DAD_TRANSMITS,
NET_IPV6_RTR_SOLICITS,
NET_IPV6_RTR_SOLICIT_INTERVAL,
- NET_IPV6_RTR_SOLICIT_DELAY,
+/*10*/ NET_IPV6_RTR_SOLICIT_DELAY,
};
/* /proc/sys/net/<protocol>/neigh/<dev> */
enum {
- NET_NEIGH_MCAST_SOLICIT=1,
+/*1*/ NET_NEIGH_MCAST_SOLICIT=1,
NET_NEIGH_UCAST_SOLICIT,
NET_NEIGH_APP_SOLICIT,
NET_NEIGH_RETRANS_TIME,
@@ -261,13 +278,13 @@ enum {
NET_NEIGH_GC_STALE_TIME,
NET_NEIGH_UNRES_QLEN,
NET_NEIGH_PROXY_QLEN,
- NET_NEIGH_ANYCAST_DELAY,
+/*10*/ NET_NEIGH_ANYCAST_DELAY,
NET_NEIGH_PROXY_DELAY,
NET_NEIGH_LOCKTIME,
NET_NEIGH_GC_INTERVAL,
NET_NEIGH_GC_THRESH1,
NET_NEIGH_GC_THRESH2,
- NET_NEIGH_GC_THRESH3
+/*16*/ NET_NEIGH_GC_THRESH3
};
/* /proc/sys/net/ipx */
@@ -275,16 +292,16 @@ enum {
/* /proc/sys/net/appletalk */
enum {
- NET_ATALK_AARP_EXPIRY_TIME = 1,
+/*1*/ NET_ATALK_AARP_EXPIRY_TIME = 1,
NET_ATALK_AARP_TICK_TIME,
NET_ATALK_AARP_RETRANSMIT_LIMIT,
- NET_ATALK_AARP_RESOLVE_TIME,
+/*4*/ NET_ATALK_AARP_RESOLVE_TIME,
};
/* /proc/sys/net/netrom */
enum {
- NET_NETROM_DEFAULT_PATH_QUALITY = 1,
+/*1*/ NET_NETROM_DEFAULT_PATH_QUALITY = 1,
NET_NETROM_OBSOLESCENCE_COUNT_INITIALISER,
NET_NETROM_NETWORK_TTL_INITIALISER,
NET_NETROM_TRANSPORT_TIMEOUT,
@@ -293,13 +310,13 @@ enum {
NET_NETROM_TRANSPORT_BUSY_DELAY,
NET_NETROM_TRANSPORT_REQUESTED_WINDOW_SIZE,
NET_NETROM_TRANSPORT_NO_ACTIVITY_TIMEOUT,
- NET_NETROM_ROUTING_CONTROL,
- NET_NETROM_LINK_FAILS_COUNT
+/*10*/ NET_NETROM_ROUTING_CONTROL,
+/*11*/ NET_NETROM_LINK_FAILS_COUNT
};
/* /proc/sys/net/ax25 */
enum {
- NET_AX25_IP_DEFAULT_MODE = 1,
+/*1*/ NET_AX25_IP_DEFAULT_MODE = 1,
NET_AX25_DEFAULT_MODE,
NET_AX25_BACKOFF_TYPE,
NET_AX25_CONNECT_MODE,
@@ -308,50 +325,50 @@ enum {
NET_AX25_T1_TIMEOUT,
NET_AX25_T2_TIMEOUT,
NET_AX25_T3_TIMEOUT,
- NET_AX25_IDLE_TIMEOUT,
+/*10*/ NET_AX25_IDLE_TIMEOUT,
NET_AX25_N2,
NET_AX25_PACLEN,
NET_AX25_PROTOCOL,
- NET_AX25_DAMA_SLAVE_TIMEOUT
+/*14*/ NET_AX25_DAMA_SLAVE_TIMEOUT
};
/* /proc/sys/net/rose */
enum {
- NET_ROSE_RESTART_REQUEST_TIMEOUT = 1,
+/*1*/ NET_ROSE_RESTART_REQUEST_TIMEOUT = 1,
NET_ROSE_CALL_REQUEST_TIMEOUT,
NET_ROSE_RESET_REQUEST_TIMEOUT,
NET_ROSE_CLEAR_REQUEST_TIMEOUT,
- NET_ROSE_NO_ACTIVITY_TIMEOUT,
NET_ROSE_ACK_HOLD_BACK_TIMEOUT,
NET_ROSE_ROUTING_CONTROL,
NET_ROSE_LINK_FAIL_TIMEOUT,
NET_ROSE_MAX_VCS,
- NET_ROSE_WINDOW_SIZE
+ NET_ROSE_WINDOW_SIZE,
+/*10*/ NET_ROSE_NO_ACTIVITY_TIMEOUT,
};
/* /proc/sys/net/x25 */
enum {
- NET_X25_RESTART_REQUEST_TIMEOUT = 1,
+/*1*/ NET_X25_RESTART_REQUEST_TIMEOUT = 1,
NET_X25_CALL_REQUEST_TIMEOUT,
NET_X25_RESET_REQUEST_TIMEOUT,
NET_X25_CLEAR_REQUEST_TIMEOUT,
- NET_X25_ACK_HOLD_BACK_TIMEOUT
+/*5*/ NET_X25_ACK_HOLD_BACK_TIMEOUT
};
/* /proc/sys/net/token-ring */
enum
{
- NET_TR_RIF_TIMEOUT=1
+/*1*/ NET_TR_RIF_TIMEOUT=1
};
/* /proc/sys/net/decnet */
enum {
- NET_DECNET_DEF_T3_BROADCAST = 1,
+/*1*/ NET_DECNET_DEF_T3_BROADCAST = 1,
NET_DECNET_DEF_T3_POINTTOPOINT,
NET_DECNET_DEF_T1,
NET_DECNET_DEF_BCT1,
NET_DECNET_CACHETIMEOUT,
- NET_DECNET_DEBUG_LEVEL
+/*6*/ NET_DECNET_DEBUG_LEVEL
};
/* CTL_PROC names: */
@@ -359,7 +376,7 @@ enum {
/* CTL_FS names: */
enum
{
- FS_NRINODE=1, /* int: current number of allocated inodes */
+/*1*/ FS_NRINODE=1, /* int: current number of allocated inodes */
FS_STATINODE,
FS_MAXINODE, /* int: maximum number of inodes that can be allocated */
FS_NRDQUOT, /* int: current number of allocated dquots */
@@ -367,18 +384,21 @@ enum
FS_NRFILE, /* int: current number of allocated filedescriptors */
FS_MAXFILE, /* int: maximum number of filedescriptors that can be allocated */
FS_DENTRY,
+ FS_NRSUPER, /* int: current number of allocated super_blocks */
+/*10*/ FS_MAXSUPER, /* int: maximum number of super_blocks that can be allocated */
};
/* CTL_DEBUG names: */
/* CTL_DEV names: */
enum {
- DEV_CDROM = 1,
+/*1*/ DEV_CDROM = 1,
+/*2*/ DEV_HWMON,
};
/* /proc/sys/dev/cdrom */
enum {
- DEV_CDROM_INFO = 1,
+/*1*/ DEV_CDROM_INFO = 1,
};
#ifdef __KERNEL__
diff --git a/include/linux/ufs_fs.h b/include/linux/ufs_fs.h
index 70740489c..1b8d98b22 100644
--- a/include/linux/ufs_fs.h
+++ b/include/linux/ufs_fs.h
@@ -6,7 +6,7 @@
* Laboratory for Computer Science Research Computing Facility
* Rutgers, The State University of New Jersey
*
- * Clean swab support by Fare <rideau@ens.fr>
+ * Clean swab support by Fare <fare@tunes.org>
* just hope no one is using NNUUXXI on __?64 structure elements
* 64-bit clean thanks to Maciej W. Rozycki <macro@ds2.pg.gda.pl>
*
@@ -31,8 +31,8 @@
#define UFS_SBLOCK 8192
#define UFS_SBSIZE 8192
-#define SECTOR_SIZE 512
-#define SECTOR_BITS 9
+#define UFS_SECTOR_SIZE 512
+#define UFS_SECTOR_BITS 9
#define UFS_MAGIC 0x00011954
#define UFS_CIGAM 0x54190100 /* byteswapped MAGIC */
@@ -68,8 +68,15 @@
/* From here to next blank line, s_flags for ufs_sb_info */
/* endianness */
#define UFS_BYTESEX 0x00000001 /* mask; leave room to 0xF */
+#if defined(__LITTLE_ENDIAN) || defined(__BIG_ENDIAN)
+/* these are for sane architectures */
+#define UFS_NATIVE_ENDIAN 0x00000000
+#define UFS_SWABBED_ENDIAN 0x00000001
+#else
+/* these are for pervert architectures */
#define UFS_LITTLE_ENDIAN 0x00000000
#define UFS_BIG_ENDIAN 0x00000001
+#endif
/* directory entry encoding */
#define UFS_DE_MASK 0x00000010 /* mask for the following */
#define UFS_DE_OLD 0x00000000
diff --git a/include/linux/umsdos_fs.h b/include/linux/umsdos_fs.h
index c9cfd16e6..7a170c115 100644
--- a/include/linux/umsdos_fs.h
+++ b/include/linux/umsdos_fs.h
@@ -1,6 +1,9 @@
#ifndef LINUX_UMSDOS_FS_H
#define LINUX_UMSDOS_FS_H
+/* #define UMSDOS_DEBUG 1 */
+#define UMSDOS_PARANOIA 1
+
#define UMSDOS_VERSION 0
#define UMSDOS_RELEASE 4
@@ -15,6 +18,9 @@
#ifndef _LINUX_TYPES_H
#include <linux/types.h>
#endif
+#ifndef _LINUX_LIMITS_H
+#include <linux/limits.h>
+#endif
#ifndef _LINUX_DIRENT_H
#include <linux/dirent.h>
#endif
@@ -23,6 +29,27 @@
#endif
+#ifdef __KERNEL__
+/* #Specification: convention / PRINTK Printk and printk
+ * Here is the convention for the use of printk inside fs/umsdos
+ *
+ * printk carry important message (error or status).
+ * Printk is for debugging (it is a macro defined at the beginning of
+ * most source.
+ * PRINTK is a nulled Printk macro.
+ *
+ * This convention makes the source easier to read, and Printk easier
+ * to shut off.
+ */
+# define PRINTK(x)
+# ifdef UMSDOS_DEBUG
+# define Printk(x) printk x
+# else
+# define Printk(x)
+# endif
+#endif
+
+
struct umsdos_fake_info {
char fname[13];
int len;
@@ -93,7 +120,7 @@ struct umsdos_info {
#define UMSDOS_READDIR_EMD _IO(0x04,216) /* read the EMD file only. */
#define UMSDOS_GETVERSION _IO(0x04,217) /* Get the release number of UMSDOS */
#define UMSDOS_INIT_EMD _IO(0x04,218) /* Create the EMD file if not there */
-#define UMSDOS_DOS_SETUP _IO(0x04,219) /* Set the defaults of the MsDOS driver */
+#define UMSDOS_DOS_SETUP _IO(0x04,219) /* Set the defaults of the MS-DOS driver. */
#define UMSDOS_RENAME_DOS _IO(0x04,220) /* rename a file/directory in the DOS
* directory only */
diff --git a/include/linux/umsdos_fs.p b/include/linux/umsdos_fs.p
index 0a7475a1c..44a6eec2b 100644
--- a/include/linux/umsdos_fs.p
+++ b/include/linux/umsdos_fs.p
@@ -1,19 +1,22 @@
/* check.c 23/01/95 03.38.30 */
void check_page_tables (void);
+
/* dir.c 22/06/95 00.22.12 */
int compat_msdos_create(struct inode *dir,
const char *name,
int len,
int mode,
struct inode **inode);
-int UMSDOS_dir_read ( struct file *filp,
+int dummy_dir_read ( struct file *filp,
char *buf,
size_t size,
loff_t *count);
+void umsdos_lookup_patch_new(struct dentry *, struct umsdos_dirent *, off_t);
void umsdos_lookup_patch (struct inode *dir,
struct inode *inode,
struct umsdos_dirent *entry,
off_t emd_pos);
+int umsdos_dentry_to_entry (struct dentry *, struct umsdos_dirent *);
int umsdos_inode2entry (struct inode *dir,
struct inode *inode,
struct umsdos_dirent *entry);
@@ -23,89 +26,74 @@ int umsdos_lookup_x (
struct inode *dir,
struct dentry *dentry,
int nopseudo);
-int UMSDOS_lookup(struct inode *dir,struct dentry *dentry);
-
-int umsdos_hlink2inode (struct inode *hlink, struct inode **result);
+int UMSDOS_lookup(struct inode *, struct dentry *);
+struct dentry *umsdos_lookup_dentry(struct dentry *, char *, int);
+
+struct dentry *umsdos_solve_hlink (struct dentry *hlink);
+
/* emd.c 22/06/95 00.22.04 */
ssize_t umsdos_file_write_kmem_real (struct file *filp,
const char *buf,
- size_t count,
- loff_t *offs);
+ size_t count);
-ssize_t umsdos_file_read_kmem (struct inode *emd_dir,
- struct file *filp,
+ssize_t umsdos_file_read_kmem (struct file *filp,
char *buf,
- size_t count,
- loff_t *offs);
-ssize_t umsdos_file_write_kmem (struct inode *emd_dir,
- struct file *filp,
+ size_t count);
+ssize_t umsdos_file_write_kmem (struct file *filp,
const char *buf,
- size_t count,
- loff_t *offs);
-ssize_t umsdos_emd_dir_write (struct inode *emd_dir,
- struct file *filp,
+ size_t count);
+ssize_t umsdos_emd_dir_write (struct file *filp,
char *buf,
- size_t count,
- loff_t *offs);
-ssize_t umsdos_emd_dir_read (struct inode *emd_dir,
- struct file *filp,
+ size_t count);
+ssize_t umsdos_emd_dir_read (struct file *filp,
char *buf,
- size_t count,
- loff_t *loffs);
+ size_t count);
+struct dentry *umsdos_get_emd_dentry(struct dentry *);
+int umsdos_have_emd(struct dentry *);
+int umsdos_make_emd(struct dentry *);
struct inode *umsdos_emd_dir_lookup (struct inode *dir, int creat);
-int umsdos_emd_dir_readentry (struct inode *emd_dir,
- struct file *filp,
- struct umsdos_dirent *entry);
-int umsdos_writeentry (struct inode *dir,
- struct inode *emd_dir,
- struct umsdos_info *info,
- int free_entry);
-int umsdos_newentry (struct inode *dir, struct umsdos_info *info);
-int umsdos_newhidden (struct inode *dir, struct umsdos_info *info);
-int umsdos_delentry (struct inode *dir,
- struct umsdos_info *info,
- int isdir);
-int umsdos_isempty (struct inode *dir);
-int umsdos_findentry (struct inode *dir,
- struct umsdos_info *info,
- int expect);
+int umsdos_emd_dir_readentry (struct file *, struct umsdos_dirent *);
+int umsdos_newentry (struct dentry *, struct umsdos_info *);
+int umsdos_newhidden (struct dentry *, struct umsdos_info *);
+int umsdos_delentry (struct dentry *, struct umsdos_info *, int);
+int umsdos_findentry (struct dentry *, struct umsdos_info *, int);
+int umsdos_isempty (struct dentry *);
+
/* file.c 25/01/95 02.25.38 */
+
/* inode.c 12/06/95 09.49.40 */
inline struct dentry *geti_dentry (struct inode *inode);
-inline void inc_count (struct inode *inode);
+void checkd_inode (struct inode *inode);
void check_inode (struct inode *inode);
void check_dentry (struct dentry *dentry);
+void check_dentry_path (struct dentry *dentry, const char *desc);
void fill_new_filp (struct file *filp, struct dentry *dentry);
-void kill_dentry (struct dentry *dentry);
struct dentry *creat_dentry (const char *name,
const int len,
struct inode *inode,
struct dentry *parent);
-void UMSDOS_put_inode (struct inode *inode);
-void UMSDOS_put_super (struct super_block *sb);
-int UMSDOS_statfs (struct super_block *sb,
- struct statfs *buf,
- int bufsiz);
-int compat_umsdos_real_lookup (struct inode *dir,
+void UMSDOS_read_inode (struct inode *);
+void UMSDOS_write_inode (struct inode *);
+int UMSDOS_notify_change (struct dentry *, struct iattr *attr);
+void UMSDOS_put_inode (struct inode *);
+int UMSDOS_statfs (struct super_block *, struct statfs *, int);
+struct super_block *UMSDOS_read_super (struct super_block *, void *, int);
+void UMSDOS_put_super (struct super_block *);
+
+struct dentry *compat_umsdos_real_lookup (struct dentry *d_dir,
const char *name,
- int len,
- struct inode **result);
-int umsdos_real_lookup(struct inode *inode,struct dentry *dentry);
+ int len);
+int umsdos_real_lookup(struct inode *, struct dentry *);
+void umsdos_setup_dir(struct dentry *);
void umsdos_setup_dir_inode (struct inode *inode);
void umsdos_set_dirinfo (struct inode *inode,
struct inode *dir,
off_t f_pos);
int umsdos_isinit (struct inode *inode);
-void umsdos_patch_inode (struct inode *inode,
- struct inode *dir,
- off_t f_pos);
+void umsdos_patch_dentry_inode (struct dentry *, off_t);
+void umsdos_patch_inode (struct inode *, struct inode *, off_t);
int umsdos_get_dirowner (struct inode *inode, struct inode **result);
-void UMSDOS_read_inode (struct inode *inode);
-void UMSDOS_write_inode (struct inode *inode);
-int UMSDOS_notify_change (struct dentry *dentry, struct iattr *attr);
-struct super_block *UMSDOS_read_super (struct super_block *s,
- void *data,
- int silent);
+
/* ioctl.c 22/06/95 00.22.08 */
int UMSDOS_ioctl_dir (struct inode *dir,
struct file *filp,
@@ -115,12 +103,16 @@ int UMSDOS_ioctl_dir (struct inode *dir,
void umsdos_manglename (struct umsdos_info *info);
int umsdos_evalrecsize (int len);
int umsdos_parse (const char *name,int len, struct umsdos_info *info);
+
/* namei.c 25/01/95 02.25.38 */
void umsdos_lockcreate (struct inode *dir);
void umsdos_startlookup (struct inode *dir);
void umsdos_unlockcreate (struct inode *dir);
void umsdos_endlookup (struct inode *dir);
+int umsdos_readlink_x ( struct dentry *dentry,
+ char *buffer,
+ int bufsiz);
int UMSDOS_symlink (struct inode *dir,
struct dentry *dentry,
const char *symname);
@@ -144,6 +136,7 @@ int UMSDOS_rename (struct inode *old_dir,
struct dentry *old_dentry,
struct inode *new_dir,
struct dentry *new_dentry);
+
/* rdir.c 22/03/95 03.31.42 */
int umsdos_rlookup_x (struct inode *dir,
struct dentry *dentry,
diff --git a/include/linux/videodev.h b/include/linux/videodev.h
index 701fb8870..e089d607e 100644
--- a/include/linux/videodev.h
+++ b/include/linux/videodev.h
@@ -47,6 +47,7 @@ extern void video_unregister_device(struct video_device *);
#define VID_TYPE_FRAMERAM 64 /* Uses the frame buffer memory */
#define VID_TYPE_SCALES 128 /* Scalable */
#define VID_TYPE_MONOCHROME 256 /* Monochrome only */
+#define VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */
struct video_capability
{
@@ -72,6 +73,7 @@ struct video_channel
__u16 type;
#define VIDEO_TYPE_TV 1
#define VIDEO_TYPE_CAMERA 2
+ __u16 norm; /* Norm set by channel */
};
struct video_tuner
@@ -84,6 +86,7 @@ struct video_tuner
#define VIDEO_TUNER_NTSC 2
#define VIDEO_TUNER_SECAM 4
#define VIDEO_TUNER_LOW 8 /* Uses KHz not MHz */
+#define VIDEO_TUNER_NORM 16 /* Tuner can set norm */
#define VIDEO_TUNER_STEREO_ON 128 /* Tuner is seeing stereo */
__u16 mode; /* PAL/NTSC/SECAM/OTHER */
#define VIDEO_MODE_PAL 0
@@ -135,6 +138,8 @@ struct video_audio
#define VIDEO_SOUND_LANG1 3
#define VIDEO_SOUND_LANG2 4
__u16 mode;
+ __u16 balance; /* Stereo balance */
+ __u16 step; /* Step actual volume uses */
};
struct video_clip
@@ -146,8 +151,8 @@ struct video_clip
struct video_window
{
- __u32 x,y;
- __u32 width,height;
+ __u32 x,y; /* Position of window */
+ __u32 width,height; /* Its size */
__u32 chromakey;
__u32 flags;
struct video_clip *clips; /* Set only */
@@ -155,6 +160,16 @@ struct video_window
#define VIDEO_WINDOW_INTERLACE 1
};
+struct video_capture
+{
+ __u32 x,y; /* Offsets into image */
+ __u32 width, height; /* Area to capture */
+ __u16 decimation; /* Decimation divder */
+ __u16 flags; /* Flags for capture */
+#define VIDEO_CAPTURE_ODD 0 /* Temporal */
+#define VIDEO_CAPTURE_EVEN 1
+};
+
struct video_buffer
{
void *base;
@@ -165,9 +180,9 @@ struct video_buffer
struct video_mmap
{
- unsigned int frame; /* Frame (0 or 1) for double buffer */
- int height,width;
- unsigned int format; /* should be VIDEO_PALETTE_* */
+ unsigned int frame; /* Frame (0 - n) for double buffer */
+ int height,width;
+ unsigned int format; /* should be VIDEO_PALETTE_* */
};
struct video_key
@@ -175,10 +190,33 @@ struct video_key
__u8 key[8];
__u32 flags;
};
+
+
+#define VIDEO_MAX_FRAME 32
+
+struct video_mbuf
+{
+ int size; /* Total memory to map */
+ int frames; /* Frames */
+ int offsets[VIDEO_MAX_FRAME];
+};
+
+#define VIDEO_NO_UNIT (-1)
+
+
+struct video_unit
+{
+ int video; /* Video minor */
+ int vbi; /* VBI minor */
+ int radio; /* Radio minor */
+ int audio; /* Audio minor */
+ int teletext; /* Teletext minor */
+};
+
#define VIDIOCGCAP _IOR('v',1,struct video_capability) /* Get capabilities */
#define VIDIOCGCHAN _IOWR('v',2,struct video_channel) /* Get channel info (sources) */
-#define VIDIOCSCHAN _IOW('v',3,int) /* Set channel */
+#define VIDIOCSCHAN _IOW('v',3,struct video_channel) /* Set channel */
#define VIDIOCGTUNER _IOWR('v',4,struct video_tuner) /* Get tuner abilities */
#define VIDIOCSTUNER _IOW('v',5,struct video_tuner) /* Tune the tuner for the current channel */
#define VIDIOCGPICT _IOR('v',6,struct video_picture) /* Get picture properties */
@@ -193,9 +231,12 @@ struct video_key
#define VIDIOCSFREQ _IOW('v',15, unsigned long) /* Set tuner */
#define VIDIOCGAUDIO _IOR('v',16, struct video_audio) /* Get audio info */
#define VIDIOCSAUDIO _IOW('v',17, struct video_audio) /* Audio source, mute etc */
-#define VIDIOCSYNC _IO('v',18) /* Sync with mmap grabbing */
+#define VIDIOCSYNC _IOW('v',18, int) /* Sync with mmap grabbing */
#define VIDIOCMCAPTURE _IOW('v',19, struct video_mmap) /* Grab frames */
-
+#define VIDIOCGMBUF _IOR('v', 20, struct video_mbuf) /* Memory map buffer info */
+#define VIDIOCGUNIT _IOR('v', 21, struct video_unit) /* Get attached units */
+#define VIDIOCGCAPTURE _IOR('v',22, struct video_capture) /* Get frame buffer */
+#define VIDIOCSCAPTURE _IOW('v',23, struct video_capture) /* Set frame buffer - root only */
#define BASE_VIDIOCPRIVATE 192 /* 192-255 are private */
@@ -213,6 +254,8 @@ struct video_key
#define VID_HARDWARE_SAA7146 11
#define VID_HARDWARE_VIDEUM 12 /* Reserved for Winnov videum */
#define VID_HARDWARE_RTRACK2 13
+#define VID_HARDWARE_PERMEDIA2 14 /* Reserved for Permedia2 */
+#define VID_HARDWARE_RIVA128 15 /* Reserved for RIVA 128 */
/*
* Initialiser list