summaryrefslogtreecommitdiffstats
path: root/include/linux
diff options
context:
space:
mode:
Diffstat (limited to 'include/linux')
-rw-r--r--include/linux/a.out.h2
-rw-r--r--include/linux/arcdevice.h353
-rw-r--r--include/linux/blk.h3
-rw-r--r--include/linux/dcache.h34
-rw-r--r--include/linux/fd.h2
-rw-r--r--include/linux/fs.h21
-rw-r--r--include/linux/hdlcdrv.h2
-rw-r--r--include/linux/hfmodem.h254
-rw-r--r--include/linux/if.h3
-rw-r--r--include/linux/if_arcnet.h63
-rw-r--r--include/linux/if_pppvar.h6
-rw-r--r--include/linux/ip_fw.h8
-rw-r--r--include/linux/kernel.h10
-rw-r--r--include/linux/lp.h1
-rw-r--r--include/linux/msdos_fs.h2
-rw-r--r--include/linux/netdevice.h15
-rw-r--r--include/linux/nfs_fs_i.h7
-rw-r--r--include/linux/nfsd/nfsfh.h2
-rw-r--r--include/linux/nfsd/syscall.h3
-rw-r--r--include/linux/openpic.h364
-rw-r--r--include/linux/parport.h5
-rw-r--r--include/linux/pci.h85
-rw-r--r--include/linux/proc_fs.h13
-rw-r--r--include/linux/sched.h10
-rw-r--r--include/linux/smb.h181
-rw-r--r--include/linux/smb_fs.h197
-rw-r--r--include/linux/smb_fs_i.h26
-rw-r--r--include/linux/smb_fs_sb.h69
-rw-r--r--include/linux/smb_mount.h17
-rw-r--r--include/linux/sockios.h3
-rw-r--r--include/linux/sysctl.h3
-rw-r--r--include/linux/trdevice.h2
-rw-r--r--include/linux/tty.h5
-rw-r--r--include/linux/udp.h8
34 files changed, 1413 insertions, 366 deletions
diff --git a/include/linux/a.out.h b/include/linux/a.out.h
index 172664afa..af8a1dfa5 100644
--- a/include/linux/a.out.h
+++ b/include/linux/a.out.h
@@ -34,7 +34,7 @@ enum machine_type {
/* skip a bunch so we don't run into any of sun's numbers */
M_386 = 100,
M_MIPS1 = 151, /* MIPS R3000/R3000 binary */
- M_MIPS2 = 152, /* MIPS R6000/R4000 binary */
+ M_MIPS2 = 152 /* MIPS R6000/R4000 binary */
};
#if !defined (N_MAGIC)
diff --git a/include/linux/arcdevice.h b/include/linux/arcdevice.h
new file mode 100644
index 000000000..843c0ad8c
--- /dev/null
+++ b/include/linux/arcdevice.h
@@ -0,0 +1,353 @@
+/*
+ * INET An implementation of the TCP/IP protocol suite for the LINUX
+ * operating system. NET is implemented using the BSD Socket
+ * interface as the means of communication with the user level.
+ *
+ * Definitions for the ARCnet handlers.
+ *
+ * Version: $Id: arcdevice.h,v 1.2 1997/09/05 08:57:56 mj Exp $
+ *
+ * Authors: Avery Pennarun <apenwarr@bond.net>
+ * David Woodhouse <dwmw2@cam.ac.uk>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version
+ * 2 of the License, or (at your option) any later version.
+ *
+ */
+#ifndef _LINUX_ARCDEVICE_H
+#define _LINUX_ARCDEVICE_H
+
+#include <linux/config.h>
+#include <linux/if_arcnet.h>
+
+#ifdef __KERNEL__
+
+#define ARC_20020 1
+#define ARC_RIM_I 2
+#define ARC_90xx 3
+#define ARC_90xx_IO 4
+
+#define MAX_ARCNET_DEVS 8
+
+
+/* The card sends the reconfiguration signal when it loses the connection to
+ * the rest of its network. It is a 'Hello, is anybody there?' cry. This
+ * usually happens when a new computer on the network is powered on or when
+ * the cable is broken.
+ *
+ * Define DETECT_RECONFIGS if you want to detect network reconfigurations.
+ * Recons may be a real nuisance on a larger ARCnet network; if you are a
+ * network administrator you probably would like to count them.
+ * Reconfigurations will be recorded in stats.tx_carrier_errors (the last
+ * field of the /proc/net/dev file).
+ *
+ * Define SHOW_RECONFIGS if you really want to see a log message whenever
+ * a RECON occurs.
+ */
+#define DETECT_RECONFIGS
+#undef SHOW_RECONFIGS
+
+
+/* RECON_THRESHOLD is the maximum number of RECON messages to receive within
+ * one minute before printing a "cabling problem" warning. You must have
+ * DETECT_RECONFIGS enabled if you want to use this. The default value
+ * should be fine.
+ *
+ * After that, a "cabling restored" message will be printed on the next IRQ
+ * if no RECON messages have been received for 10 seconds.
+ *
+ * Do not define RECON_THRESHOLD at all if you want to disable this feature.
+ */
+#define RECON_THRESHOLD 30
+
+
+/* Define this to the minimum "timeout" value. If a transmit takes longer
+ * than TX_TIMEOUT jiffies, Linux will abort the TX and retry. On a large
+ * network, or one with heavy network traffic, this timeout may need to be
+ * increased. The larger it is, though, the longer it will be between
+ * necessary transmits - don't set this too large.
+ */
+#define TX_TIMEOUT 20
+
+
+/* Display warnings about the driver being an ALPHA version.
+ */
+#define ALPHA_WARNING
+
+
+/* New debugging bitflags: each option can be enabled individually.
+ *
+ * These can be set while the driver is running by typing:
+ * ifconfig arc0 down metric 1xxx HOSTNAME
+ * where 1xxx is 1000 + the debug level you want
+ * and HOSTNAME is your hostname/ip address
+ * and then resetting your routes.
+ *
+ * An ioctl() should be used for this instead, someday.
+ *
+ * Note: only debug flags included in the ARCNET_DEBUG_MAX define will
+ * actually be available. GCC will (at least, GCC 2.7.0 will) notice
+ * lines using a BUGLVL not in ARCNET_DEBUG_MAX and automatically optimize
+ * them out.
+ */
+#define D_NORMAL 1 /* important operational info */
+#define D_EXTRA 2 /* useful, but non-vital information */
+#define D_INIT 4 /* show init/probe messages */
+#define D_INIT_REASONS 8 /* show reasons for discarding probes */
+/* debug levels below give LOTS of output during normal operation! */
+#define D_DURING 16 /* trace operations (including irq's) */
+#define D_TX 32 /* show tx packets */
+#define D_RX 64 /* show rx packets */
+#define D_SKB 128 /* show skb's */
+
+#ifndef ARCNET_DEBUG_MAX
+#define ARCNET_DEBUG_MAX (~0) /* enable ALL debug messages */
+#endif
+
+#ifndef ARCNET_DEBUG
+#define ARCNET_DEBUG (D_NORMAL|D_EXTRA)
+#endif
+extern int arcnet_debug;
+
+/* macros to simplify debug checking */
+#define BUGLVL(x) if ((ARCNET_DEBUG_MAX)&arcnet_debug&(x))
+#define BUGMSG2(x,msg,args...) BUGLVL(x) printk(msg, ## args)
+#define BUGMSG(x,msg,args...) BUGMSG2(x,"%s%6s: " msg, \
+ x==D_NORMAL ? KERN_WARNING : \
+ x<=D_INIT_REASONS ? KERN_INFO : KERN_DEBUG , \
+ dev->name , ## args)
+
+
+#define SETMASK AINTMASK(lp->intmask)
+
+ /* Time needed to resetthe card - in jiffies. This works on my SMC
+ * PC100. I can't find a reference that tells me just how long I
+ * should wait.
+ */
+#define RESETtime (HZ * 3 / 10) /* reset */
+
+ /* these are the max/min lengths of packet data. (including
+ * ClientData header)
+ * note: packet sizes 250, 251, 252 are impossible (God knows why)
+ * so exception packets become necessary.
+ *
+ * These numbers are compared with the length of the full packet,
+ * including ClientData header.
+ */
+#define MTU 253 /* normal packet max size */
+#define MinTU 257 /* extended packet min size */
+#define XMTU 508 /* extended packet max size */
+
+ /* status/interrupt mask bit fields */
+#define TXFREEflag 0x01 /* transmitter available */
+#define TXACKflag 0x02 /* transmitted msg. ackd */
+#define RECONflag 0x04 /* system reconfigured */
+#define TESTflag 0x08 /* test flag */
+#define RESETflag 0x10 /* power-on-reset */
+#define RES1flag 0x20 /* reserved - usually set by jumper */
+#define RES2flag 0x40 /* reserved - usually set by jumper */
+#define NORXflag 0x80 /* receiver inhibited */
+
+ /* Flags used for IO-mapped memory operations */
+#define AUTOINCflag 0x40 /* Increase location with each access */
+#define IOMAPflag 0x02 /* (for 90xx) Use IO mapped memory, not mmap */
+#define ENABLE16flag 0x80 /* (for 90xx) Enable 16-bit mode */
+
+ /* in the command register, the following bits have these meanings:
+ * 0-2 command
+ * 3-4 page number (for enable rcv/xmt command)
+ * 7 receive broadcasts
+ */
+#define NOTXcmd 0x01 /* disable transmitter */
+#define NORXcmd 0x02 /* disable receiver */
+#define TXcmd 0x03 /* enable transmitter */
+#define RXcmd 0x04 /* enable receiver */
+#define CONFIGcmd 0x05 /* define configuration */
+#define CFLAGScmd 0x06 /* clear flags */
+#define TESTcmd 0x07 /* load test flags */
+
+ /* flags for "clear flags" command */
+#define RESETclear 0x08 /* power-on-reset */
+#define CONFIGclear 0x10 /* system reconfigured */
+
+ /* flags for "load test flags" command */
+#define TESTload 0x08 /* test flag (diagnostic) */
+
+ /* byte deposited into first address of buffers on reset */
+#define TESTvalue 0321 /* that's octal for 0xD1 :) */
+
+ /* for "enable receiver" command */
+#define RXbcasts 0x80 /* receive broadcasts */
+
+ /* flags for "define configuration" command */
+#define NORMALconf 0x00 /* 1-249 byte packets */
+#define EXTconf 0x08 /* 250-504 byte packets */
+
+ /* Starts receiving packets into recbuf.
+ */
+#define EnableReceiver() ACOMMAND(RXcmd|(recbuf<<3)|RXbcasts)
+
+
+
+#define JIFFER(time) for (delayval=jiffies+time; jiffies<delayval;) ;
+
+ /* a complete ARCnet packet */
+union ArcPacket
+{
+ struct archdr hardheader; /* the hardware header */
+ u_char raw[512]; /* raw packet info, incl ClientData */
+};
+
+
+ /* the "client data" header - RFC1201 information
+ * notice that this screws up if it's not an even number of bytes
+ * <sigh>
+ */
+struct ClientData
+{
+ /* data that's NOT part of real packet - we MUST get rid of it before
+ * actually sending!!
+ */
+ u_char saddr, /* Source address - needed for IPX */
+ daddr; /* Destination address */
+
+ /* data that IS part of real packet */
+ u_char protocol_id, /* ARC_P_IP, ARC_P_ARP, etc */
+ split_flag; /* for use with split packets */
+ u_short sequence; /* sequence number */
+};
+#define EXTRA_CLIENTDATA (sizeof(struct ClientData)-4)
+
+
+ /* the "client data" header - RFC1051 information
+ * this also screws up if it's not an even number of bytes
+ * <sigh again>
+ */
+struct S_ClientData
+{
+ /* data that's NOT part of real packet - we MUST get rid of it before
+ * actually sending!!
+ */
+ u_char saddr, /* Source address - needed for IPX */
+ daddr, /* Destination address */
+ junk; /* padding to make an even length */
+
+ /* data that IS part of real packet */
+ u_char protocol_id; /* ARC_P_IP, ARC_P_ARP, etc */
+};
+#define S_EXTRA_CLIENTDATA (sizeof(struct S_ClientData)-1)
+
+
+/* "Incoming" is information needed for each address that could be sending
+ * to us. Mostly for partially-received split packets.
+ */
+struct Incoming
+{
+ struct sk_buff *skb; /* packet data buffer */
+ unsigned char lastpacket, /* number of last packet (from 1) */
+ numpackets; /* number of packets in split */
+ u_short sequence; /* sequence number of assembly */
+};
+
+struct Outgoing
+{
+ struct sk_buff *skb; /* buffer from upper levels */
+ struct ClientData *hdr; /* clientdata of last packet */
+ u_char *data; /* pointer to data in packet */
+ short length, /* bytes total */
+ dataleft, /* bytes left */
+ segnum, /* segment being sent */
+ numsegs, /* number of segments */
+ seglen; /* length of segment */
+};
+
+
+struct arcnet_local {
+ struct net_device_stats stats;
+ u_short sequence; /* sequence number (incs with each packet) */
+ u_short aborted_seq;
+ u_char stationid, /* our 8-bit station address */
+ recbuf, /* receive buffer # (0 or 1) */
+ txbuf, /* transmit buffer # (2 or 3) */
+ txready, /* buffer where a packet is ready to send */
+ config, /* current value of CONFIG register */
+ timeout, /* Extended timeout for COM20020 */
+ backplane, /* Backplane flag for COM20020 */
+ setup, /* Contents of setup register */
+ intmask; /* current value of INTMASK register */
+ short intx, /* in TX routine? */
+ in_txhandler, /* in TX_IRQ handler? */
+ sending, /* transmit in progress? */
+ lastload_dest, /* can last loaded packet be acked? */
+ lasttrans_dest; /* can last TX'd packet be acked? */
+
+#if defined(DETECT_RECONFIGS) && defined(RECON_THRESHOLD)
+ time_t first_recon, /* time of "first" RECON message to count */
+ last_recon; /* time of most recent RECON */
+ int num_recons, /* number of RECONs between first and last. */
+ network_down; /* do we think the network is down? */
+#endif
+
+ struct timer_list timer; /* the timer interrupt struct */
+ struct Incoming incoming[256]; /* one from each address */
+ struct Outgoing outgoing; /* packet currently being sent */
+
+ int card_type;
+ char *card_type_str;
+
+ void (*inthandler) (struct device *dev);
+ int (*arcnet_reset) (struct device *dev, int reset_delay);
+ void (*asetmask) (struct device *dev, u_char mask);
+ void (*acommand) (struct device *dev, u_char command);
+ u_char (*astatus) (struct device *dev);
+ void (*en_dis_able_TX) (struct device *dev, int enable);
+ void (*prepare_tx)(struct device *dev,u_char *hdr,int hdrlen,
+ char *data,int length,int daddr,int exceptA, int offset);
+ void (*openclose_device)(int open);
+
+ struct device *adev; /* RFC1201 protocol device */
+
+ /* These are last to ensure that the chipset drivers don't depend on the
+ * CONFIG_ARCNET_ETH and CONFIG_ARCNET_1051 options.
+ */
+
+#ifdef CONFIG_ARCNET_ETH
+ struct device *edev; /* Ethernet-Encap device */
+#endif
+
+#ifdef CONFIG_ARCNET_1051
+ struct device *sdev; /* RFC1051 protocol device */
+#endif
+};
+
+/* Functions exported by arcnet.c
+ */
+
+#if ARCNET_DEBUG_MAX & D_SKB
+extern void arcnet_dump_skb(struct device *dev,struct sk_buff *skb,
+ char *desc);
+#else
+#define arcnet_dump_skb(dev,skb,desc) ;
+#endif
+
+#if (ARCNET_DEBUG_MAX & D_RX) || (ARCNET_DEBUG_MAX & D_TX)
+extern void arcnet_dump_packet(struct device *dev,u_char *buffer,int ext,
+ char *desc);
+#else
+#define arcnet_dump_packet(dev,buffer,ext,desc) ;
+#endif
+
+extern void arcnet_tx_done(struct device *dev, struct arcnet_local *lp);
+extern void arcnet_makename(char *device);
+extern void arcnet_interrupt(int irq,void *dev_id,struct pt_regs *regs);
+extern void arcnet_setup(struct device *dev);
+extern int arcnet_go_tx(struct device *dev,int enable_irq);
+extern void arcnetA_continue_tx(struct device *dev);
+extern void arcnet_rx(struct arcnet_local *lp, u_char *arcsoft, short length, int saddr, int daddr);
+extern void arcnet_use_count(int open);
+
+
+#endif /* __KERNEL__ */
+#endif /* _LINUX_ARCDEVICE_H */
diff --git a/include/linux/blk.h b/include/linux/blk.h
index 412f0c1c3..66ef4b47e 100644
--- a/include/linux/blk.h
+++ b/include/linux/blk.h
@@ -97,6 +97,9 @@ extern int ddv_init(void);
#ifdef CONFIG_AMIGA_Z2RAM
extern int z2_init(void);
#endif
+#ifdef CONFIG_MAC_FLOPPY
+extern int swim3_init(void);
+#endif
extern void set_device_ro(kdev_t dev,int flag);
void add_blkdev_randomness(int major);
diff --git a/include/linux/dcache.h b/include/linux/dcache.h
index 82390ea64..2735f37ea 100644
--- a/include/linux/dcache.h
+++ b/include/linux/dcache.h
@@ -46,15 +46,34 @@ struct dentry {
struct dentry * d_mounts; /* mount information */
struct dentry * d_covers;
struct list_head d_hash; /* lookup hash list */
- struct list_head d_alias; /* inode alias list */
struct list_head d_lru; /* d_count = 0 LRU list */
struct qstr d_name;
unsigned long d_time; /* used by d_revalidate */
+ struct dentry_operations *d_op;
+};
+
+struct dentry_operations {
int (*d_revalidate)(struct dentry *);
+ int (*d_hash) (struct dentry *,struct qstr *);
+ int (*d_compare) (struct dentry *,struct qstr *, struct qstr *);
+ void (*d_delete)(struct dentry *);
};
+/* the dentry parameter passed to d_hash and d_compare is the parent
+ * directory of the entries to be compared. It is used in case these
+ * functions need any directory specific information for determining
+ * equivalency classes. Using the dentry itself might not work, as it
+ * might be a negative dentry which has no information associated with
+ * it */
+
+
+
/* d_flags entries */
#define DCACHE_AUTOFS_PENDING 0x0001 /* autofs: "under construction" */
+#define DCACHE_NFSFS_RENAMED 0x0002 /* this dentry has been "silly
+ * renamed" and has to be
+ * deleted on the last dput()
+ */
/*
* d_drop() unhashes the entry from the parent
@@ -81,11 +100,10 @@ static inline void d_drop(struct dentry * dentry)
extern void d_instantiate(struct dentry *, struct inode *);
extern void d_delete(struct dentry *);
-
/* allocate/de-allocate */
-extern void d_free(struct dentry *);
extern struct dentry * d_alloc(struct dentry * parent, const struct qstr *name);
extern void shrink_dcache(void);
+extern int d_invalidate(struct dentry *);
/* only used at mount-time */
extern struct dentry * d_alloc_root(struct inode * root_inode, struct dentry * old_root);
@@ -97,7 +115,7 @@ extern struct dentry * d_alloc_root(struct inode * root_inode, struct dentry * o
extern void d_add(struct dentry * entry, struct inode * inode);
/* used for rename() and baskets */
-extern void d_move(struct dentry * entry, struct dentry * newparent, struct qstr * newname);
+extern void d_move(struct dentry * entry, struct dentry * newdentry);
/* appendix may either be NULL or be used for transname suffixes */
extern struct dentry * d_lookup(struct dentry * dir, struct qstr * name);
@@ -119,12 +137,4 @@ static inline struct dentry * dget(struct dentry *dentry)
extern void dput(struct dentry *);
-/*
- * This is ugly. The inode:dentry relationship is a 1:n
- * relationship, so we have to return one (random) dentry
- * from the alias list. We select the first one..
- */
-#define i_dentry(inode) \
- list_entry((inode)->i_dentry.next, struct dentry, d_alias)
-
#endif /* __LINUX_DCACHE_H */
diff --git a/include/linux/fd.h b/include/linux/fd.h
index da7293c35..a32532668 100644
--- a/include/linux/fd.h
+++ b/include/linux/fd.h
@@ -248,7 +248,7 @@ struct floppy_fdc_state {
int dtr;
unsigned char version; /* FDC version code */
unsigned char dor;
- int address; /* io address */
+ unsigned long address; /* io address */
unsigned int rawcmd:2;
unsigned int reset:1;
unsigned int need_configure:1;
diff --git a/include/linux/fs.h b/include/linux/fs.h
index 665b56c38..8dd814564 100644
--- a/include/linux/fs.h
+++ b/include/linux/fs.h
@@ -93,7 +93,7 @@ extern int max_files, nr_files;
/*
* Flags that can be altered by MS_REMOUNT
*/
-#define MS_RMT_MASK (MS_RDONLY|MS_MANDLOCK)
+#define MS_RMT_MASK (MS_RDONLY|MS_MANDLOCK|MS_NOATIME)
/*
* Magic mount flag number. Has to be or-ed to the flag values.
@@ -250,6 +250,7 @@ static inline int buffer_protected(struct buffer_head * bh)
#include <linux/affs_fs_i.h>
#include <linux/ufs_fs_i.h>
#include <linux/romfs_fs_i.h>
+#include <linux/smb_fs_i.h>
/*
* Attribute flags. These should be or-ed together to figure out what
@@ -327,8 +328,6 @@ struct inode {
struct page *i_pages;
struct dquot *i_dquot[MAXQUOTAS];
- struct list_head i_dentry;
-
unsigned long i_state;
unsigned int i_flags;
@@ -350,20 +349,21 @@ struct inode {
struct affs_inode_info affs_i;
struct ufs_inode_info ufs_i;
struct romfs_inode_info romfs_i;
+ struct smb_inode_info smbfs_i;
struct socket socket_i;
void *generic_ip;
} u;
};
/* Inode state bits.. */
-#define I_DIRTY 0
-#define I_LOCK 1
-#define I_FREEING 2
+#define I_DIRTY 1
+#define I_LOCK 2
+#define I_FREEING 4
extern void __mark_inode_dirty(struct inode *);
static inline void mark_inode_dirty(struct inode *inode)
{
- if (!test_and_set_bit(I_DIRTY, &inode->i_state))
+ if (!(inode->i_state & I_DIRTY))
__mark_inode_dirty(inode);
}
@@ -481,6 +481,7 @@ extern int fasync_helper(struct inode *, struct file *, int, struct fasync_struc
#include <linux/affs_fs_sb.h>
#include <linux/ufs_fs_sb.h>
#include <linux/romfs_fs_sb.h>
+#include <linux/smb_fs_sb.h>
struct super_block {
kdev_t s_dev;
@@ -501,6 +502,7 @@ struct super_block {
struct inode *s_ibasket;
short int s_ibasket_count;
short int s_ibasket_max;
+ struct list_head s_dirty; /* dirty inodes */
union {
struct minix_sb_info minix_sb;
@@ -513,6 +515,7 @@ struct super_block {
struct affs_sb_info affs_sb;
struct ufs_sb_info ufs_sb;
struct romfs_sb_info romfs_sb;
+ struct smb_sb_info smbfs_sb;
void *generic_sbp;
} u;
};
@@ -529,7 +532,7 @@ struct file_operations {
long long (*llseek) (struct inode *, struct file *, long long, int);
long (*read) (struct inode *, struct file *, char *, unsigned long);
long (*write) (struct inode *, struct file *, const char *, unsigned long);
- int (*readdir) (struct inode *, struct file *, void *, filldir_t);
+ int (*readdir) (struct file *, void *, filldir_t);
unsigned int (*poll) (struct file *, poll_table *);
int (*ioctl) (struct inode *, struct file *, unsigned int, unsigned long);
int (*mmap) (struct inode *, struct file *, struct vm_area_struct *);
@@ -672,7 +675,7 @@ extern inline void mark_buffer_dirty(struct buffer_head * bh, int flag)
}
extern int check_disk_change(kdev_t dev);
-extern int invalidate_inodes(kdev_t dev);
+extern int invalidate_inodes(struct super_block * sb);
extern void invalidate_inode_pages(struct inode *);
extern void invalidate_buffers(kdev_t dev);
extern int floppy_is_wp(int minor);
diff --git a/include/linux/hdlcdrv.h b/include/linux/hdlcdrv.h
index 0a6b9c735..b321d292c 100644
--- a/include/linux/hdlcdrv.h
+++ b/include/linux/hdlcdrv.h
@@ -117,7 +117,7 @@ struct hdlcdrv_ioctl {
#define HDLCDRV_MAGIC 0x5ac6e778
#define HDLCDRV_IFNAMELEN 6
-#define HDLCDRV_HDLCBUFFER 16 /* should be a power of 2 for speed reasons */
+#define HDLCDRV_HDLCBUFFER 32 /* should be a power of 2 for speed reasons */
#define HDLCDRV_BITBUFFER 256 /* should be a power of 2 for speed reasons */
#undef HDLCDRV_LOOPBACK /* define for HDLC debugging purposes */
#define HDLCDRV_DEBUG
diff --git a/include/linux/hfmodem.h b/include/linux/hfmodem.h
new file mode 100644
index 000000000..739dc5acd
--- /dev/null
+++ b/include/linux/hfmodem.h
@@ -0,0 +1,254 @@
+/*****************************************************************************/
+
+/*
+ * hfmodem.h -- Linux soundcard HF FSK driver.
+ *
+ * Copyright (C) 1997 Thomas Sailer (sailer@ife.ee.ethz.ch)
+ * Swiss Federal Institute of Technology (ETH), Electronics Lab
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ *
+ *
+ * This is the Linux realtime sound output driver
+ */
+
+/*****************************************************************************/
+
+#ifndef _HFMODEM_H
+#define _HFMODEM_H
+/* --------------------------------------------------------------------- */
+
+#include <linux/version.h>
+
+#include <linux/ioctl.h>
+#include <linux/types.h>
+#include <linux/fs.h>
+#if LINUX_VERSION_CODE >= 0x20100
+#include <linux/poll.h>
+#endif
+
+/* --------------------------------------------------------------------- */
+
+#define HFMODEM_MINOR 145
+
+#define HFMODEM_SRATE 8000
+#define HFMODEM_MAXBITS 4800 /* required for GTOR 300 baud mode */
+#define HFMODEM_MINBAUD 40
+#define HFMODEM_MAXBAUD 400
+#define HFMODEM_MAXCORRLEN ((HFMODEM_SRATE+HFMODEM_MINBAUD-1)/HFMODEM_MINBAUD)
+
+/* --------------------------------------------------------------------- */
+
+typedef unsigned long hfmodem_time_t;
+typedef int hfmodem_soft_t;
+typedef unsigned long hfmodem_id_t;
+
+/* --------------------------------------------------------------------- */
+
+struct hfmodem_ioctl_fsk_tx_request {
+ hfmodem_time_t tstart;
+ hfmodem_time_t tinc;
+ int inv;
+ hfmodem_id_t id;
+ unsigned int nbits;
+ unsigned char *data;
+ unsigned int freq[2];
+};
+
+struct hfmodem_ioctl_fsk_rx_request {
+ hfmodem_time_t tstart;
+ hfmodem_time_t tinc;
+ unsigned int baud;
+ hfmodem_id_t id;
+ unsigned int nbits;
+ hfmodem_soft_t *data;
+ unsigned int freq[2];
+};
+
+struct hfmodem_ioctl_mixer_params {
+ int src;
+ int igain;
+ int ogain;
+};
+
+struct hfmodem_ioctl_sample_params {
+ __s16 *data;
+ int len;
+};
+
+#define HFMODEM_IOCTL_FSKTXREQUEST _IOW('H', 0, struct hfmodem_ioctl_fsk_tx_request)
+#define HFMODEM_IOCTL_FSKRXREQUEST _IOW('H', 1, struct hfmodem_ioctl_fsk_rx_request)
+#define HFMODEM_IOCTL_CLEARRQ _IO('H', 3)
+#define HFMODEM_IOCTL_GETCURTIME _IOR('H', 4, hfmodem_time_t)
+#define HFMODEM_IOCTL_WAITRQ _IOR('H', 5, hfmodem_id_t)
+#define HFMODEM_IOCTL_MIXERPARAMS _IOW('H', 6, struct hfmodem_ioctl_mixer_params)
+#define HFMODEM_IOCTL_SAMPLESTART _IOW('H', 7, struct hfmodem_ioctl_sample_params)
+#define HFMODEM_IOCTL_SAMPLEFINISHED _IO('H', 8)
+
+/* --------------------------------------------------------------------- */
+#ifdef __KERNEL__
+
+
+#define DMA_MODE_AUTOINIT 0x10
+
+#define NR_DEVICE 1
+
+#define HFMODEM_FRAGSAMPLES (HFMODEM_SRATE/100)
+#define HFMODEM_FRAGSIZE (HFMODEM_FRAGSAMPLES*2)
+#define HFMODEM_NUMFRAGS 8
+#define HFMODEM_EXCESSFRAGS 3
+
+#define HFMODEM_NUMRXSLOTS 20
+#define HFMODEM_NUMTXSLOTS 4
+
+#define HFMODEM_CORRELATOR_CACHE 8
+
+enum slot_st { ss_unused = 0, ss_ready, ss_oper, ss_retired };
+typedef int hfmodem_conv_t;
+
+struct hfmodem_state {
+ const struct hfmodem_scops *scops;
+
+ /* io params */
+ struct {
+ unsigned int base_addr;
+ unsigned int dma;
+ unsigned int irq;
+ } io;
+
+ struct {
+ unsigned int seriobase;
+ unsigned int pariobase;
+ unsigned int midiiobase;
+ unsigned int flags;
+ } ptt_out;
+
+ struct {
+ __s16 *buf;
+ unsigned int lastfrag;
+ unsigned int fragptr;
+ unsigned int last_dmaptr;
+ int ptt_frames;
+ } dma;
+
+ struct {
+ unsigned int last_tvusec;
+ unsigned long long time_cnt;
+ hfmodem_time_t lasttime;
+#ifdef __i386__
+ unsigned int starttime_lo, starttime_hi;
+#endif /* __i386__ */
+ } clk;
+
+ int active;
+ struct wait_queue *wait;
+
+ struct {
+ __s16 *kbuf;
+ __s16 *ubuf;
+ __s16 *kptr;
+ unsigned int size;
+ int rem;
+ } sbuf;
+
+ struct {
+ hfmodem_time_t last_time;
+ unsigned int tx_phase;
+
+ struct hfmodem_l1_rxslot {
+ enum slot_st state;
+ hfmodem_time_t tstart, tinc;
+ hfmodem_soft_t *data;
+ hfmodem_soft_t *userdata;
+ unsigned int nbits;
+ unsigned int cntbits;
+ hfmodem_id_t id;
+ unsigned int corrlen;
+ hfmodem_conv_t scale;
+ unsigned int corr_cache;
+ } rxslots[HFMODEM_NUMRXSLOTS];
+
+ struct hfmodem_l1_txslot {
+ enum slot_st state;
+ hfmodem_time_t tstart, tinc;
+ unsigned char *data;
+ unsigned int nbits;
+ unsigned int cntbits;
+ hfmodem_id_t id;
+ unsigned char inv;
+ unsigned int phinc;
+ unsigned int phase_incs[2];
+ } txslots[HFMODEM_NUMTXSLOTS];
+ } l1;
+};
+
+struct hfmodem_correlator_cache {
+ int refcnt;
+ int lru;
+ unsigned short phase_incs[2];
+ hfmodem_conv_t correlator[2][2][HFMODEM_MAXCORRLEN];
+};
+
+struct hfmodem_scops {
+ unsigned int extent;
+
+ void (*init)(struct hfmodem_state *dev);
+ void (*prepare_input)(struct hfmodem_state *dev);
+ void (*trigger_input)(struct hfmodem_state *dev);
+ void (*prepare_output)(struct hfmodem_state *dev);
+ void (*trigger_output)(struct hfmodem_state *dev);
+ void (*stop)(struct hfmodem_state *dev);
+ unsigned int (*intack)(struct hfmodem_state *dev);
+ void (*mixer)(struct hfmodem_state *dev, int src, int igain, int ogain);
+};
+
+/* --------------------------------------------------------------------- */
+
+extern int hfmodem_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsigned long arg);
+#if LINUX_VERSION_CODE >= 0x20100
+extern unsigned int hfmodem_poll(struct file *file, poll_table *wait);
+#else
+extern int hfmodem_select(struct inode *inode, struct file *file, int sel_type, select_table *wait);
+#endif
+
+extern void hfmodem_clear_rq(struct hfmodem_state *dev);
+extern void hfmodem_input_samples(struct hfmodem_state *dev, hfmodem_time_t tstart,
+ hfmodem_time_t tinc, __s16 *samples);
+extern int hfmodem_output_samples(struct hfmodem_state *dev, hfmodem_time_t tstart,
+ hfmodem_time_t tinc, __s16 *samples);
+extern long hfmodem_next_tx_event(struct hfmodem_state *dev, hfmodem_time_t curr);
+extern void hfmodem_finish_pending_rx_requests(struct hfmodem_state *dev);
+extern void hfmodem_wakeup(struct hfmodem_state *dev);
+
+
+extern int hfmodem_sbcprobe(struct hfmodem_state *dev);
+extern int hfmodem_wssprobe(struct hfmodem_state *dev);
+
+extern void hfmodem_refclock_probe(void);
+extern void hfmodem_refclock_init(struct hfmodem_state *dev);
+extern hfmodem_time_t hfmodem_refclock_current(struct hfmodem_state *dev, hfmodem_time_t expected, int exp_valid);
+
+/* --------------------------------------------------------------------- */
+
+extern const char hfmodem_drvname[];
+extern const char hfmodem_drvinfo[];
+
+extern struct hfmodem_state hfmodem_state[NR_DEVICE];
+extern struct hfmodem_correlator_cache hfmodem_correlator_cache[HFMODEM_CORRELATOR_CACHE];
+
+/* --------------------------------------------------------------------- */
+#endif /* __KERNEL__ */
+/* --------------------------------------------------------------------- */
+#endif /* _HFMODEM_H */
diff --git a/include/linux/if.h b/include/linux/if.h
index 06e2d740e..09c066cb3 100644
--- a/include/linux/if.h
+++ b/include/linux/if.h
@@ -39,6 +39,9 @@
#define IFF_MULTICAST 0x1000 /* Supports multicast */
+#define IFF_PORTSEL 0x2000 /* can set media type */
+#define IFF_AUTOMEDIA 0x4000 /* auto media select active */
+
/*
* The ifaddr structure contains information about one address
* of an interface. They are maintained by the different address
diff --git a/include/linux/if_arcnet.h b/include/linux/if_arcnet.h
new file mode 100644
index 000000000..8b2ba0aae
--- /dev/null
+++ b/include/linux/if_arcnet.h
@@ -0,0 +1,63 @@
+/*
+ * INET An implementation of the TCP/IP protocol suite for the LINUX
+ * operating system. INET is implemented using the BSD Socket
+ * interface as the means of communication with the user level.
+ *
+ * Global definitions for the ARCnet interface.
+ *
+ * Version: $Id: if_arcnet.h,v 1.2 1997/09/05 08:57:54 mj Exp $
+ *
+ * Author: David Woodhouse <dwmw2@cam.ac.uk>
+ * Avery Pennarun <apenwarr@bond.net>
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version
+ * 2 of the License, or (at your option) any later version.
+ */
+
+#ifndef _LINUX_IF_ARCNET_H
+#define _LINUX_IF_ARCNET_H
+
+
+/*
+ * These are the defined ARCnet Protocol ID's.
+ */
+
+ /* RFC1201 Protocol ID's */
+#define ARC_P_IP 212 /* 0xD4 */
+#define ARC_P_ARP 213 /* 0xD5 */
+#define ARC_P_RARP 214 /* 0xD6 */
+#define ARC_P_IPX 250 /* 0xFA */
+#define ARC_P_NOVELL_EC 236 /* 0xEC */
+
+ /* Old RFC1051 Protocol ID's */
+#define ARC_P_IP_RFC1051 240 /* 0xF0 */
+#define ARC_P_ARP_RFC1051 241 /* 0xF1 */
+
+ /* MS LanMan/WfWg protocol */
+#define ARC_P_ETHER 0xE8
+
+ /* Unsupported/indirectly supported protocols */
+#define ARC_P_DATAPOINT_BOOT 0 /* very old Datapoint equipment */
+#define ARC_P_DATAPOINT_MOUNT 1
+#define ARC_P_POWERLAN_BEACON 8 /* Probably ATA-Netbios related */
+#define ARC_P_POWERLAN_BEACON2 243
+#define ARC_P_LANSOFT 251 /* 0xFB - what is this? */
+#define ARC_P_ATALK 0xDD
+
+
+/*
+ * This is an ARCnet frame header.
+ */
+
+struct archdr /* was struct HardHeader */
+{
+ u_char source, /* source ARCnet - filled in automagically */
+ destination, /* destination ARCnet - 0 for broadcast */
+ offset1, /* offset of ClientData (256-byte packets) */
+ offset2; /* offset of ClientData (512-byte packets) */
+
+};
+
+#endif /* _LINUX_IF_ARCNET_H */
diff --git a/include/linux/if_pppvar.h b/include/linux/if_pppvar.h
index 2538d3408..720e5cdad 100644
--- a/include/linux/if_pppvar.h
+++ b/include/linux/if_pppvar.h
@@ -1,4 +1,4 @@
-/* $Id: if_pppvar.h,v 1.3 1996/09/01 07:45:23 davem Exp $ */
+/* $Id: if_pppvar.h,v 1.4 1997/09/03 11:55:06 ecd Exp $ */
/*
* if_pppvar.h - private structures and declarations for PPP.
*
@@ -72,7 +72,7 @@ struct ppp_buffer {
__s32 count; /* Count of characters in bufr */
__s32 head; /* index to head of list */
__s32 tail; /* index to tail of list */
- __u32 locked; /* Buffer is being sent */
+ unsigned long locked; /* Buffer is being sent */
__s32 type; /* Type of the buffer */
/* =0, device read buffer */
/* =1, device write buffer */
@@ -93,7 +93,7 @@ struct ppp {
__s32 magic; /* magic value for structure */
/* Bitmapped flag fields. */
- __u32 inuse; /* are we allocated? */
+ unsigned long inuse; /* are we allocated? */
__u8 escape; /* 0x20 if prev char was PPP_ESC*/
__u8 toss; /* toss this frame */
diff --git a/include/linux/ip_fw.h b/include/linux/ip_fw.h
index 3a33555f7..0b6c103f1 100644
--- a/include/linux/ip_fw.h
+++ b/include/linux/ip_fw.h
@@ -65,15 +65,15 @@ struct ip_fw
struct in_addr fw_smsk, fw_dmsk; /* Mask for src and dest IP addr */
struct in_addr fw_via; /* IP address of interface "via" */
struct device *fw_viadev; /* device of interface "via" */
- unsigned short fw_flg; /* Flags word */
- unsigned short fw_nsp, fw_ndp; /* N'of src ports and # of dst ports */
+ __u16 fw_flg; /* Flags word */
+ __u16 fw_nsp, fw_ndp; /* N'of src ports and # of dst ports */
/* in ports array (dst ports follow */
/* src ports; max of 10 ports in all; */
/* count of 0 means match all ports) */
#define IP_FW_MAX_PORTS 10 /* A reasonable maximum */
- unsigned short fw_pts[IP_FW_MAX_PORTS]; /* Array of port numbers to match */
+ __u16 fw_pts[IP_FW_MAX_PORTS]; /* Array of port numbers to match */
unsigned long fw_pcnt,fw_bcnt; /* Packet and byte counters */
- unsigned char fw_tosand, fw_tosxor; /* Revised packet priority */
+ __u8 fw_tosand, fw_tosxor; /* Revised packet priority */
char fw_vianame[IFNAMSIZ]; /* name of interface "via" */
};
diff --git a/include/linux/kernel.h b/include/linux/kernel.h
index 51b319891..c6f2497fd 100644
--- a/include/linux/kernel.h
+++ b/include/linux/kernel.h
@@ -68,6 +68,16 @@ asmlinkage int printk(const char * fmt, ...)
*/
#define fsuser() (current->fsuid == 0)
+/*
+ * Display an IP address in readable format.
+ */
+
+#define NIPQUAD(addr) \
+ (((addr) >> 0) & 0xff), \
+ (((addr) >> 8) & 0xff), \
+ (((addr) >> 16) & 0xff), \
+ (((addr) >> 24) & 0xff)
+
#endif /* __KERNEL__ */
#define SI_LOAD_SHIFT 16
diff --git a/include/linux/lp.h b/include/linux/lp.h
index 5554600a2..368cd9bef 100644
--- a/include/linux/lp.h
+++ b/include/linux/lp.h
@@ -123,6 +123,7 @@ struct lp_struct {
unsigned int lastcall;
unsigned int runchars;
unsigned int waittime;
+ unsigned int should_relinquish;
struct lp_stats stats;
};
diff --git a/include/linux/msdos_fs.h b/include/linux/msdos_fs.h
index dba07c796..2c7843ea7 100644
--- a/include/linux/msdos_fs.h
+++ b/include/linux/msdos_fs.h
@@ -219,7 +219,7 @@ extern struct file_operations fat_dir_operations;
extern int fat_readdirx(struct inode *inode, struct file *filp, void *dirent,
fat_filldir_t fat_filldir, filldir_t filldir,
int shortnames, int longnames, int both);
-extern int fat_readdir(struct inode *inode, struct file *filp,
+extern int fat_readdir(struct file *filp,
void *dirent, filldir_t);
extern int fat_dir_ioctl(struct inode * inode, struct file * filp,
unsigned int cmd, unsigned long arg);
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
index 3f2301ace..4a530fe8f 100644
--- a/include/linux/netdevice.h
+++ b/include/linux/netdevice.h
@@ -130,8 +130,21 @@ struct net_device_stats
};
+/* Media selection options. */
+enum {
+ IF_PORT_UNKNOWN = 0,
+ IF_PORT_10BASE2,
+ IF_PORT_10BASET,
+ IF_PORT_AUI,
+ IF_PORT_100BASET,
+ IF_PORT_100BASETX,
+ IF_PORT_100BASEFX
+};
+
#ifdef __KERNEL__
+extern const char *if_port_text[];
+
#include <linux/skbuff.h>
/*
@@ -163,7 +176,7 @@ struct device
unsigned long mem_end; /* shared mem end */
unsigned long mem_start; /* shared mem start */
unsigned long base_addr; /* device I/O address */
- unsigned char irq; /* device IRQ number */
+ unsigned int irq; /* device IRQ number */
/* Low-level status flags. */
volatile unsigned char start, /* start an operation */
diff --git a/include/linux/nfs_fs_i.h b/include/linux/nfs_fs_i.h
index e89bc495f..b0163ec22 100644
--- a/include/linux/nfs_fs_i.h
+++ b/include/linux/nfs_fs_i.h
@@ -47,13 +47,6 @@ struct nfs_inode_info {
unsigned long attrtimeo;
/*
- * This is to support the clandestine rename on unlink.
- * Instead of the directory inode, we might as well keep
- * its NFS FH, but that requires a kmalloc.
- */
- struct inode * silly_inode;
-
- /*
* This is the list of dirty unwritten pages.
* NFSv3 will want to add a list for written but uncommitted
* pages.
diff --git a/include/linux/nfsd/nfsfh.h b/include/linux/nfsd/nfsfh.h
index ae88f161d..4d089f946 100644
--- a/include/linux/nfsd/nfsfh.h
+++ b/include/linux/nfsd/nfsfh.h
@@ -137,6 +137,7 @@ fh_put(struct svc_fh *fhp)
if (fhp->fh_dverified) {
fh_unlock(fhp);
dput(fhp->fh_handle.fh_dentry);
+ fhp->fh_dverified = 0;
}
}
#else
@@ -159,6 +160,7 @@ __fh_put(struct svc_fh *fhp, char *file, int line)
} else {
fh_unlock(fhp);
dput(dentry);
+ fhp->fh_dverified = 0;
}
}
#endif
diff --git a/include/linux/nfsd/syscall.h b/include/linux/nfsd/syscall.h
index 690f0095f..0bf4a5a58 100644
--- a/include/linux/nfsd/syscall.h
+++ b/include/linux/nfsd/syscall.h
@@ -112,8 +112,7 @@ union nfsctl_res {
* Kernel syscall implementation.
*/
#if defined(CONFIG_NFSD) || defined(CONFIG_NFSD_MODULE)
-extern asmlinkage int sys_nfsservctl(int, struct nfsctl_arg *,
- union nfsctl_res *);
+extern asmlinkage int sys_nfsservctl(int, void *, void *);
#else
#define sys_nfsservctl sys_ni_syscall
#endif
diff --git a/include/linux/openpic.h b/include/linux/openpic.h
new file mode 100644
index 000000000..863e65997
--- /dev/null
+++ b/include/linux/openpic.h
@@ -0,0 +1,364 @@
+/*
+ * linux/openpic.h -- OpenPIC definitions
+ *
+ * Copyright (C) 1997 Geert Uytterhoeven
+ *
+ * This file is subject to the terms and conditions of the GNU General Public
+ * License. See the file COPYING in the main directory of this archive
+ * for more details.
+ *
+ * This file is based on the following documentation:
+ *
+ * The Open Programmable Interrupt Controller (PIC)
+ * Register Interface Specification Revision 1.2
+ *
+ * Issue Date: October 1995
+ *
+ * Issued jointly by Advanced Micro Devices and Cyrix Corporation
+ *
+ * AMD is a registered trademark of Advanced Micro Devices, Inc.
+ * Copyright (C) 1995, Advanced Micro Devices, Inc. and Cyrix, Inc.
+ * All Rights Reserved.
+ *
+ * To receive a copy of this documentation, send an email to openpic@amd.com.
+ *
+ * This file is subject to the terms and conditions of the GNU General Public
+ * License. See the file COPYING in the main directory of this archive
+ * for more details.
+ */
+
+#ifndef _LINUX_OPENPIC_H
+#define _LINUX_OPENPIC_H
+
+#if !defined(__powerpc__) && !defined(__i386__)
+#error Unsupported OpenPIC platform
+#endif
+
+
+#ifdef __KERNEL__
+
+ /*
+ * OpenPIC supports up to 2048 interrupt sources and up to 32 processors
+ */
+
+#define OPENPIC_MAX_SOURCES 2048
+#define OPENPIC_MAX_PROCESSORS 32
+
+#define OPENPIC_NUM_TIMERS 4
+#define OPENPIC_NUM_IPI 4
+#define OPENPIC_NUM_PRI 16
+#define OPENPIC_NUM_VECTORS 256
+
+
+ /*
+ * OpenPIC Registers are 32 bits and aligned on 128 bit boundaries
+ */
+
+typedef struct _OpenPIC_Reg {
+ u_int Reg; /* Little endian! */
+ char Pad[0xc];
+} OpenPIC_Reg;
+
+
+ /*
+ * Per Processor Registers
+ */
+
+typedef struct _OpenPIC_Processor {
+ /*
+ * Private Shadow Registers (for SLiC backwards compatibility)
+ */
+ u_int IPI0_Dispatch_Shadow; /* Write Only */
+ char Pad1[0x4];
+ u_int IPI0_Vector_Priority_Shadow; /* Read/Write */
+ char Pad2[0x34];
+ /*
+ * Interprocessor Interrupt Command Ports
+ */
+ OpenPIC_Reg _IPI_Dispatch[OPENPIC_NUM_IPI]; /* Write Only */
+ /*
+ * Current Task Priority Register
+ */
+ OpenPIC_Reg _Current_Task_Priority; /* Read/Write */
+#ifndef __powerpc__
+ /*
+ * Who Am I Register
+ */
+ OpenPIC_Reg _Who_Am_I; /* Read Only */
+#else
+ char Pad3[0x10];
+#endif
+#ifndef __i386__
+ /*
+ * Interrupt Acknowledge Register
+ */
+ OpenPIC_Reg _Interrupt_Acknowledge; /* Read Only */
+#else
+ char Pad4[0x10];
+#endif
+ /*
+ * End of Interrupt (EOI) Register
+ */
+ OpenPIC_Reg _EOI; /* Read/Write */
+ char Pad5[0xf40];
+} OpenPIC_Processor;
+
+
+ /*
+ * Timer Registers
+ */
+
+typedef struct _OpenPIC_Timer {
+ OpenPIC_Reg _Current_Count; /* Read Only */
+ OpenPIC_Reg _Base_Count; /* Read/Write */
+ OpenPIC_Reg _Vector_Priority; /* Read/Write */
+ OpenPIC_Reg _Destination; /* Read/Write */
+} OpenPIC_Timer;
+
+
+ /*
+ * Global Registers
+ */
+
+typedef struct _OpenPIC_Global {
+ /*
+ * Feature Reporting Registers
+ */
+ OpenPIC_Reg _Feature_Reporting0; /* Read Only */
+ OpenPIC_Reg _Feature_Reporting1; /* Future Expansion */
+ /*
+ * Global Configuration Registers
+ */
+ OpenPIC_Reg _Global_Configuration0; /* Read/Write */
+ OpenPIC_Reg _Global_Configuration1; /* Future Expansion */
+ /*
+ * Vendor Specific Registers
+ */
+ OpenPIC_Reg _Vendor_Specific[4];
+ /*
+ * Vendor Identification Register
+ */
+ OpenPIC_Reg _Vendor_Identification; /* Read Only */
+ /*
+ * Processor Initialization Register
+ */
+ OpenPIC_Reg _Processor_Initialization; /* Read/Write */
+ /*
+ * IPI Vector/Priority Registers
+ */
+ OpenPIC_Reg _IPI_Vector_Priority[OPENPIC_NUM_IPI]; /* Read/Write */
+ /*
+ * Spurious Vector Register
+ */
+ OpenPIC_Reg _Spurious_Vector; /* Read/Write */
+ /*
+ * Global Timer Registers
+ */
+ OpenPIC_Reg _Timer_Frequency; /* Read/Write */
+ OpenPIC_Timer Timer[OPENPIC_NUM_TIMERS];
+ char Pad1[0xee00];
+} OpenPIC_Global;
+
+
+ /*
+ * Interrupt Source Registers
+ */
+
+typedef struct _OpenPIC_Source {
+ OpenPIC_Reg _Vector_Priority; /* Read/Write */
+ OpenPIC_Reg _Destination; /* Read/Write */
+} OpenPIC_Source;
+
+
+ /*
+ * OpenPIC Register Map
+ */
+
+struct OpenPIC {
+#ifndef __powerpc__
+ /*
+ * Per Processor Registers --- Private Access
+ */
+ OpenPIC_Processor Private;
+#else
+ char Pad1[0x1000];
+#endif
+ /*
+ * Global Registers
+ */
+ OpenPIC_Global Global;
+ /*
+ * Interrupt Source Configuration Registers
+ */
+ OpenPIC_Source Source[OPENPIC_MAX_SOURCES];
+ /*
+ * Per Processor Registers
+ */
+ OpenPIC_Processor Processor[OPENPIC_MAX_PROCESSORS];
+};
+
+extern volatile struct OpenPIC *OpenPIC;
+
+
+ /*
+ * Current Task Priority Register
+ */
+
+#define OPENPIC_CURRENT_TASK_PRIORITY_MASK 0x0000000f
+
+ /*
+ * Who Am I Register
+ */
+
+#define OPENPIC_WHO_AM_I_ID_MASK 0x0000001f
+
+ /*
+ * Feature Reporting Register 0
+ */
+
+#define OPENPIC_FEATURE_LAST_SOURCE_MASK 0x07ff0000
+#define OPENPIC_FEATURE_LAST_SOURCE_SHIFT 16
+#define OPENPIC_FEATURE_LAST_PROCESSOR_MASK 0x00001f00
+#define OPENPIC_FEATURE_LAST_PROCESSOR_SHIFT 8
+#define OPENPIC_FEATURE_VERSION_MASK 0x000000ff
+
+ /*
+ * Global Configuration Register 0
+ */
+
+#define OPENPIC_CONFIG_RESET 0x80000000
+#define OPENPIC_CONFIG_8259_PASSTHROUGH_DISABLE 0x20000000
+#define OPENPIC_CONFIG_BASE_MASK 0x000fffff
+
+ /*
+ * Vendor Identification Register
+ */
+
+#define OPENPIC_VENDOR_ID_STEPPING_MASK 0x00ff0000
+#define OPENPIC_VENDOR_ID_STEPPING_SHIFT 16
+#define OPENPIC_VENDOR_ID_DEVICE_ID_MASK 0x0000ff00
+#define OPENPIC_VENDOR_ID_DEVICE_ID_SHIFT 8
+#define OPENPIC_VENDOR_ID_VENDOR_ID_MASK 0x000000ff
+
+ /*
+ * Vector/Priority Registers
+ */
+
+#define OPENPIC_MASK 0x80000000
+#define OPENPIC_ACTIVITY 0x40000000 /* Read Only */
+#define OPENPIC_PRIORITY_MASK 0x000f0000
+#define OPENPIC_PRIORITY_SHIFT 16
+#define OPENPIC_VECTOR_MASK 0x000000ff
+
+
+ /*
+ * Interrupt Source Registers
+ */
+
+#define OPENPIC_SENSE_POLARITY 0x00800000 /* Undoc'd */
+#define OPENPIC_SENSE_LEVEL 0x00400000
+
+
+ /*
+ * Timer Registers
+ */
+
+#define OPENPIC_COUNT_MASK 0x7fffffff
+#define OPENPIC_TIMER_TOGGLE 0x80000000
+#define OPENPIC_TIMER_COUNT_INHIBIT 0x80000000
+
+
+ /*
+ * Aliases to make life simpler
+ */
+
+/* Per Processor Registers */
+#define IPI_Dispatch(i) _IPI_Dispatch[i].Reg
+#define Current_Task_Priority _Current_Task_Priority.Reg
+#ifndef __powerpc__
+#define Who_Am_I _Who_Am_I.Reg
+#endif
+#ifndef __i386__
+#define Interrupt_Acknowledge _Interrupt_Acknowledge.Reg
+#endif
+#define EOI _EOI.Reg
+
+/* Global Registers */
+#define Feature_Reporting0 _Feature_Reporting0.Reg
+#define Feature_Reporting1 _Feature_Reporting1.Reg
+#define Global_Configuration0 _Global_Configuration0.Reg
+#define Global_Configuration1 _Global_Configuration1.Reg
+#define Vendor_Specific(i) _Vendor_Specific[i].Reg
+#define Vendor_Identification _Vendor_Identification.Reg
+#define Processor_Initialization _Processor_Initialization.Reg
+#define IPI_Vector_Priority(i) _IPI_Vector_Priority[i].Reg
+#define Spurious_Vector _Spurious_Vector.Reg
+#define Timer_Frequency _Timer_Frequency.Reg
+
+/* Timer Registers */
+#define Current_Count _Current_Count.Reg
+#define Base_Count _Base_Count.Reg
+#define Vector_Priority _Vector_Priority.Reg
+#define Destination _Destination.Reg
+
+/* Interrupt Source Registers */
+#define Vector_Priority _Vector_Priority.Reg
+#define Destination _Destination.Reg
+
+
+ /*
+ * Vendor and Device IDs
+ */
+
+#define OPENPIC_VENDOR_ID_APPLE 0x14
+#define OPENPIC_DEVICE_ID_APPLE_HYDRA 0x46
+
+
+ /*
+ * OpenPIC Operations
+ */
+
+/* Global Operations */
+extern void openpic_init(void);
+extern void openpic_reset(void);
+extern void openpic_enable_8259_pass_through(void);
+extern void openpic_disable_8259_pass_through(void);
+#ifndef __i386__
+extern u_int openpic_irq(u_int cpu);
+#endif
+#ifndef __powerpc__
+extern void openpic_eoi(void);
+extern u_int openpic_get_priority(void);
+extern void openpic_set_priority(u_int pri);
+#else
+extern void openpic_eoi(u_int cpu);
+extern u_int openpic_get_priority(u_int cpu);
+extern void openpic_set_priority(u_int cpu, u_int pri);
+#endif
+extern u_int openpic_get_spurious(void);
+extern void openpic_set_spurious(u_int vector);
+extern void openpic_init_processor(u_int cpumask);
+
+/* Interprocessor Interrupts */
+extern void openpic_initipi(u_int ipi, u_int pri, u_int vector);
+#ifndef __powerpc__
+extern void openpic_cause_IPI(u_int ipi, u_int cpumask);
+#else
+extern void openpic_cause_IPI(u_int cpu, u_int ipi, u_int cpumask);
+#endif
+
+/* Timer Interrupts */
+extern void openpic_inittimer(u_int timer, u_int pri, u_int vector);
+extern void openpic_maptimer(u_int timer, u_int cpumask);
+
+/* Interrupt Sources */
+extern void openpic_enable_irq(u_int irq);
+extern void openpic_disable_irq(u_int irq);
+extern void openpic_initirq(u_int irq, u_int pri, u_int vector, int polarity,
+ int is_level);
+extern void openpic_mapirq(u_int irq, u_int cpumask);
+extern void openpic_set_sense(u_int irq, int sense);
+
+#endif /* __KERNEL__ */
+
+#endif /* _LINUX_OPENPIC_H */
diff --git a/include/linux/parport.h b/include/linux/parport.h
index eca37ac03..c3106ffdf 100644
--- a/include/linux/parport.h
+++ b/include/linux/parport.h
@@ -1,4 +1,4 @@
-/* $Id: parport.h,v 1.2 1997/07/29 04:00:12 ralf Exp $ */
+/* $Id: parport.h,v 1.3 1997/08/06 19:16:45 miguel Exp $ */
#ifndef _PARPORT_H_
#define _PARPORT_H_
@@ -81,6 +81,9 @@ struct parport_operations {
void (*enable_irq)(struct parport *);
void (*disable_irq)(struct parport *);
int (*examine_irq)(struct parport *);
+
+ void (*inc_use_count)(void);
+ void (*dec_use_count)(void);
};
#define PARPORT_CONTROL_STROBE 0x1
diff --git a/include/linux/pci.h b/include/linux/pci.h
index 138e67bfe..94c321bdf 100644
--- a/include/linux/pci.h
+++ b/include/linux/pci.h
@@ -221,6 +221,9 @@
*/
#define PCI_VENDOR_ID_COMPAQ 0x0e11
#define PCI_DEVICE_ID_COMPAQ_1280 0x3033
+#define PCI_DEVICE_ID_COMPAQ_NETELL100 0xae32
+#define PCI_DEVICE_ID_COMPAQ_NETELL10 0xae34
+#define PCI_DEVICE_ID_COMPAQ_NETFLEX3 0xae35
#define PCI_DEVICE_ID_COMPAQ_THUNDER 0xf130
#define PCI_VENDOR_ID_NCR 0x1000
@@ -247,11 +250,13 @@
#define PCI_DEVICE_ID_VLSI_82C593 0x0006
#define PCI_DEVICE_ID_VLSI_82C594 0x0007
#define PCI_DEVICE_ID_VLSI_82C597 0x0009
+#define PCI_DEVICE_ID_VLSI_VAS96011 0x0702
#define PCI_VENDOR_ID_ADL 0x1005
#define PCI_DEVICE_ID_ADL_2301 0x2301
#define PCI_VENDOR_ID_NS 0x100b
+#define PCI_DEVICE_ID_NS_87415 0x0002
#define PCI_DEVICE_ID_NS_87410 0xd001
#define PCI_VENDOR_ID_TSENG 0x100c
@@ -270,9 +275,11 @@
#define PCI_DEVICE_ID_DEC_TULIP 0x0002
#define PCI_DEVICE_ID_DEC_TGA 0x0004
#define PCI_DEVICE_ID_DEC_TULIP_FAST 0x0009
+#define PCI_DEVICE_ID_DEC_TGA2 0x000D
#define PCI_DEVICE_ID_DEC_FDDI 0x000F
#define PCI_DEVICE_ID_DEC_TULIP_PLUS 0x0014
#define PCI_DEVICE_ID_DEC_21142 0x0019
+#define PCI_DEVICE_ID_DEC_21143 0x0019
#define PCI_DEVICE_ID_DEC_21052 0x0021
#define PCI_DEVICE_ID_DEC_21152 0x0024
@@ -283,13 +290,17 @@
#define PCI_DEVICE_ID_CIRRUS_5434_8 0x00a8
#define PCI_DEVICE_ID_CIRRUS_5436 0x00ac
#define PCI_DEVICE_ID_CIRRUS_5446 0x00b8
+#define PCI_DEVICE_ID_CIRRUS_5480 0x00bc
#define PCI_DEVICE_ID_CIRRUS_5464 0x00d4
+#define PCI_DEVICE_ID_CIRRUS_5465 0x00d6
#define PCI_DEVICE_ID_CIRRUS_6729 0x1100
+#define PCI_DEVICE_ID_CIRRUS_6832 0x1110
#define PCI_DEVICE_ID_CIRRUS_7542 0x1200
#define PCI_DEVICE_ID_CIRRUS_7543 0x1202
#define PCI_DEVICE_ID_CIRRUS_7541 0x1204
#define PCI_VENDOR_ID_IBM 0x1014
+#define PCI_DEVICE_ID_IBM_FIRE_CORAL 0x000a
#define PCI_DEVICE_ID_IBM_82G2675 0x001d
#define PCI_DEVICE_ID_IBM_82351 0x0022
@@ -312,6 +323,7 @@
#define PCI_DEVICE_ID_MATROX_MGA_2 0x0518
#define PCI_DEVICE_ID_MATROX_MIL 0x0519
#define PCI_DEVICE_ID_MATROX_MYS 0x051A
+#define PCI_DEVICE_ID_MATROX_MIL_2 0x051b
#define PCI_DEVICE_ID_MATROX_MGA_IMP 0x0d10
#define PCI_VENDOR_ID_CT 0x102c
@@ -334,6 +346,7 @@
#define PCI_DEVICE_ID_SI_501 0x0406
#define PCI_DEVICE_ID_SI_496 0x0496
#define PCI_DEVICE_ID_SI_601 0x0601
+#define PCI_DEVICE_ID_SI_5107 0x5107
#define PCI_DEVICE_ID_SI_5511 0x5511
#define PCI_DEVICE_ID_SI_5513 0x5513
#define PCI_DEVICE_ID_SI_5571 0x5571
@@ -366,6 +379,10 @@
#define PCI_DEVICE_ID_BUSLOGIC_MULTIMASTER 0x1040
#define PCI_DEVICE_ID_BUSLOGIC_FLASHPOINT 0x8130
+#define PCI_VENDOR_ID_TI 0x104c
+#define PCI_DEVICE_ID_TI_PCI1130 0xac12
+#define PCI_DEVICE_ID_TI_PCI1131 0xac15
+
#define PCI_VENDOR_ID_OAK 0x104e
#define PCI_DEVICE_ID_OAK_OTI107 0x0107
@@ -381,6 +398,11 @@
#define PCI_VENDOR_ID_PROMISE 0x105a
#define PCI_DEVICE_ID_PROMISE_5300 0x5300
+#define PCI_VENDOR_ID_APPLE 0x106b
+#define PCI_DEVICE_ID_APPLE_BANDIT 0x0001
+#define PCI_DEVICE_ID_APPLE_GC 0x0002
+#define PCI_DEVICE_ID_APPLE_HYDRA 0x000e
+
#define PCI_VENDOR_ID_N9 0x105d
#define PCI_DEVICE_ID_N9_I128 0x2309
#define PCI_DEVICE_ID_N9_I128_2 0x2339
@@ -415,10 +437,23 @@
#define PCI_VENDOR_ID_FOREX 0x1083
#define PCI_VENDOR_ID_OLICOM 0x108d
+#define PCI_DEVICE_ID_OLICOM_OC3136 0x0001
+#define PCI_DEVICE_ID_OLICOM_OC2315 0x0011
+#define PCI_DEVICE_ID_OLICOM_OC2325 0x0012
+#define PCI_DEVICE_ID_OLICOM_OC2183 0x0013
+#define PCI_DEVICE_ID_OLICOM_OC2326 0x0014
+#define PCI_DEVICE_ID_OLICOM_OC6151 0x0021
+
+#define PCI_VENDOR_ID_SUN 0x108e
+#define PCI_DEVICE_ID_SUN_EBUS 0x1000
+#define PCI_DEVICE_ID_SUN_HAPPYMEAL 0x1001
+#define PCI_DEVICE_ID_SUN_PBM 0x8000
#define PCI_VENDOR_ID_CMD 0x1095
#define PCI_DEVICE_ID_CMD_640 0x0640
+#define PCI_DEVICE_ID_CMD_643 0x0643
#define PCI_DEVICE_ID_CMD_646 0x0646
+#define PCI_DEVICE_ID_CMD_670 0x0670
#define PCI_VENDOR_ID_VISION 0x1098
#define PCI_DEVICE_ID_VISION_QD8500 0x0001
@@ -438,6 +473,9 @@
#define PCI_DEVICE_ID_WINBOND_82C105 0x0105
#define PCI_DEVICE_ID_WINBOND_83C553 0x0565
+#define PCI_VENDOR_ID_DATABOOK 0x10b3
+#define PCI_DEVICE_ID_DATABOOK_87144 0xb106
+
#define PCI_VENDOR_ID_3COM 0x10b7
#define PCI_DEVICE_ID_3COM_3C590 0x5900
#define PCI_DEVICE_ID_3COM_3C595TX 0x5950
@@ -447,6 +485,8 @@
#define PCI_DEVICE_ID_3COM_3C900COMBO 0x9001
#define PCI_DEVICE_ID_3COM_3C905TX 0x9050
+#define PCI_VENDOR_ID_SMC 0x10b8
+
#define PCI_VENDOR_ID_AL 0x10b9
#define PCI_DEVICE_ID_AL_M1445 0x1445
#define PCI_DEVICE_ID_AL_M1449 0x1449
@@ -457,8 +497,11 @@
#define PCI_DEVICE_ID_AL_M1513 0x1513
#define PCI_DEVICE_ID_AL_M4803 0x5215
+#define PCI_VENDOR_ID_MITSUBISHI 0x10ba
+
#define PCI_VENDOR_ID_NEOMAGIC 0x10c8
#define PCI_DEVICE_ID_NEOMAGIC_MAGICGRAPH_NM2070 0x0001
+#define PCI_DEVICE_ID_NEOMAGIC_MAGICGRAPH_128V 0x0002
#define PCI_VENDOR_ID_ASP 0x10cd
#define PCI_DEVICE_ID_ASP_ABP940 0x1200
@@ -487,6 +530,10 @@
#define PCI_VENDOR_ID_REALTEK 0x10ec
#define PCI_DEVICE_ID_REALTEK_8029 0x8029
+#define PCI_DEVICE_ID_REALTEK_8129 0x8129
+
+#define PCI_VENDOR_ID_TRUEVISION 0x10fa
+#define PCI_DEVICE_ID_TRUEVISION_T1000 0x000c
#define PCI_VENDOR_ID_INIT 0x1101
#define PCI_DEVICE_ID_INIT_320P 0x9100
@@ -498,6 +545,7 @@
#define PCI_DEVICE_ID_VIA_82C576 0x0576
#define PCI_DEVICE_ID_VIA_82C585 0x0585
#define PCI_DEVICE_ID_VIA_82C586 0x0586
+#define PCI_DEVICE_ID_VIA_82C926 0x0926
#define PCI_DEVICE_ID_VIA_82C416 0x1571
#define PCI_VENDOR_ID_VORTEX 0x1119
@@ -527,6 +575,9 @@
#define PCI_VENDOR_ID_IMAGINGTECH 0x112f
#define PCI_DEVICE_ID_IMAGINGTECH_ICPCI 0x0000
+#define PCI_VENDOR_ID_PHILIPS 0x1131
+#define PCI_DEVICE_ID_PHILIPS_SAA7146 0x7146
+
#define PCI_VENDOR_ID_PLX 0x113c
#define PCI_DEVICE_ID_PLX_9060 0x0001
@@ -543,21 +594,38 @@
#define PCI_VENDOR_ID_MUTECH 0x1159
#define PCI_DEVICE_ID_MUTECH_MV1000 0x0001
+#define PCI_VENDOR_ID_RENDITION 0x1163
+#define PCI_DEVICE_ID_RENDITION_VERITE 0x0001
+
#define PCI_VENDOR_ID_TOSHIBA 0x1179
#define PCI_DEVICE_ID_TOSHIBA_601 0x0601
+#define PCI_VENDOR_ID_RICOH 0x1180
+#define PCI_DEVICE_ID_RICOH_RL5C466 0x0466
+
#define PCI_VENDOR_ID_ZEITNET 0x1193
#define PCI_DEVICE_ID_ZEITNET_1221 0x0001
#define PCI_DEVICE_ID_ZEITNET_1225 0x0002
#define PCI_VENDOR_ID_OMEGA 0x119b
-#define PCI_DEVICE_ID_OMEGA_PCMCIA 0x1221
+#define PCI_DEVICE_ID_OMEGA_82C092G 0x1221
+
+#define PCI_VENDOR_ID_GALILEO 0x11ab
+#define PCI_DEVICE_ID_GALILEO_GT64011 0x4146
+
+#define PCI_VENDOR_ID_NP 0x11bc
+#define PCI_DEVICE_ID_NP_PCI_FDDI 0x0001
#define PCI_VENDOR_ID_SPECIALIX 0x11cb
#define PCI_DEVICE_ID_SPECIALIX_XIO 0x4000
#define PCI_DEVICE_ID_SPECIALIX_RIO 0x8000
+#define PCI_VENDOR_ID_IKON 0x11d5
+#define PCI_DEVICE_ID_IKON_10115 0x0115
+#define PCI_DEVICE_ID_IKON_10117 0x0117
+
#define PCI_VENDOR_ID_ZORAN 0x11de
+#define PCI_DEVICE_ID_ZORAN_36057 0x6057
#define PCI_DEVICE_ID_ZORAN_36120 0x6120
#define PCI_VENDOR_ID_COMPEX 0x11f6
@@ -584,7 +652,7 @@
#define PCI_VENDOR_ID_OPTIBASE 0x1255
#define PCI_DEVICE_ID_OPTIBASE_FORGE 0x1110
#define PCI_DEVICE_ID_OPTIBASE_FUSION 0x1210
-#define PCI_DEVICE_ID_OPTIBASE_VPLEX 0x2120
+#define PCI_DEVICE_ID_OPTIBASE_VPLEX 0x2110
#define PCI_DEVICE_ID_OPTIBASE_VPLEXCC 0x2120
#define PCI_DEVICE_ID_OPTIBASE_VQUEST 0x2130
@@ -596,6 +664,7 @@
#define PCI_VENDOR_ID_3DLABS 0x3d3d
#define PCI_DEVICE_ID_3DLABS_300SX 0x0001
+#define PCI_DEVICE_ID_3DLABS_500TX 0x0002
#define PCI_DEVICE_ID_3DLABS_DELTA 0x0003
#define PCI_DEVICE_ID_3DLABS_PERMEDIA 0x0004
@@ -616,6 +685,9 @@
#define PCI_DEVICE_ID_S3_964_1 0x88d0
#define PCI_DEVICE_ID_S3_964_2 0x88d1
#define PCI_DEVICE_ID_S3_968 0x88f0
+#define PCI_DEVICE_ID_S3_TRIO64V2 0x8901
+#define PCI_DEVICE_ID_S3_PLATO_PXG 0x8902
+#define PCI_DEVICE_ID_S3_ViRGE_DXGX 0x8a01
#define PCI_VENDOR_ID_INTEL 0x8086
#define PCI_DEVICE_ID_INTEL_82375 0x0482
@@ -714,7 +786,12 @@ struct pci_dev {
* necessary. The field must not be 0 unless the device
* cannot generate interrupts at all.
*/
- unsigned char irq; /* irq generated by this device */
+ unsigned int irq; /* irq generated by this device */
+
+ /* Base registers for this device, can be adjusted by
+ * pcibios_fixup() as necessary.
+ */
+ unsigned long base_address[6];
};
struct pci_bus {
@@ -751,6 +828,8 @@ extern struct pci_dev *pci_devices; /* list of all devices */
extern unsigned long pci_init (unsigned long mem_start, unsigned long mem_end);
+extern unsigned int pci_scan_bus(struct pci_bus *bus, unsigned long *mem_startp);
+
extern struct pci_dev_info *pci_lookup_dev (unsigned int vendor,
unsigned int dev);
extern const char *pci_strclass (unsigned int class);
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h
index 901a8b9ef..e7b84f348 100644
--- a/include/linux/proc_fs.h
+++ b/include/linux/proc_fs.h
@@ -51,7 +51,8 @@ enum root_directory_inos {
PROC_HARDWARE,
PROC_SLABINFO,
PROC_PARPORT,
- PROC_OMIRR /* whether enabled or not */
+ PROC_OMIRR, /* whether enabled or not */
+ PROC_PPC_HTAB
};
enum pid_directory_inos {
@@ -182,6 +183,8 @@ enum scsi_directory_inos {
PROC_SCSI_ATARI,
PROC_SCSI_IDESCSI,
PROC_SCSI_SGIWD93,
+ PROC_SCSI_MESH,
+ PROC_SCSI_53C94,
PROC_SCSI_SCSI_DEBUG,
PROC_SCSI_NOT_PRESENT,
PROC_SCSI_FILE, /* I'm assuming here that we */
@@ -323,7 +326,7 @@ extern int proc_match(int, const char *,struct proc_dir_entry *);
* The /proc root directory has extended versions to take care
* of the /proc/<pid> subdirectories.
*/
-extern int proc_readdir(struct inode *, struct file *, void *, filldir_t);
+extern int proc_readdir(struct file *, void *, filldir_t);
extern int proc_lookup(struct inode *, struct dentry *);
struct openpromfs_dev {
@@ -363,6 +366,7 @@ extern struct inode_operations proc_fd_inode_operations;
extern struct inode_operations proc_ringbuf_inode_operations;
#endif
extern struct inode_operations proc_omirr_inode_operations;
+extern struct inode_operations proc_ppc_htab_inode_operations;
#endif
@@ -379,3 +383,8 @@ void remove_proc_entry(const char *name, struct proc_dir_entry *parent);
extern void proc_tty_init(void);
extern void proc_tty_register_driver(struct tty_driver *driver);
extern void proc_tty_unregister_driver(struct tty_driver *driver);
+
+/*
+ * proc_devtree.c
+ */
+extern void proc_device_tree_init(void);
diff --git a/include/linux/sched.h b/include/linux/sched.h
index f1fc28b18..16f024490 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -472,6 +472,16 @@ extern inline int suser(void)
return 0;
}
+/*
+ * Routines for handling mm_structs
+ */
+extern struct mm_struct * mm_alloc(void);
+static inline void mmget(struct mm_struct * mm)
+{
+ mm->count++;
+}
+extern void mmput(struct mm_struct *);
+
extern int copy_thread(int, unsigned long, unsigned long, struct task_struct *, struct pt_regs *);
extern void flush_thread(void);
extern void exit_thread(void);
diff --git a/include/linux/smb.h b/include/linux/smb.h
index 1bba4859e..8953686b0 100644
--- a/include/linux/smb.h
+++ b/include/linux/smb.h
@@ -1,119 +1,76 @@
/*
* smb.h
*
- * Copyright (C) 1995 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1995, 1996 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1997 by Volker Lendecke
*
*/
#ifndef _LINUX_SMB_H
#define _LINUX_SMB_H
-#define SMB_PORT 139
-#define SMB_MAXNAMELEN 255
-#define SMB_MAXPATHLEN 1024
-
-#define SMB_DEF_MAX_XMIT 32768
-
-/* Allocate max. 1 page */
-#define TRANS2_MAX_TRANSFER (4096-17)
-
-#include <asm/types.h>
-#ifdef __KERNEL__
-typedef u8 byte;
-typedef u16 word;
-typedef u32 dword;
-#else
-typedef unsigned char byte;
-typedef unsigned short word;
-typedef unsigned long dword;
-#endif
-
-/* The following macros have been taken directly from Samba. Thanks,
- Andrew! */
-
-#undef CAREFUL_ALIGNMENT
+#include <linux/types.h>
-/* we know that the 386 can handle misalignment and has the "right"
- byteorder */
-#if defined(__i386__)
-#define CAREFUL_ALIGNMENT 0
-#endif
-
-#ifndef CAREFUL_ALIGNMENT
-#define CAREFUL_ALIGNMENT 1
-#endif
+enum smb_protocol {
+ SMB_PROTOCOL_NONE,
+ SMB_PROTOCOL_CORE,
+ SMB_PROTOCOL_COREPLUS,
+ SMB_PROTOCOL_LANMAN1,
+ SMB_PROTOCOL_LANMAN2,
+ SMB_PROTOCOL_NT1
+};
-#define BVAL(buf,pos) (((u8 *)(buf))[pos])
-#define PVAL(buf,pos) ((unsigned)BVAL(buf,pos))
-#define BSET(buf,pos,val) (BVAL(buf,pos) = (val))
+enum smb_case_hndl {
+ SMB_CASE_DEFAULT,
+ SMB_CASE_LOWER,
+ SMB_CASE_UPPER
+};
+struct smb_dskattr {
+ __u16 total;
+ __u16 allocblocks;
+ __u16 blocksize;
+ __u16 free;
+};
-#if CAREFUL_ALIGNMENT
-#define WVAL(buf,pos) (PVAL(buf,pos)|PVAL(buf,(pos)+1)<<8)
-#define DVAL(buf,pos) (WVAL(buf,pos)|WVAL(buf,(pos)+2)<<16)
+struct smb_conn_opt {
-#define SSVALX(buf,pos,val) (BVAL(buf,pos)=(val)&0xFF,BVAL(buf,pos+1)=(val)>>8)
-#define SIVALX(buf,pos,val) (SSVALX(buf,pos,val&0xFFFF),SSVALX(buf,pos+2,val>>16))
-#define WSET(buf,pos,val) { word __val = (val); \
- SSVALX((buf),(pos),((word)(__val))); }
-#define DSET(buf,pos,val) { dword __val = (val); \
- SIVALX((buf),(pos),((dword)(__val))); }
-#else
-/* this handles things for architectures like the 386 that can handle
- alignment errors */
-/*
- WARNING: This section is dependent on the length of word and dword
- being correct
-*/
-#define WVAL(buf,pos) (*(word *)((char *)(buf) + (pos)))
-#define DVAL(buf,pos) (*(dword *)((char *)(buf) + (pos)))
-#define WSET(buf,pos,val) WVAL(buf,pos)=((word)(val))
-#define DSET(buf,pos,val) DVAL(buf,pos)=((dword)(val))
-#endif
+ /* The socket */
+ unsigned int fd;
+ enum smb_protocol protocol;
+ enum smb_case_hndl case_handling;
-/* where to find the base of the SMB packet proper */
-#define smb_base(buf) ((byte *)(((byte *)(buf))+4))
+ /* Connection-Options */
-#define LANMAN1
-#define LANMAN2
-#define NT1
+ __u32 max_xmit;
+ __u16 server_uid;
+ __u16 tid;
-enum smb_protocol {
- PROTOCOL_NONE,
- PROTOCOL_CORE,
- PROTOCOL_COREPLUS,
- PROTOCOL_LANMAN1,
- PROTOCOL_LANMAN2,
- PROTOCOL_NT1
-};
+ /* The following are LANMAN 1.0 options */
+ __u16 secmode;
+ __u16 maxmux;
+ __u16 maxvcs;
+ __u16 rawmode;
+ __u32 sesskey;
-enum smb_case_hndl {
- CASE_DEFAULT,
- CASE_LOWER,
- CASE_UPPER
+ /* The following are NT LM 0.12 options */
+ __u32 maxraw;
+ __u32 capabilities;
+ __u16 serverzone;
};
#ifdef __KERNEL__
-enum smb_conn_state {
- CONN_VALID, /* everything's fine */
- CONN_INVALID, /* Something went wrong, but did not
- try to reconnect yet. */
- CONN_RETRIED /* Tried a reconnection, but was refused */
-};
-
-struct smb_dskattr {
- word total;
- word allocblocks;
- word blocksize;
- word free;
-};
+#define SMB_MAXNAMELEN 255
+#define SMB_MAXPATHLEN 1024
/*
* Contains all relevant data on a SMB networked file.
*/
-struct smb_dirent {
+struct smb_fattr {
+
+ __u16 attr;
unsigned long f_ino;
umode_t f_mode;
@@ -127,16 +84,40 @@ struct smb_dirent {
time_t f_ctime;
unsigned long f_blksize;
unsigned long f_blocks;
-
- int opened; /* is it open on the fileserver? */
- word fileid; /* What id to handle a file with? */
- word attr; /* Attribute fields, DOS value */
-
- unsigned short access; /* Access bits. */
- unsigned long f_pos; /* File position. (For readdir.) */
- unsigned char name[SMB_MAXNAMELEN+1];
- int len; /* namelength */
};
-#endif /* __KERNEL__ */
-#endif /* _LINUX_SMB_H */
+struct smb_dirent {
+ struct smb_fattr attr;
+
+ int f_pos;
+ int len;
+ __u8 name[SMB_MAXNAMELEN];
+};
+
+enum smb_conn_state {
+ CONN_VALID, /* everything's fine */
+ CONN_INVALID, /* Something went wrong, but did not
+ try to reconnect yet. */
+ CONN_RETRIED /* Tried a reconnection, but was refused */
+};
+
+/*
+ * The readdir cache size controls how many directory entries are cached.
+ */
+#define SMB_READDIR_CACHE_SIZE 64
+
+#define SMB_SUPER_MAGIC 0x517B
+
+#define SMB_SERVER(inode) (&(inode->i_sb->u.smbfs_sb))
+#define SMB_INOP(inode) (&(inode->u.smbfs_i))
+
+#define SMB_HEADER_LEN 37 /* includes everything up to, but not
+ * including smb_bcc */
+#define SMB_DEF_MAX_XMIT 32768
+#define SMB_INITIAL_PACKET_SIZE 4000
+
+/* Allocate max. 1 page */
+#define TRANS2_MAX_TRANSFER (4096-17)
+
+#endif
+#endif
diff --git a/include/linux/smb_fs.h b/include/linux/smb_fs.h
index c129cb540..be01f3048 100644
--- a/include/linux/smb_fs.h
+++ b/include/linux/smb_fs.h
@@ -2,6 +2,7 @@
* smb_fs.h
*
* Copyright (C) 1995 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1997 by Volker Lendecke
*
*/
@@ -9,72 +10,37 @@
#define _LINUX_SMB_FS_H
#include <linux/smb.h>
-#include <linux/fs.h>
-#include <linux/in.h>
-#include <linux/types.h>
-#include <linux/vmalloc.h>
-
-#include <linux/smb_mount.h>
-#include <linux/smb_fs_sb.h>
-#include <linux/smb_fs_i.h>
/*
* ioctl commands
*/
#define SMB_IOC_GETMOUNTUID _IOR('u', 1, uid_t)
+#define SMB_IOC_NEWCONN _IOW('u', 2, struct smb_conn_opt)
#ifdef __KERNEL__
-/*
- * The readdir cache size controls how many directory entries are cached.
- */
-#define SMB_READDIR_CACHE_SIZE 64
-
-/*
- * This defines the number of filenames cached in memory to avoid
- * constructing filenames from \
- */
-#define SMB_CACHE_TABLE_SIZE 64
-
-#define SMB_SUPER_MAGIC 0x517B
+#include <asm/unaligned.h>
+#define WVAL(buf,pos) \
+(le16_to_cpu(get_unaligned((__u16 *)((__u8 *)(buf) + (pos)))))
+#define DVAL(buf,pos) \
+(le32_to_cpu(get_unaligned((__u32 *)((__u8 *)(buf) + (pos)))))
+#define WSET(buf,pos,val) \
+put_unaligned(cpu_to_le16((__u16)(val)), (__u16 *)((__u8 *)(buf) + (pos)))
+#define DSET(buf,pos,val) \
+put_unaligned(cpu_to_le32((__u32)(val)), (__u32 *)((__u8 *)(buf) + (pos)))
+/* where to find the base of the SMB packet proper */
+#define smb_base(buf) ((__u8 *)(((__u8 *)(buf))+4))
-#define SMB_SBP(sb) ((struct smb_sb_info *)(sb->u.generic_sbp))
-#define SMB_INOP(inode) ((struct smb_inode_info *)(inode->u.generic_ip))
-
-#define SMB_SERVER(inode) (&(SMB_SBP(inode->i_sb)->s_server))
-#define SMB_SERVATTR(inode) (&(SMB_SBP(inode->i_sb)->s_attr))
-
-#define SMB_FINFO(inode) (&(SMB_INOP(inode)->finfo))
-
-#define SMB_HEADER_LEN 37 /* includes everything up to, but not
- * including smb_bcc */
+#include <linux/vmalloc.h>
#ifdef DEBUG_SMB_MALLOC
-#include <linux/malloc.h>
-
extern int smb_malloced;
-extern int smb_current_kmalloced;
extern int smb_current_vmalloced;
static inline void *
-smb_kmalloc(unsigned int size, int priority)
-{
- smb_malloced += 1;
- smb_current_kmalloced += 1;
- return kmalloc(size, priority);
-}
-
-static inline void
-smb_kfree_s(void *obj, int size)
-{
- smb_current_kmalloced -= 1;
- kfree_s(obj, size);
-}
-
-static inline void *
smb_vmalloc(unsigned int size)
{
smb_malloced += 1;
@@ -98,47 +64,20 @@ smb_vfree(void *obj)
#endif /* DEBUG_SMB_MALLOC */
-#if DEBUG_SMB > 0
-#define DPRINTK(format, args...) printk(format , ## args)
-#else
-#define DPRINTK(format, args...)
-#endif
-
-#if DEBUG_SMB > 1
-#define DDPRINTK(format, args...) printk(format , ## args)
-#else
-#define DDPRINTK(format, args...)
-#endif
-
-
-static inline ino_t
-smb_info_ino(struct smb_inode_info *info)
-{
-#if 0
- return (ino_t) info;
-#else
- if (info != NULL)
- {
- return info->finfo.f_ino;
- }
- return 1;
-#endif
-}
+struct smb_sb_info;
/* linux/fs/smbfs/file.c */
extern struct inode_operations smb_file_inode_operations;
-int smb_make_open(struct inode *i, int right);
/* linux/fs/smbfs/dir.c */
extern struct inode_operations smb_dir_inode_operations;
-struct smb_inode_info *smb_find_inode(struct smb_server *server, ino_t ino);
+struct smb_inode_info *smb_find_inode(struct smb_sb_info *server, ino_t ino);
void smb_free_inode_info(struct smb_inode_info *i);
-void smb_free_all_inodes(struct smb_server *server);
-void smb_init_root(struct smb_server *server);
-int smb_stat_root(struct smb_server *server);
+void smb_free_all_inodes(struct smb_sb_info *server);
+void smb_init_root(struct smb_sb_info *server);
+int smb_stat_root(struct smb_sb_info *server);
void smb_init_dir_cache(void);
void smb_invalid_dir_cache(unsigned long ino);
-void smb_invalidate_all_inodes(struct smb_server *server);
void smb_free_dir_cache(void);
/* linux/fs/smbfs/ioctl.c */
@@ -149,63 +88,61 @@ int smb_ioctl (struct inode * inode, struct file * filp,
struct super_block *smb_read_super(struct super_block *sb,
void *raw_data, int silent);
extern int init_smb_fs(void);
+void smb_invalidate_inodes(struct smb_sb_info *server);
+int smb_revalidate_inode(struct inode *i);
+int smb_refresh_inode(struct inode *i);
int smb_notify_change(struct inode *inode, struct iattr *attr);
-void smb_invalidate_connection(struct smb_server *server);
-int smb_conn_is_valid(struct smb_server *server);
+void smb_invalidate_connection(struct smb_sb_info *server);
+int smb_conn_is_valid(struct smb_sb_info *server);
+unsigned long smb_invent_inos(unsigned long n);
+struct inode *smb_iget(struct super_block *, struct smb_fattr *);
/* linux/fs/smbfs/proc.c */
-dword smb_len(unsigned char *packet);
-byte *smb_encode_smb_length(byte *p, dword len);
-__u8 *smb_setup_header(struct smb_server *server, byte command,
- word wct, word bcc);
-void smb_init_root_dirent(struct smb_server *server, struct smb_dirent *entry);
-int smb_proc_open(struct smb_server *server,
- struct smb_inode_info *dir, const char *name, int len,
- struct smb_dirent *entry);
-int smb_proc_close(struct smb_server *server,
- __u16 fileid, __u32 mtime);
-int smb_proc_read(struct smb_server *server, struct smb_dirent *finfo,
- off_t offset, long count, char *data, int fs);
-int smb_proc_read_raw(struct smb_server *server, struct smb_dirent *finfo,
- off_t offset, long count, char *data);
-int smb_proc_write(struct smb_server *server, struct smb_dirent *finfo,
- off_t offset, int count, const char *data);
-int smb_proc_write_raw(struct smb_server *server, struct smb_dirent *finfo,
- off_t offset, long count, const char *data);
-int smb_proc_create(struct inode *dir, const char *name, int len,
- word attr, time_t ctime);
-int smb_proc_mv(struct inode *odir, const char *oname, const int olen,
- struct inode *ndir, const char *nname, const int nlen);
-int smb_proc_mkdir(struct inode *dir, const char *name, const int len);
-int smb_proc_rmdir(struct inode *dir, const char *name, const int len);
-int smb_proc_unlink(struct inode *dir, const char *name, const int len);
-int smb_proc_readdir(struct smb_server *server, struct inode *dir,
- int fpos, int cache_size,
- struct smb_dirent *entry);
-int smb_proc_getattr(struct inode *dir, const char *name, int len,
- struct smb_dirent *entry);
-int smb_proc_setattr(struct smb_server *server,
- struct inode *ino,
- struct smb_dirent *new_finfo);
-int smb_proc_chkpath(struct smb_server *server, char *path, int len,
- int *result);
-int smb_proc_dskattr(struct super_block *super, struct smb_dskattr *attr);
-int smb_proc_reconnect(struct smb_server *server);
-int smb_proc_connect(struct smb_server *server);
-int smb_proc_disconnect(struct smb_server *server);
-int smb_proc_trunc(struct smb_server *server, word fid, dword length);
+__u32 smb_len(unsigned char *packet);
+__u8 *smb_encode_smb_length(__u8 *p, __u32 len);
+__u8 *smb_setup_header(struct smb_sb_info *server, __u8 command,
+ __u16 wct, __u16 bcc);
+int smb_offerconn(struct smb_sb_info *server);
+int smb_newconn(struct smb_sb_info *server, struct smb_conn_opt *opt);
+int smb_close(struct dentry *);
+int smb_open(struct dentry *, int);
+static inline int
+smb_is_open(struct inode *i)
+{
+ return (i->u.smbfs_i.open == SMB_SERVER(i)->generation);
+}
+
+int smb_proc_read(struct inode *, off_t, long, char *);
+int smb_proc_write(struct inode *, off_t, int, const char *);
+int smb_proc_create(struct dentry *, struct qstr *, __u16, time_t);
+int smb_proc_mv(struct dentry *, struct qstr *, struct dentry *, struct qstr *);
+int smb_proc_mkdir(struct dentry *, struct qstr *);
+int smb_proc_rmdir(struct dentry *, struct qstr *);
+int smb_proc_unlink(struct dentry *dir, struct qstr *);
+int smb_proc_readdir(struct dentry *dir, int fpos, int cache_size, struct smb_dirent *entry);
+int smb_proc_getattr(struct dentry *dir, struct qstr *name,
+ struct smb_fattr *entry);
+int smb_proc_setattr(struct smb_sb_info *server,
+ struct dentry *dir,
+ struct smb_fattr *new_finfo);
+int smb_proc_dskattr(struct super_block *sb, struct statfs *attr);
+int smb_proc_reconnect(struct smb_sb_info *server);
+int smb_proc_connect(struct smb_sb_info *server);
+int smb_proc_disconnect(struct smb_sb_info *server);
+int smb_proc_trunc(struct smb_sb_info *server, __u16 fid, __u32 length);
+void smb_init_root_dirent(struct smb_sb_info *server, struct smb_fattr *);
/* linux/fs/smbfs/sock.c */
-int smb_release(struct smb_server *server);
-int smb_connect(struct smb_server *server);
-int smb_request(struct smb_server *server);
-int smb_request_read_raw(struct smb_server *server,
+int smb_release(struct smb_sb_info *server);
+int smb_connect(struct smb_sb_info *server);
+int smb_request(struct smb_sb_info *server);
+int smb_request_read_raw(struct smb_sb_info *server,
unsigned char *target, int max_len);
-int smb_request_write_raw(struct smb_server *server,
+int smb_request_write_raw(struct smb_sb_info *server,
unsigned const char *source, int length);
-int smb_catch_keepalive(struct smb_server *server);
-int smb_dont_catch_keepalive(struct smb_server *server);
-int smb_trans2_request(struct smb_server *server, __u16 trans2_command,
+int smb_catch_keepalive(struct smb_sb_info *server);
+int smb_dont_catch_keepalive(struct smb_sb_info *server);
+int smb_trans2_request(struct smb_sb_info *server, __u16 trans2_command,
int ldata, unsigned char *data,
int lparam, unsigned char *param,
int *lrdata, unsigned char **rdata,
diff --git a/include/linux/smb_fs_i.h b/include/linux/smb_fs_i.h
index b6e38fd18..743e3954a 100644
--- a/include/linux/smb_fs_i.h
+++ b/include/linux/smb_fs_i.h
@@ -2,6 +2,7 @@
* smb_fs_i.h
*
* Copyright (C) 1995 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1997 by Volker Lendecke
*
*/
@@ -9,25 +10,22 @@
#define _LINUX_SMB_FS_I
#ifdef __KERNEL__
-#include <linux/smb.h>
-
-enum smb_inode_state {
- SMB_INODE_VALID = 19, /* Inode currently in use */
- SMB_INODE_LOOKED_UP, /* directly before iget */
- SMB_INODE_CACHED, /* in a path to an inode which is in use */
- SMB_INODE_INVALID
-};
+#include <linux/types.h>
/*
* smb fs inode data (in memory only)
*/
struct smb_inode_info {
- enum smb_inode_state state;
- int nused; /* for directories:
- number of references in memory */
- struct smb_inode_info *dir;
- struct smb_inode_info *next, *prev;
- struct smb_dirent finfo;
+
+ /*
+ * file handles are local to a connection. A file is open if
+ * (open == generation).
+ */
+ unsigned int open;
+ __u16 fileid; /* What id to handle a file with? */
+ __u16 attr; /* Attribute fields, DOS value */
+
+ __u16 access; /* Access bits. */
};
#endif
diff --git a/include/linux/smb_fs_sb.h b/include/linux/smb_fs_sb.h
index 863062022..72b805e60 100644
--- a/include/linux/smb_fs_sb.h
+++ b/include/linux/smb_fs_sb.h
@@ -2,76 +2,41 @@
* smb_fs_sb.h
*
* Copyright (C) 1995 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1997 by Volker Lendecke
*
*/
#ifndef _SMB_FS_SB
#define _SMB_FS_SB
+#ifdef __KERNEL__
+
+#include <linux/types.h>
#include <linux/smb.h>
-#include <linux/smb_fs_i.h>
#include <linux/smb_mount.h>
-#include <linux/types.h>
-
-#ifdef __KERNEL__
-struct smb_server {
- enum smb_protocol protocol; /* The protocol this
- connection accepts. */
- enum smb_case_hndl case_handling;
- struct file * sock_file; /* The socket we transfer
- data on. */
- int lock; /* To prevent mismatch in
- protocols. */
- struct wait_queue *wait;
+struct smb_sb_info {
+ enum smb_conn_state state;
+ struct file * sock_file;
- __u32 max_xmit;
- char hostname[256];
- word pid;
- word server_uid;
- word mid;
- word tid;
+ struct smb_mount_data m;
- struct smb_mount_data m; /* We store the complete information here
- * to be able to reconnect.
- */
+ /* Connections are counted. Each time a new socket arrives,
+ * generation is incremented.
+ */
+ unsigned int generation;
+ pid_t conn_pid;
+ struct smb_conn_opt opt;
- unsigned short rcls; /* The error codes we received */
- unsigned short err;
+ struct semaphore sem;
__u32 packet_size;
unsigned char * packet;
-
- enum smb_conn_state state;
- unsigned long reconnect_time; /* The time of the last attempt */
-
- /* The following are LANMAN 1.0 options transferred to us in
- SMBnegprot */
- word secmode;
- word maxmux;
- word maxvcs;
- word blkmode;
- dword sesskey;
+ unsigned short rcls; /* The error codes we received */
+ unsigned short err;
/* We use our on data_ready callback, but need the original one */
void *data_ready;
-
- /* We do not have unique numbers for files in the smb protocol
- like NFS-filehandles. (SMB was designed for DOS, not for
- UNIX!) So we have to create our own inode numbers. We keep
- a complete path of smb_inode_info's to each active
- inode. The inode number is then created by the address of
- this structure. */
- struct smb_inode_info root;
-};
-
-/*
- * This is the part of the super-block (in memory) for the SMB file system.
- */
-
-struct smb_sb_info {
- struct smb_server s_server;
- struct smb_dskattr s_attr;
};
#endif /* __KERNEL__ */
diff --git a/include/linux/smb_mount.h b/include/linux/smb_mount.h
index 7f1748731..0a8a10ee2 100644
--- a/include/linux/smb_mount.h
+++ b/include/linux/smb_mount.h
@@ -2,6 +2,7 @@
* smb_mount.h
*
* Copyright (C) 1995, 1996 by Paal-Kr. Engstad and Volker Lendecke
+ * Copyright (C) 1997 by Volker Lendecke
*
*/
@@ -9,26 +10,12 @@
#define _LINUX_SMB_MOUNT_H
#include <linux/types.h>
-#include <linux/in.h>
-#define SMB_MOUNT_VERSION 5
+#define SMB_MOUNT_VERSION 6
struct smb_mount_data {
int version;
- unsigned int fd;
uid_t mounted_uid; /* Who may umount() this filesystem? */
- struct sockaddr_in addr;
-
- char server_name[17];
- char client_name[17];
- char service[64];
- char root_path[64];
-
- char username[64];
- char password[64];
- char domain[64];
-
- unsigned short max_xmit;
uid_t uid;
gid_t gid;
diff --git a/include/linux/sockios.h b/include/linux/sockios.h
index 5be29bc57..5147dd23c 100644
--- a/include/linux/sockios.h
+++ b/include/linux/sockios.h
@@ -54,6 +54,9 @@
#define SIOCADDMULTI 0x8931 /* Multicast address lists */
#define SIOCDELMULTI 0x8932
#define SIOGIFINDEX 0x8933 /* name -> if_index mapping */
+#define SIOGIFNAME 0x8934 /* if_index -> name mapping */
+#define SIOCGIFCOUNT 0x8935 /* get number of interfaces */
+#define SIOCDIFADDR 0x8936 /* delete PA address */
#define SIOCGIFBR 0x8940 /* Bridging support */
#define SIOCSIFBR 0x8941 /* Set bridging options */
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h
index 75fdf6c3d..1e18516d7 100644
--- a/include/linux/sysctl.h
+++ b/include/linux/sysctl.h
@@ -172,8 +172,9 @@ enum
NET_IPV4_IGMP_TIMER_SCALE,
NET_IPV4_IGMP_AGE_THRESHOLD,
NET_TCP_SYNCOOKIES,
- NET_TCP_ALWAYS_SYNCOOKIE,
NET_TCP_STDURG,
+ NET_TCP_SYN_TAILDROP,
+ NET_TCP_MAX_SYN_BACKLOG,
};
diff --git a/include/linux/trdevice.h b/include/linux/trdevice.h
index 77e4efb5d..e3a469fb5 100644
--- a/include/linux/trdevice.h
+++ b/include/linux/trdevice.h
@@ -33,7 +33,7 @@ extern int tr_header(struct sk_buff *skb, struct device *dev,
void *saddr, unsigned len);
extern int tr_rebuild_header(struct sk_buff *skb);
extern unsigned short tr_type_trans(struct sk_buff *skb, struct device *dev);
-
+extern void tr_reformat(struct sk_buff *, unsigned int);
extern struct device * init_trdev(struct device *, int);
#endif
diff --git a/include/linux/tty.h b/include/linux/tty.h
index bc3ec7d27..0052d0510 100644
--- a/include/linux/tty.h
+++ b/include/linux/tty.h
@@ -77,8 +77,11 @@ extern struct screen_info screen_info;
#define VIDEO_TYPE_TGAC 0x40 /* DEC TGA */
#define VIDEO_TYPE_SUN 0x50 /* Sun frame buffer. */
+#define VIDEO_TYPE_SUNPCI 0x51 /* Sun PCI based frame buffer. */
-#define VIDEO_TYPE_SGI 0x61 /* Various SGI graphics hardware */
+#define VIDEO_TYPE_PMAC 0x60 /* PowerMacintosh frame buffer. */
+
+#define VIDEO_TYPE_SGI 0x70 /* Various SGI graphics hardware */
/*
* This character is the same as _POSIX_VDISABLE: it cannot be used as
diff --git a/include/linux/udp.h b/include/linux/udp.h
index 471301a2f..ab75a1e81 100644
--- a/include/linux/udp.h
+++ b/include/linux/udp.h
@@ -19,10 +19,10 @@
struct udphdr {
- unsigned short source;
- unsigned short dest;
- unsigned short len;
- unsigned short check;
+ __u16 source;
+ __u16 dest;
+ __u16 len;
+ __u16 check;
};