From 26265657c9b3c984efc32b15ca38261c93d4aa24 Mon Sep 17 00:00:00 2001 From: Linus Torvalds Date: Fri, 23 Nov 2007 15:10:43 -0500 Subject: [PATCH] Import 1.3.79 --- Documentation/Configure.help | 211 +++++++++++++++++++++----------- Documentation/svga.txt | 4 +- Makefile | 2 +- arch/i386/boot/video.S | 4 +- arch/i386/kernel/setup.c | 16 +++ drivers/block/floppy.c | 2 +- drivers/block/ide.c | 2 - drivers/block/ll_rw_blk.c | 24 +++- drivers/cdrom/cdu31a.c | 2 +- drivers/cdrom/sonycd535.c | 2 +- drivers/char/README.stallion | 62 ++++------ drivers/char/istallion.c | 91 +++++++------- drivers/char/stallion.c | 2 +- drivers/net/ibmtr.c | 2 +- drivers/scsi/scsi.h | 2 +- fs/buffer.c | 2 +- fs/ncpfs/dir.c | 2 +- fs/nfs/nfsroot.c | 2 +- include/asm-alpha/posix_types.h | 46 +++---- include/asm-alpha/statfs.h | 4 +- include/asm-i386/posix_types.h | 34 ++--- include/linux/blk.h | 4 +- include/linux/blkdev.h | 3 +- include/linux/posix_types.h | 11 +- include/linux/types.h | 74 +++++------ kernel/ksyms.c | 5 - net/ipv4/rarp.c | 2 +- net/netsyms.c | 5 + scripts/Menuconfig | 191 +++++++++++++---------------- scripts/README.Menuconfig | 40 ++++-- scripts/header.tk | 3 +- scripts/lxdialog/menubox.c | 29 +++-- scripts/lxdialog/util.c | 11 +- scripts/patch-kernel | 4 +- 34 files changed, 490 insertions(+), 410 deletions(-) diff --git a/Documentation/Configure.help b/Documentation/Configure.help index 8bbde9342fea..7fe8e1c92c8c 100644 --- a/Documentation/Configure.help +++ b/Documentation/Configure.help @@ -30,8 +30,6 @@ # thanks to all the contributors. Feel free to use these help texts # in your own kernel configuration tools. The texts are copyrighted # (c) 1995,1996 by Axel Boldt and governed by the GNU Public License. -# -# Send comments to Axel Boldt . Kernel math emulation CONFIG_MATH_EMULATION @@ -168,7 +166,7 @@ CONFIG_BLK_DEV_IDETAPE or something similar. Be sure to consult the drivers/block/ide-tape.c and README.ide files for usage information. -Support removeable IDE interfaces (PCMCIA) +Support removable IDE interfaces (PCMCIA) CONFIG_BLK_DEV_IDE_PCMCIA This option adds code to the IDE driver to handle hot insertion and removal of IDE interfaces and drives, under direction of an @@ -593,7 +591,8 @@ CONFIG_M386 it can make sense to specify "Pentium" even if running a 486: the kernel will be smaller but slower. On the other hand, if you use a compiler before gcc 2.7 (say "gcc -v" to find out), then you have to - say "486" here even if running on a Pentium machine. + say "386" or "486" here even if running on a Pentium or PPro + machine. If you don't know what to do, say "386". Compile the kernel into the ELF object format CONFIG_ELF_KERNEL @@ -857,18 +856,17 @@ CONFIG_INET_PCTCP Reverse ARP CONFIG_INET_RARP - Since you asked: if there are diskless machines on your local network - that know their hardware ethernet address but don't know their IP - addresses upon startup, they send out a Reverse - Address Resolution Protocol request to find out their own IP - addresses. If you want your Linux box to be able to *answer* such - requests, say Y here; you'd use the program rarp ("man rarp"). - Superior solutions to the same problem are given by the - protocols BOOTP and DHCP. If you want to compile RARP support - as a module ( = code which can be inserted - in and removed from the running kernel whenever you want), say M - here and read Documentation/modules.txt. If you don't understand a - word, say N and rest in peace. + Since you asked: if there's a diskless machine on your local network + that know its hardware ethernet address but doesn't know its IP + address upon startup, it can send out a Reverse Address Resolution + Protocol request to find out its own IP address. If you want your + Linux box to be able to *answer* such requests, say Y here; you'd + have to run the program rarp ("man rarp") on your box. Superior + solutions to the same problem are given by the protocols BOOTP and + DHCP. If you want to compile RARP support as a module ( = code which + can be inserted in and removed from the running kernel whenever you + want), say M here and read Documentation/modules.txt. If you don't + understand a word, say N and rest in peace. Assume subnets are local CONFIG_INET_SNARL @@ -938,8 +936,11 @@ CONFIG_IPX sunsite.unc.edu:/pub/Linux/system/Network/daemons/ or mars_nwe from linux01.gwdg.de:/pub/ncpfs. For more information, read the IPX-HOWTO in sunsite.unc.edu:/pub/Linux/docs/howto. The IPX driver would - enlarge your kernel by about 5 kB. Unless you want to integrate your - Linux box with a local Novell network, say N. + enlarge your kernel by about 5 kB. This driver is also available as + a module ( = code which can be inserted in and removed from the + running kernel whenever you want). If you want to compile it as a + module, say M here and read Documentation/modules.txt. Unless you + want to integrate your Linux box with a local Novell network, say N. Full internal IPX network CONFIG_IPX_INTERN @@ -968,8 +969,11 @@ CONFIG_ATALK http://www.cs.dartmouth.edu/~flowerpt/projects/linux-netatalk/ on the WWW for details (to browse the WWW, you need to have access to a machine on the Internet that has one of the programs lynx, netscape - or Mosaic). I hear that the GNU boycott of Apple is over, so even - politically correct people are allowed to say Y here. + or Mosaic). This driver is also available as a module ( = code which + can be inserted in and removed from the running kernel whenever you + want). If you want to compile it as a module, say M here and read + Documentation/modules.txt. I hear that the GNU boycott of Apple is + over, so even politically correct people are allowed to say Y here. Amateur Radio AX.25 Level 2 CONFIG_AX25 @@ -1044,20 +1048,23 @@ CONFIG_RTNETLINK SCSI support? CONFIG_SCSI - If you want to use an SCSI harddisk, SCSI tapedrive, SCSI CDROM or + If you want to use a SCSI harddisk, SCSI tapedrive, SCSI CDROM or any other SCSI device under Linux, say Y and make sure that you know the name of your SCSI host adaptor (the card inside your computer that "speaks" the SCSI protocol), because you will be asked for - it. And read the SCSI-HOWTO, available via ftp (user: anonymous) in - sunsite.unc.edu:/pub/Linux/docs/HOWTO. This driver is also available - as a module ( = code which can be inserted in and removed from the - running kernel whenever you want). If you want to compile it as a - module, say M here and read Documentation/modules.txt and - Documentation/scsi.txt. + it. You also need to say Y here if you want support for the parallel + port version of the 100MB IOMEGA ZIP drive. Please read the + SCSI-HOWTO, available via ftp (user: anonymous) in + sunsite.unc.edu:/pub/Linux/docs/HOWTO. This driver is also + available as a module ( = code which can be inserted in and removed + from the running kernel whenever you want). If you want to compile + it as a module, say M here and read Documentation/modules.txt and + Documentation/scsi.txt. SCSI disk support CONFIG_BLK_DEV_SD - If you want to use an SCSI harddisk under Linux, say Y and read the + If you want to use a SCSI harddisk or the SCSI or parallel port + version of the IOMEGA ZIP drive under Linux, say Y and read the SCSI-HOWTO, available via ftp (user: anonymous) in sunsite.unc.edu:/pub/Linux/docs/HOWTO. This is NOT for SCSI CDROMs. This driver is also available as a module ( = code which can @@ -1067,7 +1074,7 @@ CONFIG_BLK_DEV_SD SCSI tape support CONFIG_CHR_DEV_ST - If you want to use an SCSI tapedrive under Linux, say Y and read the + If you want to use a SCSI tapedrive under Linux, say Y and read the SCSI-HOWTO, available via ftp (user: anonymous) in sunsite.unc.edu:/pub/Linux/docs/HOWTO and drivers/scsi/README.st in the kernel source. This is NOT for SCSI CDROMs. This driver is also @@ -1078,7 +1085,7 @@ CONFIG_CHR_DEV_ST SCSI CDROM support CONFIG_BLK_DEV_SR - If you want to use an SCSI CDROM under Linux, say Y and read the + If you want to use a SCSI CDROM under Linux, say Y and read the SCSI-HOWTO and the CDROM-HOWTO from sunsite.unc.edu:/pub/Linux/docs/HOWTO. Also make sure to enable the ISO9660 filesystem later. This driver is also available as a module @@ -1103,7 +1110,7 @@ CONFIG_CHR_DEV_SG Probe all LUNs on each SCSI device CONFIG_SCSI_MULTI_LUN - If you have an SCSI device that supports more than one LUN (Logical + If you have a SCSI device that supports more than one LUN (Logical Unit Number), e.g. a CD jukebox, you should say Y here so that all will be found by the SCSI driver. An SCSI device with multiple LUNs acts logically like multiple SCSI devices. The vast majority of SCSI @@ -1133,7 +1140,7 @@ CONFIG_SCSI_ADVANSYS Adaptec AHA152X support CONFIG_SCSI_AHA152X - This is support for an SCSI host adaptor. It is explained in section + This is support for a SCSI host adaptor. It is explained in section 3.3 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in drivers/scsi/aha152x.h. @@ -1144,7 +1151,7 @@ CONFIG_SCSI_AHA152X Adaptec AHA1542 support CONFIG_SCSI_AHA1542 - This is support for an SCSI host adaptor. It is explained in section + This is support for a SCSI host adaptor. It is explained in section 3.4 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. Note that Trantor was recently purchased by Adaptec, and some former Trantor products are @@ -1156,7 +1163,7 @@ CONFIG_SCSI_AHA1542 Adaptec AHA1740 support CONFIG_SCSI_AHA1740 - This is support for an SCSI host adaptor. It is explained in section + This is support for a SCSI host adaptor. It is explained in section 3.5 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in @@ -1188,7 +1195,7 @@ CONFIG_SCSI_BUSLOGIC EATA-DMA (DPT,NEC&ATT for ISA,EISA,PCI) support CONFIG_SCSI_EATA_DMA - This is support for an SCSI host adaptor. Please read the + This is support for a SCSI host adaptor. Please read the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in @@ -1278,7 +1285,7 @@ CONFIG_SCSI_NCR53C7xx Always IN2000 SCSI support (test release) CONFIG_SCSI_IN2000 - Believe it or not, there is an SCSI host adaptor of that name. It is + Believe it or not, there is a SCSI host adaptor of that name. It is explained in section 3.6 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in @@ -1288,7 +1295,7 @@ CONFIG_SCSI_IN2000 PAS16 SCSI support CONFIG_SCSI_PAS16 - This is support for an SCSI host adaptor. It is explained in section + This is support for a SCSI host adaptor. It is explained in section 3.10 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in drivers/scsi/pas16.h. @@ -1317,7 +1324,7 @@ CONFIG_SCSI_SEAGATE Trantor T128/T128F/T228 SCSI support CONFIG_SCSI_T128 - This is support for an SCSI host adaptor. It is explained in section + This is support for a SCSI host adaptor. It is explained in section 3.11 of the SCSI-HOWTO, available via ftp (user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO. If it doesn't work out of the box, you may have to change some settings in @@ -1380,14 +1387,17 @@ CONFIG_SCSI_AM53C974 IOMEGA Parallel Port ZIP drive SCSI support CONFIG_SCSI_PPA This driver supports the parallel port version of IOMEGA's ZIP - drive (a 100Mb removable media device). For more infomation + drive (a 100Mb removable media device). For more information about this driver and how to use it you should read the file drivers/scsi/README.ppa. You should also read the SCSI-HOWTO, which is available via anonymous ftp from sunsite.unc.edu in the directory /pub/Linux/docs/HOWTO. This driver is also available as a module which can be inserted in and removed from the running kernel whenever you want. If you want to compile it as a - module, say M here and read Documentation/modules.txt. + module, say M here and read Documentation/modules.txt. Note that + you can say N here if you have the SCSI version of the ZIP drive: + it will be supported automatically if you enabled the generic + "SCSI disk support", above. Network device support? CONFIG_NETDEVICES @@ -1563,6 +1573,47 @@ CONFIG_EQUALIZER from the running kernel whenever you want). If you want to compile it as a module, say M here and read Documentation/modules.txt. +FRAD (Frame Relay Access Device) support +CONFIG_FRAD + This is support for the frame relay protocol; frame relay is a fast + low-cost way to connect to a remote internet access provider or to + form a private wide area network. The one physical line to your + local entry point or "switch" carries several logical + point-to-point connections to other sites connected to the frame + relay network. For a general explanation of the protocol, check out + http://frame-relay.indiana.edu/4000/4000index.html on the WWW. (To + browse the WWW, you need to have access to a machine on the Internet + that has one of the programs lynx, netscape or Mosaic.) To use frame + relay, you need supporting hardware (FRAD) and certain programs from + the net-tools package as explained in + Documentation/framerelay.txt. This driver is also available as a + module ( = code which can be inserted in and removed from the + running kernel whenever you want). If you want to compile it as a + module, say M here and read Documentation/modules.txt. + +Max open DLCI +CONFIG_DLCI_COUNT + This is the maximal number of logical point-to-point frame relay + connections (the identifiers of which are called DCLIs) that + the driver can handle. The default is probably fine. + +Max DLCI per device +CONFIG_DLCI_MAX + You can specify here how many logical point-to-point frame relay + connections (the identifiers of which are called DCLIs) should be + handled by each of your hardware frame relay access devices. Go with + the default. + +Sangoma S502A FRAD support +CONFIG_SDLA + Say Y here if you need a driver for the Sangoma S502A, S502E and + S508 Frame Relay Access Devices. These are multi-protocol + cards, but only frame relay is supported by the driver at this + time. Please read Documentation/framerelay.txt. This driver is also + available as a module ( = code which can be inserted in and removed + from the running kernel whenever you want). If you want to compile + it as a module, say M here and read Documentation/modules.txt. + Sun LANCE Ethernet support CONFIG_SUN_LANCE This is support for lance ethernet cards on Sun workstations such as @@ -1867,6 +1918,19 @@ CONFIG_AT1700 Multiple-Ethernet-mini-HOWTO, available from sunsite.unc.edu:/pub/Linux/docs/HOWTO/mini. +FMV-181/182 support +CONFIG_FMV18X + If you have a Fujitsu FMV-181/182 network (ethernet) card, say Y and + read the Ethernet-HOWTO, available via ftp (user: anonymous) in + sunsite.unc.edu:/pub/Linux/docs/HOWTO. This driver is also available + as a module ( = code which can be inserted in and removed from the + running kernel whenever you want). If you want to compile it as a + module, say M here and read Documentation/modules.txt as well as + Documentation/networking/net-modules.txt. If you plan to use more + than one network card under linux, read the + Multiple-Ethernet-mini-HOWTO, available from + sunsite.unc.edu:/pub/Linux/docs/HOWTO/mini. + EtherExpressPro support CONFIG_EEXPRESS_PRO If you have a network (ethernet) card of this type, say Y and read @@ -1885,14 +1949,11 @@ CONFIG_EEXPRESS If you have a network (ethernet) card of this type, say Y and read the Ethernet-HOWTO, available via ftp (user: anonymous) in sunsite.unc.edu:/pub/Linux/docs/HOWTO. Note that the Intel - EtherExpress16 card is generally regarded to be a very poor choice - and the driver is not very reliable. (Roger Wolff - (R.E.Wolff@et.tudelft.nl) is attempting to do something about - this. At the moment he could use 1) one or more etherexpress16 cards - to test locally 2) Alpha testers: people to try new versions of the - driver to see if things improve...) If you want to compile this - driver as a module ( = code which can be inserted in and removed - from the running kernel whenever you want), say M here and read + EtherExpress16 card used to be regarded as a very poor choice + because the driver was very unreliable. We now have a new driver + that should do better. If you want to compile this driver as a + module ( = code which can be inserted in and removed from the + running kernel whenever you want), say M here and read Documentation/modules.txt as well as Documentation/networking/net-modules.txt. If you plan to use more than one network card under linux, read the @@ -2573,16 +2634,17 @@ CONFIG_SYSV_FS and is often needed to run commercial software, most prominently WordPerfect. It's in tsx-11.mit.edu:/pub/linux/BETA). If you only intend to mount files from some other Unix over the network using - NFS, you don't need this (but you need nfs filesystem support - obviously). Note that this option is generally not needed for - floppies, since a good portable way to transport files between - unixes (and even to other operating systems) is given by the tar - program ("man tar"). Note also that this option has nothing to do - whatsoever with the option "System V IPC". Read about the System V - filesystem in Documentation/filesystems/sysv-fs.txt. This option - will enlarge your kernel by about 34 kB. If you want to compile this - as a module ( = code which can be inserted in and removed from the - running kernel whenever you want), say M here and read + NFS, you don't need the System V filesystem support (but you need + nfs filesystem support obviously). Note that this option is + generally not needed for floppies, since a good portable way to + transport files and directories between unixes (and even other + operating systems) is given by the tar program ("man tar"). Note + also that this option has nothing whatsoever to do with the option + "System V IPC". Read about the System V filesystem in + Documentation/filesystems/sysv-fs.txt. This option will enlarge your + kernel by about 34 kB. If you want to compile this as a module ( = + code which can be inserted in and removed from the running kernel + whenever you want), say M here and read Documentation/modules.txt. If you haven't heard about all of this before, it's safe to say N. @@ -2601,18 +2663,18 @@ CONFIG_SMB_FS information about how to connect Linux, Windows machines and Macs is on the WWW at http://eats.com/linux_mac_win.html (to browse the WWW, you need to have access to a machine on the Internet that has one of - the programs lynx, netscape or Mosaic). If you want to compile this - as a module ( = code which can be inserted in and removed from the - running kernel whenever you want), say M here and read - Documentation/modules.txt. Most people say N, however. + the programs lynx, netscape or Mosaic). If you want to compile the + SMB support as a module ( = code which can be inserted in and + removed from the running kernel whenever you want), say M here and + read Documentation/modules.txt. Most people say N, however. NCP filesystem support (to mount NetWare volumes) CONFIG_NCP_FS NCP (NetWare Core Protocol) is a protocol that runs over IPX and is - used by NetWare clients to talk to file servers. It is to IPX what - nfs is to tcp/ip, if that helps. Enabling this option allows you to - mount NetWare file server volumes and to access them just like any - other Unix directory. For details, please read the file + used by Novel NetWare clients to talk to file servers. It is to IPX + what nfs is to tcp/ip, if that helps. Enabling this option allows + you to mount NetWare file server volumes and to access them just + like any other Unix directory. For details, please read the file Documentation/filesystems/ncpfs.txt in the kernel source and the IPX-HOWTO on sunsite.unc.edu:/pub/Linux/docs/howto. If you want to compile this as a module ( = code which can be inserted in and @@ -2633,13 +2695,13 @@ CONFIG_SERIAL Cyclades async mux support CONFIG_CYCLADES - This is a card which gives you many serial ports. You would need - something like this to connect more than two modems to your linux - box, for instance in order to become a BBS. If you want to compile - this as a module ( = code which can be inserted in and removed from - the running kernel whenever you want), say M here and read - Documentation/modules.txt. If you haven't heard about it, it's safe - to say N. + This is a driver for a card that gives you many serial ports. You + would need something like this to connect more than two modems to + your linux box, for instance in order to become a BBS. If you want + to compile this as a module ( = code which can be inserted in and + removed from the running kernel whenever you want), say M here and + read Documentation/modules.txt. If you haven't heard about it, it's + safe to say N. Stallion multiport serial support CONFIG_STALDRV @@ -3038,4 +3100,5 @@ CONFIG_ISDN_DRV_TELES # LocalWords: ipppd syncppp RFC MPP VJ downloaded icn NICCY Creatix shmem ufr # LocalWords: ibp md ARCnet ether encap NDIS arcether ODI Amigas AmiTCP NetBSD # LocalWords: initrd tue util DES funet des OnNet BIOSP smc Travan Iomega CMS -# LocalWords: FC +# LocalWords: FC DC dc PPA IOMEGA's ppa RNFS FMV Fujitsu ARPD arpd loran layes +# LocalWords: FRAD indiana framerelay DLCI DCLIs Sangoma SDLA diff --git a/Documentation/svga.txt b/Documentation/svga.txt index f8240287eb75..56b3d73bcf65 100644 --- a/Documentation/svga.txt +++ b/Documentation/svga.txt @@ -1,4 +1,4 @@ - Video Mode Selection Support 2.5 + Video Mode Selection Support 2.6 (c) 1995, 1996 Martin Mares, -------------------------------------------------------------------------------- @@ -223,3 +223,5 @@ this must be done manually -- no autodetection mechanisms are available. only with some loaders now. Added a Tseng 132x60 mode. 2.5 (19-Mar-96) Fixed a VESA mode scanning bug introduced in 2.4. +2.6 (25-Mar-96) Some VESA BIOS errors not reported -- it fixes error reports on + several cards with broken VESA code (e.g., ATI VGA). diff --git a/Makefile b/Makefile index d6dd788d15b6..8c9e9b1640ca 100644 --- a/Makefile +++ b/Makefile @@ -1,6 +1,6 @@ VERSION = 1 PATCHLEVEL = 3 -SUBLEVEL = 78 +SUBLEVEL = 79 ARCH = i386 diff --git a/arch/i386/boot/video.S b/arch/i386/boot/video.S index a1b74c013b0b..07c3f9fc09c0 100644 --- a/arch/i386/boot/video.S +++ b/arch/i386/boot/video.S @@ -1,5 +1,5 @@ ! -! Display adapter & video mode setup, version 2.5 (19-Mar-96) +! Display adapter & video mode setup, version 2.6 (25-Mar-96) ! ! Copyright (C) 1995, 1996 Martin Mares ! Based on the original setup.S code (C) Linus Torvalds @@ -779,7 +779,7 @@ vesa2: push cx add bh,#VIDEO_FIRST_VESA>>8 pop cx cmp ax,#0x004f - jnz vesae + jnz vesan ! Don't report errors (buggy BIOSES :-[ ) mov al,(di) ! Check capabilities. We require and al,#0x19 ! a color text mode. cmp al,#0x09 diff --git a/arch/i386/kernel/setup.c b/arch/i386/kernel/setup.c index f0151464f215..66cdf326db24 100644 --- a/arch/i386/kernel/setup.c +++ b/arch/i386/kernel/setup.c @@ -225,6 +225,16 @@ static const char * i586model(unsigned int nr) return NULL; } +static const char * i686model(unsigned int nr) +{ + static const char *model[] = { + "PPro A-step", "Pentium Pro" + }; + if (nr < sizeof(model)/sizeof(char *)) + return model[nr]; + return NULL; +} + static const char * getmodel(int x86, int model) { const char *p = NULL; @@ -236,6 +246,9 @@ static const char * getmodel(int x86, int model) case 5: p = i586model(model); break; + case 6: + p = i686model(model); + break; } if (p) return p; @@ -294,12 +307,15 @@ int get_cpuinfo(char * buffer) "fdiv_bug\t: %s\n" "hlt_bug\t\t: %s\n" "fpu\t\t: %s\n" + "fpu_exception\t: %s\n" "cpuid\t\t: %s\n" "wp\t\t: %s\n" "flags\t\t:", CD(fdiv_bug) ? "yes" : "no", CD(hlt_works_ok) ? "no" : "yes", CD(hard_math) ? "yes" : "no", + (CD(hard_math) && ignore_irq13) + ? "yes" : "no", CD(have_cpuid) ? "yes" : "no", CD(wp_works_ok) ? "yes" : "no"); diff --git a/drivers/block/floppy.c b/drivers/block/floppy.c index 4f1c9d2e3d0b..1468b011fd6f 100644 --- a/drivers/block/floppy.c +++ b/drivers/block/floppy.c @@ -2597,7 +2597,7 @@ static void redo_fd_request(void) } while(1){ - if (!CURRENT || CURRENT_PLUGGED) { + if (!CURRENT) { CLEAR_INTR; unlock_fdc(); return; diff --git a/drivers/block/ide.c b/drivers/block/ide.c index a714dda023ef..ab406fcbd783 100644 --- a/drivers/block/ide.c +++ b/drivers/block/ide.c @@ -1469,8 +1469,6 @@ void ide_do_request (ide_hwgroup_t *hwgroup) */ hwif = hwgroup->next_hwif; do { - if (IS_PLUGGED(blk_dev + hwif->major)) - continue; rq = blk_dev[hwif->major].current_request; if (rq != NULL && rq->rq_status != RQ_INACTIVE) goto got_rq; diff --git a/drivers/block/ll_rw_blk.c b/drivers/block/ll_rw_blk.c index 3c066a8a0ddc..47b63e45e345 100644 --- a/drivers/block/ll_rw_blk.c +++ b/drivers/block/ll_rw_blk.c @@ -85,8 +85,9 @@ static void unplug_device(void * data) save_flags(flags); cli(); - if (dev->current_request) - (dev->request_fn)(); + dev->current_request = dev->plug.next; + dev->plug.next = NULL; + (dev->request_fn)(); restore_flags(flags); } @@ -94,11 +95,20 @@ static void unplug_device(void * data) * "plug" the device if there are no outstanding requests: this will * force the transfer to start only after we have put all the requests * on the list. + * + * Note! We can do the check without interrupts off, because interrupts + * will never add a new request to the queue, only take requests off.. */ static inline void plug_device(struct blk_dev_struct * dev) { - if (!dev->current_request && !IS_PLUGGED(dev)) { + if (!dev->current_request) { + unsigned long flags; + + save_flags(flags); + cli(); + dev->current_request = &dev->plug; queue_task_irq_off(&dev->plug_tq, &tq_scheduler); + restore_flags(flags); } } @@ -250,8 +260,7 @@ void add_request(struct blk_dev_struct * dev, struct request * req) if (!(tmp = dev->current_request)) { dev->current_request = req; up (&request_lock); - if (!IS_PLUGGED(dev)) - (dev->request_fn)(); + (dev->request_fn)(); sti(); return; } @@ -266,7 +275,7 @@ void add_request(struct blk_dev_struct * dev, struct request * req) up (&request_lock); /* for SCSI devices, call request_fn unconditionally */ - if (!IS_PLUGGED(dev) && scsi_major(MAJOR(req->rq_dev)) && MAJOR(req->rq_dev)!=MD_MAJOR) + if (scsi_major(MAJOR(req->rq_dev)) && MAJOR(req->rq_dev)!=MD_MAJOR) (dev->request_fn)(); sti(); @@ -609,6 +618,9 @@ int blk_dev_init(void) for (dev = blk_dev + MAX_BLKDEV; dev-- != blk_dev;) { dev->request_fn = NULL; dev->current_request = NULL; + dev->plug.rq_status = RQ_INACTIVE; + dev->plug.cmd = -1; + dev->plug.next = NULL; dev->plug_tq.routine = &unplug_device; dev->plug_tq.data = dev; } diff --git a/drivers/cdrom/cdu31a.c b/drivers/cdrom/cdu31a.c index ad5d3ce546ed..b20f1dda9484 100644 --- a/drivers/cdrom/cdu31a.c +++ b/drivers/cdrom/cdu31a.c @@ -1525,7 +1525,7 @@ cdu31a_request_startover: * The beginning here is stolen from the hard disk driver. I hope * it's right. */ - if (!(CURRENT) || CURRENT_PLUGGED || CURRENT->rq_status == RQ_INACTIVE) + if (!(CURRENT) || CURRENT->rq_status == RQ_INACTIVE) { goto end_do_cdu31a_request; } diff --git a/drivers/cdrom/sonycd535.c b/drivers/cdrom/sonycd535.c index 90790632271a..97ccb544bb4d 100644 --- a/drivers/cdrom/sonycd535.c +++ b/drivers/cdrom/sonycd535.c @@ -1654,7 +1654,7 @@ sonycd535_setup(char *strings, int *ints) * then call with io base of 0 */ if (ints[0] > 0) - if (ints[0] != 0) + if (ints[1] != 0) sony535_cd_base_io = ints[1]; if (ints[0] > 1) sony535_irq_used = ints[2]; diff --git a/drivers/char/README.stallion b/drivers/char/README.stallion index 72ae44de0ec8..02fc8ceeeab7 100644 --- a/drivers/char/README.stallion +++ b/drivers/char/README.stallion @@ -2,8 +2,8 @@ Stallion Multiport Serial Drivers --------------------------------- -Version: 1.0.6 -Date: 11MAR96 +Version: 1.0.8 +Date: 25MAR96 Author: Greg Ungerer (gerg@stallion.oz.au) @@ -12,31 +12,31 @@ Author: Greg Ungerer (gerg@stallion.oz.au) There are two drivers that work with the different families of Stallion multiport serial boards. One is for the Stallion smart boards - that is EasyIO and EasyConnection 8/32, the other for the true Stallion intelligent -multiport boards - Stallion, Brumby, ONboard and EasyConnection 8/64. +multiport boards - EasyConnection 8/64, ONboard, Brumby and Stallion. If you are using any of the Stallion intelligent multiport boards (Brumby, ONboard, Stallion, EasyConnection 8/64) with Linux you will need to get the driver utility package. This package is available at most of the Linux archive sites (and on CD's that contain these archives). The file will be called stallion-X.X.X.tar.gz where X.X.X will be the version number. In -particular this package contains the board embeded executable images that +particular this package contains the board embedded executable images that are required for these boards. It also contains the downloader program. These boards cannot be used without this. -The following ftp sites (and their mirrors) definately have the stallion +The following ftp sites (and their mirrors) definitely have the stallion driver utility package: ftp.stallion.com, tsx-11.mit.edu, sunsite.unc.edu. -ftp.stallion.com:/drivers/ata5/Linux/stallion-1.0.1.tar.gz -tsx-11.mit.edu:/pub/linux/BETA/serial/stallion/stallion-1.0.1.tar.gz -sunsite.unc.edu:/pub/Linux/kernel/patches/serial/stallion-1.0.1.tar.gz +ftp.stallion.com:/drivers/ata5/Linux/stallion-1.0.7.tar.gz +tsx-11.mit.edu:/pub/linux/BETA/serial/stallion/stallion-1.0.7.tar.gz +sunsite.unc.edu:/pub/Linux/kernel/patches/serial/stallion-1.0.7.tar.gz If you are using the EasyIO or EasyConnection 8/32 boards then you don't need this package. Although it does have a handy script to create the -/dev device nodes for these boards. +/dev device nodes for these boards, and a serial stats display program. If you require DIP switch settings, EISA/MCA configuration files, or any -other information related to Stallion boards then have a look at -http://www.stallion.com. +other information related to Stallion boards then have a look at Stallion's +web pages at http://www.stallion.com. @@ -265,13 +265,15 @@ by Greg Hankins. It will explain everything you need to know! You can use both drivers at once if you have a mix of board types installed in a system. However to do this you will need to change the major numbers -used by one of the drivers. Currently both drivers use major numbers 24 and -25 for their port devices. Change one driver to use some other major numbers, +used by one of the drivers. Currently both drivers use major numbers 24, 25 +and 28 for their devices. Change one driver to use some other major numbers, and then modify the mkdevnods script to make device nodes based on those new -major numbers. For example, you could change the stallion.c driver to use -major numbers 30 and 31 (don't use 28, it's used by istallion.c driver for its -sio memory device!). You will also need to create device nodes with different -names for the ports... +major numbers. For example, you could change the istallion.c driver to use +major numbers 60, 61 and 62. You will also need to create device nodes with +different names for the ports, for example ttyF# and cuf#. + +The original Stallion board is no longer supported by Stallion Technologies. +Although it is known to work with the istallion driver. Finding a free physical memory address range can be a problem. The older boards like the Stallion and ONboard need large areas (64K or even 128K), so @@ -301,32 +303,14 @@ them can be used then the high memory support to use the really high address ranges is the best option. Typically the 2Gb range is convenient for them, and gets them well out of the way. -There is a new utility program in the stallion utility package called -"stlstty". Most people will not need to use this. If you have an ONboard/16 -which has partial signals on the upper 12 ports then this program can be used -to set the upper ports to have modem control instead of hardware flow control. -Use the "mapcts maprts" flag options to this utility on the port(s) that you -wish to do this mapping on, eg - ./stlstty maprts mapcts < /dev/cue0 -This enables RTS to act like DTR and CTS to act like DCD on the specified -port. - The ports of the EasyIO-8M board do not have DCD or DTR signals. So these ports cannot be used as real modem devices. Generally when using these ports you should only use the cueX devices. -There is another new utility in this package that reports statistics on -the serial ports. You will need to have the curses libray installed on -your system to build it. - -To build the statistics display program type: - make stlstats -Once compiled simply run it (you will need to be root) and it will display -a port summary for the first board and panel installed. Use the digits to -select different board numbers, or 'n' to cycle through the panels on a -board. To look at detailed port information then hit 'p', that will display -detailed port 0 information. Use the digits and letteres 'a' through 'f' to -select the different ports (on this board and panel). +The driver utility package contains a couple of very useful programs. One +is a serial port statistics collection and display program - very handy +for solving serial port problems. The other is an extended option setting +program that works with the intelligent boards. diff --git a/drivers/char/istallion.c b/drivers/char/istallion.c index a264a633cd37..e497343d9115 100644 --- a/drivers/char/istallion.c +++ b/drivers/char/istallion.c @@ -180,7 +180,7 @@ static int stli_nrbrds = sizeof(stli_brdconf) / sizeof(stlconf_t); * all the local structures required by a serial tty driver. */ static char *stli_drvname = "Stallion Intelligent Multiport Serial Driver"; -static char *stli_drvversion = "1.0.6"; +static char *stli_drvversion = "1.0.8"; static char *stli_serialname = "ttyE"; static char *stli_calloutname = "cue"; @@ -279,7 +279,6 @@ typedef struct { struct termios normaltermios; struct termios callouttermios; asysigs_t asig; - comstats_t stats; unsigned long addr; unsigned long rxoffset; unsigned long txoffset; @@ -4351,48 +4350,48 @@ static int stli_getportstats(stliport_t *portp, comstats_t *cp) if (brdp == (stlibrd_t *) NULL) return(-ENODEV); - portp->stats.state = portp->state; - portp->stats.flags = portp->flags; + if ((rc = stli_cmdwait(brdp, portp, A_GETSTATS, &stli_cdkstats, sizeof(asystats_t), 1)) < 0) + return(rc); + + stli_comstats.state = portp->state; + stli_comstats.flags = portp->flags; if (portp->tty != (struct tty_struct *) NULL) { - portp->stats.ttystate = portp->tty->flags; - portp->stats.cflags = portp->tty->termios->c_cflag; - portp->stats.iflags = portp->tty->termios->c_iflag; - portp->stats.oflags = portp->tty->termios->c_oflag; - portp->stats.lflags = portp->tty->termios->c_lflag; - portp->stats.rxbuffered = portp->tty->flip.count; + stli_comstats.ttystate = portp->tty->flags; + stli_comstats.cflags = portp->tty->termios->c_cflag; + stli_comstats.iflags = portp->tty->termios->c_iflag; + stli_comstats.oflags = portp->tty->termios->c_oflag; + stli_comstats.lflags = portp->tty->termios->c_lflag; + stli_comstats.rxbuffered = portp->tty->flip.count; } else { - portp->stats.ttystate = 0; - portp->stats.cflags = 0; - portp->stats.iflags = 0; - portp->stats.oflags = 0; - portp->stats.lflags = 0; - portp->stats.rxbuffered = 0; + stli_comstats.ttystate = 0; + stli_comstats.cflags = 0; + stli_comstats.iflags = 0; + stli_comstats.oflags = 0; + stli_comstats.lflags = 0; + stli_comstats.rxbuffered = 0; } - if ((rc = stli_cmdwait(brdp, portp, A_GETSTATS, &stli_cdkstats, sizeof(asystats_t), 1)) < 0) - return(rc); - - portp->stats.txtotal = stli_cdkstats.txchars; - portp->stats.rxtotal = stli_cdkstats.rxchars + stli_cdkstats.ringover; - portp->stats.txbuffered = stli_cdkstats.txringq; - portp->stats.rxbuffered += stli_cdkstats.rxringq; - portp->stats.rxoverrun = stli_cdkstats.overruns; - portp->stats.rxparity = stli_cdkstats.parity; - portp->stats.rxframing = stli_cdkstats.framing; - portp->stats.rxlost = stli_cdkstats.ringover; - portp->stats.rxbreaks = stli_cdkstats.rxbreaks; - portp->stats.txbreaks = stli_cdkstats.txbreaks; - portp->stats.txxon = stli_cdkstats.txstart; - portp->stats.txxoff = stli_cdkstats.txstop; - portp->stats.rxxon = stli_cdkstats.rxstart; - portp->stats.rxxoff = stli_cdkstats.rxstop; - portp->stats.rxrtsoff = stli_cdkstats.rtscnt / 2; - portp->stats.rxrtson = stli_cdkstats.rtscnt - portp->stats.rxrtsoff; - portp->stats.modem = stli_cdkstats.dcdcnt; - portp->stats.hwid = stli_cdkstats.hwid; - portp->stats.signals = stli_mktiocm(stli_cdkstats.signals); - - memcpy_tofs(cp, &portp->stats, sizeof(comstats_t)); + stli_comstats.txtotal = stli_cdkstats.txchars; + stli_comstats.rxtotal = stli_cdkstats.rxchars + stli_cdkstats.ringover; + stli_comstats.txbuffered = stli_cdkstats.txringq; + stli_comstats.rxbuffered += stli_cdkstats.rxringq; + stli_comstats.rxoverrun = stli_cdkstats.overruns; + stli_comstats.rxparity = stli_cdkstats.parity; + stli_comstats.rxframing = stli_cdkstats.framing; + stli_comstats.rxlost = stli_cdkstats.ringover; + stli_comstats.rxbreaks = stli_cdkstats.rxbreaks; + stli_comstats.txbreaks = stli_cdkstats.txbreaks; + stli_comstats.txxon = stli_cdkstats.txstart; + stli_comstats.txxoff = stli_cdkstats.txstop; + stli_comstats.rxxon = stli_cdkstats.rxstart; + stli_comstats.rxxoff = stli_cdkstats.rxstop; + stli_comstats.rxrtsoff = stli_cdkstats.rtscnt / 2; + stli_comstats.rxrtson = stli_cdkstats.rtscnt - stli_comstats.rxrtsoff; + stli_comstats.modem = stli_cdkstats.dcdcnt; + stli_comstats.hwid = stli_cdkstats.hwid; + stli_comstats.signals = stli_mktiocm(stli_cdkstats.signals); + + memcpy_tofs(cp, &stli_comstats, sizeof(comstats_t)); return(0); } @@ -4418,15 +4417,15 @@ static int stli_clrportstats(stliport_t *portp, comstats_t *cp) if (brdp == (stlibrd_t *) NULL) return(-ENODEV); - memset(&portp->stats, 0, sizeof(comstats_t)); - portp->stats.brd = portp->brdnr; - portp->stats.panel = portp->panelnr; - portp->stats.port = portp->portnr; - if ((rc = stli_cmdwait(brdp, portp, A_CLEARSTATS, 0, 0, 0)) < 0) return(rc); - memcpy_tofs(cp, &portp->stats, sizeof(comstats_t)); + memset(&stli_comstats, 0, sizeof(comstats_t)); + stli_comstats.brd = portp->brdnr; + stli_comstats.panel = portp->panelnr; + stli_comstats.port = portp->portnr; + + memcpy_tofs(cp, &stli_comstats, sizeof(comstats_t)); return(0); } diff --git a/drivers/char/stallion.c b/drivers/char/stallion.c index a75051edb4ef..e70addbb35d6 100644 --- a/drivers/char/stallion.c +++ b/drivers/char/stallion.c @@ -145,7 +145,7 @@ static int stl_nrbrds = sizeof(stl_brdconf) / sizeof(stlconf_t); * all the local structures required by a serial tty driver. */ static char *stl_drvname = "Stallion Multiport Serial Driver"; -static char *stl_drvversion = "1.0.6"; +static char *stl_drvversion = "1.0.8"; static char *stl_serialname = "ttyE"; static char *stl_calloutname = "cue"; diff --git a/drivers/net/ibmtr.c b/drivers/net/ibmtr.c index ebed939d70e0..37f430013635 100644 --- a/drivers/net/ibmtr.c +++ b/drivers/net/ibmtr.c @@ -153,7 +153,7 @@ static short TokBaseAddrs[] = { MMIOStartLocP, MMIOStartLocA }; int tok_probe(struct device *dev); unsigned char get_sram_size(struct tok_info *adapt_info); -static int tok_init_card(struct device *dev); +static void tok_init_card(unsigned long dev_addr); int trdev_init(struct device *dev); void tok_interrupt(int irq, void *dev_id, struct pt_regs *regs); diff --git a/drivers/scsi/scsi.h b/drivers/scsi/scsi.h index 6e73b9e97338..a4e569424048 100644 --- a/drivers/scsi/scsi.h +++ b/drivers/scsi/scsi.h @@ -514,7 +514,7 @@ static Scsi_Cmnd * end_scsi_request(Scsi_Cmnd * SCpnt, int uptodate, int sectors * turned off */ #define INIT_SCSI_REQUEST \ - if (!CURRENT || CURRENT_PLUGGED) { \ + if (!CURRENT) { \ CLEAR_INTR; \ restore_flags(flags); \ return; \ diff --git a/fs/buffer.c b/fs/buffer.c index 1b475df21b42..76b13d8abe2b 100644 --- a/fs/buffer.c +++ b/fs/buffer.c @@ -103,7 +103,7 @@ union bdflush_param{ trim back the buffers */ } b_un; unsigned int data[N_PARAM]; -} bdf_prm = {{25, 500, 64, 256, 15, 30*HZ, 5*HZ, 1884, 2}}; +} bdf_prm = {{60, 500, 64, 256, 15, 30*HZ, 5*HZ, 1884, 2}}; /* The lav constant is set for 1 minute, as long as the update process runs every 5 seconds. If you change the frequency of update, the time diff --git a/fs/ncpfs/dir.c b/fs/ncpfs/dir.c index 2ee56276f831..c5cd2df575b3 100644 --- a/fs/ncpfs/dir.c +++ b/fs/ncpfs/dir.c @@ -393,7 +393,7 @@ ncp_read_volume_list(struct ncp_server *server, int fpos, int cache_size) if (ncp_get_volume_info_with_number(server, i, &info) != 0) { - return total_count; + return (total_count - fpos); } if (strlen(info.volume_name) > 0) diff --git a/fs/nfs/nfsroot.c b/fs/nfs/nfsroot.c index bfefbf8d60a0..04e0cf92330d 100644 --- a/fs/nfs/nfsroot.c +++ b/fs/nfs/nfsroot.c @@ -65,8 +65,8 @@ #include #include #include -#include #include +#include #ifdef CONFIG_AX25 #include /* For AX25_P_IP */ #endif diff --git a/include/asm-alpha/posix_types.h b/include/asm-alpha/posix_types.h index ee5b31d68db0..69631f0c006b 100644 --- a/include/asm-alpha/posix_types.h +++ b/include/asm-alpha/posix_types.h @@ -7,25 +7,29 @@ * assume GCC is being used. */ -typedef unsigned int __dev_t; -typedef unsigned int __ino_t; -typedef unsigned int __mode_t; -typedef unsigned short __nlink_t; -typedef long __off_t; -typedef int __pid_t; -typedef unsigned int __uid_t; -typedef unsigned int __gid_t; -typedef unsigned long __size_t; -typedef long __ssize_t; -typedef long __ptrdiff_t; -typedef long __time_t; -typedef long __clock_t; -typedef int __daddr_t; -typedef char * __caddr_t; +typedef unsigned int __kernel_dev_t; +typedef unsigned int __kernel_ino_t; +typedef unsigned int __kernel_mode_t; +typedef unsigned short __kernel_nlink_t; +typedef long __kernel_off_t; +typedef int __kernel_pid_t; +typedef unsigned int __kernel_uid_t; +typedef unsigned int __kernel_gid_t; +typedef unsigned long __kernel_size_t; +typedef long __kernel_ssize_t; +typedef long __kernel_ptrdiff_t; +typedef long __kernel_time_t; +typedef long __kernel_clock_t; +typedef int __kernel_daddr_t; +typedef char * __kernel_caddr_t; + +#ifdef __GNUC__ +typedef long long __kernel_loff_t; +#endif typedef struct { int val[2]; -} __fsid_t; +} __kernel_fsid_t; #ifndef __GNUC__ @@ -33,14 +37,14 @@ typedef struct { #define __FD_CLR(d, set) ((set)->fds_bits[__FDELT(d)] &= ~__FDMASK(d)) #define __FD_ISSET(d, set) ((set)->fds_bits[__FDELT(d)] & __FDMASK(d)) #define __FD_ZERO(set) \ - ((void) memset ((__ptr_t) (set), 0, sizeof (__fd_set))) + ((void) memset ((__ptr_t) (set), 0, sizeof (__kernel_fd_set))) #else /* __GNUC__ */ /* With GNU C, use inline functions instead so args are evaluated only once: */ #undef __FD_SET -static __inline__ void __FD_SET(unsigned long fd, __fd_set *fdsetp) +static __inline__ void __FD_SET(unsigned long fd, __kernel_fd_set *fdsetp) { unsigned long _tmp = fd / __NFDBITS; unsigned long _rem = fd % __NFDBITS; @@ -48,7 +52,7 @@ static __inline__ void __FD_SET(unsigned long fd, __fd_set *fdsetp) } #undef __FD_CLR -static __inline__ void __FD_CLR(unsigned long fd, __fd_set *fdsetp) +static __inline__ void __FD_CLR(unsigned long fd, __kernel_fd_set *fdsetp) { unsigned long _tmp = fd / __NFDBITS; unsigned long _rem = fd % __NFDBITS; @@ -56,7 +60,7 @@ static __inline__ void __FD_CLR(unsigned long fd, __fd_set *fdsetp) } #undef __FD_ISSET -static __inline__ int __FD_ISSET(unsigned long fd, __fd_set *p) +static __inline__ int __FD_ISSET(unsigned long fd, __kernel_fd_set *p) { unsigned long _tmp = fd / __NFDBITS; unsigned long _rem = fd % __NFDBITS; @@ -68,7 +72,7 @@ static __inline__ int __FD_ISSET(unsigned long fd, __fd_set *p) * for a 256-bit fd_set) */ #undef __FD_ZERO -static __inline__ void __FD_ZERO(__fd_set *p) +static __inline__ void __FD_ZERO(__kernel_fd_set *p) { unsigned int *tmp = p->fds_bits; int i; diff --git a/include/asm-alpha/statfs.h b/include/asm-alpha/statfs.h index 1f399b493d2c..9df6d95b55a7 100644 --- a/include/asm-alpha/statfs.h +++ b/include/asm-alpha/statfs.h @@ -5,7 +5,7 @@ #include -typedef __fsid_t fsid_t; +typedef __kernel_fsid_t fsid_t; #endif @@ -23,7 +23,7 @@ struct statfs { int f_bavail; int f_files; int f_ffree; - __fsid_t f_fsid; + __kernel_fsid_t f_fsid; /* linux-specific entries start here.. */ int f_namelen; }; diff --git a/include/asm-i386/posix_types.h b/include/asm-i386/posix_types.h index f2d86823f089..a6e2d7ffc1e8 100644 --- a/include/asm-i386/posix_types.h +++ b/include/asm-i386/posix_types.h @@ -7,21 +7,25 @@ * assume GCC is being used. */ -typedef unsigned short __dev_t; -typedef unsigned long __ino_t; -typedef unsigned short __mode_t; -typedef unsigned short __nlink_t; -typedef long __off_t; -typedef int __pid_t; -typedef unsigned short __uid_t; -typedef unsigned short __gid_t; -typedef unsigned int __size_t; -typedef int __ssize_t; -typedef int __ptrdiff_t; -typedef long __time_t; -typedef long __clock_t; -typedef int __daddr_t; -typedef char * __caddr_t; +typedef unsigned short __kernel_dev_t; +typedef unsigned long __kernel_ino_t; +typedef unsigned short __kernel_mode_t; +typedef unsigned short __kernel_nlink_t; +typedef long __kernel_off_t; +typedef int __kernel_pid_t; +typedef unsigned short __kernel_uid_t; +typedef unsigned short __kernel_gid_t; +typedef unsigned int __kernel_size_t; +typedef int __kernel_ssize_t; +typedef int __kernel_ptrdiff_t; +typedef long __kernel_time_t; +typedef long __kernel_clock_t; +typedef int __kernel_daddr_t; +typedef char * __kernel_caddr_t; + +#ifdef __GNUC__ +typedef long long __kernel_loff_t; +#endif #undef __FD_SET #define __FD_SET(fd,fdsetp) \ diff --git a/include/linux/blk.h b/include/linux/blk.h index 4685165fd721..04d1c88f9ad6 100644 --- a/include/linux/blk.h +++ b/include/linux/blk.h @@ -319,8 +319,6 @@ static void floppy_off(unsigned int nr); #define CURRENT (blk_dev[MAJOR_NR].current_request) #endif -#define CURRENT_PLUGGED IS_PLUGGED(blk_dev+MAJOR_NR) - #define CURRENT_DEV DEVICE_NR(CURRENT->rq_dev) #ifdef DEVICE_INTR @@ -358,7 +356,7 @@ static void (DEVICE_REQUEST)(void); #endif #define INIT_REQUEST \ - if (!CURRENT || CURRENT_PLUGGED) {\ + if (!CURRENT) {\ CLEAR_INTR; \ return; \ } \ diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index f261aca324ba..4b65a538c693 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h @@ -36,11 +36,10 @@ struct request { struct blk_dev_struct { void (*request_fn)(void); struct request * current_request; + struct request plug; struct tq_struct plug_tq; }; -#define IS_PLUGGED(dev) ((dev)->plug_tq.sync) - struct sec_size { unsigned block_size; unsigned block_size_bits; diff --git a/include/linux/posix_types.h b/include/linux/posix_types.h index 87c17c701316..88f9a63172ac 100644 --- a/include/linux/posix_types.h +++ b/include/linux/posix_types.h @@ -1,8 +1,6 @@ #ifndef _LINUX_POSIX_TYPES_H #define _LINUX_POSIX_TYPES_H -#define _GNU_TYPES_H - /* * This file is generally used by user-level software, so you need to * be a little careful about namespace pollution etc. Also, we cannot @@ -45,15 +43,8 @@ typedef struct fd_set { unsigned int fds_bits [__FDSET_INTS]; -} __fd_set; +} __kernel_fd_set; #include -/* bsd */ - -typedef unsigned char __u_char; -typedef unsigned short __u_short; -typedef unsigned int __u_int; -typedef unsigned long __u_long; - #endif /* _LINUX_POSIX_TYPES_H */ diff --git a/include/linux/types.h b/include/linux/types.h index b4a73da50bc4..af7e19d07185 100644 --- a/include/linux/types.h +++ b/include/linux/types.h @@ -6,23 +6,20 @@ #ifndef _LINUX_TYPES_DONT_EXPORT -typedef __fd_set fd_set; -typedef __dev_t dev_t; -typedef __ino_t ino_t; -typedef __mode_t mode_t; -typedef __nlink_t nlink_t; -typedef __off_t off_t; -typedef __pid_t pid_t; -typedef __uid_t uid_t; -typedef __gid_t gid_t; -typedef __daddr_t daddr_t; +typedef __kernel_fd_set fd_set; +typedef __kernel_dev_t dev_t; +typedef __kernel_ino_t ino_t; +typedef __kernel_mode_t mode_t; +typedef __kernel_nlink_t nlink_t; +typedef __kernel_off_t off_t; +typedef __kernel_pid_t pid_t; +typedef __kernel_uid_t uid_t; +typedef __kernel_gid_t gid_t; +typedef __kernel_daddr_t daddr_t; -/* bsd */ - -typedef __u_char u_char; -typedef __u_short u_short; -typedef __u_int u_int; -typedef __u_long u_long; +#if defined(__GNUC__) && !defined(__STRICT_ANSI__) +typedef __kernel_loff_t loff_t; +#endif /* * The following typedefs are also protected by individual ifdefs for @@ -30,39 +27,45 @@ typedef __u_long u_long; */ #ifndef _SIZE_T #define _SIZE_T -typedef __size_t size_t; +typedef __kernel_size_t size_t; #endif #ifndef _SSIZE_T #define _SSIZE_T -typedef __ssize_t ssize_t; +typedef __kernel_ssize_t ssize_t; #endif #ifndef _PTRDIFF_T #define _PTRDIFF_T -typedef __ptrdiff_t ptrdiff_t; +typedef __kernel_ptrdiff_t ptrdiff_t; #endif #ifndef _TIME_T #define _TIME_T -typedef __time_t time_t; +typedef __kernel_time_t time_t; #endif #ifndef _CLOCK_T #define _CLOCK_T -typedef __clock_t clock_t; +typedef __kernel_clock_t clock_t; #endif #ifndef _CADDR_T #define _CADDR_T -typedef __caddr_t caddr_t; +typedef __kernel_caddr_t caddr_t; #endif +/* bsd */ +typedef unsigned char u_char; +typedef unsigned short u_short; +typedef unsigned int u_int; +typedef unsigned long u_long; + /* sysv */ -typedef unsigned char unchar; -typedef unsigned short ushort; -typedef unsigned int uint; -typedef unsigned long ulong; +typedef unsigned char unchar; +typedef unsigned short ushort; +typedef unsigned int uint; +typedef unsigned long ulong; #endif /* _LINUX_TYPES_DONT_EXPORT */ @@ -71,22 +74,11 @@ typedef unsigned long ulong; * any application/library that wants linux/types.h. */ -#if defined(__GNUC__) && !defined(__STRICT_ANSI__) - -typedef long long __loff_t; - -#ifndef _LINUX_TYPES_DONT_EXPORT -#define _LOFF_T -typedef __loff_t loff_t; -#endif - -#endif - struct ustat { - __daddr_t f_tfree; - __ino_t f_tinode; - char f_fname[6]; - char f_fpack[6]; + __kernel_daddr_t f_tfree; + __kernel_ino_t f_tinode; + char f_fname[6]; + char f_fpack[6]; }; #endif /* _LINUX_TYPES_H */ diff --git a/kernel/ksyms.c b/kernel/ksyms.c index 29c7883648d8..8349734ee8af 100644 --- a/kernel/ksyms.c +++ b/kernel/ksyms.c @@ -346,11 +346,6 @@ struct symbol_table symbol_table = { X(aux_device_present), X(kbd_read_mask), -#ifdef CONFIG_TR - X(tr_setup), - X(tr_type_trans), -#endif - #ifdef CONFIG_BLK_DEV_IDE_PCMCIA X(ide_register), X(ide_unregister), diff --git a/net/ipv4/rarp.c b/net/ipv4/rarp.c index d3b98a432543..d2bba0ecde37 100644 --- a/net/ipv4/rarp.c +++ b/net/ipv4/rarp.c @@ -41,6 +41,7 @@ #include #include #include +#include #include #include #include @@ -49,7 +50,6 @@ #include #include #include -#include #include #include #include diff --git a/net/netsyms.c b/net/netsyms.c index c781152fb449..fec5690a9e80 100644 --- a/net/netsyms.c +++ b/net/netsyms.c @@ -113,6 +113,11 @@ static struct symbol_table net_syms = { X(NS8390_init), #endif +#ifdef CONFIG_TR + X(tr_setup), + X(tr_type_trans), +#endif + #ifdef CONFIG_NET_ALIAS #include #endif diff --git a/scripts/Menuconfig b/scripts/Menuconfig index bc64da1d298f..889f05fba691 100644 --- a/scripts/Menuconfig +++ b/scripts/Menuconfig @@ -78,16 +78,13 @@ function bool () { eval $2=\${$2:-'n'} x=\$$2 case $x in - y|m) yes='ON' no='OFF' flag="*" - ;; - n) yes='OFF' no='ON' flag=" " - ;; + y|m) flag="*" ;; + n) flag=" " ;; esac echo -ne "'$2' '($flag) $1' " >>MCmenu - echo -e "function $2 () { l_bool '$1' '$yes' '$no' '$2' }\n" \ - >>MCradiolists + echo -e "function $2 () { l_bool '$2' \"\$1\" }\n" >>MCradiolists } # @@ -104,20 +101,15 @@ function tristate () { eval $2=\${$2:-'n'} x=\$$2 case $x in - y) yes='ON' no='OFF' module='OFF' flag="*" - ;; - m) yes='OFF' no='OFF' module='ON' flag="M" - ;; - *) yes='OFF' no='ON' module='OFF' flag=" " - ;; + y) flag="*" ;; + m) flag="M" ;; + *) flag=" " ;; esac echo -ne "'$2' '<$flag> $1' " >>MCmenu echo -e " - function $2 () { \ - l_tristate '$1' '$yes' '$no' '$module' '$2' - }" >>MCradiolists + function $2 () { l_tristate '$2' \"\$1\" }" >>MCradiolists fi } @@ -155,7 +147,7 @@ function int () { echo -ne "'$2' '($x) $1' " >>MCmenu - echo -e "function $2 () { l_int '$1' '$2' '$3' '$x' }\n" >>MCradiolists + echo -e "function $2 () { l_int '$1' '$2' '$3' '$x' }" >>MCradiolists } # @@ -166,7 +158,7 @@ function hex () { echo -ne "'$2' '($x) $1' " >>MCmenu - echo -e "function $2 () { l_hex '$1' '$2' '$3' '$x' }\n" >>MCradiolists + echo -e "function $2 () { l_hex '$1' '$2' '$3' '$x' }" >>MCradiolists } # @@ -203,9 +195,8 @@ function choice () { echo -ne "'$firstchoice' '($current) $title' " >>MCmenu echo -e " - function $firstchoice () { - l_choice '$title' \"$choices\" $current - }\n" >>MCradiolists + function $firstchoice () \ + { l_choice '$title' \"$choices\" $current }" >>MCradiolists } } # END load_functions() @@ -236,12 +227,14 @@ function extract_help () { if [ -z "$text" ] then - echo "There is no help available for this kernel option." + echo "There is no help available for this kernel option." + return 1 else echo "$text" fi else echo "There is no help available for this kernel option." + return 1 fi } @@ -263,7 +256,7 @@ function help () { # # Show the README file. # -function show_readme() { +function show_readme () { $DIALOG --backtitle "$backtitle" \ --textbox scripts/README.Menuconfig $LINES $COLS } @@ -309,22 +302,15 @@ function l_soundcfg () { # Handle a boolean (Yes/No) option. # function l_bool () { - while true - do - $DIALOG --title "$1" \ - --backtitle "$backtitle" \ - --radiolist "$radiolist_instructions" 12 70 2 \ - 'y' 'Yes' $2 'n' 'No' $3 2>MCdialog.out - - case "$?" in - 0) eval $4=`cat MCdialog.out` - break ;; - - 1) help "$4" "$1" ;; - - *) break ;; + if [ -n "$2" ] + then + case "$2" in + y|m) eval $1=y ;; + *) eval $1=n ;; esac - done + else + echo -ne "\007" + fi } # @@ -334,62 +320,44 @@ function mod_bool () { eval $2=\${$2:-'n'} x=\$$2 case $x in - m) module='ON' no='OFF' flag='M' - ;; - *) module='OFF' no='ON' flag=' ' - ;; + y|m) flag='M' ;; + *) flag=' ' ;; esac echo -ne "'$2' '<$flag> $1' " >>MCmenu - echo -e "function $2 () { l_mod_bool '$1' '$module' '$no' '$2' }\n" \ - >>MCradiolists + echo -e "function $2 () { l_mod_bool '$2' \"\$1\" }" >>MCradiolists } # # Same as l_bool() except options are (Module/No) # function l_mod_bool() { - while true - do - $DIALOG --title "$1" \ - --backtitle "$backtitle" \ - --radiolist "$radiolist_instructions" 12 70 2 \ - 'm' 'Module' $2 'n' 'No' $3 2>MCdialog.out - - case "$?" in - 0) eval $4=`cat MCdialog.out` - break ;; - - 1) help "$4" "$1" ;; - - *) break ;; + if [ -n "$2" ] + then + case "$2" in + y|m) eval $1=m ;; + *) eval $1=n ;; esac - - done + else + echo -ne "\007" + fi } # # Handle a tristate (Yes/No/Module) option. # function l_tristate () { - while true - do - $DIALOG --title "$1" \ - --backtitle "$backtitle" \ - --radiolist "$radiolist_instructions" 13 70 3 \ - 'y' 'Yes' $2 'n' 'No' $3 'm' 'Module' $4 \ - 2>MCdialog.out - - case "$?" in - 0) eval $5=`cat MCdialog.out` - break ;; - - 1) help "$5" "$1" ;; - - *) break ;; + if [ -n "$2" ] + then + case "$2" in + y) eval $1=y ;; + m) eval $1=m ;; + *) eval $1=n ;; esac - done + else + echo -ne "\007" + fi } # @@ -401,7 +369,7 @@ function l_int () { if $DIALOG --title "$1" \ --backtitle "$backtitle" \ --inputbox "$inputbox_instructions_int" \ - 15 55 "$4" 2>MCdialog.out + 10 75 "$4" 2>MCdialog.out then answer="`cat MCdialog.out`" answer="${answer:-$3}" @@ -433,7 +401,7 @@ function l_hex () { if $DIALOG --title "$1" \ --backtitle "$backtitle" \ --inputbox "$inputbox_instructions_hex" \ - 15 55 "$4" 2>MCdialog.out + 10 75 "$4" 2>MCdialog.out then answer="`cat MCdialog.out`" answer="${answer:-$3}" @@ -489,7 +457,7 @@ function l_choice () { if $DIALOG --title "$title" \ --backtitle "$backtitle" \ --radiolist "$radiolist_instructions" \ - 22 70 11 $list 2>MCdialog.out + 15 70 6 $list 2>MCdialog.out then choice=`cat MCdialog.out` break @@ -647,30 +615,37 @@ function parse_config_files () { # dialog commands or recursively call other menus. # function activate_menu () { - while true do - comment_ctr=0 - $1 "$default" #Create the radiolists and dialog cmd - . MCradiolists #Read in the dialog functions. + comment_ctr=0 #So comment lines get unique tags + + $1 "$default" #Create the lxdialog menu & functions + . MCradiolists #Source the menu's functions - . MCmenu 2>MCdialog.out #Activate this menu + . MCmenu 2>MCdialog.out #Activate the lxdialog menu + ret=$? - case "$?" in - 0) - defaults="`cat MCdialog.out`$defaults" #psuedo stack - . MCdialog.out + read selection >MCdialog.out - read selection "*|\ - *"alt_config"*) show_readme ;; - *) eval help $selection ;; + *"-->"*|*"alt_config"*) + show_readme ;; + *) + eval help $selection ;; esac ;; 255|1) @@ -876,8 +851,9 @@ save_configuration () { m) if [ "$CONFIG_MODULES" = "y" ] then - echo "$1=m" >>$CONFIG - echo "#undef $1" >>$CONFIG_H + echo "$1=m" >>$CONFIG + echo "#undef $1" >>$CONFIG_H + echo "#define $1_MODULE 1" >>$CONFIG_H else echo "$1=y" >>$CONFIG echo "#define $1 1" >>$CONFIG_H @@ -1026,17 +1002,24 @@ case $x in COLS=75 ;; esac - + +if [ $LINES -lt 15 -o $COLS -lt 75 ] +then + echo -e "\n\007Your display is too small to run Menuconfig!\n" + echo "It is currently set to $LINES lines by $COLS columns." + echo "It must be at least 15 lines by 75 columns." + exit 0 +fi + menu_instructions="\ -The Arrow keys navigate the menu. \ +Arrow keys navigate the menu. \ Highlighted letters are hotkeys. \ -Press the to select an item. \ -Press to exit. \ -Press for Help. \ -(*) options will be compiled into the kernel. \ -(M) options will be modules. \ -< > marks module capable options." +Pressing includes a feature, excludes it, makes it modular. \ +Press to exit or for Help. \ +(*) shows built in features. \ +(M) shows modules. \ +< > features are module capable." radiolist_instructions="\ Use the arrow keys to navigate this window or \ @@ -1047,11 +1030,11 @@ Press for additional information about this option." inputbox_instructions_int="\ Please enter a decimal value between 1 and 9999. \ Fractions will not be accepted. \ -Use the key to move from the input field to buttons below it." +Use the key to move from the input field to the buttons below it." inputbox_instructions_hex="\ Please enter a hexidecimal value. \ -Use the key to move from the input field to buttons below it." +Use the key to move from the input field to the buttons below it." backtitle="Linux Kernel Configuration" diff --git a/scripts/README.Menuconfig b/scripts/README.Menuconfig index 6d880bef1092..410e0bd62a7c 100644 --- a/scripts/README.Menuconfig +++ b/scripts/README.Menuconfig @@ -3,25 +3,46 @@ lift. Featuring text based color menus and dialogs, it does not require X Windows. With this utility you can easily select a kernel option to modify without sifting through 100 other options. -Some Menuconfig keyboard hints: +Overview +-------- +Some kernel features may be built directly into the kernel. +Some may be made into loadable runtime modules. Some features +may be completely removed altogether. There are also certain +kernel parameters which are not really features, but must be +entered in as decimal or hexidecimal numbers or possibly text. + +Menu items beginning with (*), (M) or ( ) represent features +configured to be built in, modularized or removed respectively. +Pointed brackets <> represent module capable features. + more... + +To change any of these features, highlight it with the cursor +keys and press to build it in, to make it a module or + to removed it. (See keyboard hints below) + +Items beginning with numbers or other text within parenthesis can +be changed by highlighting the item and pressing . Then +enter the new parameter into the dialog box that pops up. + + +Some keyboard hints: Menus ---------- o Use the Up/Down arrow keys (cursor keys) to highlight the item - or submenu you wish to select. + you wish to change or submenu wish to select. Submenus are + designated by "--->". + Shortcut: Press the option's highlighted letter (hotkey). Pressing a hotkey more than once will sequence - through all items which use that hotkey. + through all visible items which use that hotkey. You may also use the and keys to scroll unseen options into view. -o Use the cursor keys to highlight and diff --git a/scripts/header.tk b/scripts/header.tk index d550355b87e1..1b53614298d2 100644 --- a/scripts/header.tk +++ b/scripts/header.tk @@ -204,7 +204,8 @@ proc write_tristate { file1 file2 varname variable dep } { puts $file2 "#undef $varname"} \ elseif { $variable == 2 || ($dep == 2 && $variable == 1) } \ then { puts $file1 "$varname=m"; \ - puts $file2 "#undef $varname" } \ + puts $file2 "#undef $varname"; \ + puts $file2 "#define $varname_MODULE 1" } \ elseif { $variable == 1 && $dep != 2 } \ then { puts $file1 "$varname=y"; \ puts $file2 "#define $varname 1" } \ diff --git a/scripts/lxdialog/menubox.c b/scripts/lxdialog/menubox.c index 0e6f1111ab4b..8a113f3c5ba1 100644 --- a/scripts/lxdialog/menubox.c +++ b/scripts/lxdialog/menubox.c @@ -197,19 +197,25 @@ dialog_menu (const char *title, const char *prompt, int height, int width, print_buttons (dialog, height, width, 0); while (key != ESC) { - key = wgetch (dialog); + key = wgetch(dialog); + if (isalpha(key)) key = tolower(key); + + if (strchr("ynm", key)) + i = max_choice; + else { for (i = choice+1; i < max_choice; i++) { j = first_alpha(items[(scroll+i)*2+1]); - if (toupper(key) == toupper(items[(scroll+i)*2+1][j])) + if (key == tolower(items[(scroll+i)*2+1][j])) break; } if (i == max_choice) for (i = 0; i < max_choice; i++) { j = first_alpha(items[(scroll+i)*2+1]); - if (toupper(key) == toupper(items[(scroll+i)*2+1][j])) + if (key == tolower(items[(scroll+i)*2+1][j])) break; } + } if (i < max_choice || key == KEY_UP || key == KEY_DOWN || @@ -302,30 +308,31 @@ dialog_menu (const char *title, const char *prompt, int height, int width, print_buttons(dialog, height, width, button); wrefresh (dialog); break; - case ' ': - case 'S': case 's': + case 'y': + case 'n': + case 'm': delwin (dialog); - fprintf(stderr, items[(scroll + choice) * 2]); + fprintf(stderr, "%s\n", items[(scroll + choice) * 2]); + if (key == 'y') return 3; + if (key == 'n') return 4; + if (key == 'm') return 5; return 0; - case 'H': case 'h': case '?': button = 2; case '\n': delwin (dialog); if (button == 2) - fprintf(stderr, "%s \"%s\"", + fprintf(stderr, "%s \"%s\"\n", items[(scroll + choice) * 2], items[(scroll + choice) * 2 + 1] + first_alpha(items[(scroll + choice) * 2 + 1])); else - fprintf(stderr, items[(scroll + choice) * 2]); + fprintf(stderr, "%s\n", items[(scroll + choice) * 2]); return button; - case 'E': case 'e': - case 'X': case 'x': key = ESC; case ESC: diff --git a/scripts/lxdialog/util.c b/scripts/lxdialog/util.c index 20c7402d8618..0cccd68b91f4 100644 --- a/scripts/lxdialog/util.c +++ b/scripts/lxdialog/util.c @@ -342,13 +342,16 @@ draw_shadow (WINDOW * win, int y, int x, int height, int width) int first_alpha(const char *string) { - int i, in_paren=0; + int i, in_paren=0, c; for (i = 0; i < strlen(string); i++) { - if (string[i] == '(') ++in_paren; - if (string[i] == ')') --in_paren; + c = tolower(string[i]); - if ((! in_paren) && isalpha(string[i])) + if (c == '(') ++in_paren; + if (c == ')') --in_paren; + + if ((! in_paren) && isalpha(c) && + strchr("nNyYmM", c) == 0) return i; } diff --git a/scripts/patch-kernel b/scripts/patch-kernel index f2c3dfe93e9d..2028efcbca3f 100644 --- a/scripts/patch-kernel +++ b/scripts/patch-kernel @@ -43,11 +43,11 @@ do echo "failed. Clean up yourself." break fi - if [ "`find $sourcedir -follow '(' -name '*.rej' -o -name '.*.rej' ')' -print`" ] + if [ "`find $sourcedir/ '(' -name '*.rej' -o -name '.*.rej' ')' -print`" ] then echo "Aborting. Reject files found." break fi # Remove backup files - find $sourcedir -follow '(' -name '*.orig' -o -name '.*.orig' ')' -print | xargs rm -f + find $sourcedir/ '(' -name '*.orig' -o -name '.*.orig' ')' -exec rm -f {} \; done -- 2.39.5