Linux Kernel Patch v2.3, patch-2.3.5 (0/2)

2 views
Skip to first unread message

Thomas...@ciw.uni-karlsruhe.de

unread,
Jun 6, 1999, 3:00:00 AM6/6/99
to
Archive-name: v2.3/patch-2.3.5/part0

lines added deleted
linux/Documentation/isdn/CREDITS : 8 1 1
linux/Documentation/kernel-parameters.txt : 336 336 0
linux/Documentation/video4linux/bttv/CONTRIBUTORS : 8 1 1
linux/Documentation/video4linux/bttv/README.WINVIEW : 33 33 0
linux/Makefile : 7 1 1
linux/arch/i386/defconfig : 18 2 1
linux/arch/i386/kernel/smp.c : 8 1 1
linux/drivers/acorn/block/ide-ics.c : 7 1 0
linux/drivers/char/acquirewdt.c : 19 3 3
linux/drivers/char/pc110pad.c : 14 3 3
linux/drivers/char/pms.c : 8 1 1
linux/drivers/char/softdog.c : 10 2 2
linux/drivers/char/videodev.c : 8 1 1
linux/drivers/char/wdt.c : 28 5 3
linux/drivers/isdn/avmb1/b1pci.c : 7 1 0
linux/drivers/isdn/hisax/hscx_irq.c : 8 2 0
linux/drivers/isdn/hisax/telespci.c : 7 1 0
linux/drivers/misc/parport_ax.c : 7 1 0
linux/drivers/misc/parport_procfs.c : 7 1 0
linux/drivers/misc/parport_share.c : 8 2 0
linux/drivers/net/ptifddi.c : 7 1 0
linux/drivers/net/shaper.c : 10 2 2
linux/drivers/sbus/dvma.c : 7 1 0
linux/drivers/sound/audio.c : 12 2 0
linux/drivers/sound/bin2hex.c : 5 1 0
linux/drivers/sound/hex2hex.c : 7 1 0
linux/drivers/sound/sound_timer.c : 7 1 0
linux/drivers/video/fbcmap.c : 7 1 0
linux/fs/binfmt_aout.c : 30 8 5
linux/fs/binfmt_elf.c : 25 4 5
linux/fs/binfmt_em86.c : 23 7 5
linux/fs/binfmt_java.c : 42 11 8
linux/fs/binfmt_misc.c : 17 4 5
linux/fs/binfmt_script.c : 22 6 5
linux/fs/coda/cnode.c : 7 1 0
linux/fs/coda/psdev.c : 8 1 1
linux/fs/devpts/inode.c : 7 1 0
linux/fs/efs/namei.c : 7 1 0
linux/fs/efs/symlink.c : 7 1 0
linux/fs/exec.c : 212 66 69
linux/fs/file_table.c : 7 1 0
linux/fs/hpfs/buffer.c : 7 1 0
linux/fs/hpfs/ea.c : 7 1 0
linux/fs/hpfs/file.c : 7 1 0
linux/fs/hpfs/name.c : 7 1 0
linux/fs/hpfs/namei.c : 7 1 0
linux/fs/hpfs/super.c : 7 1 0
linux/fs/isofs/symlink.c : 7 1 0
linux/fs/lockd/svcshare.c : 7 1 0
linux/fs/lockd/svcsubs.c : 7 1 0
linux/fs/ncpfs/file.c : 105 16 12
linux/fs/nfs/file.c : 51 22 2
linux/fs/nfs/write.c : 30 5 5
linux/fs/ntfs/util.c : 7 1 0
linux/fs/qnx4/inode.c : 7 1 0
linux/fs/qnx4/symlinks.c : 7 1 0
linux/fs/smbfs/file.c : 60 25 5
linux/fs/ufs/util.c : 7 1 0
linux/include/asm-i386/locks.h : 8 1 1
linux/include/asm-i386/softirq.h : 83 20 20
linux/include/linux/binfmts.h : 30 8 6
linux/include/linux/fs.h : 22 4 2
linux/include/linux/if_ether.h : 8 1 1
linux/include/linux/if_fddi.h : 8 1 1
linux/include/linux/if_hippi.h : 8 1 1
linux/include/linux/nfs_fs.h : 8 1 1
linux/include/linux/smp.h : 8 1 1
linux/init/main.c : 7 1 0
linux/mm/filemap.c : 46 4 15
linux/net/802/llc_macinit.c : 16 3 0
linux/net/core/datagram.c : 8 1 1
linux/net/core/dev.c : 84 15 14
linux/net/core/neighbour.c : 12 2 0
linux/net/decnet/dn_dev.c : 29 3 7
linux/net/ethernet/eth.c : 16 1 2
linux/net/ipv4/devinet.c : 48 9 11
linux/net/ipv4/icmp.c : 8 1 1
linux/net/ipv4/ip_masq_quake.c : 15 2 0
linux/net/ipv4/ip_masq_vdolive.c : 17 4 0
linux/net/ipv4/ip_options.c : 7 0 1
linux/net/ipv4/ipmr.c : 8 1 1
linux/net/ipv4/tcp_input.c : 9 1 1
linux/net/ipv6/ip6_fw.c : 7 1 0
linux/net/ipv6/ip6_output.c : 14 3 1
linux/net/ipv6/mcast.c : 7 1 0
linux/net/ipv6/reassembly.c : 12 3 0
linux/net/irda/discovery.c : 16 3 0
linux/net/irda/irda_device.c : 16 3 0
linux/net/irda/irlap_comp.c : 17 4 0
linux/net/irda/wrapper.c : 16 3 0
linux/net/netlink/af_netlink.c : 8 1 1
linux/net/netlink/netlink_dev.c : 8 1 1
linux/net/sunrpc/auth.c : 12 3 0
linux/net/sunrpc/auth_unix.c : 12 3 0
linux/net/x25/af_x25.c : 12 1 4
--
Thomas Koenig, Thomas...@ciw.uni-karlsruhe.de, ig...@dkauni2.bitnet.
The joy of engineering is to find a straight line on a double
logarithmic diagram.

Thomas...@ciw.uni-karlsruhe.de

unread,
Jun 6, 1999, 3:00:00 AM6/6/99
to
Archive-name: v2.3/patch-2.3.5/part2

#!/bin/sh
# this is part 2 of a 2 - part archive
# do not concatenate these parts, unpack them in order with /bin/sh
# file patch-2.3.5 continued
if test ! -r _shar_seq_.tmp; then
echo 'Please unpack part 1 first!'
exit 1
fi
(read Scheck
if test "$Scheck" != 2; then
echo Please unpack part "$Scheck" next!
exit 1
else
exit 0
fi
) < _shar_seq_.tmp || exit 1
if test ! -f _shar_wnt_.tmp; then
echo 'x - still skipping patch-2.3.5'
else
echo 'x - continuing with patch-2.3.5'
sed 's/^X//' << 'SHAR_EOF' >> 'patch-2.3.5' &&
+ size_t count, loff_t *ppos,
+ writepage_t write_one_page)
X {
X struct dentry *dentry = file->f_dentry;
X struct inode *inode = dentry->d_inode;
@@ -1434,10 +1435,7 @@
X struct page *page, **hash;
X unsigned long page_cache = 0;
X unsigned long written;
- long status, sync;
-
- if (!inode->i_op || !inode->i_op->updatepage)
- return -EIO;
+ long status;
X
X if (file->f_error) {
X int error = file->f_error;
@@ -1445,7 +1443,6 @@
X return error;
X }
X
- sync = file->f_flags & O_SYNC;
X written = 0;
X
X if (file->f_flags & O_APPEND)
@@ -1501,15 +1498,7 @@
X wait_on_page(page);
X set_bit(PG_locked, &page->flags);
X
- /*
- * Do the real work.. If the writer ends up delaying the write,
- * the writer needs to increment the page use counts until he
- * is done with the page.
- */
- bytes -= copy_from_user((u8*)page_address(page) + offset, buf, bytes);
- status = -EFAULT;
- if (bytes)
- status = inode->i_op->updatepage(file, page, offset, bytes, sync);
+ status = write_one_page(file, page, offset, bytes, buf);
X
X /* Mark it unlocked again and drop the page.. */
X clear_bit(PG_locked, &page->flags);
diff -u --recursive --new-file v2.3.4/linux/net/802/llc_macinit.c linux/net/802/llc_macinit.c
--- v2.3.4/linux/net/802/llc_macinit.c Fri Feb 20 18:28:23 1998
+++ linux/net/802/llc_macinit.c Tue Jun 1 23:25:48 1999
@@ -17,6 +17,8 @@
X * Alan Cox : Chainsawed to Linux format
X * Added llc_ to names
X * Started restructuring handlers
+ *
+ * Horst von Brand : Add #include <linux/string.h>
X */
X
X #include <linux/module.h>
@@ -24,6 +26,7 @@
X #include <linux/kernel.h>
X #include <linux/malloc.h>
X #include <linux/unistd.h>
+#include <linux/string.h>
X #include <linux/netdevice.h>
X #include <linux/init.h>
X #include <net/p8022.h>
diff -u --recursive --new-file v2.3.4/linux/net/core/datagram.c linux/net/core/datagram.c
--- v2.3.4/linux/net/core/datagram.c Mon May 31 22:28:07 1999
+++ linux/net/core/datagram.c Wed Jun 2 11:29:13 1999
@@ -6,7 +6,7 @@
X * This is used because UDP, RAW, PACKET, DDP, IPX, AX.25 and NetROM layer all have identical poll code and mostly
X * identical recvmsg() code. So we share it here. The poll was shared before but buried in udp.c so I moved it.
X *
- * Authors: Alan Cox <al...@cymru.net>. (datagram_poll() from old udp.c code)
+ * Authors: Alan Cox <al...@redhat.com>. (datagram_poll() from old udp.c code)
X *
X * Fixes:
X * Alan Cox : NULL return from skb_peek_copy() understood
diff -u --recursive --new-file v2.3.4/linux/net/core/dev.c linux/net/core/dev.c
--- v2.3.4/linux/net/core/dev.c Mon May 31 22:28:07 1999
+++ linux/net/core/dev.c Tue Jun 1 10:07:39 1999
@@ -453,11 +453,8 @@
X dev_do_clear_fastroute(dev);
X } else {
X read_lock_bh(&dev_base_lock);
- for (dev = dev_base; dev; dev = dev->next) {
- read_unlock_bh(&dev_base_lock);
+ for (dev = dev_base; dev; dev = dev->next)
X dev_do_clear_fastroute(dev);
- read_lock_bh(&dev_base_lock);
- }
X read_unlock_bh(&dev_base_lock);
X }
X }
@@ -1128,8 +1125,13 @@
X if (copy_from_user(&ifc, arg, sizeof(struct ifconf)))
X return -EFAULT;
X
- pos = ifc.ifc_buf;
X len = ifc.ifc_len;
+ if (ifc.ifc_buf) {
+ pos = (char *) kmalloc(len, GFP_KERNEL);
+ if(pos == NULL)
+ return -ENOBUFS;
+ } else
+ pos = NULL;
X
X /*
X * Loop over the interfaces, and write an info block for each.
@@ -1138,7 +1140,6 @@
X total = 0;
X read_lock_bh(&dev_base_lock);
X for (dev = dev_base; dev != NULL; dev = dev->next) {
- read_unlock_bh(&dev_base_lock);
X for (i=0; i<NPROTO; i++) {
X if (gifconf_list[i]) {
X int done;
@@ -1147,16 +1148,20 @@
X } else {
X done = gifconf_list[i](dev, pos+total, len-total);
X }
- if (done<0) {
- return -EFAULT;
- }
X total += done;
X }
X }
- read_lock_bh(&dev_base_lock);
X }
X read_unlock_bh(&dev_base_lock);
X
+ if(pos != NULL) {
+ int err = copy_to_user(ifc.ifc_buf, pos, total);
+
+ kfree(pos);
+ if(err)
+ return -EFAULT;
+ }
+
X /*
X * All done. Write the updated control block back to the caller.
X */
@@ -2016,7 +2021,6 @@
X */
X
X dp = &dev_base;
- write_lock_bh(&dev_base_lock);
X while ((dev = *dp) != NULL) {
X dev->iflink = -1;
X if (dev->init && dev->init(dev)) {
@@ -2026,15 +2030,12 @@
X *dp = dev->next;
X } else {
X dp = &dev->next;
- write_unlock_bh(&dev_base_lock);
X dev->ifindex = dev_new_index();
- write_lock_bh(&dev_base_lock);
X if (dev->iflink == -1)
X dev->iflink = dev->ifindex;
X dev_init_scheduler(dev);
X }
X }
- write_unlock_bh(&dev_base_lock);
X
X #ifdef CONFIG_PROC_FS
X proc_net_register(&proc_net_dev);
diff -u --recursive --new-file v2.3.4/linux/net/core/neighbour.c linux/net/core/neighbour.c
--- v2.3.4/linux/net/core/neighbour.c Thu Apr 22 19:45:19 1999
+++ linux/net/core/neighbour.c Tue Jun 1 23:25:48 1999
@@ -12,10 +12,12 @@
X *
X * Fixes:
X * Vitaly E. Lavrov releasing NULL neighbor in neigh_add.
+ * Horst von Brand Add #include <linux/string.h>
X */
X
X #include <linux/config.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/kernel.h>
X #include <linux/socket.h>
X #include <linux/sched.h>
diff -u --recursive --new-file v2.3.4/linux/net/decnet/dn_dev.c linux/net/decnet/dn_dev.c
--- v2.3.4/linux/net/decnet/dn_dev.c Mon May 31 22:28:07 1999
+++ linux/net/decnet/dn_dev.c Tue Jun 1 10:07:39 1999
@@ -1189,15 +1189,14 @@
X {
X struct dn_dev *dn_db = (struct dn_dev *)dev->dn_ptr;
X struct dn_ifaddr *ifa;
- char buffer[DN_IFREQ_SIZE];
- struct ifreq *ifr = (struct ifreq *)buffer;
+ struct ifreq *ifr = (struct ifreq *)buf;
X int done = 0;
X
X if ((dn_db == NULL) || ((ifa = dn_db->ifa_list) == NULL))
X return 0;
X
X for(; ifa; ifa = ifa->ifa_next) {
- if (!buf) {
+ if (!ifr) {
X done += sizeof(DN_IFREQ_SIZE);
X continue;
X }
@@ -1214,10 +1213,7 @@
X (*(struct sockaddr_dn *) &ifr->ifr_addr).sdn_add.a_len = 2;
X (*(dn_address *)(*(struct sockaddr_dn *) &ifr->ifr_addr).sdn_add.a_addr) = ifa->ifa_local;
X
- if (copy_to_user(buf, ifr, DN_IFREQ_SIZE))
- return -EFAULT;
-
- buf += DN_IFREQ_SIZE;
+ ifr = (struct ifreq *)((char *)ifr + DN_IFREQ_SIZE);
X len -= DN_IFREQ_SIZE;
X done += DN_IFREQ_SIZE;
X }
diff -u --recursive --new-file v2.3.4/linux/net/ethernet/eth.c linux/net/ethernet/eth.c
--- v2.3.4/linux/net/ethernet/eth.c Mon May 31 22:28:07 1999
+++ linux/net/ethernet/eth.c Tue Jun 1 09:43:41 1999
@@ -67,7 +67,7 @@
X
X if (!str || !*str)
X return;
- read_lock_bh(&dev_base_lock);
+
X d = dev_base;
X while (d)
X {
@@ -85,7 +85,6 @@
X }
X d=d->next;
X }
- read_unlock_bh(&dev_base_lock);
X }
X
X
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/devinet.c linux/net/ipv4/devinet.c
--- v2.3.4/linux/net/ipv4/devinet.c Mon May 31 22:28:07 1999
+++ linux/net/ipv4/devinet.c Tue Jun 1 10:07:39 1999
@@ -1,7 +1,7 @@
X /*
X * NET3 IP device support routines.
X *
- * Version: $Id: devinet.c,v 1.29 1999/05/27 00:37:57 davem Exp $
+ * Version: $Id: devinet.c,v 1.30 1999/06/01 07:49:59 davem Exp $
X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License
@@ -607,31 +607,29 @@
X {
X struct in_device *in_dev = dev->ip_ptr;
X struct in_ifaddr *ifa;
- struct ifreq ifr;
+ struct ifreq *ifr = (struct ifreq *) buf;
X int done=0;
X
X if (in_dev==NULL || (ifa=in_dev->ifa_list)==NULL)
X return 0;
X
X for ( ; ifa; ifa = ifa->ifa_next) {
- if (!buf) {
+ if (!ifr) {
X done += sizeof(ifr);
X continue;
X }
X if (len < (int) sizeof(ifr))
X return done;
- memset(&ifr, 0, sizeof(struct ifreq));
+ memset(ifr, 0, sizeof(struct ifreq));
X if (ifa->ifa_label)
- strcpy(ifr.ifr_name, ifa->ifa_label);
+ strcpy(ifr->ifr_name, ifa->ifa_label);
X else
- strcpy(ifr.ifr_name, dev->name);
+ strcpy(ifr->ifr_name, dev->name);
X
- (*(struct sockaddr_in *) &ifr.ifr_addr).sin_family = AF_INET;
- (*(struct sockaddr_in *) &ifr.ifr_addr).sin_addr.s_addr = ifa->ifa_local;
+ (*(struct sockaddr_in *) &ifr->ifr_addr).sin_family = AF_INET;
+ (*(struct sockaddr_in *) &ifr->ifr_addr).sin_addr.s_addr = ifa->ifa_local;
X
- if (copy_to_user(buf, &ifr, sizeof(struct ifreq)))
- return -EFAULT;
- buf += sizeof(struct ifreq);
+ ifr++;
X len -= sizeof(struct ifreq);
X done += sizeof(struct ifreq);
X }
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/icmp.c linux/net/ipv4/icmp.c
--- v2.3.4/linux/net/ipv4/icmp.c Mon May 31 22:28:07 1999
+++ linux/net/ipv4/icmp.c Wed Jun 2 11:29:13 1999
@@ -1,7 +1,7 @@
X /*
X * NET3: Implementation of the ICMP protocol layer.
X *
- * Alan Cox, <al...@cymru.net>
+ * Alan Cox, <al...@redhat.com>
X *
X * Version: $Id: icmp.c,v 1.54 1999/05/30 01:16:22 davem Exp $
X *
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/ip_masq_quake.c linux/net/ipv4/ip_masq_quake.c
--- v2.3.4/linux/net/ipv4/ip_masq_quake.c Fri May 14 18:55:31 1999
+++ linux/net/ipv4/ip_masq_quake.c Tue Jun 1 23:25:48 1999
@@ -12,6 +12,7 @@
X * http://www.gamers.org/dEngine/quake/spec/
X * Harald Hoyer : Check for QUAKE-STRING
X * Juan Jose Ciarlante : litl bits for 2.1
+ * Horst von Brand : Add #include <linux/string.h>
X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License
@@ -24,6 +25,7 @@
X #include <linux/module.h>
X #include <asm/system.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/kernel.h>
X #include <linux/skbuff.h>
X #include <linux/in.h>
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/ip_masq_vdolive.c linux/net/ipv4/ip_masq_vdolive.c
--- v2.3.4/linux/net/ipv4/ip_masq_vdolive.c Tue Oct 27 09:57:19 1998
+++ linux/net/ipv4/ip_masq_vdolive.c Tue Jun 1 23:25:48 1999
@@ -10,6 +10,9 @@
X * Fixes: Minor changes for 2.1 by
X * Steven Clarke <Steven...@ThePlanet.Net>, Planet Online Ltd
X *
+ * Add missing #include <linux/string.h>
+ * Horst von Brand <vonb...@sleipnir.valparaiso.cl>
+ *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License
X * as published by the Free Software Foundation; either version
@@ -25,6 +28,7 @@
X #include <linux/config.h>
X #include <linux/module.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/kernel.h>
X #include <asm/system.h>
X #include <linux/skbuff.h>
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/ip_options.c linux/net/ipv4/ip_options.c
--- v2.3.4/linux/net/ipv4/ip_options.c Sun Mar 21 07:22:00 1999
+++ linux/net/ipv4/ip_options.c Tue Jun 1 16:44:27 1999
@@ -452,7 +452,6 @@
X error:
X if (skb) {
X icmp_send(skb, ICMP_PARAMETERPROB, 0, htonl((pp_ptr-iph)<<24));
- kfree_skb(skb);
X }
X return -EINVAL;
X }
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/ipmr.c linux/net/ipv4/ipmr.c
--- v2.3.4/linux/net/ipv4/ipmr.c Thu Mar 25 09:23:34 1999
+++ linux/net/ipv4/ipmr.c Wed Jun 2 11:29:13 1999
@@ -1,7 +1,7 @@
X /*
X * IP multicast routing support for mrouted 3.6/3.8
X *
- * (c) 1995 Alan Cox, <al...@cymru.net>
+ * (c) 1995 Alan Cox, <al...@redhat.com>
X * Linux Consultancy and Custom Driver Development
X *
X * This program is free software; you can redistribute it and/or
diff -u --recursive --new-file v2.3.4/linux/net/ipv4/tcp_input.c linux/net/ipv4/tcp_input.c
--- v2.3.4/linux/net/ipv4/tcp_input.c Mon May 31 22:28:07 1999
+++ linux/net/ipv4/tcp_input.c Tue Jun 1 10:18:56 1999
@@ -2321,8 +2321,8 @@
X !(th->fin && TCP_SKB_CB(skb)->end_seq == tp->rcv_nxt)) {
X if (!th->rst) {
X tcp_send_ack(sk);
- goto discard;
X }
+ goto discard;
X }
X
X /* step 2: check RST bit */
diff -u --recursive --new-file v2.3.4/linux/net/ipv6/ip6_fw.c linux/net/ipv6/ip6_fw.c
--- v2.3.4/linux/net/ipv6/ip6_fw.c Thu Aug 27 19:33:09 1998
+++ linux/net/ipv6/ip6_fw.c Tue Jun 1 23:25:48 1999
@@ -16,6 +16,7 @@
X #include <linux/config.h>
X #include <linux/errno.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/socket.h>
X #include <linux/sockios.h>
X #include <linux/net.h>
diff -u --recursive --new-file v2.3.4/linux/net/ipv6/ip6_output.c linux/net/ipv6/ip6_output.c
--- v2.3.4/linux/net/ipv6/ip6_output.c Thu Apr 22 19:45:20 1999
+++ linux/net/ipv6/ip6_output.c Tue Jun 1 23:25:48 1999
@@ -20,11 +20,13 @@
X * route changes now work.
X * ip6_forward does not confuse sniffers.
X * etc.
- *
+ *
+ * H. von Brand : Added missing #include <linux/string.h>
X */
X
X #include <linux/errno.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/socket.h>
X #include <linux/net.h>
X #include <linux/netdevice.h>
diff -u --recursive --new-file v2.3.4/linux/net/ipv6/mcast.c linux/net/ipv6/mcast.c
--- v2.3.4/linux/net/ipv6/mcast.c Mon May 31 22:28:07 1999
+++ linux/net/ipv6/mcast.c Tue Jun 1 23:25:48 1999
@@ -20,6 +20,7 @@
X #include <linux/module.h>
X #include <linux/errno.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/socket.h>
X #include <linux/sockios.h>
X #include <linux/sched.h>
diff -u --recursive --new-file v2.3.4/linux/net/ipv6/reassembly.c linux/net/ipv6/reassembly.c
--- v2.3.4/linux/net/ipv6/reassembly.c Thu Aug 27 19:33:09 1998
+++ linux/net/ipv6/reassembly.c Tue Jun 1 23:25:48 1999
@@ -19,9 +19,12 @@
X * Fixes:
X * Andi Kleen Make it work with multiple hosts.
X * More RFC compliance.
+ *
+ * Horst von Brand Add missing #include <linux/string.h>
X */
X #include <linux/errno.h>
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/socket.h>
X #include <linux/sockios.h>
X #include <linux/sched.h>
diff -u --recursive --new-file v2.3.4/linux/net/irda/discovery.c linux/net/irda/discovery.c
--- v2.3.4/linux/net/irda/discovery.c Mon May 31 22:28:07 1999
+++ linux/net/irda/discovery.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,8 @@
X * Created at: Tue Apr 6 15:33:50 1999
X * Modified at: Sun May 9 22:40:43 1999
X * Modified by: Dag Brattli <da...@cs.uit.no>
+ * Modified at: Fri May 28 3:11 CST 1999
+ * Modified by: Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X *
X * Copyright (c) 1999 Dag Brattli, All Rights Reserved.
X *
@@ -28,6 +30,7 @@
X *
X ********************************************************************/
X
+#include <linux/string.h>
X #include <linux/socket.h>
X #include <linux/irda.h>
X
diff -u --recursive --new-file v2.3.4/linux/net/irda/irda_device.c linux/net/irda/irda_device.c
--- v2.3.4/linux/net/irda/irda_device.c Mon May 31 22:28:07 1999
+++ linux/net/irda/irda_device.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,8 @@
X * Created at: Wed Sep 2 20:22:08 1998
X * Modified at: Mon May 10 23:02:47 1999
X * Modified by: Dag Brattli <da...@cs.uit.no>
+ * Modified at: Fri May 28 3:11 CST 1999
+ * Modified by: Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X *
X * Copyright (c) 1998-1999 Dag Brattli, All Rights Reserved.
X *
@@ -23,6 +25,7 @@
X ********************************************************************/
X
X #include <linux/config.h>
+#include <linux/string.h>
X #include <linux/proc_fs.h>
X #include <linux/skbuff.h>
X #include <linux/if.h>
diff -u --recursive --new-file v2.3.4/linux/net/irda/irlap_comp.c linux/net/irda/irlap_comp.c
--- v2.3.4/linux/net/irda/irlap_comp.c Mon May 31 22:28:07 1999
+++ linux/net/irda/irlap_comp.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,8 @@
X * Created at: Fri Oct 9 09:18:07 1998
X * Modified at: Sun May 9 11:37:06 1999
X * Modified by: Dag Brattli <da...@cs.uit.no>
+ * Modified at: Fri May 28 3:11 CST 1999
+ * Modified by: Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X * Sources: ppp.c, isdn_ppp.c
X *
X * Copyright (c) 1998-1999 Dag Brattli, All Rights Reserved.
@@ -22,6 +24,8 @@
X * provided "AS-IS" and at no charge.
X *
X ********************************************************************/
+
+#include <linux/string.h>
X
X #include <net/irda/irda.h>
X #include <net/irda/irqueue.h>
diff -u --recursive --new-file v2.3.4/linux/net/irda/wrapper.c linux/net/irda/wrapper.c
--- v2.3.4/linux/net/irda/wrapper.c Mon May 31 22:28:07 1999
+++ linux/net/irda/wrapper.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,8 @@
X * Created at: Mon Aug 4 20:40:53 1997
X * Modified at: Sun May 2 21:58:00 1999
X * Modified by: Dag Brattli <da...@cs.uit.no>
+ * Modified at: Fri May 28 3:11 CST 1999
+ * Modified by: Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X *
X * Copyright (c) 1998-1999 Dag Brattli <da...@cs.uit.no>,
X * All Rights Reserved.
@@ -24,6 +26,7 @@
X ********************************************************************/
X
X #include <linux/skbuff.h>
+#include <linux/string.h>
X #include <asm/byteorder.h>
X
X #include <net/irda/irda.h>
diff -u --recursive --new-file v2.3.4/linux/net/netlink/af_netlink.c linux/net/netlink/af_netlink.c
--- v2.3.4/linux/net/netlink/af_netlink.c Mon May 17 09:55:23 1999
+++ linux/net/netlink/af_netlink.c Wed Jun 2 11:29:13 1999
@@ -1,7 +1,7 @@
X /*
X * NETLINK Kernel-user communication protocol.
X *
- * Authors: Alan Cox <al...@cymru.net>
+ * Authors: Alan Cox <al...@redhat.com>
X * Alexey Kuznetsov <kuz...@ms2.inr.ac.ru>
X *
X * This program is free software; you can redistribute it and/or
diff -u --recursive --new-file v2.3.4/linux/net/netlink/netlink_dev.c linux/net/netlink/netlink_dev.c
--- v2.3.4/linux/net/netlink/netlink_dev.c Thu Aug 27 19:33:09 1998
+++ linux/net/netlink/netlink_dev.c Wed Jun 2 11:29:13 1999
@@ -2,7 +2,7 @@
X * NETLINK An implementation of a loadable kernel mode driver providing
X * multiple kernel/user space bidirectional communications links.
X *
- * Author: Alan Cox <al...@cymru.net>
+ * Author: Alan Cox <al...@redhat.com>
X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License
diff -u --recursive --new-file v2.3.4/linux/net/sunrpc/auth.c linux/net/sunrpc/auth.c
--- v2.3.4/linux/net/sunrpc/auth.c Mon Mar 22 08:00:15 1999
+++ linux/net/sunrpc/auth.c Tue Jun 1 23:25:48 1999
@@ -4,9 +4,12 @@
X * Generic RPC authentication API.
X *
X * Copyright (C) 1996, Olaf Kirch <ok...@monad.swb.de>
+ *
+ * Modified May 1999, Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X */
X
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/sched.h>
X #include <linux/malloc.h>
X #include <linux/errno.h>
diff -u --recursive --new-file v2.3.4/linux/net/sunrpc/auth_unix.c linux/net/sunrpc/auth_unix.c
--- v2.3.4/linux/net/sunrpc/auth_unix.c Mon Mar 22 08:00:15 1999
+++ linux/net/sunrpc/auth_unix.c Tue Jun 1 23:25:48 1999
@@ -4,9 +4,12 @@
X * UNIX-style authentication; no AUTH_SHORT support
X *
X * Copyright (C) 1996, Olaf Kirch <ok...@monad.swb.de>
+ *
+ * Modified May 1999 Horst von Brand <vonb...@sleipnir.valparaiso.cl>
X */
X
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/malloc.h>
X #include <linux/socket.h>
X #include <linux/in.h>
diff -u --recursive --new-file v2.3.4/linux/net/x25/af_x25.c linux/net/x25/af_x25.c
--- v2.3.4/linux/net/x25/af_x25.c Mon May 31 22:28:07 1999
+++ linux/net/x25/af_x25.c Tue Jun 1 09:43:41 1999
@@ -1342,11 +1342,8 @@
X #if defined(CONFIG_LLC) || defined(CONFIG_LLC_MODULE)
X || dev->type == ARPHRD_ETHER
X #endif
- )) {
- read_unlock_bh(&dev_base_lock);
+ ))
X x25_link_device_up(dev);
- read_lock_bh(&dev_base_lock);
- }
X }
X read_unlock_bh(&dev_base_lock);
X
SHAR_EOF
true || echo 'restore of patch-2.3.5 failed'
echo 'File patch-2.3.5 is complete' &&
chmod 644 patch-2.3.5 ||
echo 'restore of patch-2.3.5 failed'
Cksum="`cksum < 'patch-2.3.5'`"
if ! test "1692146205 76666" = "$Cksum"
then
echo 'patch-2.3.5: original Checksum 1692146205 76666, current one' "$Cksum"
rm -f _shar_wnt_.tmp
rm -f _shar_seq_.tmp
exit 1
fi
rm -f _shar_wnt_.tmp
fi
rm -f _shar_seq_.tmp
echo 'You have unpacked the last part.'
exit 0

Thomas...@ciw.uni-karlsruhe.de

unread,
Jun 6, 1999, 3:00:00 AM6/6/99
to
Archive-name: v2.3/patch-2.3.5/part1

#!/bin/sh
# This is a shell archive
# To extract the files from this archive, save it to a file, remove
# everything above the "!/bin/sh" line above, and type "sh file_name".
# existing files will NOT be overwritten unless -c is specified
#
# This is part 1 of a 2 - part archive


# do not concatenate these parts, unpack them in order with /bin/sh
#

if test -r _shar_seq_.tmp; then
echo 'Must unpack archives in sequence!'
echo Please unpack part `cat _shar_seq_.tmp` next
exit 1
fi
# ============= patch-2.3.5 ==============
if test -f 'patch-2.3.5' -a X"$1" != X"-c"; then
echo 'x - skipping patch-2.3.5 (File already exists)'
rm -f _shar_wnt_.tmp
else
> _shar_wnt_.tmp
echo 'x - extracting patch-2.3.5 (Text)'


sed 's/^X//' << 'SHAR_EOF' > 'patch-2.3.5' &&

diff -u --recursive --new-file v2.3.4/linux/Documentation/isdn/CREDITS linux/Documentation/isdn/CREDITS
--- v2.3.4/linux/Documentation/isdn/CREDITS Wed Apr 1 16:20:56 1998
+++ linux/Documentation/isdn/CREDITS Wed Jun 2 11:29:13 1999
@@ -5,7 +5,7 @@
X Thomas Bogendörfer (tsbo...@bigbug.franken.de)
X Tester, lots of bugfixes and hints.
X
-Alan Cox (al...@cymru.net)
+Alan Cox (al...@redhat.com)
X For help getting into standard-kernel.
X
X Henner Eisen (e...@baty.hanse.de)
diff -u --recursive --new-file v2.3.4/linux/Documentation/kernel-parameters.txt linux/Documentation/kernel-parameters.txt
--- v2.3.4/linux/Documentation/kernel-parameters.txt Wed Dec 31 16:00:00 1969
+++ linux/Documentation/kernel-parameters.txt Wed Jun 2 11:32:45 1999
@@ -0,0 +1,336 @@
+June 1999 Kernel Parameters v2.2.9
+ ~~~~~~~~~~~~~~~~~
+
+The following is a consolidated list of the kernel parameters as defined
+in the file init/main.c and sorted into English Dictionary order (defined
+as ignoring all punctuation and sorting digits before letters in a case
+insensitive manner), and with descriptions where known.
+
+The text in square brackets at the beginning of the description state the
+restrictions on the kernel for the said kernel parameter to be valid. The
+restrictions referred to are that the relevant option is valid if:
+
+ APIC APIC support is enabled.
+ APM Automatic Power Management support is enabled.
+ AX25 Appropriate AX.25 support is enabled.
+ CD Appropriate CD support is enabled.
+ EIDE EIDE/ATAPI support is enabled.
+ FB The frame buffer device is enabled.
+ HW Appropriate hardware is enabled.
+ ISDN Appropriate ISDN support is enabled.
+ JOY Appropriate joystick support is enabled.
+ LPT Printer support is enabled.
+ MCA MCA bus support is enabled.
+ MDA The MDA console is enabled.
+ MOUSE Appropriate mouse support is enabled.
+ NET Appropriate network support is enabled.
+ NFS Appropriate NFS support is enabled.
+ PARIDE The ParIDE subsystem is enabled.
+ PCI PCI bus support is enabled.
+ PCMCIA The PCMCIA subsystem is enabled.
+ PNP Plug & Play support is enabled.
+ PS2 Appropriate PS/2 support is enabled.
+ RAM RAMdisc support is enabled.
+ SCSI Appropriate SCSI support is enabled.
+ SERIAL Serial support is enabled.
+ SMP The kernel is an SMP kernel.
+ SOUND Appropriate sound system support is enabled.
+ VGA The VGA console has been enabled.
+ VT Virtual terminal support is enabled.
+ XT IBM PC/XT support is enabled.
+
+In addition, the following text indicates that the option:
+
+ BUGS= Relates to possible processor bugs on the said processor.
+ KNL Is a kernel start-up parameter.
+
+Note that ALL kernel parameters listed below are CASE SENSITIVE, and that
+a trailing = on the name of any parameter states that that parameter will
+be entered as an environment variable, whereas its absence indicates that
+it will appear as a kernel argument readable via /proc/cmdline by programs
+running once the system is up.
+
+ 53c7xx= [HW,SCSI]
+
+ adb_buttons= [HW,MOUSE]
+
+ advansys= [HW,SCSI]
+
+ aha152x= [HW,SCSI]
+
+ aha1542= [HW,SCSI]
+
+ aic7xxx= [HW,SCSI]
+
+ AM53C974= [HW,SCSI]
+
+ apm= [APM] Automatic Power Management.
+
+ arcrimi= [HW,NET]
+
+ atamouse= [HW,MOUSE] Atari Mouse.
+
+ atascsi= [HW,SCSI] Atari SCSI.
+
+ aztcd= [HW,CD] Aztec CD driver.
+
+ baycom_par= [HW,AX25] BayCom Parallel Port AX.25 Modem.
+
+ baycom_ser_fdx= [HW,AX25] BayCom Serial Port AX.25 Modem in Full
+ Duplex Mode.
+
+ baycom_ser_hdx= [HW,AX25] BayCom Serial Port AX.25 Modem in Half
+ Duplex Mode.
+
+ bmouse= [HW,MOUSE,PS2] Bus mouse.
+
+ BusLogic= [HW,SCSI]
+
+ cdu31a= [HW,CD]
+
+ cm206= [HW,CD]
+
+ com20020= [HW,NET]
+
+ com90io= [HW,NET]
+
+ com90xx= [HW,NET]
+
+ console=
+
+ cyclades= [HW,SERIAL] Cyclades multi-serial port adapter.
+
+ debug [KNL] Enable kernel debugging.
+
+ decnet= [HW,NET]
+
+ digi= [HW,SERIAL]
+
+ digiepca= [HW,SERIAL]
+
+ dmascc= [HW,AX25,SERIAL] AX.25 Z80SCC driver with DMA
+ support available.
+
+ dmasound= [HW,SOUND]
+
+ dtc3181e= [HW,SCSI]
+
+ eata= [HW,SCSI]
+
+ eda= [HW,PS2]
+
+ edb= [HW,PS2]
+
+ ether= [HW,NET] Ethernet.
+
+ fd_mcs= [HW,SCSI]
+
+ fdomain= [HW,SCSI]
+
+ floppy= [HW]
+
+ ftape= [HW] Floppy Tape subsystem.
+
+ gdth= [HW,SCSI]
+
+ gscd= [HW,CD]
+
+ gvp11= [HW,SCSI]
+
+ hd= [EIDE] IDE and EIDE hard drive subsystem.
+
+ hfmodem= [HW,AX25]
+
+ HiSax= [HW,ISDN]
+
+ hisax= [HW,ISDN]
+
+ ibmmcascsi= [HW,MCA,SCSI] IBM MicroChannel SCSI adapter.
+
+ icn= [HW,ISDN]
+
+ in2000= [HW,SCSI]
+
+ init= [KNL]
+
+ ip= [PNP]
+
+ isp16= [HW,CD]
+
+ js_14= [HW,JOY]
+
+ js_am= [HW,JOY]
+
+ js_an= [HW,JOY]
+
+ js_as= [HW.JOY]
+
+ js_console= [HW,JOY]
+
+ js_console2= [HW,JOY]
+
+ js_console3= [HW,JOY]
+
+ js_db9= [HW,JOY]
+
+ js_db9_2= [HW,JOY]
+
+ js_db9_3= [HW,JOY]
+
+ js_tg= [HW,JOY]
+
+ js_tg_2= [HW,JOY]
+
+ js_tg_3= [HW,JOY]
+
+ kbd-reset [VT]
+
+ load_ramdisk= [RAM]
+
+ lp= [LPT] Parallel Printer.
+
+ ltpc= [HW]
+
+ mac5380= [HW,SCSI]
+
+ maxcpus= [SMP] States the maximum number of processors that
+ an SMP kernel should make use of.
+
+ max_scsi_luns= [SCSI]
+
+ mca-pentium [BUGS=ix86]
+
+ mcd= [HW,CD]
+
+ mcdx= [HW,CD]
+
+ md= [HW]
+
+ mdacon= [MDA]
+
+ msmouse= [HW,MOUSE] Microsoft Mouse.
+
+ ncr5380= [HW,SCSI]
+
+ ncr53c400= [HW,SCSI]
+
+ ncr53c400a= [HW,SCSI]
+
+ ncr53c406a= [HW,SCSI]
+
+ ncr53c8xx= [HW,SCSI]
+
+ nfsaddrs= [NFS]
+
+ nfsroot= [NFS]
+
+ no387 [BUGS=ix86] Tells the kernel to use the 387 maths
+ emulation library even if a 387 maths coprocessor
+ is present.
+
+ noapic [SMP,APIC] Tells the kernel not to make use of any
+ APIC that may be present on the system.
+
+ no-halt [BUGS=ix86]
+
+ noinitrd [RAM] Tells the kernel not to load any configured
+ initial ramdisc.
+
+ no-scroll [VGA]
+
+ nosmp [SMP] Tells an SMP kernel to act as a UP kernel.
+
+ optcd= [HW,CD]
+
+ panic=
+
+ parport= [HW,LP]
+
+ pas16= [HW,SCSI]
+
+ pcbit= [HW,ISDN]
+
+ pcd. [PARIDE]
+
+ pci= [PCI]
+
+ pd. [PARIDE]
+
+ pf. [PARIDE]
+
+ pg. [PARIDE]
+
+ pirq= [SMP,APIC]
+
+ plip= [LP,NET] Parallel port network link.
+
+ profile=
+
+ prompt_ramdisk= [RAM] Whether to prompt for ramdisk before loading
+ its contents into memory.
+
+ pt. [PARIDE]
+
+ ramdisk= [RAM]
+
+ ramdisk_size= [RAM]
+
+ ramdisk_start= [RAM]
+
+ reboot= [BUGS=ix86]
+
+ reserve=
+
+ riscom8= [HW,SERIAL]
+
+ ro [KNL] Mount root device read-only on boot.
+
+ root=
+
+ rw [KNL] Mount root device read-write on boot.
+
+ sbpcd= [HW,CD] Soundblaster CD adapter.
+
+ scsi_logging= [SCSI]
+
+ sjcd= [HW,CD]
+
+ sonycd535= [HW,CD]
+
+ sound= [SOUND]
+
+ soundmodem= [HW,AX25,SOUND] Sound cards used as AX.25 modems.
+
+ specialix= [HW,SERIAL] Specialix multi-serial port adapter.
+
+ st= [HW]
+
+ st0x= [HW,SCSI]
+
+ stram_swap= [HW]
+
+ sym53c416= [HW,SCSI]
+
+ sym53c8xx= [HW,SCSI]
+
+ t128= [HW,SCSI]
+
+ tmc8xx= [HW,SCSI]
+
+ tmscsim= [HW,SCSI]
+
+ tp720= [HW,PS2]
+
+ u14-34f= [HW,SCSI]
+
+ video= [FB]
+
+ wd33c93= [HW,SCSI]
+
+ wd7000= [HW,SCSI]
+
+ wdt= [HW]
+
+ xd= [HW,XT]
+
+ xd_geo= [HW,XT]
diff -u --recursive --new-file v2.3.4/linux/Documentation/video4linux/bttv/CONTRIBUTORS linux/Documentation/video4linux/bttv/CONTRIBUTORS
--- v2.3.4/linux/Documentation/video4linux/bttv/CONTRIBUTORS Sun Aug 23 13:32:25 1998
+++ linux/Documentation/video4linux/bttv/CONTRIBUTORS Wed Jun 2 11:29:13 1999
@@ -3,7 +3,7 @@
X Michael Chu <mm...@pobox.com>
X AverMedia fix and more flexible card recognition
X
-Alan Cox <al...@cymru.net>
+Alan Cox <al...@redhat.com>
X Video4Linux interface and 2.1.x kernel adaptation
X
X Chris Kleitsch
diff -u --recursive --new-file v2.3.4/linux/Documentation/video4linux/bttv/README.WINVIEW linux/Documentation/video4linux/bttv/README.WINVIEW
--- v2.3.4/linux/Documentation/video4linux/bttv/README.WINVIEW Wed Dec 31 16:00:00 1969
+++ linux/Documentation/video4linux/bttv/README.WINVIEW Wed Jun 2 14:11:24 1999
@@ -0,0 +1,33 @@
+
+Support for the Leadtek WinView 601 TV/FM by Jon Tombs <j...@gte.esi.us.es>
+
+This card is basically the same as all the rest (Bt484A, Philips tuner),
+the main difference is that they have attached a programmable attenuator to 3
+GPIO lines in order to give some volume control. They have also stuck an
+infra-red remote control decoded on the board, I will add support for this
+when I get time (it simple generates an interrupt for each key press, with
+the key code is placed in the GPIO port).
+
+I don't yet have any application to test the radio support. The tuner
+frequency setting should work but it is possible that the audio multiplexer
+is wrong. If it doesn't work, send me email.
+
+
+- No Thanks to Leadtek they refused to answer any questions about their
+hardware. The driver was written by visual inspection of the card. If you
+use this driver, send an email insult to them, and tell them you won't
+continue buying their hardware unless they support Linux.
+
+- Little thanks to Princeton Technology Corp (http://www.princeton.com.tw)
+who make the audio attenuator. Their publicly available data-sheet available
+on their web site doesn't include the chip programming information! Hidden
+on their server are the full data-sheets, but don't ask how I found it.
+
+To use the driver I use the following options, the tuner and pll settings might
+be different in your country
+
+insmod videodev
+insmod i2c scan=1 i2c_debug=0 verbose=0
+insmod tuner type=1 debug=0
+insmod bttv pll=1 radio=1 card=17
+
diff -u --recursive --new-file v2.3.4/linux/Makefile linux/Makefile
--- v2.3.4/linux/Makefile Mon May 31 22:28:04 1999
+++ linux/Makefile Tue Jun 1 00:26:29 1999
@@ -1,6 +1,6 @@
X VERSION = 2
X PATCHLEVEL = 3
-SUBLEVEL = 4
+SUBLEVEL = 5
X EXTRAVERSION =
X
X ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/)
diff -u --recursive --new-file v2.3.4/linux/arch/i386/defconfig linux/arch/i386/defconfig
--- v2.3.4/linux/arch/i386/defconfig Mon May 31 22:28:04 1999
+++ linux/arch/i386/defconfig Tue Jun 1 00:27:29 1999
@@ -302,9 +302,9 @@
X CONFIG_USB_UHCI=y
X # CONFIG_USB_OHCI is not set
X # CONFIG_USB_OHCI_HCD is not set
+CONFIG_USB_HUB=y
X CONFIG_USB_MOUSE=y
X CONFIG_USB_KBD=y
-CONFIG_USB_HUB=y
X # CONFIG_USB_AUDIO is not set
X # CONFIG_USB_ACM is not set
X # CONFIG_USB_PRINTER is not set
@@ -350,6 +350,7 @@
X # CONFIG_MAC_PARTITION is not set
X # CONFIG_SMD_DISKLABEL is not set
X # CONFIG_SOLARIS_X86_PARTITION is not set
+# CONFIG_SGI_DISKLABEL is not set
X # CONFIG_NLS is not set
X
X #
diff -u --recursive --new-file v2.3.4/linux/arch/i386/kernel/smp.c linux/arch/i386/kernel/smp.c
--- v2.3.4/linux/arch/i386/kernel/smp.c Mon May 10 10:32:45 1999
+++ linux/arch/i386/kernel/smp.c Wed Jun 2 11:29:13 1999
@@ -2,7 +2,7 @@
X * Intel MP v1.1/v1.4 specification support routines for multi-pentium
X * hosts.
X *
- * (c) 1995 Alan Cox, CymruNET Ltd <al...@cymru.net>
+ * (c) 1995 Alan Cox, Building #3 <al...@redhat.com>
X * (c) 1998 Ingo Molnar
X *
X * Supported by Caldera http://www.caldera.com.
diff -u --recursive --new-file v2.3.4/linux/drivers/acorn/block/ide-ics.c linux/drivers/acorn/block/ide-ics.c
--- v2.3.4/linux/drivers/acorn/block/ide-ics.c Thu Dec 17 09:07:45 1998
+++ linux/drivers/acorn/block/ide-ics.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,7 @@
X * 12-09-1997 RMK Added interrupt enable/disable
X */
X
+#include <linux/string.h>
X #include <linux/module.h>
X #include <linux/ioport.h>
X #include <linux/malloc.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/char/acquirewdt.c linux/drivers/char/acquirewdt.c
--- v2.3.4/linux/drivers/char/acquirewdt.c Mon Aug 24 13:02:43 1998
+++ linux/drivers/char/acquirewdt.c Wed Jun 2 11:29:13 1999
@@ -3,8 +3,8 @@
X *
X * Based on wdt.c. Original copyright messages:
X *
- * (c) Copyright 1996 Alan Cox <al...@cymru.net>, All Rights Reserved.
- * http://www.cymru.net
+ * (c) Copyright 1996 Alan Cox <al...@redhat.com>, All Rights Reserved.
+ * http://www.redhat.com


X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License

@@ -15,7 +15,7 @@
X * warranty for any of this software. This material is provided
X * "AS-IS" and at no charge.
X *
- * (c) Copyright 1995 Alan Cox <al...@lxorguk.ukuu.org.uk>
+ * (c) Copyright 1995 Alan Cox <al...@redhat.com>
X *
X */
X
diff -u --recursive --new-file v2.3.4/linux/drivers/char/pc110pad.c linux/drivers/char/pc110pad.c
--- v2.3.4/linux/drivers/char/pc110pad.c Fri May 14 18:55:17 1999
+++ linux/drivers/char/pc110pad.c Wed Jun 2 11:29:13 1999
@@ -9,11 +9,11 @@
X * This is read internally and used to synthesize a stream of
X * triples in the form expected from a PS/2 device.
X *
- * 0.0 1997-05-16 Alan Cox <al...@cymru.net> - Pad reader
+ * 0.0 1997-05-16 Alan Cox <al...@redhat.com> - Pad reader
X * 0.1 1997-05-19 Robin O'Leary <ro...@acm.org> - PS/2 emulation
X * 0.2 1997-06-03 Robin O'Leary <ro...@acm.org> - tap gesture
- * 0.3 1997-06-27 Alan Cox <al...@cymru.net> - 2.1 commit
- * 0.4 1997-11-09 Alan Cox <al...@cymru.net> - Single Unix VFS API changes
+ * 0.3 1997-06-27 Alan Cox <al...@redhat.com> - 2.1 commit
+ * 0.4 1997-11-09 Alan Cox <al...@redhat.com> - Single Unix VFS API changes


X */
X
X #include <linux/module.h>

diff -u --recursive --new-file v2.3.4/linux/drivers/char/pms.c linux/drivers/char/pms.c
--- v2.3.4/linux/drivers/char/pms.c Thu Dec 31 17:07:10 1998
+++ linux/drivers/char/pms.c Wed Jun 2 11:29:13 1999
@@ -10,7 +10,7 @@
X * 14478 Potsdam, Germany
X *
X * Most of this code is directly derived from his userspace driver.
- * His driver works so send any reports to al...@cymru.net unless the
+ * His driver works so send any reports to al...@redhat.com unless the
X * userspace driver also doesnt work for you...
X */
X
diff -u --recursive --new-file v2.3.4/linux/drivers/char/softdog.c linux/drivers/char/softdog.c
--- v2.3.4/linux/drivers/char/softdog.c Sat Apr 24 17:49:37 1999
+++ linux/drivers/char/softdog.c Wed Jun 2 11:29:13 1999
@@ -1,8 +1,8 @@
X /*
X * SoftDog 0.05: A Software Watchdog Device
X *
- * (c) Copyright 1996 Alan Cox <al...@cymru.net>, All Rights Reserved.
- * http://www.cymru.net
+ * (c) Copyright 1996 Alan Cox <al...@redhat.com>, All Rights Reserved.
+ * http://www.redhat.com


X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License

diff -u --recursive --new-file v2.3.4/linux/drivers/char/videodev.c linux/drivers/char/videodev.c
--- v2.3.4/linux/drivers/char/videodev.c Thu Apr 15 05:42:40 1999
+++ linux/drivers/char/videodev.c Wed Jun 2 11:29:13 1999
@@ -9,7 +9,7 @@


X * as published by the Free Software Foundation; either version

X * 2 of the License, or (at your option) any later version.
X *
- * Author: Alan Cox, <al...@cymru.net>
+ * Author: Alan Cox, <al...@redhat.com>
X *
X * Fixes:
X */
diff -u --recursive --new-file v2.3.4/linux/drivers/char/wdt.c linux/drivers/char/wdt.c
--- v2.3.4/linux/drivers/char/wdt.c Sat Oct 17 15:52:18 1998
+++ linux/drivers/char/wdt.c Wed Jun 2 11:29:13 1999
@@ -1,8 +1,8 @@
X /*
X * Industrial Computer Source WDT500/501 driver for Linux 2.1.x
X *
- * (c) Copyright 1996-1997 Alan Cox <al...@cymru.net>, All Rights Reserved.
- * http://www.cymru.net
+ * (c) Copyright 1996-1997 Alan Cox <al...@redhat.com>, All Rights Reserved.
+ * http://www.redhat.com


X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License

@@ -15,7 +15,7 @@
X *
X * (c) Copyright 1995 Alan Cox <al...@lxorguk.ukuu.org.uk>
X *
- * Release 0.07.
+ * Release 0.08.


X *
X * Fixes

X * Dave Gregorich : Modularisation and minor bugs
@@ -24,6 +24,8 @@
X * Matt Crocker).
X * Alan Cox : Added wdt= boot option
X * Alan Cox : Cleaned up copy/user stuff
+ * Tim Hockin : Added insmod parameters, comment cleanup
+ * Parameterized timeout


X */
X
X #include <linux/config.h>

diff -u --recursive --new-file v2.3.4/linux/drivers/isdn/avmb1/b1pci.c linux/drivers/isdn/avmb1/b1pci.c
--- v2.3.4/linux/drivers/isdn/avmb1/b1pci.c Mon May 31 22:28:05 1999
+++ linux/drivers/isdn/avmb1/b1pci.c Tue Jun 1 23:25:48 1999
@@ -46,6 +46,7 @@
X */
X

X #include <linux/config.h>
+#include <linux/string.h>

X #include <linux/module.h>
X #include <linux/kernel.h>
X #include <linux/pci.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/isdn/hisax/hscx_irq.c linux/drivers/isdn/hisax/hscx_irq.c
--- v2.3.4/linux/drivers/isdn/hisax/hscx_irq.c Mon May 31 22:28:05 1999
+++ linux/drivers/isdn/hisax/hscx_irq.c Tue Jun 1 23:25:48 1999
@@ -42,6 +42,8 @@
X *
X */
X
+#include <linux/string.h>
+
X
X static inline void
X waitforCEC(struct IsdnCardState *cs, int hscx)
diff -u --recursive --new-file v2.3.4/linux/drivers/isdn/hisax/telespci.c linux/drivers/isdn/hisax/telespci.c
--- v2.3.4/linux/drivers/isdn/hisax/telespci.c Mon May 31 22:28:05 1999
+++ linux/drivers/isdn/hisax/telespci.c Tue Jun 1 23:25:48 1999
@@ -24,6 +24,7 @@
X */
X #define __NO_VERSION__


X #include <linux/config.h>
+#include <linux/string.h>

X #include "hisax.h"
X #include "isac.h"
X #include "hscx.h"
diff -u --recursive --new-file v2.3.4/linux/drivers/misc/parport_ax.c linux/drivers/misc/parport_ax.c
--- v2.3.4/linux/drivers/misc/parport_ax.c Mon Mar 15 16:11:30 1999
+++ linux/drivers/misc/parport_ax.c Tue Jun 1 23:25:48 1999
@@ -11,6 +11,7 @@
X * Grant Guenther <gr...@torque.net>
X */
X
+#include <linux/string.h>
X #include <linux/module.h>
X #include <linux/delay.h>
X #include <linux/errno.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/misc/parport_procfs.c linux/drivers/misc/parport_procfs.c
--- v2.3.4/linux/drivers/misc/parport_procfs.c Thu Jan 7 09:28:47 1999
+++ linux/drivers/misc/parport_procfs.c Tue Jun 1 23:25:48 1999
@@ -12,6 +12,7 @@
X * Cleaned up include files - Russell King <li...@arm.uk.linux.org>
X */
X
+#include <linux/string.h>
X #include <linux/config.h>
X #include <linux/sched.h>
X #include <linux/delay.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/misc/parport_share.c linux/drivers/misc/parport_share.c
--- v2.3.4/linux/drivers/misc/parport_share.c Mon May 31 22:28:05 1999
+++ linux/drivers/misc/parport_share.c Tue Jun 1 23:25:48 1999
@@ -15,6 +15,8 @@


X
X #include <linux/config.h>
X

+#include <linux/string.h>
+
X #include <linux/tasks.h>
X
X #include <linux/parport.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/net/ptifddi.c linux/drivers/net/ptifddi.c
--- v2.3.4/linux/drivers/net/ptifddi.c Tue Feb 10 12:56:45 1998
+++ linux/drivers/net/ptifddi.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,7 @@
X static char *version =
X "ptifddi.c:v1.0 10/Dec/96 David S. Miller (da...@caipfs.rutgers.edu)\n";
X
+#include <linux/string.h>
X #include <linux/init.h>
X
X #include "ptifddi.h"
diff -u --recursive --new-file v2.3.4/linux/drivers/net/shaper.c linux/drivers/net/shaper.c
--- v2.3.4/linux/drivers/net/shaper.c Fri May 14 18:55:20 1999
+++ linux/drivers/net/shaper.c Wed Jun 2 11:29:13 1999
@@ -1,8 +1,8 @@
X /*
X * Simple traffic shaper for Linux NET3.
X *
- * (c) Copyright 1996 Alan Cox <al...@cymru.net>, All Rights Reserved.
- * http://www.cymru.net
+ * (c) Copyright 1996 Alan Cox <al...@redhat.com>, All Rights Reserved.
+ * http://www.redhat.com


X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License

diff -u --recursive --new-file v2.3.4/linux/drivers/sbus/dvma.c linux/drivers/sbus/dvma.c
--- v2.3.4/linux/drivers/sbus/dvma.c Sun Oct 4 10:22:44 1998
+++ linux/drivers/sbus/dvma.c Tue Jun 1 23:25:48 1999
@@ -4,6 +4,7 @@
X */
X

X #include <linux/config.h>
+#include <linux/string.h>

X #include <linux/kernel.h>
X #include <linux/malloc.h>

X #include <linux/init.h>
diff -u --recursive --new-file v2.3.4/linux/drivers/sound/audio.c linux/drivers/sound/audio.c
--- v2.3.4/linux/drivers/sound/audio.c Mon Apr 12 16:18:27 1999
+++ linux/drivers/sound/audio.c Tue Jun 1 23:25:48 1999
@@ -20,10 +20,12 @@
X * Thomas Sailer : use more logical O_NONBLOCK semantics
X * Daniel Rodriksson: reworked the use of the device specific copy_user
X * still generic


+ * Horst von Brand: Add missing #include <linux/string.h>
X */
X

X #include <linux/config.h>
X #include <linux/stddef.h>
+#include <linux/string.h>
X #include <linux/kmod.h>
X
X #include "sound_config.h"
diff -u --recursive --new-file v2.3.4/linux/drivers/sound/bin2hex.c linux/drivers/sound/bin2hex.c
--- v2.3.4/linux/drivers/sound/bin2hex.c Thu Mar 12 10:52:09 1998
+++ linux/drivers/sound/bin2hex.c Tue Jun 1 23:25:48 1999
@@ -1,4 +1,5 @@
X #include <stdio.h>
+#include <string.h>
X
X int main( int argc, const char * argv [] )
X {
diff -u --recursive --new-file v2.3.4/linux/drivers/sound/hex2hex.c linux/drivers/sound/hex2hex.c
--- v2.3.4/linux/drivers/sound/hex2hex.c Thu May 14 10:33:17 1998
+++ linux/drivers/sound/hex2hex.c Tue Jun 1 23:25:48 1999
@@ -5,6 +5,7 @@
X */
X
X #include <stdio.h>
+#include <string.h>
X #include <stdlib.h>
X
X #define ABANDON(why) { fprintf(stderr, "%s\n", why); exit(1); }
diff -u --recursive --new-file v2.3.4/linux/drivers/sound/sound_timer.c linux/drivers/sound/sound_timer.c
--- v2.3.4/linux/drivers/sound/sound_timer.c Thu May 14 10:33:17 1998
+++ linux/drivers/sound/sound_timer.c Tue Jun 1 23:25:48 1999
@@ -12,6 +12,7 @@
X * Thomas Sailer : ioctl code reworked (vmalloc/vfree removed)
X */


X #include <linux/config.h>
+#include <linux/string.h>
X

X
X #include "sound_config.h"
diff -u --recursive --new-file v2.3.4/linux/drivers/video/fbcmap.c linux/drivers/video/fbcmap.c
--- v2.3.4/linux/drivers/video/fbcmap.c Tue Sep 29 20:56:33 1998
+++ linux/drivers/video/fbcmap.c Tue Jun 1 23:25:48 1999
@@ -8,6 +8,7 @@
X * more details.
X */
X
+#include <linux/string.h>
X #include <linux/module.h>
X #include <linux/tty.h>
X #include <linux/fb.h>
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_aout.c linux/fs/binfmt_aout.c
--- v2.3.4/linux/fs/binfmt_aout.c Mon May 31 22:28:06 1999
+++ linux/fs/binfmt_aout.c Wed Jun 2 13:49:49 1999
@@ -307,7 +307,6 @@
X struct file * file;
X int fd;
X unsigned long error;
- unsigned long p = bprm->p;
X unsigned long fd_offset;
X unsigned long rlim;
X int retval;
@@ -468,14 +467,18 @@
X
X set_brk(current->mm->start_brk, current->mm->brk);
X
- p = setup_arg_pages(p, bprm);
+ retval = setup_arg_pages(bprm);
+ if (retval < 0) {
+ /* Someone check-me: is this error path enough? */
+ send_sig(SIGKILL, current, 0);
+ return retval;
+ }
X
- p = (unsigned long) create_aout_tables((char *)p, bprm);
- current->mm->start_stack = p;
+ current->mm->start_stack = create_aout_tables(bprm->p, bprm);
X #ifdef __alpha__
X regs->gp = ex.a_gpvalue;
X #endif
- start_thread(regs, ex.a_entry, p);
+ start_thread(regs, ex.a_entry, current->mm->start_stack);
X if (current->flags & PF_PTRACED)
X send_sig(SIGTRAP, current, 0);
X return 0;
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_elf.c linux/fs/binfmt_elf.c
--- v2.3.4/linux/fs/binfmt_elf.c Mon May 31 22:28:06 1999
+++ linux/fs/binfmt_elf.c Wed Jun 2 13:49:52 1999
@@ -573,13 +573,12 @@
X passed_p = passed_fileno;
X
X if (elf_interpreter) {
- bprm->p = copy_strings(1,&passed_p,bprm->page,bprm->p,2);
+ retval = copy_strings_kernel(1,&passed_p,bprm);
+ if (retval)
+ goto out_free_dentry;
X bprm->argc++;
X }
X }
- retval = -E2BIG;
- if (!bprm->p)
- goto out_free_dentry;
X }
X
X /* Flush all traces of the currently running executable */
@@ -601,7 +600,7 @@
X /* Do this so that we can load the interpreter, if need be. We will
X change some of these later */
X current->mm->rss = 0;
- bprm->p = setup_arg_pages(bprm->p, bprm);
+ setup_arg_pages(bprm); /* XXX: check error */
X current->mm->start_stack = bprm->p;
X
X /* Try and get dynamic programs out of the way of the default mmap
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_em86.c linux/fs/binfmt_em86.c
--- v2.3.4/linux/fs/binfmt_em86.c Thu Aug 20 14:32:48 1998
+++ linux/fs/binfmt_em86.c Wed Jun 2 13:49:55 1999
@@ -65,16 +65,18 @@
X * user environment and arguments are stored.
X */
X remove_arg_zero(bprm);
- bprm->p = copy_strings(1, &bprm->filename, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &bprm->filename, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X if (i_arg) {
- bprm->p = copy_strings(1, &i_arg, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_arg, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X }
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
- if (!bprm->p)
- return -E2BIG;
+
X /*
X * OK, now restart the process with the interpreter's inode.
X * Note that we use open_namei() as the name is now in kernel
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_java.c linux/fs/binfmt_java.c
--- v2.3.4/linux/fs/binfmt_java.c Thu Aug 20 14:32:48 1998
+++ linux/fs/binfmt_java.c Wed Jun 2 13:49:58 1999
@@ -67,15 +67,18 @@
X i_name++;
X else
X i_name = bprm->filename;
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval < 0)
+ return retval;
X bprm->argc++;
X
X i_name = binfmt_java_interpreter;
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval < 0)
+ return retval;
X bprm->argc++;
X
- if (!bprm->p)
- return -E2BIG;
X /*
X * OK, now restart the process with the interpreter's dentry.
X */
@@ -114,15 +117,15 @@
X */
X remove_arg_zero(bprm);
X i_name = bprm->filename;
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X
X i_name = binfmt_java_appletviewer;
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X
- if (!bprm->p)
- return -E2BIG;
X /*
X * OK, now restart the process with the interpreter's dentry.
X */
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_misc.c linux/fs/binfmt_misc.c
--- v2.3.4/linux/fs/binfmt_misc.c Sat Jan 2 17:55:06 1999
+++ linux/fs/binfmt_misc.c Wed Jun 2 13:50:01 1999
@@ -210,13 +210,12 @@
X
X /* Build args for interpreter */
X remove_arg_zero(bprm);
- bprm->p = copy_strings(1, &bprm->filename, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &bprm->filename, bprm);
+ if (retval < 0) goto _ret;
X bprm->argc++;
- bprm->p = copy_strings(1, &iname_addr, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &iname_addr, bprm);
+ if (retval < 0) goto _ret;
X bprm->argc++;
- retval = -E2BIG;
- if (!bprm->p)
- goto _ret;
X bprm->filename = iname; /* for binfmt_script */
X
X dentry = open_namei(iname, 0, 0);
diff -u --recursive --new-file v2.3.4/linux/fs/binfmt_script.c linux/fs/binfmt_script.c
--- v2.3.4/linux/fs/binfmt_script.c Thu Aug 20 14:32:48 1998
+++ linux/fs/binfmt_script.c Wed Jun 2 13:50:04 1999
@@ -66,16 +66,17 @@
X * user environment and arguments are stored.
X */
X remove_arg_zero(bprm);
- bprm->p = copy_strings(1, &bprm->filename, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &bprm->filename, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X if (i_arg) {
- bprm->p = copy_strings(1, &i_arg, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_arg, bprm);
+ if (retval < 0) return retval;
X bprm->argc++;
X }
- bprm->p = copy_strings(1, &i_name, bprm->page, bprm->p, 2);
+ retval = copy_strings_kernel(1, &i_name, bprm);
+ if (retval) return retval;
X bprm->argc++;
- if (!bprm->p)
- return -E2BIG;
X /*
X * OK, now restart the process with the interpreter's dentry.
X */
diff -u --recursive --new-file v2.3.4/linux/fs/coda/cnode.c linux/fs/coda/cnode.c
--- v2.3.4/linux/fs/coda/cnode.c Fri May 14 18:55:24 1999
+++ linux/fs/coda/cnode.c Tue Jun 1 23:25:47 1999
@@ -3,6 +3,7 @@
X */
X

X #include <linux/types.h>
+#include <linux/string.h>

X #include <linux/time.h>
X
X #include <linux/coda.h>
diff -u --recursive --new-file v2.3.4/linux/fs/coda/psdev.c linux/fs/coda/psdev.c
--- v2.3.4/linux/fs/coda/psdev.c Fri May 14 18:55:24 1999
+++ linux/fs/coda/psdev.c Wed Jun 2 11:29:13 1999
@@ -2,7 +2,7 @@
X * An implementation of a loadable kernel mode driver providing


X * multiple kernel/user space bidirectional communications links.
X *
- * Author: Alan Cox <al...@cymru.net>
+ * Author: Alan Cox <al...@redhat.com>
X *
X * This program is free software; you can redistribute it and/or
X * modify it under the terms of the GNU General Public License

diff -u --recursive --new-file v2.3.4/linux/fs/devpts/inode.c linux/fs/devpts/inode.c
--- v2.3.4/linux/fs/devpts/inode.c Thu Aug 20 18:33:50 1998
+++ linux/fs/devpts/inode.c Tue Jun 1 23:25:47 1999


@@ -12,6 +12,7 @@
X

X #include <linux/module.h>
X
+#include <linux/string.h>
X #include <linux/fs.h>
X #include <linux/init.h>
X #include <linux/kdev_t.h>
diff -u --recursive --new-file v2.3.4/linux/fs/efs/namei.c linux/fs/efs/namei.c
--- v2.3.4/linux/fs/efs/namei.c Sat May 15 23:46:04 1999
+++ linux/fs/efs/namei.c Tue Jun 1 23:25:48 1999
@@ -6,6 +6,7 @@
X * Portions derived from work (c) 1995,1996 Christian Vogelgsang.
X */
X
+#include <linux/string.h>
X #include <linux/efs_fs.h>
X
X static efs_ino_t efs_find_entry(struct inode *inode, const char *name, int len) {
diff -u --recursive --new-file v2.3.4/linux/fs/efs/symlink.c linux/fs/efs/symlink.c
--- v2.3.4/linux/fs/efs/symlink.c Sat May 15 23:46:04 1999
+++ linux/fs/efs/symlink.c Tue Jun 1 23:25:48 1999
@@ -6,6 +6,7 @@
X * Portions derived from work (c) 1995,1996 Christian Vogelgsang.
X */
X
+#include <linux/string.h>
X #include <linux/malloc.h>
X #include <linux/efs_fs.h>
X
diff -u --recursive --new-file v2.3.4/linux/fs/exec.c linux/fs/exec.c
--- v2.3.4/linux/fs/exec.c Mon May 31 22:28:06 1999
+++ linux/fs/exec.c Wed Jun 2 13:50:07 1999
@@ -222,78 +222,64 @@
X }
X
X /*
- * 'copy_string()' copies argument/envelope strings from user
+ * 'copy_strings()' copies argument/envelope strings from user
X * memory to free pages in kernel mem. These are in a format ready
X * to be put directly into the top of new user memory.
- *
- * Modified by TYT, 11/24/91 to add the from_kmem argument, which specifies
- * whether the string and the string array are from user or kernel segments:
- *
- * from_kmem argv * argv **
- * 0 user space user space
- * 1 kernel space user space
- * 2 kernel space kernel space
- *
- * We do this by playing games with the fs segment register. Since it
- * is expensive to load a segment register, we try to avoid calling
- * set_fs() unless we absolutely have to.
- */
-unsigned long copy_strings(int argc,char ** argv,unsigned long *page,
- unsigned long p, int from_kmem)
-{
- char *str;
- mm_segment_t old_fs;
-
- if (!p)
- return 0; /* bullet-proofing */
- old_fs = get_fs();
- if (from_kmem==2)
- set_fs(KERNEL_DS);
+ */
+int copy_strings(int argc,char ** argv, struct linux_binprm *bprm)
+{
X while (argc-- > 0) {
+ char *str;
X int len;
X unsigned long pos;
X
- if (from_kmem == 1)
- set_fs(KERNEL_DS);
- get_user(str, argv+argc);
- if (!str)
- panic("VFS: argc is wrong");
- if (from_kmem == 1)
- set_fs(old_fs);
- len = strlen_user(str); /* includes the '\0' */
- if (p < len) { /* this shouldn't happen - 128kB */
- set_fs(old_fs);
- return 0;
- }
- p -= len;
- pos = p;
+ if (get_user(str, argv+argc) || !str || !(len = strlen_user(str)))
+ return -EFAULT;
+ if (bprm->p < len)
+ return -E2BIG;
+
+ bprm->p -= len;
+ /* XXX: add architecture specific overflow check here. */
+
+ pos = bprm->p;
X while (len) {
X char *pag;
X int offset, bytes_to_copy;
X
X offset = pos % PAGE_SIZE;
- if (!(pag = (char *) page[pos/PAGE_SIZE]) &&
- !(pag = (char *) page[pos/PAGE_SIZE] =
- (unsigned long *) get_free_page(GFP_USER))) {
- if (from_kmem==2)
- set_fs(old_fs);
- return 0;
- }
+ if (!(pag = (char *) bprm->page[pos/PAGE_SIZE]) &&
+ !(pag = (char *) bprm->page[pos/PAGE_SIZE] =
+ (unsigned long *) get_free_page(GFP_USER)))
+ return -ENOMEM;
+
X bytes_to_copy = PAGE_SIZE - offset;
X if (bytes_to_copy > len)
X bytes_to_copy = len;
- copy_from_user(pag + offset, str, bytes_to_copy);
+ if (copy_from_user(pag + offset, str, bytes_to_copy))
+ return -EFAULT;
+
X pos += bytes_to_copy;
X str += bytes_to_copy;
X len -= bytes_to_copy;
X }
X }
- if (from_kmem==2)
- set_fs(old_fs);
- return p;
+ return 0;
X }
X
-unsigned long setup_arg_pages(unsigned long p, struct linux_binprm * bprm)
+/*
+ * Like copy_strings, but get argv and its values from kernel memory.
+ */
+int copy_strings_kernel(int argc,char ** argv, struct linux_binprm *bprm)
+{
+ int r;
+ mm_segment_t oldfs = get_fs();
+ set_fs(KERNEL_DS);
+ r = copy_strings(argc, argv, bprm);
+ set_fs(oldfs);
+ return r;
+}
+
+int setup_arg_pages(struct linux_binprm *bprm)
X {
X unsigned long stack_base;
X struct vm_area_struct *mpnt;
@@ -301,15 +287,18 @@
X
X stack_base = STACK_TOP - MAX_ARG_PAGES*PAGE_SIZE;
X
- p += stack_base;
+ bprm->p += stack_base;
X if (bprm->loader)
X bprm->loader += stack_base;
X bprm->exec += stack_base;
X
X mpnt = kmem_cache_alloc(vm_area_cachep, SLAB_KERNEL);
- if (mpnt) {
+ if (!mpnt)
+ return -ENOMEM;
+
+ {
X mpnt->vm_mm = current->mm;
- mpnt->vm_start = PAGE_MASK & (unsigned long) p;
+ mpnt->vm_start = PAGE_MASK & (unsigned long) bprm->p;
X mpnt->vm_end = STACK_TOP;
X mpnt->vm_page_prot = PAGE_COPY;
X mpnt->vm_flags = VM_STACK_FLAGS;
@@ -319,7 +308,7 @@
X mpnt->vm_pte = 0;
X insert_vm_struct(current->mm, mpnt);
X current->mm->total_vm = (mpnt->vm_end - mpnt->vm_start) >> PAGE_SHIFT;
- }
+ }
X
X for (i = 0 ; i < MAX_ARG_PAGES ; i++) {
X if (bprm->page[i]) {
@@ -328,7 +317,8 @@
X }
X stack_base += PAGE_SIZE;
X }
- return p;
+
+ return 0;
X }
X
X /*
@@ -804,8 +794,7 @@
X int i;
X
X bprm.p = PAGE_SIZE*MAX_ARG_PAGES-sizeof(void *);
- for (i=0 ; i<MAX_ARG_PAGES ; i++) /* clear page-table */
- bprm.page[i] = 0;
+ memset(bprm.page, 0, MAX_ARG_PAGES*sizeof(bprm.page[0]));
X
X dentry = open_namei(filename, 0, 0);
X retval = PTR_ERR(dentry);
@@ -829,26 +818,34 @@
X }
X
X retval = prepare_binprm(&bprm);
-
- if (retval >= 0) {
- bprm.p = copy_strings(1, &bprm.filename, bprm.page, bprm.p, 2);
- bprm.exec = bprm.p;
- bprm.p = copy_strings(bprm.envc,envp,bprm.page,bprm.p,0);
- bprm.p = copy_strings(bprm.argc,argv,bprm.page,bprm.p,0);
- if (!bprm.p)
- retval = -E2BIG;
- }
+ if (retval < 0)
+ goto out;
X
- if (retval >= 0)
- retval = search_binary_handler(&bprm,regs);
+ retval = copy_strings_kernel(1, &bprm.filename, &bprm);
+ if (retval < 0)
+ goto out;
+
+ bprm.exec = bprm.p;
+ retval = copy_strings(bprm.envc, envp, &bprm);
+ if (retval < 0)
+ goto out;
+
+ retval = copy_strings(bprm.argc, argv, &bprm);
+ if (retval < 0)
+ goto out;
+
+ retval = search_binary_handler(&bprm,regs);
X if (retval >= 0)
X /* execve success */
X return retval;
X
+out:
X /* Something went wrong, return the inode and free the argument pages*/
X if (bprm.dentry)
X dput(bprm.dentry);
X
+ /* Assumes that free_page() can take a NULL argument. */
+ /* I hope this is ok for all architectures */
X for (i=0 ; i<MAX_ARG_PAGES ; i++)
X free_page(bprm.page[i]);
X
diff -u --recursive --new-file v2.3.4/linux/fs/file_table.c linux/fs/file_table.c
--- v2.3.4/linux/fs/file_table.c Tue Feb 23 15:30:59 1999
+++ linux/fs/file_table.c Tue Jun 1 23:25:48 1999
@@ -5,6 +5,7 @@
X * Copyright (C) 1997 David S. Miller (da...@caip.rutgers.edu)
X */
X
+#include <linux/string.h>
X #include <linux/slab.h>
X #include <linux/file.h>
X #include <linux/init.h>
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/buffer.c linux/fs/hpfs/buffer.c
--- v2.3.4/linux/fs/hpfs/buffer.c Sat May 15 23:46:04 1999
+++ linux/fs/hpfs/buffer.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * general buffer i/o
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X
X void hpfs_lock_creation(struct super_block *s)
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/ea.c linux/fs/hpfs/ea.c
--- v2.3.4/linux/fs/hpfs/ea.c Sat May 15 23:46:04 1999
+++ linux/fs/hpfs/ea.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * handling extended attributes
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X
X /* Remove external extended attributes. ano specifies wheter a is a
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/file.c linux/fs/hpfs/file.c
--- v2.3.4/linux/fs/hpfs/file.c Mon May 17 09:55:22 1999
+++ linux/fs/hpfs/file.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * file VFS functions
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X
X int hpfs_open(struct inode *i, struct file *f)
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/name.c linux/fs/hpfs/name.c
--- v2.3.4/linux/fs/hpfs/name.c Mon May 17 09:55:22 1999
+++ linux/fs/hpfs/name.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * operations with filenames
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X
X char *text_postfix[]={
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/namei.c linux/fs/hpfs/namei.c
--- v2.3.4/linux/fs/hpfs/namei.c Mon May 17 09:55:22 1999
+++ linux/fs/hpfs/namei.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * adding & removing files & directories
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X
X int hpfs_mkdir(struct inode *dir, struct dentry *dentry, int mode)
diff -u --recursive --new-file v2.3.4/linux/fs/hpfs/super.c linux/fs/hpfs/super.c
--- v2.3.4/linux/fs/hpfs/super.c Mon May 17 09:55:22 1999
+++ linux/fs/hpfs/super.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * mouning, unmounting, error handling
X */
X
+#include <linux/string.h>
X #include "hpfs_fn.h"
X #include <linux/module.h>
X
diff -u --recursive --new-file v2.3.4/linux/fs/isofs/symlink.c linux/fs/isofs/symlink.c
--- v2.3.4/linux/fs/isofs/symlink.c Sat Sep 19 13:42:23 1998
+++ linux/fs/isofs/symlink.c Tue Jun 1 23:25:47 1999
@@ -9,6 +9,7 @@
X * extensions to iso9660
X */
X
+#include <linux/string.h>
X #include <linux/errno.h>
X #include <linux/sched.h>
X #include <linux/fs.h>
diff -u --recursive --new-file v2.3.4/linux/fs/lockd/svcshare.c linux/fs/lockd/svcshare.c
--- v2.3.4/linux/fs/lockd/svcshare.c Mon Apr 7 11:35:30 1997
+++ linux/fs/lockd/svcshare.c Tue Jun 1 23:25:47 1999
@@ -8,6 +8,7 @@
X
X #include <linux/sched.h>


X #include <linux/unistd.h>
+#include <linux/string.h>

X #include <linux/malloc.h>
X
X #include <linux/sunrpc/clnt.h>
diff -u --recursive --new-file v2.3.4/linux/fs/lockd/svcsubs.c linux/fs/lockd/svcsubs.c
--- v2.3.4/linux/fs/lockd/svcsubs.c Fri May 14 18:55:24 1999
+++ linux/fs/lockd/svcsubs.c Tue Jun 1 23:25:47 1999
@@ -7,6 +7,7 @@


X */
X
X #include <linux/types.h>
+#include <linux/string.h>
X #include <linux/sched.h>

X #include <linux/in.h>
X #include <linux/sunrpc/svc.h>
diff -u --recursive --new-file v2.3.4/linux/fs/ncpfs/file.c linux/fs/ncpfs/file.c
--- v2.3.4/linux/fs/ncpfs/file.c Sat May 15 23:46:04 1999
+++ linux/fs/ncpfs/file.c Wed Jun 2 11:30:24 1999
@@ -21,7 +21,7 @@
X #include <linux/ncp_fs.h>
X #include "ncplib_kernel.h"
X
-static inline int min(int a, int b)
+static inline unsigned int min(unsigned int a, unsigned int b)
X {
X return a < b ? a : b;
X }
@@ -99,9 +99,10 @@


X struct inode *inode = dentry->d_inode;

X size_t already_read = 0;
X off_t pos;
- int bufsize, error;
+ size_t bufsize;
+ int error;
X void* freepage;
- int freelen;
+ size_t freelen;
X
X DPRINTK(KERN_DEBUG "ncp_file_read: enter %s/%s\n",
X dentry->d_parent->d_name.name, dentry->d_name.name);
@@ -121,10 +122,12 @@
X goto out;
X }
X
- pos = file->f_pos;
+ pos = *ppos;
+/* leave it out on server ...
X if (pos + count > inode->i_size) {
X count = inode->i_size - pos;
X }
+*/
X error = 0;
X if (!count) /* size_t is never < 0 */
X goto out;
@@ -146,7 +149,7 @@
X /* First read in as much as possible for each bufsize. */
X while (already_read < count) {
X int read_this_time;
- int to_read = min(bufsize - (pos % bufsize),
+ size_t to_read = min(bufsize - (pos % bufsize),
X count - already_read);
X
X error = ncp_read_bounce(NCP_SERVER(inode),
@@ -162,13 +165,13 @@
X buf += read_this_time;
X already_read += read_this_time;
X
- if (read_this_time < to_read) {
+ if (read_this_time != to_read) {
X break;
X }
X }
X kfree(freepage);
X
- file->f_pos = pos;
+ *ppos = pos;
X
X if (!IS_RDONLY(inode)) {
X inode->i_atime = CURRENT_TIME;
@@ -187,7 +190,8 @@


X struct inode *inode = dentry->d_inode;

X size_t already_written = 0;
X off_t pos;
- int bufsize, errno;
+ size_t bufsize;
+ int errno;
X void* bouncebuffer;
X
X DPRINTK(KERN_DEBUG "ncp_file_write: enter %s/%s\n",
@@ -213,7 +217,7 @@
X printk(KERN_ERR "ncp_file_write: open failed, error=%d\n", errno);
X return errno;
X }
- pos = file->f_pos;
+ pos = *ppos;
X
X if (file->f_flags & O_APPEND) {
X pos = inode->i_size;
@@ -227,7 +231,7 @@
X return -EIO; /* -ENOMEM */
X while (already_written < count) {
X int written_this_time;
- int to_write = min(bufsize - (pos % bufsize),
+ size_t to_write = min(bufsize - (pos % bufsize),
X count - already_written);
X
X if (copy_from_user(bouncebuffer, buf, to_write)) {
@@ -244,14 +248,14 @@
X buf += written_this_time;
X already_written += written_this_time;
X
- if (written_this_time < to_write) {
+ if (written_this_time != to_write) {
X break;
X }
X }
X kfree(bouncebuffer);
X inode->i_mtime = inode->i_atime = CURRENT_TIME;
X
- file->f_pos = pos;
+ *ppos = pos;
X
X if (pos > inode->i_size) {
X inode->i_size = pos;
diff -u --recursive --new-file v2.3.4/linux/fs/nfs/file.c linux/fs/nfs/file.c
--- v2.3.4/linux/fs/nfs/file.c Sat May 8 20:01:19 1999
+++ linux/fs/nfs/file.c Wed Jun 2 13:46:59 1999
@@ -27,6 +27,7 @@
X #include <linux/pagemap.h>
X #include <linux/lockd/bind.h>
X
+#include <asm/uaccess.h>
X #include <asm/segment.h>
X #include <asm/system.h>
X
@@ -75,7 +76,7 @@
X NULL, /* truncate */
X NULL, /* permission */
X NULL, /* smap */
- nfs_updatepage, /* updatepage */
+ NULL, /* updatepage */
X nfs_revalidate, /* revalidate */
X };
X
@@ -156,6 +157,25 @@
X return status;
X }
X
+/*
+ * This does the "real" work of the write. The generic routine has
+ * allocated the page, locked it, done all the page alignment stuff
+ * calculations etc. Now we should just copy the data from user
+ * space and write it back to the real medium..
+ *
+ * If the writer ends up delaying the write, the writer needs to
+ * increment the page use counts until he is done with the page.
+ */
+static long nfs_write_one_page(struct file *file, struct page *page, unsigned long offset, unsigned long bytes, const char * buf)
+{
+ long status;
+
+ bytes -= copy_from_user((u8*)page_address(page) + offset, buf, bytes);
+ status = -EFAULT;
+ if (bytes)
+ status = nfs_updatepage(file, page, offset, bytes);
+ return status;
+}
X
X /*
X * Write to a file (through the page cache).
@@ -182,7 +202,7 @@
X if (!count)
X goto out;
X
- result = generic_file_write(file, buf, count, ppos);
+ result = generic_file_write(file, buf, count, ppos, nfs_write_one_page);
X out:
X return result;
X
diff -u --recursive --new-file v2.3.4/linux/fs/nfs/write.c linux/fs/nfs/write.c
--- v2.3.4/linux/fs/nfs/write.c Fri May 14 18:55:26 1999
+++ linux/fs/nfs/write.c Tue Jun 1 10:41:07 1999
@@ -408,17 +408,17 @@
X * things with a page scheduled for an RPC call (e.g. invalidate it).
X */
X int
-nfs_updatepage(struct file *file, struct page *page, unsigned long offset, unsigned int count, int sync)
+nfs_updatepage(struct file *file, struct page *page, unsigned long offset, unsigned int count)


X {
X struct dentry *dentry = file->f_dentry;
X struct inode *inode = dentry->d_inode;

X struct nfs_wreq *req;
- int synchronous = sync;
+ int synchronous = file->f_flags & O_SYNC;
X int retval;
X
- dprintk("NFS: nfs_updatepage(%s/%s %d@%ld, sync=%d)\n",
+ dprintk("NFS: nfs_updatepage(%s/%s %d@%ld)\n",
X dentry->d_parent->d_name.name, dentry->d_name.name,
- count, page->offset+offset, sync);
+ count, page->offset+offset);
X
X /*
X * Try to find a corresponding request on the writeback queue.
@@ -454,7 +454,7 @@
X file->f_count++;
X
X /* Schedule request */
- synchronous = schedule_write_request(req, sync);
+ synchronous = schedule_write_request(req, synchronous);
X
X updated:
X if (req->wb_bytes == PAGE_SIZE)
diff -u --recursive --new-file v2.3.4/linux/fs/ntfs/util.c linux/fs/ntfs/util.c
--- v2.3.4/linux/fs/ntfs/util.c Sat Jan 2 10:24:46 1999
+++ linux/fs/ntfs/util.c Tue Jun 1 23:25:47 1999
@@ -12,6 +12,7 @@
X #include "struct.h"
X #include "util.h"
X
+#include <linux/string.h>
X #include <linux/errno.h>
X /* FreeBSD doesn't seem to have EILSEQ in errno.h */
X #ifndef EILSEQ
diff -u --recursive --new-file v2.3.4/linux/fs/qnx4/inode.c linux/fs/qnx4/inode.c
--- v2.3.4/linux/fs/qnx4/inode.c Fri May 14 18:55:26 1999
+++ linux/fs/qnx4/inode.c Tue Jun 1 23:25:47 1999
@@ -15,6 +15,7 @@


X #include <linux/config.h>
X #include <linux/module.h>
X #include <linux/types.h>
+#include <linux/string.h>

X #include <linux/errno.h>
X #include <linux/malloc.h>
X #include <linux/qnx4_fs.h>
diff -u --recursive --new-file v2.3.4/linux/fs/qnx4/symlinks.c linux/fs/qnx4/symlinks.c
--- v2.3.4/linux/fs/qnx4/symlinks.c Mon Jan 4 11:42:43 1999
+++ linux/fs/qnx4/symlinks.c Tue Jun 1 23:25:47 1999
@@ -13,6 +13,7 @@
X
X /* THIS FILE HAS TO BE REWRITTEN */
X
+#include <linux/string.h>
X #include <linux/errno.h>
X #include <linux/sched.h>
X #include <linux/fs.h>
diff -u --recursive --new-file v2.3.4/linux/fs/smbfs/file.c linux/fs/smbfs/file.c
--- v2.3.4/linux/fs/smbfs/file.c Wed Feb 17 15:59:32 1999
+++ linux/fs/smbfs/file.c Wed Jun 2 13:46:59 1999
@@ -188,13 +188,13 @@
X }
X
X static int
-smb_updatepage(struct file *file, struct page *page, unsigned long offset, unsigned int count, int sync)
+smb_updatepage(struct file *file, struct page *page, unsigned long offset, unsigned int count)


X {
X struct dentry *dentry = file->f_dentry;
X

- pr_debug("SMBFS: smb_updatepage(%s/%s %d@%ld, sync=%d)\n",
+ pr_debug("SMBFS: smb_updatepage(%s/%s %d@%ld)\n",
X dentry->d_parent->d_name.name, dentry->d_name.name,
- count, page->offset+offset, sync);
+ count, page->offset+offset);
X
X return smb_writepage_sync(dentry, page, offset, count);
X }
@@ -256,6 +256,26 @@
X return status;
X }
X
+/*
+ * This does the "real" work of the write. The generic routine has
+ * allocated the page, locked it, done all the page alignment stuff
+ * calculations etc. Now we should just copy the data from user
+ * space and write it back to the real medium..
+ *
+ * If the writer ends up delaying the write, the writer needs to
+ * increment the page use counts until he is done with the page.
+ */
+static long smb_write_one_page(struct file *file, struct page *page, unsigned long offset, unsigned long bytes, const char * buf)
+{
+ long status;
+
+ bytes -= copy_from_user((u8*)page_address(page) + offset, buf, bytes);
+ status = -EFAULT;
+ if (bytes)
+ status = smb_updatepage(file, page, offset, bytes);
+ return status;
+}
+
X /*
X * Write to a file (through the page cache).
X */
@@ -287,7 +307,7 @@
X
X if (count > 0)
X {
- result = generic_file_write(file, buf, count, ppos);
+ result = generic_file_write(file, buf, count, ppos, smb_write_one_page);
X #ifdef SMBFS_DEBUG_VERBOSE
X printk("smb_file_write: pos=%ld, size=%ld, mtime=%ld, atime=%ld\n",
X (long) file->f_pos, dentry->d_inode->i_size, dentry->d_inode->i_mtime,
@@ -386,6 +406,6 @@
X NULL, /* truncate */
X smb_file_permission, /* permission */
X NULL, /* smap */
- smb_updatepage, /* updatepage */
+ NULL, /* updatepage */
X smb_revalidate_inode, /* revalidate */
X };
diff -u --recursive --new-file v2.3.4/linux/fs/ufs/util.c linux/fs/ufs/util.c
--- v2.3.4/linux/fs/ufs/util.c Fri Oct 16 11:53:20 1998
+++ linux/fs/ufs/util.c Tue Jun 1 23:25:47 1999
@@ -6,6 +6,7 @@
X * Charles University, Faculty of Mathematics and Physics
X */
X
+#include <linux/string.h>
X #include <linux/malloc.h>
X #include <linux/locks.h>
X
diff -u --recursive --new-file v2.3.4/linux/include/asm-i386/locks.h linux/include/asm-i386/locks.h
--- v2.3.4/linux/include/asm-i386/locks.h Mon Jan 11 10:11:58 1999
+++ linux/include/asm-i386/locks.h Wed Jun 2 11:29:13 1999
@@ -2,7 +2,7 @@
X * SMP locks primitives for building ix86 locks
X * (not yet used).
X *
- * Alan Cox, al...@cymru.net, 1995
+ * Alan Cox, al...@redhat.com, 1995
X */
X
X /*
diff -u --recursive --new-file v2.3.4/linux/include/asm-i386/softirq.h linux/include/asm-i386/softirq.h
--- v2.3.4/linux/include/asm-i386/softirq.h Mon May 31 22:28:06 1999
+++ linux/include/asm-i386/softirq.h Wed Jun 2 13:54:53 1999
@@ -6,6 +6,15 @@
X
X extern unsigned int local_bh_count[NR_CPUS];
X
+#define cpu_bh_disable(cpu) do { local_bh_count[(cpu)]++; barrier(); } while (0)
+#define cpu_bh_enable(cpu) do { barrier(); local_bh_count[(cpu)]--; } while (0)
+
+#define cpu_bh_trylock(cpu) (local_bh_count[(cpu)] ? 0 : (local_bh_count[(cpu)] = 1))
+#define cpu_bh_endlock(cpu) (local_bh_count[(cpu)] = 0)
+
+#define local_bh_disable() cpu_bh_disable(smp_processor_id())
+#define local_bh_enable() cpu_bh_enable(smp_processor_id())
+
X #define get_active_bhs() (bh_mask & bh_active)
X #define clear_active_bhs(x) atomic_clear_mask((x),&bh_active)
X
@@ -40,13 +49,6 @@
X
X extern void synchronize_bh(void);
X
-/*
- * This is suboptimal. We only need to disable bh's locally
- * on this CPU...
- */
-#define local_bh_disable() atomic_inc(&global_bh_lock)
-#define local_bh_enable() atomic_dec(&global_bh_lock)
-
X static inline void start_bh_atomic(void)
X {
X atomic_inc(&global_bh_lock);
@@ -61,19 +63,20 @@
X /* These are for the IRQs testing the lock */
X static inline int softirq_trylock(int cpu)
X {
- if (!test_and_set_bit(0,&global_bh_count)) {
- if (atomic_read(&global_bh_lock) == 0) {
- ++local_bh_count[cpu];
- return 1;
+ if (cpu_bh_trylock(cpu)) {
+ if (!test_and_set_bit(0,&global_bh_count)) {
+ if (atomic_read(&global_bh_lock) == 0)
+ return 1;
+ clear_bit(0,&global_bh_count);
X }
- clear_bit(0,&global_bh_count);
+ cpu_bh_endlock(cpu);
X }


X return 0;
X }
X

X static inline void softirq_endlock(int cpu)
X {
- local_bh_count[cpu]--;
+ cpu_bh_enable(cpu);
X clear_bit(0,&global_bh_count);
X }
X
@@ -81,22 +84,19 @@
X
X extern inline void start_bh_atomic(void)
X {
- local_bh_count[smp_processor_id()]++;
+ local_bh_disable();
X barrier();
X }
X
X extern inline void end_bh_atomic(void)
X {
X barrier();
- local_bh_count[smp_processor_id()]--;
+ local_bh_enable();
X }
X
-#define local_bh_disable() (local_bh_count[smp_processor_id()]++)
-#define local_bh_enable() (local_bh_count[smp_processor_id()]--)
-
X /* These are for the irq's testing the lock */
-#define softirq_trylock(cpu) (local_bh_count[cpu] ? 0 : (local_bh_count[cpu]=1))
-#define softirq_endlock(cpu) (local_bh_count[cpu] = 0)
+#define softirq_trylock(cpu) (cpu_bh_trylock(cpu))
+#define softirq_endlock(cpu) (cpu_bh_endlock(cpu))
X #define synchronize_bh() barrier()
X
X #endif /* SMP */
diff -u --recursive --new-file v2.3.4/linux/include/linux/binfmts.h linux/include/linux/binfmts.h
--- v2.3.4/linux/include/linux/binfmts.h Tue May 11 13:04:00 1999
+++ linux/include/linux/binfmts.h Wed Jun 2 13:54:56 1999
@@ -19,7 +19,7 @@
X struct linux_binprm{
X char buf[128];
X unsigned long page[MAX_ARG_PAGES];
- unsigned long p;
+ unsigned long p; /* current top of mem */
X int sh_bang;
X int java; /* Java binary, prevent recursive invocation */
X struct dentry * dentry;
@@ -63,14 +63,16 @@
X extern void remove_arg_zero(struct linux_binprm *);
X extern int search_binary_handler(struct linux_binprm *,struct pt_regs *);
X extern int flush_old_exec(struct linux_binprm * bprm);
-extern unsigned long setup_arg_pages(unsigned long p, struct linux_binprm * bprm);
-extern unsigned long copy_strings(int argc,char ** argv,unsigned long *page,
- unsigned long p, int from_kmem);
-
+extern int setup_arg_pages(struct linux_binprm * bprm);
+extern int copy_strings(int argc,char ** argv,struct linux_binprm *bprm);
+extern int copy_strings_kernel(int argc,char ** argv,struct linux_binprm *bprm);
X extern void compute_creds(struct linux_binprm *binprm);
X
-/* this eventually goes away */
+
+#if 0
+/* this went away now */
X #define change_ldt(a,b) setup_arg_pages(a,b)
+#endif
X
X #endif /* __KERNEL__ */
X #endif /* _LINUX_BINFMTS_H */
diff -u --recursive --new-file v2.3.4/linux/include/linux/fs.h linux/include/linux/fs.h
--- v2.3.4/linux/include/linux/fs.h Mon May 17 09:55:23 1999
+++ linux/include/linux/fs.h Wed Jun 2 13:54:54 1999
@@ -625,7 +625,7 @@
X void (*truncate) (struct inode *);
X int (*permission) (struct inode *, int);
X int (*smap) (struct inode *,int);
- int (*updatepage) (struct file *, struct page *, unsigned long, unsigned int, int);
+ int (*updatepage) (struct file *, struct page *, unsigned long, unsigned int);
X int (*revalidate) (struct dentry *);
X };
X
@@ -874,10 +874,12 @@
X
X extern int brw_page(int, struct page *, kdev_t, int [], int, int);
X
+typedef long (*writepage_t)(struct file *, struct page *, unsigned long, unsigned long, const char *);
+
X extern int generic_readpage(struct file *, struct page *);
X extern int generic_file_mmap(struct file *, struct vm_area_struct *);
X extern ssize_t generic_file_read(struct file *, char *, size_t, loff_t *);
-extern ssize_t generic_file_write(struct file *, const char*, size_t, loff_t*);
+extern ssize_t generic_file_write(struct file *, const char*, size_t, loff_t *, writepage_t);
X
X extern struct super_block *get_super(kdev_t dev);
X extern void put_super(kdev_t dev);
diff -u --recursive --new-file v2.3.4/linux/include/linux/if_ether.h linux/include/linux/if_ether.h
--- v2.3.4/linux/include/linux/if_ether.h Wed Dec 16 13:35:50 1998
+++ linux/include/linux/if_ether.h Wed Jun 2 11:29:13 1999
@@ -9,7 +9,7 @@
X *
X * Author: Fred N. van Kempen, <wal...@uWalt.NL.Mugnet.ORG>
X * Donald Becker, <bec...@super.org>


- * Alan Cox, <al...@cymru.net>
+ * Alan Cox, <al...@redhat.com>

X * Steve Whitehouse, <gw7...@eeshack3.swan.ac.uk>


X *
X * This program is free software; you can redistribute it and/or

diff -u --recursive --new-file v2.3.4/linux/include/linux/if_fddi.h linux/include/linux/if_fddi.h
--- v2.3.4/linux/include/linux/if_fddi.h Fri May 8 00:08:02 1998
+++ linux/include/linux/if_fddi.h Wed Jun 2 11:29:13 1999
@@ -12,7 +12,7 @@
X * if_fddi.h is based on previous if_ether.h and if_tr.h work by
X * Fred N. van Kempen, <wal...@uWalt.NL.Mugnet.ORG>
X * Donald Becker, <bec...@super.org>


- * Alan Cox, <al...@cymru.net>
+ * Alan Cox, <al...@redhat.com>

X * Steve Whitehouse, <gw7...@eeshack3.swan.ac.uk>
X * Peter De Schrijver, <stu...@cc4.kuleuven.ac.be>
X *
diff -u --recursive --new-file v2.3.4/linux/include/linux/if_hippi.h linux/include/linux/if_hippi.h
--- v2.3.4/linux/include/linux/if_hippi.h Tue May 11 13:03:59 1999
+++ linux/include/linux/if_hippi.h Wed Jun 2 13:54:53 1999
@@ -9,7 +9,7 @@
X *
X * Author: Fred N. van Kempen, <wal...@uWalt.NL.Mugnet.ORG>
X * Donald Becker, <bec...@super.org>


- * Alan Cox, <al...@cymru.net>
+ * Alan Cox, <al...@redhat.com>

X * Steve Whitehouse, <gw7...@eeshack3.swan.ac.uk>
X * Jes Sorensen, <Jes.So...@cern.ch>
X *
diff -u --recursive --new-file v2.3.4/linux/include/linux/nfs_fs.h linux/include/linux/nfs_fs.h
--- v2.3.4/linux/include/linux/nfs_fs.h Fri May 14 18:55:29 1999
+++ linux/include/linux/nfs_fs.h Wed Jun 2 13:54:59 1999
@@ -228,7 +228,7 @@
X * back first..
X */
X extern void nfs_inval(struct inode *);
-extern int nfs_updatepage(struct file *, struct page *, unsigned long, unsigned int, int);
+extern int nfs_updatepage(struct file *, struct page *, unsigned long, unsigned int);
X
X /*
X * linux/fs/nfs/read.c
diff -u --recursive --new-file v2.3.4/linux/include/linux/smp.h linux/include/linux/smp.h
--- v2.3.4/linux/include/linux/smp.h Tue May 11 13:03:59 1999
+++ linux/include/linux/smp.h Wed Jun 2 13:54:53 1999
@@ -3,7 +3,7 @@
X
X /*
X * Generic SMP support
- * Alan Cox. <al...@cymru.net>
+ * Alan Cox. <al...@redhat.com>
X */
X
X #ifdef __SMP__
diff -u --recursive --new-file v2.3.4/linux/init/main.c linux/init/main.c
--- v2.3.4/linux/init/main.c Sat May 15 23:46:05 1999
+++ linux/init/main.c Tue Jun 1 23:25:48 1999
@@ -14,6 +14,7 @@
X #include <linux/config.h>
X #include <linux/proc_fs.h>


X #include <linux/unistd.h>
+#include <linux/string.h>

X #include <linux/ctype.h>
X #include <linux/delay.h>
X #include <linux/utsname.h>
diff -u --recursive --new-file v2.3.4/linux/mm/filemap.c linux/mm/filemap.c
--- v2.3.4/linux/mm/filemap.c Mon May 31 22:28:07 1999
+++ linux/mm/filemap.c Wed Jun 2 13:47:49 1999
@@ -1425,7 +1425,8 @@
X */
X ssize_t
X generic_file_write(struct file *file, const char *buf,
- size_t count, loff_t *ppos)


SHAR_EOF
true || echo 'restore of patch-2.3.5 failed'

fi
echo 'End of part 1'
echo 'File patch-2.3.5 is continued in part 2'
echo 2 > _shar_seq_.tmp
exit 0

Reply all
Reply to author
Forward
0 new messages