Commit b4dfb143 authored by Linus Torvalds's avatar Linus Torvalds

Import 1.3.89

parent ed6ac3a1
......@@ -187,6 +187,14 @@ S: 3674 Oakwood Terrace #201
S: Fremont, CA 94536
S: USA
N: Chih-Jen Chang
E: chihjenc@scf.usc.edu
E: chihjen@iis.sinica.edu.tw
D: IGMP(Internet Group Management Protocol) version 2
S: 3F, 65 Tajen street
S: Tamsui town, Taipei county,
S: Taiwan 251, Republic of China
N: Raymond Chen
E: raymondc@microsoft.com
D: Author of Configure script
......@@ -858,10 +866,12 @@ S: Derbyshire DE4 3RL
S: United Kingdom
N: Michael Neuffer
E: mike@i-Connect.Net
E: neuffer@goofy.zdv.uni-mainz.de
W: http://www.i-Connect.Net/~mike/
D: Developer and maintainer of the EATA-DMA SCSI driver
D: Co-developer EATA-PIO SCSI driver
D: Assorted other snippets
D: /proc/scsi and assorted other snippets
S: Zum Schiersteiner Grund 2
S: 55127 Mainz
S: Germany
......@@ -968,6 +978,13 @@ S: 59 Bugden Avenue
S: Gowrie ACT 2904
S: Australia
N: Gerard Roudier
E: groudier@iplus.fr
D: Contributed to asynchronous read-ahead improvement
S: 21 Rue Carnot
S: 95170 Deuil La Barre
S: France
N: Alessandro Rubini
E: rubini@ipvvis.unipv.it
D: the gpm mouse server and kernel support for it
......@@ -1006,6 +1023,15 @@ S: POB 64132
S: Sunnyvale, CA 94088-4132
S: USA
N: Simon Shapiro
E: shimon@i-Connect.Net
W: http://www.-i-Connect.Net/~shimon
D: SCSI debugging
D: Maintainer of the Debian Kernel packages
S: 14355 SW Allen Blvd., Suite #140
S: Beaverton, OR 97008
S: USA
N: Rick Sladkey
E: jrs@world.std.com
D: utility hacker: Emacs, NFS server, mount, kmem-ps, UPS debugger, strace, GDB
......@@ -1127,6 +1153,16 @@ S: 1 Amherst Street
S: Cambridge, Massachusetts 02139
S: USA
N: Tsu-Sheng Tsao
E: tsusheng@scf.usc.edu
D: IGMP(Internet Group Management Protocol) version 2
S: 2F 14 ALY 31 LN 166 SEC 1 SHIH-PEI RD
S: Taipei
S: Taiwan 112, Republic of China
S: 24335 Delta Drive
S: Diamond Bar, CA 91765
S: USA
N: Simmule Turner
E: sturner@tele-tv.com
D: Added swapping to filesystem
......@@ -1306,21 +1342,3 @@ D: Miscellaneous kernel fixes
S: 3078 Sulphur Spring Court
S: San Jose, California 95148
S: USA
N: Chih-Jen Chang
E: chihjenc@scf.usc.edu
E: chihjen@iis.sinica.edu.tw
D: IGMP(Internet Group Management Protocol) version 2
S: 3F, 65 Tajen street
S: Tamsui town, Taipei county,
S: Taiwan 251, Republic of China
N: Tsu-Sheng Tsao
E: tsusheng@scf.usc.edu
D: IGMP(Internet Group Management Protocol) version 2
S: 2F 14 ALY 31 LN 166 SEC 1 SHIH-PEI RD
S: Taipei
S: Taiwan 112, Republic of China
S: 24335 Delta Drive
S: Diamond Bar, CA 91765
S: USA
This diff is collapsed.
......@@ -1225,27 +1225,29 @@ DTC3180/3280 SCSI support
CONFIG_SCSI_DTC3280
This is support for DTC 3180/3280 SCSI Host Adaptors. It does not
use IRQ's. It does not support parity on the SCSI bus.
EATA-DMA (DPT,NEC&ATT for ISA,EISA,PCI) support
EATA-DMA (DPT, NEC, ATT, Olivetti for ISA, EISA, PCI) support
CONFIG_SCSI_EATA_DMA
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
drivers/scsi/eata_dma.h. 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.
This is support for the EATA-DMA protocol compliant SCSI Host Adaptors
like the SmartCache III/IV, SmartRAID controller families and the DPT
PM2011B and PM2012B controllers.
Please read the SCSI-HOWTO, available via ftp (user: anonymous) at
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.
EATA-PIO (old DPT PM2001, PM2012A) support
CONFIG_SCSI_EATA_PIO
This driver supports all EATA-PIO SCSI host adaptors. You might want
to have a look at the settings in drivers/scsi/eata_pio.h and at the
SCSI-HOWTO, available via ftp (user: anonymous) at
sunsite.unc.edu:/pub/Linux/docs/HOWTO. 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.
This driver supports all EATA-PIO protocol compliant SCSI Host Adaptors
like the DPT PM2001 and the PM2012A. EATA-DMA compliant HBAs can also use
this driver but are discuraged from doing so, since this driver only
supports harddisks and lacks numerous features.
You might want to have a look at the SCSI-HOWTO, available via ftp
(user: anonymous) at sunsite.unc.edu:/pub/Linux/docs/HOWTO.
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.
UltraStor 14F/34F support
CONFIG_SCSI_U14_34F
......@@ -3034,6 +3036,20 @@ CONFIG_SOFT_WATCHDOG
from some situations that the hardware watchdog will recover
from. Equally it's a lot cheaper to install.
Enhanced Real Time Clock Support
CONFIG_RTC
If you enable this option and create a character special file
/dev/rtc with major number 10 and minor number 135 using mknod
("man mknod"), you will get access to the real time clock built
into your computer. It can be used to generate signals from as
low as 1Hz up to 8192Hz, and can also be used as a 24 hour alarm.
It reports status information via the file /proc/rtc and its
behaviour is set by various ioctls on /dev/rtc. People running
SMP versions of Linux should enable this option to read and set
the RTC clock in a SMP compatible fashion. If you think you
have a use for such a device (such as periodic data sampling), then
say Y here, and go read the file Documentation/rtc.txt for details.
Sound card support
CONFIG_SOUND
If you have a Sound Card in your Computer, i.e. if it can say more
......@@ -3168,7 +3184,7 @@ CONFIG_ISDN_DRV_TELES
# LocalWords: pppd Zilog ZS soundcards SRM bootloader ez mainmenu rarp ipfwadm
# LocalWords: RTNETLINK mknod xos MTU lwared Macs mac netatalk macs cs Wolff
# LocalWords: dartmouth flowerpt MultiMaster FlashPoint tudelft etherexpress
# LocalWords: ICL EtherTeam ETH IDESCSI TXC dmesg httpd hlt sjc barlow dlp mtu
# LocalWords: ICL EtherTeam ETH IDESCSI TXC SmartRAID SmartCache
# LocalWords: thesphere TwoServers BOOTP DHCP ncpfs BPQETHER BPQ chipsets MG
# LocalWords: bsd comp Sparcstation le SunOS ie Gracilis PackeTwin PT pt LU FX
# LocalWords: FX TEAC SoundBlaster CR CreativeLabs LCS mS ramdisk IDETAPE cmd
......
Real Time Clock Driver for Linux
================================
All PCs (even Alpha machines) have a Real Time Clock built into them.
Usually they are built into the chipset of the computer, but some may
actually have a Motorola MC146818 (or clone) on the board. This is the
clock that keeps the date and time while your computer is turned off.
However it can also be used to generate signals from a slow 2Hz to a
relatively fast 8192Hz, in increments of powers of two. These signals
are reported by interrupt number 8. (Oh! So *thats* what IRQ 8 is
for...) It can also function as a 24hr alarm, raising IRQ 8 when the
alarm goes off. The alarm can also be programmed to only check any
subset of the three programmable values, meaning that it could be set to
ring on the 30th second of the 30th minute of every hour, for example.
The clock can also be set to generate an interrupt upon every clock
update, thus generating a 1Hz signal.
The interrupts are reported via /dev/rtc (major 10, minor 135, read only
character device) in the form of an unsigned long. The low byte contains
the type of interrupt (update-done, alarm-rang, or periodic) that was
raised, and the remaining bytes contain the number of interrupts since
the last read. Status information is reported through the pseudo-file
/proc/rtc if the /proc filesystem was enabled. The driver has built in
locking so that only one process is allowed to have the /dev/rtc
interface open at a time.
A user process can monitor these interrupts by doing a read(2) or a
select(2) on /dev/rtc -- either will block/stop the user process until
the next interrupt is received. This is useful for things like
reasonably high frequency data acquisition where one doesn't want to
burn up 100% CPU by polling gettimeofday etc. etc.
At high frequencies, or under high loads, the user process should check
the number of interrupts received since the last read to determine if
there has been any interrupt "pileup" so to speak. Just for reference, a
typical 486-33 running a tight read loop on /dev/rtc will start to suffer
occasional interrupt pileup (i.e. > 1 IRQ event since last read) for
frequencies above 1024Hz. So you really should check the high bytes
of the value you read, especially at frequencies above that of the
normal timer interrupt, which is 100Hz.
Programming and/or enabling interrupt frequencies greater than 64Hz is
only allowed by root. This is perhaps a bit conservative, but we don't want
an evil user generating lots of IRQs on a slow 386sx-16, where it might have
a negative impact on performance. Note that the interrupt handler is only
four lines of code to minimize any possibility of this effect.
The alarm and/or interrupt frequency are programmed into the RTC via
various ioctl(2) calls as listed in ./include/linux/mc146818rtc.h
Rather than write 50 pages describing the ioctl() and so on, it is
perhaps more useful to include a small test program that demonstrates
how to use them, and demonstrates the features of the driver. This is
probably a lot more useful to people interested in writing applications
that will be using this driver.
Paul Gortmaker
-------------------- 8< ---------------- 8< -----------------------------
/*
* Real Time Clock Driver Test/Example Program
*
* Compile with:
* gcc -s -Wall -Wstrict-prototypes rtctest.c -o rtctest
*
* Copyright (C) 1996, Paul Gortmaker.
*
* Released under the GNU General Public License, version 2,
* included herein by reference.
*
*/
#include <stdio.h>
#include <linux/mc146818rtc.h>
#include <sys/ioctl.h>
#include <sys/time.h>
#include <sys/types.h>
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
#include <time.h>
void main(void) {
int i, fd, retval, irqcount = 0;
unsigned long tmp, data;
struct tm rtc_tm;
fd = open ("/dev/rtc", O_RDONLY);
if (fd == -1) {
perror("/dev/rtc");
exit(errno);
}
fprintf(stderr, "\n\t\t\tRTC Driver Test Example.\n\n");
/* Turn on update interrupts (one per second) */
retval = ioctl(fd, RTC_UIE_ON, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "Counting 5 update (1/sec) interrupts from reading /dev/rtc:");
fflush(stderr);
for (i=1; i<6; i++) {
/* This read will block */
retval = read(fd, &data, sizeof(unsigned long));
if (retval == -1) {
perror("read");
exit(errno);
}
fprintf(stderr, " %d",i);
fflush(stderr);
irqcount++;
}
fprintf(stderr, "\nAgain, from using select(2) on /dev/rtc:");
fflush(stderr);
for (i=1; i<6; i++) {
struct timeval tv = {5, 0}; /* 5 second timeout on select */
struct fd_set readfds;
FD_ZERO(&readfds);
FD_SET(fd, &readfds);
/* The select will wait until an RTC interrupt happens. */
retval = select(fd+1, &readfds, NULL, NULL, &tv);
if (retval == -1) {
perror("select");
exit(errno);
}
/* This read won't block unlike the select-less case above. */
retval = read(fd, &data, sizeof(unsigned long));
if (retval == -1) {
perror("read");
exit(errno);
}
fprintf(stderr, " %d",i);
fflush(stderr);
irqcount++;
}
/* Turn off update interrupts */
retval = ioctl(fd, RTC_UIE_OFF, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
/* Read the RTC time/date */
retval = ioctl(fd, RTC_RD_TIME, &rtc_tm);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "\n\nCurrent RTC date/time is %d-%d-%d, %02d:%02d:%02d.\n",
rtc_tm.tm_mday, rtc_tm.tm_mon + 1, rtc_tm.tm_year + 1900,
rtc_tm.tm_hour, rtc_tm.tm_min, rtc_tm.tm_sec);
/* Set the alarm to 5 sec in the future, and check for rollover */
rtc_tm.tm_sec += 5;
if (rtc_tm.tm_sec >= 60) {
rtc_tm.tm_sec %= 60;
rtc_tm.tm_min++;
}
if (rtc_tm.tm_min == 60) {
rtc_tm.tm_min = 0;
rtc_tm.tm_hour++;
}
if (rtc_tm.tm_hour == 24)
rtc_tm.tm_hour = 0;
retval = ioctl(fd, RTC_ALM_SET, &rtc_tm);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
/* Read the current alarm settings */
retval = ioctl(fd, RTC_ALM_READ, &rtc_tm);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "Alarm time now set to %02d:%02d:%02d.\n",
rtc_tm.tm_hour, rtc_tm.tm_min, rtc_tm.tm_sec);
/* Enable alarm interrupts */
retval = ioctl(fd, RTC_AIE_ON, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "Waiting 5 seconds for alarm...");
fflush(stderr);
/* This blocks until the alarm ring causes an interrupt */
retval = read(fd, &data, sizeof(unsigned long));
if (retval == -1) {
perror("read");
exit(errno);
}
irqcount++;
fprintf(stderr, " okay. Alarm rang.\n");
/* Disable alarm interrupts */
retval = ioctl(fd, RTC_AIE_OFF, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
/* Read periodic IRQ rate */
retval = ioctl(fd, RTC_IRQP_READ, &tmp);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "\nPeriodic IRQ rate was %ldHz.\n", tmp);
fprintf(stderr, "Counting 20 interrupts at:");
fflush(stderr);
/* The frequencies 128Hz, 256Hz, ... 8192Hz are only allowed for root. */
for (tmp=2; tmp<=64; tmp*=2) {
retval = ioctl(fd, RTC_IRQP_SET, tmp);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
fprintf(stderr, "\n%ldHz:\t", tmp);
fflush(stderr);
/* Enable periodic interrupts */
retval = ioctl(fd, RTC_PIE_ON, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
for (i=1; i<21; i++) {
/* This blocks */
retval = read(fd, &data, sizeof(unsigned long));
if (retval == -1) {
perror("read");
exit(errno);
}
fprintf(stderr, " %d",i);
fflush(stderr);
irqcount++;
}
/* Disable periodic interrupts */
retval = ioctl(fd, RTC_PIE_OFF, 0);
if (retval == -1) {
perror("ioctl");
exit(errno);
}
}
fprintf(stderr, "\n\n\t\t\t *** Test complete ***\n");
fprintf(stderr, "\nTyping \"cat /proc/interrupts\" will show %d more events on IRQ 8.\n\n",
irqcount);
close(fd);
} /* end main */
......@@ -241,3 +241,5 @@ this must be done manually -- no autodetection mechanisms are available.
original version written by hhanemaa@cs.ruu.nl, patched by
Jeff Chua, rewritten by me).
- Screen store/restore fixed.
2.8 (14-Apr-96) - Previous release was not compilable without CONFIG_VIDEO_SVGA.
- Better recognition of text modes during mode scan.
......@@ -99,7 +99,19 @@ S: Maintained
BUSLOGIC SCSI DRIVER
P: Leonard N. Zubkoff
M: Leonard N. Zubkoff <lnz@dandelion.com>
L: None
L: linux-scsi@vger.rutgers.edu
S: Maintained
EATA-DMA SCSI DRIVER
P: Michael Neuffer
M: mike@i-Connect.Net
L: linux-scsi@vger.rutgers.edu
S: Maintained
EATA-PIO SCSI DRIVER
P: Michael Neuffer
M: mike@i-Connect.Net
L: linux-scsi@vger.rutgers.edu
S: Maintained
FRAME RELAY DLCI/FRAD (Sangoma drivers too)
......
VERSION = 1
PATCHLEVEL = 3
SUBLEVEL = 88
SUBLEVEL = 89
ARCH = i386
......@@ -328,9 +328,9 @@ mrproper: clean
distclean: mrproper
rm -f core `find . \( -name '*.orig' -o -name '*~' -o -name '*.bak' \
-o -name '#*#' -o -name '.*.orig' \) -print` TAGS
rm -f core `find . \( -name '*.orig' -o -name '*.rej' -o -name '*~' \
-o -name '*.bak' -o -name '#*#' -o -name '.*.orig' \
-o -name '.*.rej' -o -name '.SUMS' -o -size 0 \) -print` TAGS
backup: mrproper
cd .. && tar cf - linux/ | gzip -9 > backup.gz
......
......@@ -195,6 +195,7 @@ CONFIG_PSMOUSE=y
# CONFIG_FTAPE is not set
# CONFIG_APM is not set
# CONFIG_WATCHDOG is not set
# CONFIG_RTC is not set
#
# Sound
......
......@@ -62,7 +62,7 @@ void show_mem(void)
i = MAP_NR(high_memory);
while (i-- > 0) {
total++;
if (mem_map[i].reserved)
if (PageReserved(mem_map+i))
reserved++;
else if (!mem_map[i].count)
free++;
......@@ -121,7 +121,7 @@ unsigned long paging_init(unsigned long start_mem, unsigned long end_mem)
continue;
while (nr--)
mem_map[pfn++].reserved = 0;
clear_bit(PG_reserved, &mem_map[pfn++].flags);
}
/* unmap the console stuff: we don't need it, and we don't want it */
......@@ -152,14 +152,14 @@ void mem_init(unsigned long start_mem, unsigned long end_mem)
*/
tmp = KERNEL_START;
while (tmp < start_mem) {
mem_map[MAP_NR(tmp)].reserved = 1;
set_bit(PG_reserved, &mem_map[MAP_NR(tmp)].flags);
tmp += PAGE_SIZE;
}
for (tmp = PAGE_OFFSET ; tmp < high_memory ; tmp += PAGE_SIZE) {
if (tmp >= MAX_DMA_ADDRESS)
mem_map[MAP_NR(tmp)].dma = 0;
if (mem_map[MAP_NR(tmp)].reserved)
clear_bit(PG_DMA, &mem_map[MAP_NR(tmp)].flags);
if (PageReserved(mem_map+MAP_NR(tmp)))
continue;
mem_map[MAP_NR(tmp)].count = 1;
free_page(tmp);
......@@ -179,7 +179,7 @@ void si_meminfo(struct sysinfo *val)
val->freeram = nr_free_pages << PAGE_SHIFT;
val->bufferram = buffermem;
while (i-- > 0) {
if (mem_map[i].reserved)
if (PageReserved(mem_map+i))
continue;
val->totalram++;
if (!mem_map[i].count)
......
!
! Display adapter & video mode setup, version 2.7 (09-Apr-96)
! Display adapter & video mode setup, version 2.8 (14-Apr-96)
!
! Copyright (C) 1995, 1996 Martin Mares <mj@k332.feld.cvut.cz>
! Based on the original setup.S code (C) Linus Torvalds
......@@ -738,6 +738,19 @@ res1: ret
#endif /* CONFIG_VIDEO_RETAIN */
!
! Write to indexed VGA register (AL=index, AH=data, DX=index reg. port)
!
outidx: out dx,al
push ax
mov al,ah
inc dx
out dx,al
dec dx
pop ax
ret
!
! Build the table of video modes (stored after the setup.S code at the
! `modelist' label. Each video mode record looks like:
......@@ -947,7 +960,12 @@ scm1: mov ah,#0 ! Test the mode
call inidx
and al,#0x03
jnz scm2
mov dx,#0x3d4 ! Cursor location
mov dl,#0xce ! Another set of mode bits
mov al,#0x06
call inidx
shr al,#1
jc scm2
mov dl,#0xd4 ! Cursor location
mov al,#0x0f
call inidx
or al,al
......@@ -1117,14 +1135,7 @@ no_s3: movb al,#0x35 ! restore CRT register 0x35
no_s31: xor bp,bp ! Detection failed
s3rest: movb ah,bh
movb al,#0x38 ! restore old value of CRT register 0x38
outidx: out dx,al ! Write to indexed VGA register
push ax ! AL=index, AH=data, DX=index reg port
mov al,ah
inc dx
out dx,al
dec dx
pop ax
ret
br outidx
idS3: .byte 0x81, 0x82, 0x90, 0x91, 0x92, 0x93, 0x94, 0x95
.byte 0xa0, 0xa1, 0xa2, 0xa3, 0xa4, 0xa5, 0xa8, 0xb0
......
......@@ -156,6 +156,7 @@ CONFIG_SERIAL=y
# CONFIG_FTAPE is not set
# CONFIG_APM is not set
# CONFIG_WATCHDOG is not set
# CONFIG_RTC is not set
#
# Sound
......
......@@ -199,7 +199,6 @@ void setup_arch(char **cmdline_p,
/* request io space for devices used on all i[345]86 PC'S */
request_region(0x00,0x20,"dma1");
request_region(0x40,0x20,"timer");
request_region(0x70,0x10,"rtc");
request_region(0x80,0x20,"dma page reg");
request_region(0xc0,0x20,"dma2");
request_region(0xf0,0x10,"npu");
......
......@@ -1808,7 +1808,7 @@ static void ide_release(struct inode * inode, struct file * file)
ide_drive_t *drive;
if ((drive = get_info_ptr(inode->i_rdev)) != NULL) {
sync_dev(inode->i_rdev);
fsync_dev(inode->i_rdev);
drive->usage--;
#ifdef CONFIG_BLK_DEV_IDECD
if (drive->media == ide_cdrom) {
......@@ -1822,7 +1822,7 @@ static void ide_release(struct inode * inode, struct file * file)
return;
}
#endif /* CONFIG_BLK_DEV_IDETAPE */
if (drive->removable) {
if (drive->removable && !drive->usage) {
byte door_unlock[] = {WIN_DOORUNLOCK,0,0,0};
struct request rq;
invalidate_buffers(inode->i_rdev);
......
......@@ -346,7 +346,9 @@ static void make_request(int major,int rw, struct buffer_head * bh)
cli();
req = blk_dev[major].current_request;
if (!req) {
plug_device(blk_dev + major);
/* MD and loop can't handle plugging without deadlocking */
if (major != MD_MAJOR && major != LOOP_MAJOR)
plug_device(blk_dev + major);
} else switch (major) {
case IDE0_MAJOR: /* same as HD_MAJOR */
case IDE1_MAJOR:
......
......@@ -59,4 +59,5 @@ if [ "$CONFIG_WATCHDOG" != "n" ]; then
bool ' Software Watchdog' CONFIG_SOFT_WATCHDOG
fi
fi
bool 'Enhanced Real Time Clock Support' CONFIG_RTC
endmenu
......@@ -125,6 +125,11 @@ else
endif
endif
ifeq ($(CONFIG_RTC),y)
M = y
L_OBJS += rtc.o
endif
ifdef CONFIG_QIC02_TAPE
L_OBJS += tpqic02.o
endif
......
......@@ -390,7 +390,7 @@ int chr_dev_init(void)
#if defined (CONFIG_BUSMOUSE) || defined(CONFIG_UMISC) || \
defined (CONFIG_PSMOUSE) || defined (CONFIG_MS_BUSMOUSE) || \
defined (CONFIG_ATIXL_BUSMOUSE) || defined(CONFIG_SOFT_WATCHDOG) || \
defined (CONFIG_APM)
defined (CONFIG_APM) || defined (CONFIG_RTC)
misc_init();
#endif
#ifdef CONFIG_SOUND
......
......@@ -66,6 +66,7 @@ extern int psaux_init(void);
extern int ms_bus_mouse_init(void);
extern int atixl_busmouse_init(void);
extern void watchdog_init(void);
extern int rtc_init(void);
#ifdef CONFIG_PROC_FS
static int proc_misc_read(char *buf, char **start, off_t offset, int len, int unused)
......@@ -210,6 +211,9 @@ int misc_init(void)
#ifdef CONFIG_APM
apm_bios_init();
#endif
#ifdef CONFIG_RTC
rtc_init();
#endif
#endif /* !MODULE */
if (register_chrdev(MISC_MAJOR,"misc",&misc_fops)) {
printk("unable to get major %d for misc devices\n",
......
This diff is collapsed.
......@@ -5,10 +5,21 @@
* interfaces. Requires 'dlcicfg' program to create usable
* interfaces, the initial one, 'dlci' is for IOCTL use only.
*
* Version: @(#)dlci.c 0.15 31 Mar 1996
* Version: @(#)dlci.c 0.20 13 Apr 1996
*
* Author: Mike McLagan <mike.mclagan@linux.org>
*
* Changes:
*
* 0.15 Mike Mclagan Packet freeing, bug in kmalloc call
* DLCI_RET handling
*
* 0.20 Mike McLagan More conservative on which packets
* are returned for retry and whic are
* are dropped. If DLCI_RET_DROP is
* returned from the FRAD, the packet is
* sent back to Linux for re-transmission
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
......@@ -41,7 +52,7 @@
#include <net/sock.h>
static const char *devname = "dlci";
static const char *version = "DLCI driver v0.15, 31 Mar 1996, mike.mclagan@linux.org";
static const char *version = "DLCI driver v0.20, 13 Apr 1996, mike.mclagan@linux.org";
static struct device *open_dev[CONFIG_DLCI_COUNT];
......@@ -240,20 +251,26 @@ static int dlci_transmit(struct sk_buff *skb, struct device *dev)
{
case DLCI_RET_OK:
dlp->stats.tx_packets++;
ret = 0;
break;
case DLCI_RET_ERR:
dlp->stats.tx_errors++;
ret = 0;
break;
case DLCI_RET_DROP:
dlp->stats.tx_dropped++;
ret = 1;
break;
}
/* Alan Cox recommends always returning 0, and always freeing the packet */
ret = 0;
dev_kfree_skb(skb, FREE_WRITE);
/* experience suggest a slightly more conservative approach */
if (!ret)
dev_kfree_skb(skb, FREE_WRITE);
dev->tbusy = 0;
}
......@@ -406,6 +423,10 @@ int dlci_config(struct device *dev, struct dlci_conf *conf, int get)
if (!get)
{
err = verify_area(VERIFY_READ, conf, sizeof(struct dlci_conf));
if (err)
return(err);
memcpy_fromfs(&config, conf, sizeof(struct dlci_conf));
if (config.flags & ~DLCI_VALID_FLAGS)
return(-EINVAL);
......@@ -418,7 +439,13 @@ int dlci_config(struct device *dev, struct dlci_conf *conf, int get)
return(err);
if (get)
{
err = verify_area(VERIFY_WRITE, conf, sizeof(struct dlci_conf));
if (err)
return(err);
memcpy_tofs(conf, &dlp->config, sizeof(struct dlci_conf));
}
return(0);
}
......
This diff is collapsed.
......@@ -21,7 +21,7 @@ static char *version =
/* A few user-configurable values. */
/* Default to using non-10baseT (i.e. AUI/10base2/100baseT port) port. */
/* Default to using 10baseT (i.e. non-AUI/10base2/100baseT port) port. */
#define TULIP_10TP_PORT 0
#define TULIP_100TP_PORT 1
#define TULIP_AUI_PORT 1
......@@ -561,10 +561,26 @@ static void
generic21040_select(struct device *dev)
{
int ioaddr = dev->base_addr;
const char *if_port;
dev->if_port &= 3;
printk("%s: enabling %s port.\n",
dev->name, dev->if_port ? "AUI":"10baseT");
switch (dev->if_port)
{
case TULIP_10TP_PORT:
if_port = "10baseT";
break;
case TULIP_100TP_PORT:
/* TULIP_AUI_PORT is the same as TULIP_100TP_PORT. */
if_port = "100baseT/AUI";
break;
case TULIP_BNC_PORT:
if_port = "BNC";
break;
default:
if_port = "unknown type";
break;
}
printk("%s: enabling %s port.\n", dev->name, if_port);
/* Set the full duplex match frame. */
tio_write(FULL_DUPLEX_MAGIC, CSR11);
tio_write(TSIAC_RESET, CSR13);
......
......@@ -125,10 +125,10 @@ struct wic_local {
enum wic_nibble_state nibble;
union {
struct {
#if defined(LITTLE_ENDIAN)
#if defined(__LITTLE_ENDIAN)
unsigned char lsb;
unsigned char msb;
#elif defined(BIG_ENDIAN)
#elif defined(__BIG_ENDIAN)
unsigned char msb;
unsigned char lsb;
#else
......
This diff is collapsed.
This diff is collapsed.
Sat Apr 13 13:58:00 1996 Leonard N. Zubkoff <lnz@dandelion.com>
* BusLogic Driver Version 1.3.2 Released.
Sun Dec 31 23:26:00 1995 Leonard N. Zubkoff <lnz@dandelion.com>
* BusLogic Driver Version 1.3.1 Released.
......
This diff is collapsed.
ANNOUNCEMENT
BusLogic FlashPoint/BT-948 Upgrade Program
1 February 1996
Ever since its introduction last October, the BusLogic FlashPoint LT has
been problematic for members of the Linux community, in that no Linux
drivers have been available for this new Ultra SCSI product. Despite it's
officially being positioned as a desktop workstation product, and not being
particularly well suited for a high performance multitasking operating
system like Linux, the FlashPoint LT has been touted by computer system
vendors as the latest thing, and has been sold even on many of their high
end systems, to the exclusion of the older MultiMaster products. This has
caused grief for many people who inadvertently purchased a system expecting
that all BusLogic SCSI Host Adapters were supported by Linux, only to
discover that the FlashPoint was not supported and would not be for quite
some time, if ever.
After this problem was identified, BusLogic contacted its major OEM
customers to make sure the BT-946C/956C MultiMaster cards would still be
made available, and that Linux users who mistakenly ordered systems with
the FlashPoint would be able to upgrade to the BT-946C. While this helped
many purchasers of new systems, it was only a partial solution to the
overall problem of FlashPoint support for Linux users. It did nothing to
assist the people who initially purchased a FlashPoint for a supported
operating system and then later decided to run Linux, or those who had
ended up with a FlashPoint LT, believing it was supported, and were unable
to return it.
In the middle of December, I asked to meet with BusLogic's senior
management to discuss the issues related to Linux and free software support
for the FlashPoint. Rumors of varying accuracy had been circulating
publicly about BusLogic's attitude toward the Linux community, and I felt
it was best that these issues be addressed directly. I sent an email
message after 11pm one evening, and the meeting took place the next
afternoon. Unfortunately, corporate wheels sometimes grind slowly,
especially when a company is being acquired, and so it's taken until now
before the details were completely determined and a public statement could
be made.
BusLogic is not prepared at this time to release the information necessary
for third parties to write drivers for the FlashPoint. The only existing
FlashPoint drivers have been written directly by BusLogic Engineering, and
there is no FlashPoint documentation sufficiently detailed to allow outside
developers to write a driver without substantial assistance. While there
are people at BusLogic who would rather not release the details of the
FlashPoint architecture at all, that debate has not yet been settled either
way. In any event, even if documentation were available today it would
take quite a while for a usable driver to be written, especially since I'm
not convinced that the effort required would be worthwhile.
However, BusLogic does remain committed to providing a high performance
SCSI solution for the Linux community, and does not want to see anyone left
unable to run Linux because they have a Flashpoint LT. Therefore, BusLogic
has put in place a direct upgrade program to allow any Linux user worldwide
to trade in their FlashPoint LT for the new BT-948 MultiMaster PCI Ultra
SCSI Host Adapter. The BT-948 is the Ultra SCSI successor to the BT-946C
and has all the best features of both the BT-946C and FlashPoint LT,
including smart termination and a flash PROM for easy firmware updates, and
is of course compatible with the present Linux driver. The price for this
upgrade has been set at US $45, and the upgrade program will be
administered through BusLogic Technical Support, which can be reached by
electronic mail at techsup@buslogic.com, by Voice at +1 408 654-0760, or by
FAX at +1 408 492-1542.
I was a beta test site for the BT-948 and versions 1.2.1 and 1.3.1 of my
BusLogic driver already include latent support for the BT-948. Additional
cosmetic support for the Ultra SCSI MultiMaster cards will be added in a
subsequent release. As a result of this cooperative testing process,
several firmware bugs were found and corrected (make sure you have firmware
version 5.05R or later). My heavily loaded Linux test system provided an
ideal environment for testing error recovery processes that are much more
rarely exercised in production systems, but are crucial to overall system
stability. It was especially convenient being able to work directly with
their firmware engineer in demonstrating the problems under control of the
firmware debugging environment; things sure have come a long way since the
last time I worked on firmware for an embedded system. I am presently
working on some performance testing and expect to have some data to report
in the not too distant future.
BusLogic asked me to send this announcement since a large percentage of the
questions regarding support for the FlashPoint have either been sent to me
directly via email, or have appeared in the Linux newsgroups in which I
participate. To summarize, BusLogic is offering Linux users an upgrade
from the unsupported FlashPoint LT (BT-930) to the supported BT-948 for US
$45. Contact BusLogic Technical Support at techsup@buslogic.com or +1 408
654-0760 to take advantage of their offer.
Leonard N. Zubkoff
lnz@dandelion.com
......@@ -1179,7 +1179,7 @@ int aha1542_abort(Scsi_Cmnd * SCpnt)
For a first go, we assume that the 1542 notifies us with all of the
pending commands (it does implement soft reset, after all). */
int aha1542_reset(Scsi_Cmnd * SCpnt)
int aha1542_reset(Scsi_Cmnd * SCpnt, unsigned int reset_flags)
{
unchar ahacmd = CMD_START_SCSI;
int i;
......@@ -1187,7 +1187,7 @@ int aha1542_reset(Scsi_Cmnd * SCpnt)
/*
* See if a bus reset was suggested.
*/
if( SCpnt->host->suggest_bus_reset )
if( reset_flags & SCSI_RESET_SUGGEST_BUS_RESET )
{
/*
* This does a scsi reset for all devices on the bus.
......
......@@ -134,7 +134,7 @@ int aha1542_detect(Scsi_Host_Template *);
int aha1542_command(Scsi_Cmnd *);
int aha1542_queuecommand(Scsi_Cmnd *, void (*done)(Scsi_Cmnd *));
int aha1542_abort(Scsi_Cmnd *);
int aha1542_reset(Scsi_Cmnd *);
int aha1542_reset(Scsi_Cmnd *, unsigned int);
int aha1542_biosparam(Disk *, kdev_t, int*);
#define AHA1542_MAILBOXES 8
......
......@@ -122,13 +122,15 @@ static void internal_setup(int board, char *str, int *ints) {
static int commandline_current = 0;
switch (board) {
case BOARD_NCR5380:
if (ints[0] != 2 && ints[0] != 3)
if (ints[0] != 2 && ints[0] != 3) {
printk("generic_NCR5380_setup : usage ncr5380=" STRVAL(NCR5380_map_name) ",irq,dma\n");
return;
return;
}
case BOARD_NCR53C400:
if (ints[0] != 2)
printk("generic_NCR53C400_setup : usage ncr53c400= " STRVAL(NCR5380_map_name) ",irq\n");
return;
if (ints[0] != 2) {
printk("generic_NCR53C400_setup : usage ncr53c400=" STRVAL(NCR5380_map_name) ",irq\n");
return;
}
}
if (commandline_current < NO_OVERRIDES) {
......
......@@ -333,6 +333,9 @@ struct Scsi_Host * scsi_register(Scsi_Host_Template * tpnt, int j){
retval->cmd_per_lun = tpnt->cmd_per_lun;
retval->unchecked_isa_dma = tpnt->unchecked_isa_dma;
retval->use_clustering = tpnt->use_clustering;
retval->select_queue_depths = NULL;
if(!scsi_hostlist)
scsi_hostlist = retval;
else
......
......@@ -156,7 +156,7 @@ typedef struct SHT
* and these hosts must call scsi_request_sense(SCpnt) to keep
* the command alive.
*/
int (* reset)(Scsi_Cmnd *);
int (* reset)(Scsi_Cmnd *, unsigned int);
/*
* This function is used to select synchronous communications,
......@@ -246,7 +246,7 @@ struct Scsi_Host
char host_no; /* Used for IOCTL_GET_IDLUN, /proc/scsi et al. */
int last_reset;
struct wait_queue *host_wait;
Scsi_Cmnd *host_queue;
Scsi_Cmnd *host_queue;
Scsi_Host_Template * hostt;
/*
......@@ -298,13 +298,9 @@ struct Scsi_Host
* True if this host was loaded as a loadable module
*/
unsigned loaded_as_module:1;
/*
* True when we call the low-level reset function, and
* the midlevel code suggests a full bus reset.
*/
unsigned suggest_bus_reset:1;
void (*select_queue_depths)(struct Scsi_Host *, Scsi_Device *);
unsigned long hostdata[0]; /* Used for storage of host specific stuff */
};
......
This diff is collapsed.
......@@ -163,6 +163,7 @@ typedef struct scsi_device {
struct Scsi_Host * host;
void (*scsi_request_fn)(void); /* Used to jumpstart things after an
* ioctl */
struct scsi_cmnd *device_queue; /* queue of SCSI Command structures */
void *hostdata; /* available to low-level driver */
char type;
char scsi_level;
......@@ -170,6 +171,7 @@ typedef struct scsi_device {
unsigned char current_tag; /* current tag */
unsigned char sync_min_period; /* Not less than this period */
unsigned char sync_max_offset; /* Not greater than this offset */
unsigned char queue_depth; /* How deep a queue to use */
unsigned writeable:1;
unsigned removable:1;
......@@ -186,11 +188,12 @@ typedef struct scsi_device {
unsigned soft_reset:1; /* Uses soft reset option */
unsigned sync:1; /* Negotiate for sync transfers */
unsigned single_lun:1; /* Indicates we should only allow I/O to
one of the luns for the device at a time. */
unsigned was_reset:1; /* There was a bus reset on the bus for this
device */
unsigned expecting_cc_ua:1; /* Expecting a CHECK_CONDITION/UNIT_ATTN
because we did a bus reset. */
* one of the luns for the device at a
* time. */
unsigned was_reset:1; /* There was a bus reset on the bus for
* this device */
unsigned expecting_cc_ua:1; /* Expecting a CHECK_CONDITION/UNIT_ATTN
* because we did a bus reset. */
} Scsi_Device;
/*
......@@ -304,8 +307,16 @@ struct scatterlist {
* should keep the command alive. */
#define SCSI_RESET_WAKEUP 4
/* The command is not active in the low level code. Command probably
finished. */
#define SCSI_RESET_NOT_RUNNING 5
/* Something went wrong, and we do not know how to fix it. */
#define SCSI_RESET_ERROR 5
#define SCSI_RESET_ERROR 6
#define SCSI_RESET_SYNCHRONOUS 0x01
#define SCSI_RESET_ASYNCHRONOUS 0x02
#define SCSI_RESET_SUGGEST_BUS_RESET 0x04
/*
* This is a bitmask that is ored with one of the above codes.
......@@ -347,7 +358,7 @@ typedef struct scsi_cmnd {
unsigned char target, lun, channel;
unsigned char cmd_len;
unsigned char old_cmd_len;
struct scsi_cmnd *next, *prev;
struct scsi_cmnd *next, *prev, *device_next, *reset_chain;
/* These elements define the operation we are about to perform */
unsigned char cmnd[12];
......@@ -378,6 +389,22 @@ typedef struct scsi_cmnd {
unsigned char sense_buffer[16]; /* Sense for this command, if needed */
/*
A SCSI Command is assigned a nonzero serial_number when internal_cmnd
passes it to the driver's queue command function. The serial_number
is cleared when scsi_done is entered indicating that the command has
been completed. If a timeout occurs, the serial number at the moment
of timeout is copied into serial_number_at_timeout. By subseuqently
comparing the serial_number and serial_number_at_timeout fields
during abort or reset processing, we can detect whether the command
has already completed. This also detects cases where the command has
completed and the SCSI Command structure has already being reused
for another command, so that we can avoid incorrectly aborting or
resetting the new command.
*/
unsigned long serial_number;
unsigned long serial_number_at_timeout;
int retries;
int allowed;
......@@ -428,7 +455,7 @@ typedef struct scsi_cmnd {
* DID_ABORT is returned in the hostbyte.
*/
extern int scsi_abort (Scsi_Cmnd *, int code, int pid);
extern int scsi_abort (Scsi_Cmnd *, int code);
extern void scsi_do_cmd (Scsi_Cmnd *, const void *cmnd ,
void *buffer, unsigned bufflen,
......@@ -439,7 +466,7 @@ extern void scsi_do_cmd (Scsi_Cmnd *, const void *cmnd ,
extern Scsi_Cmnd * allocate_device(struct request **, Scsi_Device *, int);
extern Scsi_Cmnd * request_queueable(struct request *, Scsi_Device *);
extern int scsi_reset (Scsi_Cmnd *, int);
extern int scsi_reset (Scsi_Cmnd *, unsigned int);
extern int max_scsi_hosts;
......
......@@ -56,8 +56,8 @@
* Time out in seconds for disks and Magneto-opticals (which are slower).
*/
#define SD_TIMEOUT (7 * HZ)
#define SD_MOD_TIMEOUT (8 * HZ)
#define SD_TIMEOUT (15 * HZ)
#define SD_MOD_TIMEOUT (15 * HZ)
#define CLUSTERABLE_DEVICE(SC) (SC->host->use_clustering && \
SC->device->type != TYPE_MOD)
......
......@@ -170,13 +170,13 @@ sound_ioctl (inode_handle * inode, file_handle * file,
len = _IOC_SIZE (cmd);
if (_IOC_DIR (cmd) == _IOC_WRITE)
if (_IOC_DIR (cmd) & _IOC_WRITE)
{
if ((err = verify_area (VERIFY_READ, (void *) arg, len)) < 0)
return err;
}
if (_IOC_DIR (cmd) == _IOC_READ)
if (_IOC_DIR (cmd) & _IOC_READ)
{
if ((err = verify_area (VERIFY_WRITE, (void *) arg, len)) < 0)
return err;
......
......@@ -964,16 +964,17 @@ static int elf_core_dump(long signr, struct pt_regs * regs)
segs = 0;
size = 0;
for(vma = current->mm->mmap; vma != NULL; vma = vma->vm_next) {
int sz = vma->vm_end-vma->vm_start;
if (maydump(vma))
{
int sz = vma->vm_end-vma->vm_start;
if (!maydump(vma))
continue;
if (size+sz > limit)
break;
if (size+sz >= limit)
break;
else
size += sz;
}
segs++;
size += sz;
}
#ifdef DEBUG
printk("elf_core_dump: %d segs taking %d bytes\n", segs, size);
......@@ -1152,8 +1153,6 @@ static int elf_core_dump(long signr, struct pt_regs * regs)
struct elf_phdr phdr;
size_t sz;
if (!maydump(vma))
continue;
i++;
sz = vma->vm_end - vma->vm_start;
......@@ -1162,9 +1161,9 @@ static int elf_core_dump(long signr, struct pt_regs * regs)
phdr.p_offset = offset;
phdr.p_vaddr = vma->vm_start;
phdr.p_paddr = 0;
phdr.p_filesz = sz;
phdr.p_filesz = maydump(vma) ? sz : 0;
phdr.p_memsz = sz;
offset += sz;
offset += phdr.p_filesz;
phdr.p_flags = vma->vm_flags & VM_READ ? PF_R : 0;
if (vma->vm_flags & VM_WRITE) phdr.p_flags |= PF_W;
if (vma->vm_flags & VM_EXEC) phdr.p_flags |= PF_X;
......
......@@ -1818,9 +1818,11 @@ struct wait_queue * bdflush_done = NULL;
static void wakeup_bdflush(int wait)
{
run_task_queue(&tq_disk);
wake_up(&bdflush_wait);
if(wait) sleep_on(&bdflush_done);
if (wait) {
run_task_queue(&tq_disk);
sleep_on(&bdflush_done);
}
}
......
......@@ -507,6 +507,7 @@ char * get_rock_ridge_symlink(struct inode * inode)
if(slen < 2) break;
if(!rootflag) strcat(rpnt,"/");
};
break;
case SIG('C','E'):
CHECK_CE; /* This tells is if there is a continuation record */
break;
......
......@@ -861,26 +861,29 @@ static void locks_insert_lock(struct file_lock **pos, struct file_lock *fl)
static void locks_delete_lock(struct file_lock **fl_p, unsigned int wait)
{
struct file_lock *fl;
struct file_lock *bfl;
struct file_lock *pfl;
struct file_lock *nfl;
fl = *fl_p;
*fl_p = (*fl_p)->fl_next;
*fl_p = fl->fl_next;
pfl = fl->fl_prevlink;
nfl = fl->fl_nextlink;
if (fl->fl_nextlink != NULL)
fl->fl_nextlink->fl_prevlink = fl->fl_prevlink;
if (nfl != NULL)
nfl->fl_prevlink = pfl;
if (fl->fl_prevlink != NULL)
fl->fl_prevlink->fl_nextlink = fl->fl_nextlink;
if (pfl != NULL)
pfl->fl_nextlink = nfl;
else {
file_lock_table = fl->fl_nextlink;
file_lock_table = nfl;
}
while ((bfl = fl->fl_block) != NULL) {
fl->fl_block = bfl->fl_block;
bfl->fl_block = NULL;
wake_up(&bfl->fl_wait);
while ((nfl = fl->fl_block) != NULL) {
fl->fl_block = nfl->fl_block;
nfl->fl_block = NULL;
wake_up(&nfl->fl_wait);
if (wait)
sleep_on(&bfl->fl_wait);
sleep_on(&nfl->fl_wait);
}
wake_up(&fl->fl_wait);
......
......@@ -388,7 +388,8 @@ int open_namei(const char * pathname, int flag, int mode,
/* SunOS, Solaris 2.x and HPUX all deny open() on
* an existing file with mandatory locks.
*/
if ((error = locks_verify_locked(inode)) != 0) {
error = locks_verify_locked(inode);
if (error) {
iput(inode);
return error;
}
......@@ -443,7 +444,8 @@ int open_namei(const char * pathname, int flag, int mode,
* here. Only O_TRUNC calls can modify the file contents -
* but none of the commercial OS'es seem to do it this way.
*/
if ((error = locks_verify_locked(inode)) != 0) {
error = locks_verify_locked(inode);
if (error) {
iput(inode);
return error;
}
......
......@@ -25,6 +25,7 @@
#include <linux/errno.h>
#include <linux/locks.h>
#include <linux/smp.h>
#include <linux/smp_lock.h>
#include <asm/system.h>
#include <asm/segment.h>
......
......@@ -959,6 +959,7 @@ extern int get_dma_list(char *);
extern int get_cpuinfo(char *);
extern int get_pci_list(char*);
extern int get_md_status (char *);
extern int get_rtc_status (char *);
#ifdef __SMP_PROF__
extern int get_smp_prof_list(char *);
#endif
......@@ -1029,6 +1030,10 @@ static int get_root_array(char * page, int type, char **start, off_t offset, int
case PROC_MTAB:
return get_filesystem_info( page );
#ifdef CONFIG_RTC
case PROC_RTC:
return get_rtc_status(page);
#endif
}
return -EBADF;
}
......
......@@ -352,6 +352,12 @@ void proc_root_init(void)
PROC_CMDLINE, 7, "cmdline",
S_IFREG | S_IRUGO, 1, 0, 0,
});
#ifdef CONFIG_RTC
proc_register(&proc_root, &(struct proc_dir_entry) {
PROC_RTC, 3, "rtc",
S_IFREG | S_IRUGO, 1, 0, 0,
});
#endif
proc_register( &proc_root, &(struct proc_dir_entry)
{ PROC_MTAB, 6, "mounts", S_IFREG | S_IRUGO, 1, 0, 0, } );
......
......@@ -8,6 +8,9 @@
* - mount systemcall
* - umount systemcall
*
* Added options to /proc/mounts
* Torbjrn Lindh (torbjorn.lindh@gopta.se), April 14, 1996.
*
* GK 2/5/95 - Changed to support mounting the root fs via NFS
*
* Added kerneld support: Jacques Gelinas and Bjorn Ekwall
......@@ -36,9 +39,9 @@
#include <linux/kerneld.h>
#endif
#ifdef CONFIG_ROOT_NFS
#include <linux/nfs_fs.h>
#endif
#include <linux/nfs_fs_sb.h>
#include <linux/nfs_mount.h>
extern void wait_for_keypress(void);
extern struct file_operations * get_blkfops(unsigned int major);
......@@ -263,16 +266,94 @@ asmlinkage int sys_sysfs(int option, ...)
return retval;
}
static struct proc_fs_info {
int flag;
char *str;
} fs_info[] = {
{ MS_NOEXEC, ",noexec" },
{ MS_NOSUID, ",nosuid" },
{ MS_NODEV, ",nodev" },
{ MS_SYNCHRONOUS, ",sync" },
#ifdef MS_NOSUB /* Can't find this except in mount.c */
{ MS_NOSUB, ",nosub" },
#endif
{ 0, NULL }
};
static struct proc_nfs_info {
int flag;
char *str;
} nfs_info[] = {
{ NFS_MOUNT_SOFT, ",soft" },
{ NFS_MOUNT_INTR, ",intr" },
{ NFS_MOUNT_POSIX, ",posix" },
{ NFS_MOUNT_NOCTO, ",nocto" },
{ NFS_MOUNT_NOAC, ",noac" },
{ 0, NULL }
};
int get_filesystem_info( char *buf )
{
struct vfsmount *tmp = vfsmntlist;
struct proc_fs_info *fs_infop;
struct proc_nfs_info *nfs_infop;
struct nfs_server *nfss;
int len = 0;
while ( tmp && len < PAGE_SIZE - 80 )
while ( tmp && len < PAGE_SIZE - 160)
{
len += sprintf( buf + len, "%s %s %s %s",
tmp->mnt_devname, tmp->mnt_dirname, tmp->mnt_sb->s_type->name,
tmp->mnt_flags & MS_RDONLY ? "ro" : "rw" );
for (fs_infop = fs_info; fs_infop->flag; fs_infop++) {
if (tmp->mnt_flags & fs_infop->flag) {
strcpy(buf + len, fs_infop->str);
len += strlen(fs_infop->str);
}
}
if (!strcmp("nfs", tmp->mnt_sb->s_type->name)) {
nfss = &tmp->mnt_sb->u.nfs_sb.s_server;
if (nfss->rsize != NFS_DEF_FILE_IO_BUFFER_SIZE) {
len += sprintf(buf+len, ",rsize=%d",
nfss->rsize);
}
if (nfss->wsize != NFS_DEF_FILE_IO_BUFFER_SIZE) {
len += sprintf(buf+len, ",wsize=%d",
nfss->wsize);
}
if (nfss->timeo != 7*HZ/10) {
len += sprintf(buf+len, ",timeo=%d",
nfss->timeo*10/HZ);
}
if (nfss->retrans != 3) {
len += sprintf(buf+len, ",retrans=%d",
nfss->retrans);
}
if (nfss->acregmin != 3*HZ) {
len += sprintf(buf+len, ",acregmin=%d",
nfss->acregmin/HZ);
}
if (nfss->acregmax != 60*HZ) {
len += sprintf(buf+len, ",acregmax=%d",
nfss->acregmax/HZ);
}
if (nfss->acdirmin != 30*HZ) {
len += sprintf(buf+len, ",acdirmin=%d",
nfss->acdirmin/HZ);
}
if (nfss->acdirmax != 60*HZ) {
len += sprintf(buf+len, ",acdirmax=%d",
nfss->acdirmax/HZ);
}
for (nfs_infop = nfs_info; nfs_infop->flag; nfs_infop++) {
if (nfss->flags & nfs_infop->flag) {
strcpy(buf + len, nfs_infop->str);
len += strlen(nfs_infop->str);
}
}
len += sprintf(buf+len, ",addr=%s",
nfss->hostname);
}
len += sprintf( buf + len, " 0 0\n" );
tmp = tmp->mnt_next;
}
......
......@@ -27,7 +27,7 @@
* in linux/version.h, and should only be used by linux/version.c
*/
/* Don't touch these, unless you really know what your doing. */
/* Don't touch these, unless you really know what you're doing. */
#define DEF_INITSEG 0x9000
#define DEF_SYSSEG 0x1000
#define DEF_SETUPSEG 0x9020
......
......@@ -320,7 +320,7 @@ struct file {
loff_t f_pos;
unsigned short f_flags;
unsigned short f_count;
unsigned long f_reada, f_ramax, f_rapos, f_ralen;
unsigned long f_reada, f_ramax, f_rapos, f_ralen, f_rawin;
struct file *f_next, *f_prev;
int f_owner; /* pid or -pgrp where SIGIO should be sent */
struct inode * f_inode;
......
......@@ -10,6 +10,11 @@
*
* Author: Mike McLagan <mike.mclagan@linux.org>
*
* Changes:
* 0.15 Mike McLagan changed structure defs (packed)
* re-arranged flags
* added DLCI_RET vars
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
......
......@@ -106,4 +106,22 @@ outb_p((val),RTC_PORT(1)); \
#define BIN_TO_BCD(val) ((val)=(((val)/10)<<4) + (val)%10)
#endif
/*
* ioctl calls that are permitted to the /dev/rtc interface, if
* CONFIG_RTC was enabled.
*/
#define RTC_AIE_ON 0x01 /* Alarm int. enable on */
#define RTC_AIE_OFF 0x02 /* ... off */
#define RTC_UIE_ON 0x03 /* Update int. enable on */
#define RTC_UIE_OFF 0x04 /* ... off */
#define RTC_PIE_ON 0x05 /* Periodic int. enable on */
#define RTC_PIE_OFF 0x06 /* ... off */
#define RTC_ALM_SET 0x07 /* Set alarm (struct tm) */
#define RTC_ALM_READ 0x08 /* Read alarm (struct tm) */
#define RTC_RD_TIME 0x09 /* Read RTC time (struct tm) */
#define RTC_SET_TIME 0x0a /* Set time of RTC (not used) */
#define RTC_IRQP_READ 0x0b /* Read periodic IRQ rate (Hz) */
#define RTC_IRQP_SET 0x0c /* Set periodic IRQ rate (Hz) */
#endif /* _MC146818RTC_H */
......@@ -41,7 +41,8 @@ enum root_directory_inos {
PROC_CMDLINE,
PROC_SYS,
PROC_MTAB,
PROC_MD
PROC_MD,
PROC_RTC
};
enum pid_directory_inos {
......
......@@ -5,10 +5,15 @@
*
* Global definitions for the Frame relay interface.
*
* Version: @(#)if_ifrad.h 0.15 31 Mar 96
* Version: @(#)if_ifrad.h 0.20 13 Apr 96
*
* Author: Mike McLagan <mike.mclagan@linux.org>
*
* Changes:
* 0.15 Mike McLagan Structure packing
*
* 0.20 Mike McLagan New flags for S508 buffer handling
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version
......@@ -216,6 +221,11 @@ void sdla(void *cfg_info, char *dev, struct frad_conf *conf, int quiet);
/* Configuration flags */
#define SDLA_DIRECT_RECV 0x0080
#define SDLA_TX_NO_EXCEPT 0x0020
#define SDLA_NO_ICF_MSGS 0x1000
#define SDLA_TX50_RX50 0x0000
#define SDLA_TX70_RX30 0x2000
#define SDLA_TX30_RX70 0x4000
/* IRQ selection flags */
#define SDLA_IRQ_RECEIVE 0x01
......
This diff is collapsed.
......@@ -742,7 +742,7 @@ int verify_area(int type, const void * addr, unsigned long size)
check_stack:
if (!(vma->vm_flags & VM_GROWSDOWN))
goto bad_area;
if (expand_stack(vma, start))
if (expand_stack(vma, start) == 0)
goto good_area;
bad_area:
......
......@@ -705,10 +705,11 @@ static int tcp_ack(struct sock *sk, struct tcphdr *th, u32 ack, int len)
* right hand window edge of the host.
* We do a bit of work here to track number of times we've
* seen this ack without a change in the right edge of the
* window. This will allow us to do fast retransmits.
* window and no data in the packet.
* This will allow us to do fast retransmits.
*/
if (sk->rcv_ack_seq == ack && sk->window_seq == window_seq)
if (sk->rcv_ack_seq == ack && sk->window_seq == window_seq && !(flag&1))
{
/*
* We only want to short cut this once, many
......@@ -1318,8 +1319,7 @@ static void tcp_queue(struct sk_buff * skb, struct sock * sk, struct tcphdr *th)
if(sk->debug)
printk("Ack past end of seq packet.\n");
tcp_send_ack(sk);
sk->ack_backlog++;
tcp_reset_xmit_timer(sk, TIME_WRITE, min(sk->ato, HZ/2));
tcp_send_delayed_ack(sk,HZ/2);
}
}
}
......
......@@ -35,6 +35,6 @@ tkgen.o: tkgen.c tkparse.h
$(HOSTCC) $(HOSTCFLAGS) -c -o tkgen.o tkgen.c
clean:
rm -f kconfig.tk *.o parse
rm -f *~ kconfig.tk *.o tkparse
include $(TOPDIR)/Rules.make
......@@ -46,6 +46,10 @@
* (Apparently there still are some out there!)
* - Tabstops seem sensible now.
*
* 1996 04 14
* Avery Pennarun - Reduced flicker when creating windows, even with "update
* idletasks" hack.
*
* TO DO:
* - clean up - there are useless ifdef's everywhere.
* - better comments throughout - C code generating tcl is really cryptic.
......@@ -93,6 +97,7 @@ static void start_proc(char * label, int menu_num, int flag)
printf("proc menu%d {w title} {\n", menu_num);
printf("\tcatch {destroy $w}\n");
printf("\ttoplevel $w -class Dialog\n");
printf("\twm withdraw $w\n");
printf("\tmessage $w.m -width 400 -aspect 300 -text \\\n");
printf("\t\t\"%s\" -relief raised\n",label);
printf("\tpack $w.m -pady 10 -side top -padx 10\n");
......@@ -546,7 +551,8 @@ static void end_proc(int menu_num)
printf("\tupdate idletasks\n");
printf("\twm maxsize $w [winfo width $w] [winfo screenheight $w]\n");
printf("\twm minsize $w [winfo width $w] 100\n\n");
printf("\twm deiconify $w\n");
printf("}\n\n\n");
/*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment