Commit 105978db authored by Linus Torvalds's avatar Linus Torvalds

Import 1.3.5

parent 3a527c36
VERSION = 1
PATCHLEVEL = 3
SUBLEVEL = 4
SUBLEVEL = 5
ARCH = i386
......@@ -236,6 +236,7 @@ clean: archclean
mrproper: clean
rm -f include/linux/autoconf.h include/linux/version.h
rm -f drivers/sound/local.h
rm -f drivers/scsi/aic7xxx_asm drivers/scsi/aic7xxx_seq.h
rm -f drivers/char/uni_hash_tbl.h drivers/char/conmakehash
rm -f .version .config* config.in config.old
rm -f include/asm
......@@ -246,6 +247,8 @@ ifdef CONFIG_MODVERSIONS
endif
distclean: mrproper
rm -f core `find . -name '*.orig' -print`
backup: mrproper
cd .. && tar cf - linux | gzip -9 > backup.gz
......
......@@ -86,9 +86,10 @@ comment 'SCSI low-level drivers'
bool 'Adaptec AHA152X support' CONFIG_SCSI_AHA152X n
bool 'Adaptec AHA1542 support' CONFIG_SCSI_AHA1542 n
bool 'Adaptec AHA1740 support' CONFIG_SCSI_AHA1740 y
bool 'Adaptec AHA274X/284X support' CONFIG_SCSI_AHA274X n
bool 'Adaptec AHA274X/284X/294X support' CONFIG_SCSI_AIC7XXX n
bool 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC n
bool 'EATA-DMA (DPT,NEC&ATT for ISA,EISA,PCI) support' CONFIG_SCSI_EATA_DMA n
bool 'EATA-DMA (DPT, NEC, ATT, Olivetti) support' CONFIG_SCSI_EATA_DMA n
bool 'EATA-PIO (old DPT PM2001, PM2012A) support' CONFIG_SCSI_EATA_PIO n
bool 'UltraStor 14F/34F support' CONFIG_SCSI_U14_34F n
bool 'Future Domain 16xx SCSI support' CONFIG_SCSI_FUTURE_DOMAIN n
bool 'Generic NCR5380 SCSI support' CONFIG_SCSI_GENERIC_NCR5380 n
......
......@@ -90,8 +90,3 @@ wrmces:
call_pal PAL_wrmces
ret ($26)
.end wrmces
.align 9
.globl floppy_track_buffer
floppy_track_buffer:
.space 512*2*MAX_BUFFER_SECTORS,1
......@@ -99,6 +99,40 @@ void writel(unsigned int b, unsigned long addr)
__writel(b, addr);
}
/*
* Read COUNT 8-bit bytes from port PORT into memory starting at
* SRC.
*/
#undef insb
void insb (unsigned long port, void *dst, unsigned long count)
{
while (((unsigned long)dst) & 0x3) {
if (!count)
return;
count--;
*(unsigned char *) dst = inb(port);
((unsigned char *) dst)++;
}
while (count >= 4) {
unsigned int w;
count -= 4;
w = inb(port);
w |= inb(port) << 8;
w |= inb(port) << 16;
w |= inb(port) << 24;
*(unsigned int *) dst = w;
((unsigned int *) dst)++;
}
while (count) {
--count;
*(unsigned char *) dst = inb(port);
((unsigned char *) dst)++;
}
}
/*
* Read COUNT 16-bit words from port PORT into memory starting at
* SRC. SRC must be at least short aligned. This is used by the
......@@ -109,28 +143,28 @@ void writel(unsigned int b, unsigned long addr)
#undef insw
void insw (unsigned long port, void *dst, unsigned long count)
{
unsigned int *ip, w;
if (((unsigned long)dst) & 0x3) {
if (((unsigned long)dst) & 0x1) {
panic("insw: memory not short aligned");
}
*(unsigned short*)dst = inw(port);
dst += 2;
--count;
if (!count)
return;
count--;
*(unsigned short* ) dst = inw(port);
((unsigned short *) dst)++;
}
ip = dst;
while (count >= 2) {
w = inw(port);
w |= inw(port) << 16;
unsigned int w;
count -= 2;
*ip++ = w;
w = inw(port);
w |= inw(port) << 16;
*(unsigned int *) dst = w;
((unsigned int *) dst)++;
}
if (count) {
w = inw(port);
*(unsigned short*)ip = w;
*(unsigned short*) dst = inw(port);
}
}
......@@ -145,20 +179,32 @@ void insw (unsigned long port, void *dst, unsigned long count)
#undef insl
void insl (unsigned long port, void *dst, unsigned long count)
{
unsigned int *ip, w;
if (((unsigned long)dst) & 0x3) {
panic("insl: memory not aligned");
}
ip = dst;
while (count > 0) {
w = inw(port);
while (count) {
--count;
*ip++ = w;
*(unsigned int *) dst = inl(port);
((unsigned int *) dst)++;
}
}
/*
* Like insb but in the opposite direction.
* Don't worry as much about doing aligned memory transfers:
* doing byte reads the "slow" way isn't nearly as slow as
* doing byte writes the slow way (no r-m-w cycle).
*/
#undef outsb
void outsb(unsigned long port, void * src, unsigned long count)
{
while (count) {
count--;
outb(*(char *)src, port);
((char *) src)++;
}
}
/*
* Like insw but in the opposite direction. This is used by the IDE
......@@ -169,27 +215,26 @@ void insl (unsigned long port, void *dst, unsigned long count)
#undef outsw
void outsw (unsigned long port, void *src, unsigned long count)
{
unsigned int *ip, w;
if (((unsigned long)src) & 0x3) {
if (((unsigned long)src) & 0x1) {
panic("outsw: memory not short aligned");
}
outw(*(unsigned short*)src, port);
src += 2;
((unsigned short *) src)++;
--count;
}
ip = src;
while (count >= 2) {
w = *ip++;
unsigned int w;
count -= 2;
w = *(unsigned int *) src;
((unsigned int *) src)++;
outw(w >> 0, port);
outw(w >> 16, port);
}
if (count) {
outw(*(unsigned short*)ip, port);
outw(*(unsigned short *) src, port);
}
}
......@@ -203,16 +248,55 @@ void outsw (unsigned long port, void *src, unsigned long count)
#undef outsw
void outsl (unsigned long port, void *src, unsigned long count)
{
unsigned int *ip, w;
if (((unsigned long)src) & 0x3) {
panic("outsw: memory not aligned");
}
ip = src;
while (count > 0) {
w = *ip++;
while (count) {
--count;
outw(w, port);
outl(*(unsigned int *) src, port);
((unsigned int *) src)++;
}
}
/*
* Copy data from IO memory space to "real" memory space.
* This needs to be optimized.
*/
void memcpy_fromio(void * to, unsigned long from, unsigned long count)
{
while (count) {
count--;
*(char *) to = readb(from);
((char *) to)++;
from++;
}
}
/*
* Copy data from "real" memory space to IO memory space.
* This needs to be optimized.
*/
void memcpy_toio(unsigned long to, void * from, unsigned long count)
{
while (count) {
count--;
writeb(*(char *) from, to);
((char *) from)++;
to++;
}
}
/*
* "memset" on IO memory space.
* This needs to be optimized.
*/
void memset_io(unsigned long dst, int c, unsigned long count)
{
while (count) {
count--;
writeb(c, dst);
dst++;
}
}
......@@ -20,11 +20,30 @@
#
# ZLINKFLAGS = -Ttext 0x1000
# LINKFLAGS = -Ttext 0x100000
#
#
ifdef CONFIG_KERNEL_ELF
LD=ld -m elf_i386
CPP=$(CC) -E -D__ELF__
OBJDUMP =objdump
OBJDUMP_FLAGS=-k -q
LDFLAGS=-e startup_32
LDFLAGS=-e stext
ZIMAGE_OFFSET=0x1000
IMAGE_OFFSET=0x100000
ZLINKFLAGS =-Ttext $(ZIMAGE_OFFSET) $(LDFLAGS)
LINKFLAGS =-Ttext $(IMAGE_OFFSET) $(LDFLAGS)
else
#
# -qmagic (we need to remove the 32 byte header for bootup purposes)
#
ZLINKFLAGS =-qmagic -Ttext 0xfe0
LINKFLAGS =-qmagic -Ttext 0xfffe0
endif
CFLAGS := $(CFLAGS) -pipe
ifdef CONFIG_M486
......@@ -43,11 +62,6 @@ SUBDIRS := $(SUBDIRS) arch/i386/kernel arch/i386/mm arch/i386/lib
ARCHIVES := arch/i386/kernel/kernel.o arch/i386/mm/mm.o $(ARCHIVES)
LIBS := $(TOPDIR)/arch/i386/lib/lib.a $(LIBS) $(TOPDIR)/arch/i386/lib/lib.a
ifdef CONFIG_IBCS
SUBDIRS := $(SUBDIRS) arch/i386/ibcs
DRIVERS := $(DRIVERS) arch/i386/ibcs/ibcs.o
endif
ifdef CONFIG_MATH_EMULATION
SUBDIRS := $(SUBDIRS) arch/i386/math-emu
DRIVERS := $(DRIVERS) arch/i386/math-emu/math.a
......
......@@ -11,8 +11,17 @@
AS86 =as86 -0 -a
LD86 =ld86 -0
ifdef CONFIG_KERNEL_ELF
CFLAGS := $(CFLAGS) -D__BFD__
endif
zImage: $(CONFIGURE) bootsect setup compressed/vmlinux tools/build
ifdef CONFIG_KERNEL_ELF
$(OBJDUMP) $(OBJDUMP_FLAGS) -o $(ZIMAGE_OFFSET) compressed/vmlinux > compressed/vmlinux.out
tools/build bootsect setup compressed/vmlinux.out $(ROOT_DEV) > zImage
else
tools/build bootsect setup compressed/vmlinux $(ROOT_DEV) > zImage
endif
sync
compressed/vmlinux: $(TOPDIR)/vmlinux
......@@ -56,5 +65,5 @@ dep:
clean:
rm -f bootsect setup
rm -f zImage tools/build
rm -f zImage tools/build compressed/vmlinux.out
@$(MAKE) -C compressed clean
......@@ -11,6 +11,12 @@ OBJECTS = $(HEAD) inflate.o unzip.o misc.o
CFLAGS = -O2 -DSTDC_HEADERS
ifdef CONFIG_KERNEL_ELF
TARGET=--target elf32-i386
INPUT_DATA=input_data
INPUT_LEN=input_len
endif
.c.s:
$(CC) $(CFLAGS) -S $<
.s.o:
......@@ -20,13 +26,24 @@ CFLAGS = -O2 -DSTDC_HEADERS
all: vmlinux
vmlinux: piggy.o $(OBJECTS)
$(LD) $(ZLINKFLAGS) -o vmlinux $(OBJECTS) piggy.o
vmlinux: piggy.o $(OBJECTS)
$(LD) $(ZLINKFLAGS) -o vmlinux $(OBJECTS) piggy.o
head.o: head.S $(TOPDIR)/include/linux/tasks.h
$(CC) -traditional -c head.S
head.o: head.s
ifdef CONFIG_KERNEL_ELF
head.s: head.S $(TOPDIR)/include/linux/tasks.h
$(CPP) -traditional head.S -o head.s
# You cannot compress a file and have the kernel uncompress it, it must
# be stdin
piggy.o: $(SYSTEM)
tmppiggy=/tmp/$$.piggy; \
rm -f $$tmppiggy $$tmppiggy.gz; \
$(OBJDUMP) $(OBJDUMP_FLAGS) -o $(IMAGE_OFFSET) $(SYSTEM) > $$tmppiggy; \
gzip -f -9 < $$tmppiggy > $$tmppiggy.gz; \
encaps $(TARGET) piggy.o $$tmppiggy.gz $(INPUT_DATA) $(INPUT_LEN); \
rm -f $$tmppiggy $$tmppiggy.gz
else
piggy.o: $(SYSTEM) xtract piggyback
./xtract $(SYSTEM) | gzip -9 | ./piggyback > piggy.o
......@@ -37,5 +54,7 @@ xtract: xtract.c
piggyback: piggyback.c
$(HOSTCC) $(CFLAGS) -o piggyback piggyback.c
endif
clean:
rm -f xtract piggyback vmlinux
......@@ -19,8 +19,10 @@
.text
#define __ASSEMBLY__
#include <linux/linkage.h>
#include <asm/segment.h>
.globl startup_32
startup_32:
cld
cli
......@@ -29,7 +31,7 @@ startup_32:
mov %ax,%es
mov %ax,%fs
mov %ax,%gs
lss _stack_start,%esp
lss SYMBOL_NAME(stack_start),%esp
xorl %eax,%eax
1: incl %eax # check that A20 really IS enabled
movl %eax,0x000000 # loop forever if it isn't
......@@ -46,8 +48,8 @@ startup_32:
* Clear BSS
*/
xorl %eax,%eax
movl $__edata,%edi
movl $__end,%ecx
movl $ SYMBOL_NAME(_edata),%edi
movl $ SYMBOL_NAME(_end),%ecx
subl %edi,%ecx
cld
rep
......@@ -55,5 +57,5 @@ startup_32:
/*
* Do the decompression, and jump to the new kernel..
*/
call _decompress_kernel
call SYMBOL_NAME(decompress_kernel)
ljmp $(KERNEL_CS), $0x100000
......@@ -30,11 +30,14 @@
#include <fcntl.h>
#include <linux/a.out.h>
#include <linux/config.h>
#include <errno.h>
#define MINIX_HEADER 32
#define N_MAGIC_OFFSET 1024
#ifndef __BFD__
static int GCC_HEADER = sizeof(struct exec);
#endif
#define SYS_SIZE DEF_SYSSIZE
......@@ -89,7 +92,9 @@ int main(int argc, char ** argv)
int i,c,id, sz;
unsigned long sys_size;
char buf[1024];
#ifndef __BFD__
struct exec *ex = (struct exec *)buf;
#endif
char major_root, minor_root;
struct stat sb;
unsigned char setup_sectors;
......@@ -190,6 +195,7 @@ int main(int argc, char ** argv)
if ((id=open(argv[3],O_RDONLY,0))<0)
die("Unable to open 'system'");
#ifndef __BFD__
if (read(id,buf,GCC_HEADER) != GCC_HEADER)
die("Unable to read header of 'system'");
if (N_MAGIC(*ex) == ZMAGIC) {
......@@ -203,6 +209,14 @@ int main(int argc, char ** argv)
ex->a_data /1024,
ex->a_bss /1024);
sz = N_SYMOFF(*ex) - GCC_HEADER + 4;
#else
if (fstat (id, &sb)) {
perror ("fstat");
die ("Unable to stat 'system'");
}
sz = sb.st_size;
fprintf (stderr, "System is %d kB\n", sz/1024);
#endif
sys_size = (sz + 15) / 16;
if (sys_size > SYS_SIZE)
die("System is too big");
......
......@@ -91,12 +91,11 @@ comment 'SCSI low-level drivers'
bool 'Adaptec AHA152X support' CONFIG_SCSI_AHA152X y
bool 'Adaptec AHA1542 support' CONFIG_SCSI_AHA1542 n
bool 'Adaptec AHA1740 support' CONFIG_SCSI_AHA1740 y
if [ "$CONFIG_PCI" = "y" ]; then
bool 'Adaptec AHA274X/284X/294X support' CONFIG_SCSI_AIC7XXX n
fi
bool 'Adaptec AHA1740 support' CONFIG_SCSI_AHA1740 n
bool 'Adaptec AHA274X/284X/294X support' CONFIG_SCSI_AIC7XXX n
bool 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC n
bool 'EATA-DMA (DPT,NEC&ATT for ISA,EISA,PCI) support' CONFIG_SCSI_EATA_DMA n
bool 'EATA-DMA (DPT, NEC, ATT, Olivetti) support' CONFIG_SCSI_EATA_DMA n
bool 'EATA-PIO (old DPT PM2001, PM2012A) support' CONFIG_SCSI_EATA_PIO n
bool 'UltraStor 14F/34F support' CONFIG_SCSI_U14_34F n
bool 'Future Domain 16xx SCSI support' CONFIG_SCSI_FUTURE_DOMAIN n
bool 'Generic NCR5380 SCSI support' CONFIG_SCSI_GENERIC_NCR5380 n
......@@ -173,6 +172,7 @@ if [ "$CONFIG_NET_ISA" = "y" ]; then
fi
bool 'HP PCLAN+ (27247B and 27252A) support' CONFIG_HPLAN_PLUS n
bool 'HP PCLAN (27245 and other 27xxx series) support' CONFIG_HPLAN n
bool 'HP 10/100VG PCLAN (257X series) support' CONFIG_HP100 y
bool 'NE2000/NE1000 support' CONFIG_NE2000 y
if [ "$CONFIG_AX25" = "y" ]; then
bool 'Ottawa PI and PI/2 support' CONFIG_PI y
......@@ -185,7 +185,7 @@ if [ "$CONFIG_NET_EISA" = "y" ]; then
bool 'Ansel Communications EISA 3200 support' CONFIG_AC3200 n
fi
bool 'Apricot Xen-II on board ethernet' CONFIG_APRICOT n
bool 'DE425, DE434, DE435 support' CONFIG_DE4X5 n
bool 'DE425, DE434, DE435, DE500 support' CONFIG_DE4X5 n
# bool 'DEC 21040 PCI support' CONFIG_DEC_ELCP n
# bool 'LPL T100V 100Mbs support' CONFIG_LPL_T100 n
# bool 'PCnet32 (32 bit VLB and PCI LANCE) support' CONFIG_PCNET32 n
......
#
# Makefile for the iBCS emulator files
#
# Note! Dependencies are done automagically by 'make dep', which also
# removes any old dependencies. DON'T put your own dependencies here
# unless it's something special (ie not a .c file).
#
# Note 2! The CFLAGS definitions are now in the main makefile...
.S.s:
$(CPP) -traditional $< -o $*.s
.c.s:
$(CC) $(CFLAGS) -S $<
.s.o:
$(AS) -c -o $*.o $<
.c.o:
$(CC) $(CFLAGS) -c $<
SUBDIRS =
OBJS = emulate.o
ibcs.o: $(OBJS)
$(LD) -r -o ibcs.o $(OBJS)
sync
dep:
$(CPP) -M *.c > .depend
dummy:
#
# include a dependency file if one exists
#
ifeq (.depend,$(wildcard .depend))
include .depend
endif
This diff is collapsed.
This diff is collapsed.
/*
* linux/abi/emulate.c
*
* Copyright (C) 1993 Linus Torvalds
*/
/*
* Yes, sir, this file is completely empty, waiting for some real code..
* I still copyright it, silly me.
*/
......@@ -13,8 +13,8 @@
$(AS) -o $*.o $<
.c.o:
$(CC) $(CFLAGS) -c $<
.S.s:
$(CPP) -D__ASSEMBLY__ -traditional $< -o $*.s
#.S.s:
# $(CPP) -D__ASSEMBLY__ -traditional $< -o $*.s
.S.o:
$(CC) -D__ASSEMBLY__ -traditional -c $< -o $*.o
......@@ -23,10 +23,11 @@ OBJS = process.o signal.o entry.o traps.o irq.o vm86.o bios32.o ptrace.o \
all: kernel.o head.o
head.o: head.s
#head.o: head.s
head.s: head.S $(TOPDIR)/include/linux/tasks.h
$(CPP) -traditional -o $*.s $<
head.o: head.S $(TOPDIR)/include/linux/tasks.h
$(CC) -D__ASSEMBLY__ -traditional -c $*.S -o $*.o
# $(CPP) -traditional -o $*.s $<
kernel.o: $(OBJS)
$(LD) -r -o kernel.o $(OBJS)
......
This diff is collapsed.
......@@ -9,15 +9,9 @@
*/
.text
.globl _idt,_gdt,_stext,__stext
.globl _swapper_pg_dir,_pg0
.globl _empty_bad_page
.globl _empty_bad_page_table
.globl _empty_zero_page
#define __ASSEMBLY__
#include <linux/tasks.h>
#include <linux/fd.h>
#include <linux/linkage.h>
#include <asm/segment.h>
#define CL_MAGIC_ADDR 0x90020
......@@ -29,8 +23,8 @@
* swapper_pg_dir is the main page directory, address 0x00001000 (or at
* address 0x00101000 for a compressed boot).
*/
_stext:
__stext:
ENTRY(stext)
ENTRY(_stext)
startup_32:
cld
movl $(KERNEL_DS),%eax
......@@ -43,8 +37,8 @@ startup_32:
* Clear BSS first so that there are no surprises...
*/
xorl %eax,%eax
movl $__edata,%edi
movl $__end,%ecx
movl $ SYMBOL_NAME(_edata),%edi
movl $ SYMBOL_NAME(_end),%ecx
subl %edi,%ecx
cld
rep
......@@ -72,7 +66,7 @@ startup_32:
* is for the command line.
*/
movl $0x90000,%esi
movl $_empty_zero_page,%edi
movl $ SYMBOL_NAME(empty_zero_page),%edi
movl $512,%ecx
cld
rep
......@@ -83,7 +77,7 @@ startup_32:
stosl
cmpw $(CL_MAGIC),CL_MAGIC_ADDR
jne 1f
movl $_empty_zero_page+2048,%edi
movl $ SYMBOL_NAME(empty_zero_page)+2048,%edi
movzwl CL_OFFSET,%esi
addl $(CL_BASE_ADDR),%esi
movl $2048,%ecx
......@@ -96,7 +90,7 @@ startup_32:
* apply at our cpl of 0 and the stack ought to be aligned already, and
* we don't need to preserve eflags.
*/
movl $3,_x86
movl $3, SYMBOL_NAME(x86)
pushfl # push EFLAGS
popl %eax # get EFLAGS
movl %eax,%ecx # save original EFLAGS
......@@ -108,7 +102,7 @@ startup_32:
xorl %ecx,%eax # change in flags
andl $0x40000,%eax # check if AC bit changed
je is386
movl $4,_x86
movl $4,SYMBOL_NAME(x86)
movl %ecx,%eax
xorl $0x200000,%eax # check ID flag
pushl %eax
......@@ -125,19 +119,19 @@ isnew: pushl %ecx # restore original EFLAGS
.byte 0x0f, 0xa2 # check the processor type
movb %al, %cl # save reg for future use
andb $0x0f,%ah # mask processor family
movb %ah, _x86
movb %ah,SYMBOL_NAME(x86)
andb $0xf0, %eax # mask model
shrb $4, %al
movb %al, _x86_model
movb %al,SYMBOL_NAME(x86_model)
andb $0x0f, %cl # mask mask revision
movb %cl, _x86_mask
movl %edx, _x86_capability
movb %cl,SYMBOL_NAME(x86_mask)
movl %edx,SYMBOL_NAME(x86_capability)
/* get vendor info */
xorl %eax, %eax # call CPUID with 0 -> return vendor ID
.byte 0x0f, 0xa2 # CPUID
movl %ebx, _x86_vendor_id # lo 4 chars
movl %edx, _x86_vendor_id+4 # next 4 chars
movl %ecx, _x86_vendor_id+8 # last 4 chars
movl %ebx,SYMBOL_NAME(x86_vendor_id) # lo 4 chars
movl %edx,SYMBOL_NAME(x86_vendor_id)+4 # next 4 chars
movl %ecx,SYMBOL_NAME(x86_vendor_id)+8 # last 4 chars
movl %cr0,%eax # 486+
andl $0x80000011,%eax # Save PG,PE,ET
......@@ -172,7 +166,7 @@ is386: pushl %ecx # restore original EFLAGS
pushl %eax
pushl %eax
cld # gcc2 wants the direction flag cleared at all times
call _start_kernel
call SYMBOL_NAME(start_kernel)
L6:
jmp L6 # main should never return here, but
# just in case, we know what happens.
......@@ -181,7 +175,7 @@ L6:
* We depend on ET to be correct. This checks for 287/387.
*/
check_x87:
movb $0,_hard_math
movb $0,SYMBOL_NAME(hard_math)
clts
fninit
fstsw %ax
......@@ -191,8 +185,8 @@ check_x87:
xorl $4,%eax /* set EM */
movl %eax,%cr0
ret
.align 2
1: movb $1,_hard_math
ALIGN
1: movb $1,SYMBOL_NAME(hard_math)
.byte 0xDB,0xE4 /* fsetpm for 287, ignored by 387 */
ret
......@@ -212,7 +206,7 @@ setup_idt:
movw %dx,%ax /* selector = 0x0010 = cs */
movw $0x8E00,%dx /* interrupt gate - dpl=0, present */
lea _idt,%edi
lea SYMBOL_NAME(idt),%edi
mov $256,%ecx
rp_sidt:
movl %eax,(%edi)
......@@ -234,24 +228,26 @@ rp_sidt:
* (ref: update, 25Sept92) -- croutons@crunchy.uucp
* (ref: 92.10.11 - Linus Torvalds. Corrected 16M limit - no upper memory limit)
*/
.align 2
ALIGN
setup_paging:
movl $1024*2,%ecx /* 2 pages - swapper_pg_dir+1 page table */
xorl %eax,%eax
movl $_swapper_pg_dir,%edi /* swapper_pg_dir is at 0x1000 */
movl $ SYMBOL_NAME(swapper_pg_dir),%edi /* swapper_pg_dir is at 0x1000 */
cld;rep;stosl
/* Identity-map the kernel in low 4MB memory for ease of transition */
movl $_pg0+7,_swapper_pg_dir /* set present bit/user r/w */
/* set present bit/user r/w */
movl $ SYMBOL_NAME(pg0)+7,SYMBOL_NAME(swapper_pg_dir)
/* But the real place is at 0xC0000000 */
movl $_pg0+7,_swapper_pg_dir+3072 /* set present bit/user r/w */
movl $_pg0+4092,%edi
/* set present bit/user r/w */
movl $ SYMBOL_NAME(pg0)+7,SYMBOL_NAME(swapper_pg_dir)+3072
movl $ SYMBOL_NAME(pg0)+4092,%edi
movl $0x03ff007,%eax /* 4Mb - 4096 + 7 (r/w user,p) */
std
1: stosl /* fill the page backwards - more efficient :-) */
subl $0x1000,%eax
jge 1b
cld
movl $_swapper_pg_dir,%eax
movl $ SYMBOL_NAME(swapper_pg_dir),%eax
movl %eax,%cr3 /* cr3 - page directory start */
movl %cr0,%eax
orl $0x80000000,%eax
......@@ -269,33 +265,33 @@ setup_paging:
* by 2-3k. This would be a good thing to do at some point.....
*/
.org 0x1000
_swapper_pg_dir:
ENTRY(swapper_pg_dir)
/*
* The page tables are initialized to only 4MB here - the final page
* tables are set up later depending on memory size.
*/
.org 0x2000
_pg0:
ENTRY(pg0)
.org 0x3000
_empty_bad_page:
ENTRY(empty_bad_page)
.org 0x4000
_empty_bad_page_table:
ENTRY(empty_bad_page_table)
.org 0x5000
_empty_zero_page:
ENTRY(empty_zero_page)
.org 0x6000
stack_start:
.long _init_user_stack+4096
.long SYMBOL_NAME(init_user_stack)+4096
.long KERNEL_DS
/* This is the default interrupt "handler" :-) */
int_msg:
.asciz "Unknown interrupt\n"
.align 2
ALIGN
ignore_int:
cld
pushl %eax
......@@ -309,7 +305,7 @@ ignore_int:
mov %ax,%es
mov %ax,%fs
pushl $int_msg
call _printk
call SYMBOL_NAME(printk)
popl %eax
pop %fs
pop %es
......@@ -322,28 +318,26 @@ ignore_int:
/*
* The interrupt descriptor table has room for 256 idt's
*/
.align 4
ALIGN
.word 0
idt_descr:
.word 256*8-1 # idt contains 256 entries
.long 0xc0000000+_idt
.long 0xc0000000+SYMBOL_NAME(idt)
.align 4
_idt:
ENTRY(idt)
.fill 256,8,0 # idt is uninitialized
.align 4
ALIGN
.word 0
gdt_descr:
.word (8+2*NR_TASKS)*8-1
.long 0xc0000000+_gdt
.long 0xc0000000+SYMBOL_NAME(gdt)
/*
* This gdt setup gives the kernel a 1GB address space at virtual
* address 0xC0000000 - space enough for expansion, I hope.
*/
.align 4
_gdt:
ENTRY(gdt)
.quad 0x0000000000000000 /* NULL descriptor */
.quad 0x0000000000000000 /* not used */
.quad 0xc0c39a000000ffff /* 0x10 kernel 1GB code at 0xC0000000 */
......
......@@ -193,6 +193,31 @@ void copy_thread(int nr, unsigned long clone_flags, unsigned long esp,
__asm__("clts ; fnsave %0 ; frstor %0":"=m" (p->tss.i387));
}
/*
* fill in the fpu structure for a core dump..
*/
int dump_fpu (struct user_i387_struct* fpu)
{
int fpvalid;
/* Flag indicating the math stuff is valid. We don't support this for the
soft-float routines yet */
if (hard_math) {
if ((fpvalid = current->used_math) != 0) {
if (last_task_used_math == current)
__asm__("clts ; fnsave %0": :"m" (*fpu));
else
memcpy(fpu,&current->tss.i387.hard,sizeof(*fpu));
}
} else {
/* we should dump the emulator state here, but we need to
convert it into standard 387 format first.. */
fpvalid = 0;
}
return fpvalid;
}
/*
* fill in the user structure for a core dump..
*/
......@@ -216,20 +241,7 @@ void dump_thread(struct pt_regs * regs, struct user * dump)
dump->regs = *regs;
/* Flag indicating the math stuff is valid. We don't support this for the
soft-float routines yet */
if (hard_math) {
if ((dump->u_fpvalid = current->used_math) != 0) {
if (last_task_used_math == current)
__asm__("clts ; fnsave %0": :"m" (dump->i387));
else
memcpy(&dump->i387,&current->tss.i387.hard,sizeof(dump->i387));
}
} else {
/* we should dump the emulator state here, but we need to
convert it into standard 387 format first.. */
dump->u_fpvalid = 0;
}
dump->u_fpvalid = dump_fpu (&dump->i387);
}
asmlinkage int sys_fork(struct pt_regs regs)
......
......@@ -56,7 +56,7 @@ struct screen_info screen_info;
unsigned char aux_device_present;
extern int ramdisk_size;
extern int root_mountflags;
extern int etext, edata, end;
extern int _etext, _edata, _end;
extern char empty_zero_page[PAGE_SIZE];
......@@ -96,11 +96,11 @@ void setup_arch(char **cmdline_p,
#endif
if (MOUNT_ROOT_RDONLY)
root_mountflags |= MS_RDONLY;
memory_start = (unsigned long) &end;
memory_start = (unsigned long) &_end;
init_task.mm->start_code = TASK_SIZE;
init_task.mm->end_code = TASK_SIZE + (unsigned long) &etext;
init_task.mm->end_data = TASK_SIZE + (unsigned long) &edata;
init_task.mm->brk = TASK_SIZE + (unsigned long) &end;
init_task.mm->end_code = TASK_SIZE + (unsigned long) &_etext;
init_task.mm->end_data = TASK_SIZE + (unsigned long) &_edata;
init_task.mm->brk = TASK_SIZE + (unsigned long) &_end;
for (;;) {
if (c == ' ' && *(unsigned long *)from == *(unsigned long *)"mem=") {
......
......@@ -99,7 +99,7 @@ int kstack_depth_to_print = 24;
unsigned long esp;
unsigned short ss;
unsigned long *stack, addr, module_start, module_end;
extern char start_kernel, etext;
extern char start_kernel, _etext;
esp = (unsigned long) &regs->esp;
ss = KERNEL_DS;
......@@ -147,7 +147,7 @@ int kstack_depth_to_print = 24;
* out the call path that was taken.
*/
if (((addr >= (unsigned long) &start_kernel) &&
(addr <= (unsigned long) &etext)) ||
(addr <= (unsigned long) &_etext)) ||
((addr >= module_start) && (addr <= module_end))) {
if (i && ((i % 8) == 0))
printk("\n ");
......
......@@ -74,11 +74,7 @@ FPU_result_1:
.text
.align 2,144
.globl _div_Xsig
_div_Xsig:
ENTRY(div_Xsig)
pushl %ebp
movl %esp,%ebp
#ifndef NON_REENTRANT_FPU
......
......@@ -17,11 +17,7 @@
#include "fpu_asm.h"
.text
.align 2,144
.globl _div_small
_div_small:
ENTRY(div_small)
pushl %ebp
movl %esp,%ebp
......
......@@ -9,9 +9,10 @@
#ifndef _FPU_ASM_H_
#define _FPU_ASM_H_
#include <linux/linkage.h>
#include "fpu_emu.h"
#define EXCEPTION _exception
#define EXCEPTION SYMBOL_NAME(exception)
#define PARAM1 8(%ebp)
......
......@@ -24,9 +24,7 @@
#include "fpu_asm.h"
.text
.align 2,144
.globl _mul32_Xsig
_mul32_Xsig:
ENTRY(mul32_Xsig)
pushl %ebp
movl %esp,%ebp
subl $16,%esp
......@@ -66,9 +64,7 @@ _mul32_Xsig:
ret
.align 2,144
.globl _mul64_Xsig
_mul64_Xsig:
ENTRY(mul64_Xsig)
pushl %ebp
movl %esp,%ebp
subl $16,%esp
......@@ -121,9 +117,7 @@ _mul64_Xsig:
.align 2,144
.globl _mul_Xsig_Xsig
_mul_Xsig_Xsig:
ENTRY(mul_Xsig_Xsig)
pushl %ebp
movl %esp,%ebp
subl $16,%esp
......
......@@ -36,9 +36,7 @@
#define OVERFLOWED -16(%ebp) /* addition overflow flag */
.text
.align 2,144
.globl _polynomial_Xsig
_polynomial_Xsig:
ENTRY(polynomial_Xsig)
pushl %ebp
movl %esp,%ebp
subl $32,%esp
......
......@@ -19,10 +19,7 @@
.text
.align 2
.globl _reg_div
_reg_div:
ENTRY(reg_div)
pushl %ebp
movl %esp,%ebp
#ifndef NON_REENTRANT_FPU
......@@ -47,7 +44,7 @@ _reg_div:
cmpl EXP_UNDER,EXP(%esi)
jg xL_arg1_not_denormal
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -55,7 +52,7 @@ xL_arg1_not_denormal:
cmpl EXP_UNDER,EXP(%ebx)
jg xL_arg2_not_denormal
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -75,7 +72,7 @@ xL_arg2_not_denormal:
addl EXP_BIAS,%edx
movl %edx,EXP(%edi)
jmp _divide_kernel
jmp SYMBOL_NAME(divide_kernel)
/*-----------------------------------------------------------------------*/
......@@ -92,14 +89,14 @@ L_arg2_NaN:
pushl %edi /* Destination */
pushl %esi
pushl %ebx /* Ordering is important here */
call _real_2op_NaN
call SYMBOL_NAME(real_2op_NaN)
jmp LDiv_exit
/* Invalid operations */
L_zero_zero:
L_inf_inf:
pushl %edi /* Destination */
call _arith_invalid /* 0/0 or Infinity/Infinity */
call SYMBOL_NAME(arith_invalid) /* 0/0 or Infinity/Infinity */
jmp LDiv_exit
L_no_NaN_arg:
......@@ -126,7 +123,7 @@ L_inf_valid:
cmpl EXP_UNDER,EXP(%ebx)
jg L_copy_arg1 /* Answer is Inf */
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
#endif DENORM_OPERAND
......@@ -151,7 +148,7 @@ L_arg1_not_inf:
movb SIGN(%esi),%al
xorb SIGN(%ebx),%al
pushl %eax /* lower 8 bits have the sign */
call _divide_by_zero
call SYMBOL_NAME(divide_by_zero)
jmp LDiv_exit
L_arg2_not_zero:
......@@ -165,7 +162,7 @@ L_arg2_not_zero:
cmpl EXP_UNDER,EXP(%esi)
jg L_return_zero /* Answer is zero */
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
#endif DENORM_OPERAND
......@@ -185,7 +182,7 @@ L_arg2_not_inf:
cmpl EXP_UNDER,EXP(%ebx)
jg L_copy_arg1 /* Answer is zero */
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
#endif DENORM_OPERAND
......@@ -241,11 +238,11 @@ L_unknown_tags:
call EXCEPTION
/* Generate a NaN for unknown tags */
movl _CONST_QNaN,%eax
movl SYMBOL_NAME(CONST_QNaN),%eax
movl %eax,(%edi)
movl _CONST_QNaN+4,%eax
movl SYMBOL_NAME(CONST_QNaN)+4,%eax
movl %eax,SIGL(%edi)
movl _CONST_QNaN+8,%eax
movl SYMBOL_NAME(CONST_QNaN)+8,%eax
movl %eax,SIGH(%edi)
jmp LDiv_exit /* %eax is nz */
#endif PARANOID
......@@ -18,11 +18,7 @@
.text
.align 2,144
.globl _normalize
_normalize:
ENTRY(normalize)
pushl %ebp
movl %esp,%ebp
pushl %ebx
......@@ -34,7 +30,7 @@ _normalize:
je L_ok
pushl $0x220
call _exception
call SYMBOL_NAME(exception)
addl $4,%esp
L_ok:
......@@ -86,23 +82,20 @@ L_zero:
L_underflow:
push %ebx
call _arith_underflow
call SYMBOL_NAME(arith_underflow)
pop %ebx
jmp L_exit
L_overflow:
push %ebx
call _arith_overflow
call SYMBOL_NAME(arith_overflow)
pop %ebx
jmp L_exit
/* Normalise without reporting underflow or overflow */
.align 2,144
.globl _normalize_nuo
_normalize_nuo:
ENTRY(normalize_nuo)
pushl %ebp
movl %esp,%ebp
pushl %ebx
......@@ -114,7 +107,7 @@ _normalize_nuo:
je L_ok_nuo
pushl $0x221
call _exception
call SYMBOL_NAME(exception)
addl $4,%esp
L_ok_nuo:
......
......@@ -101,14 +101,12 @@ FPU_denormal:
.text
.align 2,144
.globl fpu_reg_round
.globl fpu_reg_round_sqrt
.globl fpu_Arith_exit
.globl _round_reg
/* Entry point when called from C */
_round_reg:
ENTRY(round_reg)
pushl %ebp
movl %esp,%ebp
pushl %esi
......@@ -435,7 +433,7 @@ fpu_Arith_exit:
*/
xL_precision_lost_up:
push %eax
call _set_precision_flag_up
call SYMBOL_NAME(set_precision_flag_up)
popl %eax
jmp xL_no_precision_loss
......@@ -445,7 +443,7 @@ xL_precision_lost_up:
*/
xL_precision_lost_down:
push %eax
call _set_precision_flag_down
call SYMBOL_NAME(set_precision_flag_down)
popl %eax
jmp xL_no_precision_loss
......@@ -598,7 +596,7 @@ LNormalise_shift_done:
/* There must be a masked underflow */
push %eax
pushl EX_Underflow
call _exception
call SYMBOL_NAME(exception)
popl %eax
popl %eax
jmp xL_Normalised
......@@ -610,12 +608,12 @@ LNormalise_shift_done:
*/
L_underflow_to_zero:
push %eax
call _set_precision_flag_down
call SYMBOL_NAME(set_precision_flag_down)
popl %eax
push %eax
pushl EX_Underflow
call _exception
call SYMBOL_NAME(exception)
popl %eax
popl %eax
......@@ -628,7 +626,7 @@ L_underflow_to_zero:
/* The operations resulted in a number too large to represent. */
L_overflow:
push %edi
call _arith_overflow
call SYMBOL_NAME(arith_overflow)
pop %edi
jmp fpu_reg_round_exit
......
......@@ -29,9 +29,7 @@
#include "control_w.h"
.text
.align 2,144
.globl _reg_u_add
_reg_u_add:
ENTRY(reg_u_add)
pushl %ebp
movl %esp,%ebp
pushl %esi
......@@ -45,7 +43,7 @@ _reg_u_add:
cmpl EXP_UNDER,EXP(%esi)
jg xOp1_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -53,7 +51,7 @@ xOp1_not_denorm:
cmpl EXP_UNDER,EXP(%edi)
jg xOp2_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......
......@@ -69,13 +69,7 @@ FPU_ovfl_flag:
.text
.align 2,144
.globl _reg_u_div
.globl _divide_kernel
_reg_u_div:
ENTRY(reg_u_div)
pushl %ebp
movl %esp,%ebp
#ifndef NON_REENTRANT_FPU
......@@ -95,7 +89,7 @@ _reg_u_div:
cmpl EXP_UNDER,%eax
jg xOp1_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -104,14 +98,14 @@ xOp1_not_denorm:
cmpl EXP_UNDER,%eax
jg xOp2_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
xOp2_not_denorm:
#endif DENORM_OPERAND
_divide_kernel:
ENTRY(divide_kernel)
#ifdef PARANOID
/* testl $0x80000000, SIGH(%esi) // Dividend */
/* je L_bugged */
......
......@@ -44,10 +44,7 @@ FPU_accum_1:
.text
.align 2,144
.globl _reg_u_mul
_reg_u_mul:
ENTRY(reg_u_mul)
pushl %ebp
movl %esp,%ebp
#ifndef NON_REENTRANT_FPU
......@@ -73,7 +70,7 @@ _reg_u_mul:
cmpl EXP_UNDER,%eax
jg xOp1_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -82,7 +79,7 @@ xOp1_not_denorm:
cmpl EXP_UNDER,%eax
jg xOp2_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......
......@@ -30,9 +30,7 @@
#include "control_w.h"
.text
.align 2,144
.globl _reg_u_sub
_reg_u_sub:
ENTRY(reg_u_sub)
pushl %ebp
movl %esp,%ebp
pushl %esi
......@@ -46,7 +44,7 @@ _reg_u_sub:
cmpl EXP_UNDER,EXP(%esi)
jg xOp1_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......@@ -54,7 +52,7 @@ xOp1_not_denorm:
cmpl EXP_UNDER,EXP(%edi)
jg xOp2_not_denorm
call _denormal_operand
call SYMBOL_NAME(denormal_operand)
orl %eax,%eax
jnz fpu_Arith_exit
......
......@@ -22,11 +22,7 @@
.text
.align 2,144
.globl _round_Xsig
_round_Xsig:
ENTRY(round_Xsig)
pushl %ebp
movl %esp,%ebp
pushl %ebx /* Reserve some space */
......@@ -86,10 +82,7 @@ L_exit:
.align 2,144
.globl _norm_Xsig
_norm_Xsig:
ENTRY(norm_Xsig)
pushl %ebp
movl %esp,%ebp
pushl %ebx /* Reserve some space */
......
......@@ -21,10 +21,7 @@
#include "fpu_asm.h"
.text
.align 2,144
.globl _shr_Xsig
_shr_Xsig:
ENTRY(shr_Xsig)
push %ebp
movl %esp,%ebp
pushl %esi
......
......@@ -17,8 +17,6 @@
#include "fpu_asm.h"
.text
.align 2,144
/*---------------------------------------------------------------------------+
| unsigned shrx(void *arg1, unsigned arg2) |
| |
......@@ -33,9 +31,7 @@
| Results returned in the 64 bit arg and eax. |
+---------------------------------------------------------------------------*/
.globl _shrx
_shrx:
ENTRY(shrx)
push %ebp
movl %esp,%ebp
pushl %esi
......@@ -113,8 +109,7 @@ L_more_than_95:
| part which has been shifted out of the arg. |
| Results returned in the 64 bit arg and eax. |
+---------------------------------------------------------------------------*/
.globl _shrxs
_shrxs:
ENTRY(shrxs)
push %ebp
movl %esp,%ebp
pushl %esi
......
......@@ -74,10 +74,7 @@ FPU_fsqrt_arg_0:
.text
.align 2,144
.globl _wm_sqrt
_wm_sqrt:
ENTRY(wm_sqrt)
pushl %ebp
movl %esp,%ebp
#ifndef NON_REENTRANT_FPU
......
......@@ -149,7 +149,7 @@ void mem_init(unsigned long start_mem, unsigned long end_mem)
int reservedpages = 0;
int datapages = 0;
unsigned long tmp;
extern int etext;
extern int _etext;
end_mem &= PAGE_MASK;
high_memory = end_mem;
......@@ -185,7 +185,7 @@ void mem_init(unsigned long start_mem, unsigned long end_mem)
if (mem_map[MAP_NR(tmp)]) {
if (tmp >= 0xA0000 && tmp < 0x100000)
reservedpages++;
else if (tmp < (unsigned long) &etext)
else if (tmp < (unsigned long) &_etext)
codepages++;
else
datapages++;
......
......@@ -74,7 +74,8 @@ bool 'Adaptec AHA152X support' CONFIG_SCSI_AHA152X n
bool 'Adaptec AHA1542 support' CONFIG_SCSI_AHA1542 y
bool 'Adaptec AHA1740 support' CONFIG_SCSI_AHA1740 n
bool 'BusLogic SCSI support' CONFIG_SCSI_BUSLOGIC n
bool 'EATA-DMA (DPT,NEC&ATT for ISA,EISA,PCI) support' CONFIG_SCSI_EATA_DMA n
bool 'EATA-DMA (DPT, NEC, ATT, Olivetti) support' CONFIG_SCSI_EATA_DMA y
bool 'EATA-PIO (old DPT PM2001, PM2012A) support' CONFIG_SCSI_EATA_PIO n
bool 'UltraStor 14F/34F support' CONFIG_SCSI_U14_34F n
bool 'Future Domain 16xx SCSI support' CONFIG_SCSI_FUTURE_DOMAIN n
bool 'Generic NCR5380 SCSI support' CONFIG_SCSI_GENERIC_NCR5380 n
......
This diff is collapsed.
......@@ -211,7 +211,7 @@ unsigned char inverse_translate(unsigned char c) {
* 0xf000-0xf0ff "transparent" Unicodes) whereas the "new" variants set
* unicodes explictly.
*/
int con_set_trans_old(char * arg)
int con_set_trans_old(unsigned char * arg)
{
int i;
unsigned short *p = translations[USER_MAP];
......@@ -227,7 +227,7 @@ int con_set_trans_old(char * arg)
return 0;
}
int con_get_trans_old(char * arg)
int con_get_trans_old(unsigned char * arg)
{
int i, ch;
unsigned short *p = translations[USER_MAP];
......
......@@ -588,7 +588,7 @@ void cleanup_module(void)
else {
unregister_chrdev(LP_MAJOR,"lp");
for (offset = 0; offset < LP_NO; offset++)
if(LP_F(offset) && LP_EXIST)
if (LP_F(offset) & LP_EXIST)
release_region(LP_B(offset),3);
}
}
......
......@@ -488,7 +488,7 @@ static int poll_aux_status(void)
int retries=0;
while ((inb(AUX_STATUS)&0x03) && retries < MAX_RETRIES) {
if (inb_p(AUX_STATUS) & AUX_OBUF_FULL == AUX_OBUF_FULL)
if ((inb_p(AUX_STATUS) & AUX_OBUF_FULL) == AUX_OBUF_FULL)
inb_p(AUX_INPUT_PORT);
current->state = TASK_INTERRUPTIBLE;
current->timeout = jiffies + (5*HZ + 99) / 100;
......
......@@ -66,8 +66,8 @@ extern unsigned int keymap_count;
* routines to load custom translation table, EGA/VGA font and
* VGA colour palette from console.c
*/
extern int con_set_trans_old(char * table);
extern int con_get_trans_old(char * table);
extern int con_set_trans_old(unsigned char * table);
extern int con_get_trans_old(unsigned char * table);
extern int con_set_trans_new(unsigned short * table);
extern int con_get_trans_new(unsigned short * table);
extern void con_clear_unimap(struct unimapinit *ui);
......@@ -1007,10 +1007,10 @@ int vt_ioctl(struct tty_struct *tty, struct file * file,
case PIO_SCRNMAP:
if (!perm)
return -EPERM;
return con_set_trans_old((char *)arg);
return con_set_trans_old((unsigned char *)arg);
case GIO_SCRNMAP:
return con_get_trans_old((char *)arg);
return con_get_trans_old((unsigned char *)arg);
case PIO_UNISCRNMAP:
if (!perm)
......
......@@ -10,7 +10,7 @@
* be here without 3C505 technical reference provided by
* 3Com.
*
* Version: @(#)3c505.c 0.8 4-Jun-95
* Version: @(#)3c505.c 0.8.1 26-Jun-95
*
* Authors: Linux 3c505 device driver by
* Craig Southeren, <craigs@ineluki.apana.org.au>
......@@ -101,7 +101,7 @@ static int elp_debug = 0;
* 3 = messages when interrupts received
*/
#define ELP_VERSION "0.7.0"
#define ELP_VERSION "0.8.1"
/*****************************************************************
*
......@@ -182,7 +182,7 @@ outw_data (unsigned int val, unsigned int base_addr)
*****************************************************************/
typedef struct {
short got[NUM_TRANSMIT_CMDS]; /* flags for command completion */
volatile short got[NUM_TRANSMIT_CMDS]; /* flags for command completion */
pcb_struct tx_pcb; /* PCB for foreground sending */
pcb_struct rx_pcb; /* PCB for foreground receiving */
pcb_struct itx_pcb; /* PCB for background sending */
......
......@@ -48,15 +48,15 @@
# If you want at least one board to not autosense then
# no board can autosense. For a board mix of several
# types, OR the manual values [eg for a DE500 (100M) with
# a DE450 (AUI) use '-DDE4X5_AUTOSENSE=(0x80|0x08)']
# For full auto media/mode selection = 0x4000
# For manual TP media selection = 0x01
# For manual TP/Nway media selection (DC21041) = 0x02
# For manual BNC media selection = 0x04
# For manual AUI media selection = 0x08
# For manual BNC/AUI media selection (DC21040) = 0x10
# For manual 10Mb/s mode selection (DC21140) = 0x40
# For manual 100Mb/s mode selection (DC21140) = 0x80
# a DE450 (AUI) use '-DDE4X5_AUTOSENSE=(_100Mb|AUI)']
# For full auto media/mode selection = AUTO
# For manual TP media selection = TP
# For manual TP/Nway media selection (DC21041) = TP_NW
# For manual BNC media selection = BNC
# For manual AUI media selection = AUI
# For manual BNC/AUI media selection (DC21040) = BNC_AUI
# For manual 10Mb/s mode selection (DC21140) = _10Mb
# For manual 100Mb/s mode selection (DC21140) = _100Mb
# The DC21040 will default to TP if TP_NW is specified
# The DC21041 will default to BNC if BNC_AUI is specified
# The DC21140 needs it's speed to be manually set to
......@@ -83,5 +83,6 @@ HP_OPTS =
PLIP_OPTS =
DEPCA_OPTS = -DDEPCA_DEBUG=1
EWRK3_OPTS = -DEWRK3_DEBUG=1
DE4X5_OPTS = -DDE4X5_DEBUG=1 -DDE4X5_AUTOSENSE=0x4000
DE4X5_OPTS = -DDE4X5_DEBUG=1 -DDE4X5_AUTOSENSE=AUTO
ELP_OPTS = -DELP_DEBUG=1 -DELP_NEED_HARD_RESET=0
......@@ -36,6 +36,10 @@ ifdef CONFIG_NET_IPIP
NETDRV_OBJS := $(NETDRV_OBJS) tunnel.o
endif
ifdef CONFIG_HP100
NETDRV_OBJS := $(NETDRV_OBJS) hp100.o
endif
ifdef CONFIG_WD80x3
NETDRV_OBJS := $(NETDRV_OBJS) wd.o
CONFIG_8390 = CONFIG_8390
......@@ -212,7 +216,7 @@ else
MODULES := $(MODULES) de4x5.o
endif
de4x5.o: de4x5.c CONFIG
$(CC) $(CPPFLAGS) $(CFLAGS) $(DE4x5_OPTS) -c $<
$(CC) $(CPPFLAGS) $(CFLAGS) $(DE4X5_OPTS) -c $<
ifdef CONFIG_NI52
NETDRV_OBJS := $(NETDRV_OBJS) ni52.o
......
......@@ -38,6 +38,7 @@
ethernet adaptor have the name "eth[0123...]".
*/
extern int hp100_probe(struct device *dev);
extern int ultra_probe(struct device *dev);
extern int wd_probe(struct device *dev);
extern int el2_probe(struct device *dev);
......@@ -74,12 +75,15 @@ extern int de620_probe(struct device *);
static int
ethif_probe(struct device *dev)
{
short base_addr = dev->base_addr;
u_long base_addr = dev->base_addr;
if (base_addr < 0 || base_addr == 1)
if ((base_addr == 0xffe0) || (base_addr == 1))
return 1; /* ENXIO */
if (1
#if defined(CONFIG_HP100)
&& hp100_probe(dev)
#endif
#if defined(CONFIG_ULTRA)
&& ultra_probe(dev)
#endif
......
This diff is collapsed.
......@@ -153,7 +153,7 @@
/*
** PCI Configuration Base I/O Address Register (PCI_CBIO)
*/
#define CBIO_MASK 0x0000ff80 /* Base I/O Address Mask */
#define CBIO_MASK 0xffffff80 /* Base I/O Address Mask */
#define CBIO_IOSI 0x00000001 /* I/O Space Indicator (RO, value is 1) */
/*
......@@ -642,6 +642,3 @@ struct de4x5_ioctl {
#define DE4X5_GET_OMR 0x0c /* Get the OMR Register contents */
#define DE4X5_SET_OMR 0x0d /* Set the OMR Register contents */
#define DE4X5_GET_REG 0x0e /* Get the DE4X5 Registers */
This diff is collapsed.
......@@ -62,6 +62,8 @@
#define STOP 0x0004 /* Stop */
#define STRT 0x0002 /* Start */
#define INIT 0x0001 /* Initialize */
#define INTM 0xff00 /* Interrupt Mask */
#define INTE 0xfff0 /* Interrupt Enable */
/*
** CONTROL AND STATUS REGISTER 3 (CSR3)
......@@ -110,6 +112,7 @@
#define T_DEF 0x0400 /* Deferred */
#define T_STP 0x02000000 /* Start of Packet */
#define T_ENP 0x01000000 /* End of Packet */
#define T_FLAGS 0xff000000 /* TX Flags Field */
/*
** Transmit Message Descriptor 3 (TMD3) bit definitions.
......@@ -139,10 +142,44 @@
/*
** Miscellaneous
*/
#define HASH_TABLE_LEN 64 /* Bits */
#define HASH_BITS 0x003f /* 6 LS bits */
#define MASK_INTERRUPTS 1
#define UNMASK_INTERRUPTS 0
#define EISA_EN 0x0001 /* Enable EISA bus buffers */
#define DEPCA_EISA_ID ioaddr+0x80 /* ID long word for EISA card */
#define DEPCA_EISA_CTRL ioaddr+0x84 /* Control word for EISA card */
#define EISA_EN 0x0001 /* Enable EISA bus buffers */
#define EISA_ID iobase+0x0080 /* ID long word for EISA card */
#define EISA_CTRL iobase+0x0084 /* Control word for EISA card */
/*
** Include the IOCTL stuff
*/
#include <linux/sockios.h>
#define DEPCAIOCTL SIOCDEVPRIVATE
struct depca_ioctl {
unsigned short cmd; /* Command to run */
unsigned short len; /* Length of the data buffer */
unsigned char *data; /* Pointer to the data buffer */
};
/*
** Recognised commands for the driver
*/
#define DEPCA_GET_HWADDR 0x01 /* Get the hardware address */
#define DEPCA_SET_HWADDR 0x02 /* Get the hardware address */
#define DEPCA_SET_PROM 0x03 /* Set Promiscuous Mode */
#define DEPCA_CLR_PROM 0x04 /* Clear Promiscuous Mode */
#define DEPCA_SAY_BOO 0x05 /* Say "Boo!" to the kernel log file */
#define DEPCA_GET_MCA 0x06 /* Get a multicast address */
#define DEPCA_SET_MCA 0x07 /* Set a multicast address */
#define DEPCA_CLR_MCA 0x08 /* Clear a multicast address */
#define DEPCA_MCA_EN 0x09 /* Enable a multicast address group */
#define DEPCA_GET_STATS 0x0a /* Get the driver statistics */
#define DEPCA_CLR_STATS 0x0b /* Zero out the driver statistics */
#define DEPCA_GET_REG 0x0c /* Get the Register contents */
#define DEPCA_SET_REG 0x0d /* Set the Register contents */
#define DEPCA_DUMP 0x0f /* Dump the DEPCA Status */
This diff is collapsed.
This diff is collapsed.
......@@ -1517,7 +1517,7 @@ ppp_ioctl(struct tty_struct *tty, struct file *file, unsigned int i,
case PPPIOCSDEBUG:
error = verify_area (VERIFY_READ, (void *) l, sizeof (temp_i));
if (error == 0) {
ppp_debug = get_int ((int *) l);
ppp_debug = get_user ((int *) l);
ppp_debug_netpackets = (ppp_debug & 0xff00) >> 8;
ppp_debug &= 0xff;
PRINTKN (1, (KERN_INFO "ppp_ioctl: set debug level %d, netpacket %d\n",
......
......@@ -41,6 +41,7 @@ struct pci_dev_info dev_info[] = {
DEVICE( NCR, NCR_53C825, "53c825"),
DEVICE( ADAPTEC, ADAPTEC_2940, "2940"),
DEVICE( ADAPTEC, ADAPTEC_294x, "294x"),
DEVICE( ADAPTEC, ADAPTEC_7850, "AIC-7850"),
DEVICE( DPT, DPT, "SmartCache/Raid"),
DEVICE( S3, S3_864_1, "Vision 864-P"),
DEVICE( S3, S3_864_2, "Vision 864-P"),
......@@ -57,9 +58,11 @@ struct pci_dev_info dev_info[] = {
BRIDGE( UMC, UMC_UM8881F, "UM8881F", 0x02),
BRIDGE( UMC, UMC_UM8891A, "UM8891A", 0x01),
DEVICE( UMC, UMC_UM8886F, "UM8886F"),
DEVICE( UMC, UMC_UM8886A, "UM8886A"),
DEVICE( UMC, UMC_UM8673F, "UM8673F"),
DEVICE( DEC, DEC_TULIP, "DC21040"),
DEVICE( DEC, DEC_TULIP_FAST, "DC21040"),
DEVICE( DEC, DEC_TULIP_FAST, "DC21140"),
DEVICE( DEC, DEC_TULIP_PLUS, "DC21041"),
DEVICE( DEC, DEC_FDDI, "DEFPA"),
DEVICE( DEC, DEC_BRD, "DC21050"),
DEVICE( MATROX, MATROX_MGA_2, "Atlas PX2085"),
......@@ -80,6 +83,7 @@ struct pci_dev_info dev_info[] = {
DEVICE( CIRRUS, CIRRUS_5434_4, "GD 5434"),
DEVICE( CIRRUS, CIRRUS_5434_8, "GD 5434"),
DEVICE( CIRRUS, CIRRUS_6729, "CL 6729"),
DEVICE( CIRRUS, CIRRUS_7542, "CL 7542"),
DEVICE( BUSLOGIC, BUSLOGIC_946C, "946C"),
DEVICE( BUSLOGIC, BUSLOGIC_946C_2,"946C"),
DEVICE( N9, N9_I128, "Imagine 128"),
......@@ -128,7 +132,8 @@ struct pci_dev_info dev_info[] = {
DEVICE( PROMISE, PROMISE_5300, "DC5030"),
DEVICE( QLOGIC, QLOGIC_ISP1020, "ISP1020"),
DEVICE( QLOGIC, QLOGIC_ISP1022, "ISP1022"),
DEVICE( X, X_AGX016, "ITT AGX016")
DEVICE( X, X_AGX016, "ITT AGX016"),
DEVICE( VORTEX, VORTEX_GDT, "GDT 6000b")
};
......@@ -327,6 +332,9 @@ const char *pci_strvendor(unsigned int vendor)
case PCI_VENDOR_ID_3COM: return "3Com";
case PCI_VENDOR_ID_PROMISE: return "Promise Technology";
case PCI_VENDOR_ID_QLOGIC: return "Q Logic";
case PCI_VENDOR_ID_X: return "X TECHNOLOGY";
case PCI_VENDOR_ID_ACC: return "ACC MICROELECTRONICS";
case PCI_VENDOR_ID_VORTEX: return "VORTEX";
default: return "Unknown vendor";
}
}
......
......@@ -168,6 +168,7 @@
#include <linux/errno.h>
#include <linux/bios32.h>
#include <linux/pci.h>
#include <linux/proc_fs.h>
#include <linux/string.h>
#include <linux/mm.h>
#include "../block/blk.h"
......@@ -218,7 +219,7 @@ static Scsi_Host_Template *the_template = NULL;
*
* NCR53c720/710 - need to add fatal interrupt or GEN code for
* command completion signaling. Need to take care of
* ADD WITH CARRY instructions since carry is unimplemented.
* ADD WITH CARRY instructions since carry is unimplemented.
* Also need to modify all SDID, SCID, etc. registers,
* and table indirect select code since these use bit
* fielded (ie 1<<target) instead of binary encoded
......@@ -642,7 +643,7 @@ NCR53c7x0_init (struct Scsi_Host *host) {
hostdata->expecting_sto = 0;
if ((hostdata->run_tests && hostdata->run_tests(host) == -1) ||
(hostdata->options & OPTION_DEBUG_TESTS_ONLY)) {
(hostdata->options & OPTION_DEBUG_TESTS_ONLY)) {
/* XXX Should disable interrupts, etc. here */
scsi_unregister (host);
return -1;
......@@ -720,8 +721,8 @@ static int normal_init (Scsi_Host_Template *tpnt, int board, int chip,
/* Size of dynamic part of command structure : */
2 * /* Worst case : we don't know if we need DATA IN or DATA out */
( 2 * /* Current instructions per scatter/gather segment */
tpnt->sg_tablesize +
3 /* Current startup / termination required per phase */
tpnt->sg_tablesize +
3 /* Current startup / termination required per phase */
) *
8 /* Each instruction is eight bytes */;
/* Note that alignment will be guaranteed, since we put the command
......@@ -742,7 +743,7 @@ static int normal_init (Scsi_Host_Template *tpnt, int board, int chip,
ASSUMPTION :
Regardless of how many simultaneous SCSI commands we allow,
the probe code only executes a _single_ instruction at a time,
the probe code only executes a _single_ instruction at a time,
so we only need one here, and don't need to allocate NCR53c7x0_cmd
structures for each target until we are no longer in scan_scsis
and kmalloc() has become functional (memory_init() happens
......@@ -879,9 +880,9 @@ static int ncr_pci_init (Scsi_Host_Template *tpnt, int board, int chip,
(error = pcibios_read_config_word (bus, device_fn, PCI_COMMAND,
&command)) ||
(error = pcibios_read_config_dword (bus, device_fn,
PCI_BASE_ADDRESS_0, &io_port)) ||
PCI_BASE_ADDRESS_0, (int *) &io_port)) ||
(error = pcibios_read_config_dword (bus, device_fn,
PCI_BASE_ADDRESS_1, &base)) ||
PCI_BASE_ADDRESS_1, (int *) &base)) ||
(error = pcibios_read_config_byte (bus, device_fn, PCI_CLASS_REVISION,
&revision)) ||
(error = pcibios_read_config_byte (bus, device_fn, PCI_INTERRUPT_LINE,
......@@ -951,7 +952,7 @@ static int ncr_pci_init (Scsi_Host_Template *tpnt, int board, int chip,
if (chip && device_id != expected_id)
printk ("scsi-ncr53c7,8xx : warning : device id of 0x%04x doesn't\n"
" match expected 0x%04x\n",
" match expected 0x%04x\n",
(unsigned int) device_id, (unsigned int) expected_id );
if (max_revision != -1 && revision > max_revision)
......@@ -1015,7 +1016,7 @@ int NCR53c7xx_detect(Scsi_Host_Template *tpnt) {
!pcibios_find_device (PCI_VENDOR_ID_NCR,
pci_chip_ids[i].pci_device_id, pci_index, &pci_bus,
&pci_device_fn) &&
!ncr_pci_init (tpnt, BOARD_GENERIC, pci_chip_ids[i].chip,
!ncr_pci_init (tpnt, BOARD_GENERIC, pci_chip_ids[i].chip,
pci_bus, pci_device_fn, /* no options */ 0);
++count, ++pci_index);
}
......@@ -1275,7 +1276,7 @@ static int NCR53c8xx_run_tests (struct Scsi_Host *host) {
if (hostdata->test_dest != 0xdeadbeef) {
printk ("scsi%d : driver test 1 read 0x%x instead of 0xdeadbeef indicating a\n"
" probable cache invalidation problem. Please configure caching\n"
" probable cache invalidation problem. Please configure caching\n"
" as write-through or disabled\n",
host->host_no, hostdata->test_dest);
}
......@@ -1872,7 +1873,7 @@ static int NCR53c8x0_dstat_sir_intr (struct Scsi_Host *host, struct
* status, etc are used.
*/
cmd->cmd->result = 0xffff;
cmd->cmd->result = 0xffff;
/*
* Restart command as a REQUEST SENSE.
......@@ -2285,13 +2286,19 @@ NCR53c8x0_soft_reset (struct Scsi_Host *host) {
* and SCSI recommended .5s selection timeout.
*/
/*
* The new gcc won't recognize preprocessing directives
* within macro args.
*/
#if 0
NCR53c7x0_write8(STIME0_REG_800,
((14 << STIME0_800_SEL_SHIFT) & STIME0_800_SEL_MASK)
/* Disable HTH interrupt */
#if 0
| ((15 << STIME0_800_HTH_SHIFT) & STIME0_800_HTH_MASK)
| ((15 << STIME0_800_HTH_SHIFT) & STIME0_800_HTH_MASK));
#else
NCR53c7x0_write8(STIME0_REG_800,
((14 << STIME0_800_SEL_SHIFT) & STIME0_800_SEL_MASK));
#endif
);
......@@ -2344,7 +2351,7 @@ create_cmd (Scsi_Cmnd *cmd) {
NCR53c7x0_local_declare();
struct Scsi_Host *host = cmd->host;
struct NCR53c7x0_hostdata *hostdata = (struct NCR53c7x0_hostdata *)
host->hostdata;
host->hostdata;
struct NCR53c7x0_cmd *tmp = NULL; /* NCR53c7x0_cmd structure for this command */
int datain, /* Number of instructions per phase */
dataout;
......@@ -2601,7 +2608,7 @@ create_cmd (Scsi_Cmnd *cmd) {
DCMD_TCI_CD | DCMD_TCI_IO | DCMD_TCI_MSG) << 24) |
DBC_TCI_WAIT_FOR_VALID | DBC_TCI_COMPARE_PHASE | DBC_TCI_TRUE;
cmd_datain[3] = virt_to_bus(hostdata->script) +
hostdata->E_msg_in;
hostdata->E_msg_in;
#if 0
print_insn (host, cmd_datain, "dynamic ", 1);
print_insn (host, cmd_datain + 2, "dynamic ", 1);
......@@ -2615,7 +2622,7 @@ create_cmd (Scsi_Cmnd *cmd) {
DCMD_TCI_CD | DCMD_TCI_IO | DCMD_TCI_MSG) << 24) |
DBC_TCI_WAIT_FOR_VALID | DBC_TCI_COMPARE_PHASE | DBC_TCI_TRUE;
cmd_dataout[3] = virt_to_bus(hostdata->script) +
hostdata->E_msg_in;
hostdata->E_msg_in;
#if 0
print_insn (host, cmd_dataout, "dynamic ", 1);
print_insn (host, cmd_dataout + 2, "dynamic ", 1);
......@@ -2900,7 +2907,7 @@ static void intr_scsi (struct Scsi_Host *host, struct NCR53c7x0_cmd *cmd) {
/* selection timeout */
if ((is_8xx_chip && (sist1 & SIST1_800_STO)) ||
(!is_8xx_chip && (sstat0_sist0 & SSTAT0_700_STO))) {
(!is_8xx_chip && (sstat0_sist0 & SSTAT0_700_STO))) {
fatal = 1;
if (hostdata->options & OPTION_DEBUG_INTR) {
printk ("scsi%d : Selection Timeout\n", host->host_no);
......@@ -3112,8 +3119,8 @@ static void NCR53c7x0_intr (int irq, struct pt_regs * regs) {
restart:
for (cmd_prev_ptr = (struct NCR53c7x0_cmd **)
&(hostdata->running_list), cmd =
(struct NCR53c7x0_cmd *) hostdata->running_list; cmd ;
cmd_prev_ptr = (struct NCR53c7x0_cmd **) &(cmd->next),
(struct NCR53c7x0_cmd *) hostdata->running_list; cmd ;
cmd_prev_ptr = (struct NCR53c7x0_cmd **) &(cmd->next),
cmd = (struct NCR53c7x0_cmd *) cmd->next) {
Scsi_Cmnd *tmp;
......@@ -3766,9 +3773,9 @@ int NCR53c7xx_abort (Scsi_Cmnd *cmd) {
*/
for (curr = (volatile struct NCR53c7x0_cmd *) hostdata->issue_queue,
prev = (volatile struct NCR53c7x0_cmd **) &(hostdata->issue_queue);
prev = (volatile struct NCR53c7x0_cmd **) &(hostdata->issue_queue);
curr && curr->cmd != cmd; prev = (volatile struct NCR53c7x0_cmd **)
&(curr->next), curr = (volatile struct NCR53c7x0_cmd *) curr->next);
&(curr->next), curr = (volatile struct NCR53c7x0_cmd *) curr->next);
if (curr) {
*prev = (struct NCR53c7x0_cmd *) curr->next;
......@@ -3793,7 +3800,7 @@ int NCR53c7xx_abort (Scsi_Cmnd *cmd) {
for (curr = (volatile struct NCR53c7x0_cmd *) hostdata->running_list,
prev = (volatile struct NCR53c7x0_cmd **) &(hostdata->running_list);
curr && curr->cmd != cmd; prev = (volatile struct NCR53c7x0_cmd **)
&(curr->next), curr = (volatile struct NCR53c7x0_cmd *) curr->next);
&(curr->next), curr = (volatile struct NCR53c7x0_cmd *) curr->next);
if (curr) {
restore_flags(flags);
......@@ -3973,7 +3980,7 @@ ncr_halt (struct Scsi_Host *host) {
tmp = NCR53c7x0_read8(SSTAT0_REG);
}
} else if (istat & ISTAT_DIP) {
NCR53c7x0_write8(hostdata->istat, 0);
NCR53c7x0_write8(hostdata->istat, 0);
tmp = NCR53c7x0_read8(DSTAT_REG);
if (tmp & DSTAT_ABRT)
break;
......
......@@ -78,12 +78,15 @@ extern int NCR53c7xx_release(struct Scsi_Host *);
#define NCR53c7xx_release NULL
#endif
#define NCR53c7xx {NULL, NULL, "NCR53c{7,8}xx (rel 4)", NCR53c7xx_detect, \
extern int generic_proc_info(char *, char **, off_t, int, int, int);
#define NCR53c7xx {NULL, NULL, generic_proc_info, "NCR53c7xx", \
PROC_SCSI_NCR53C7xx, "NCR53c{7,8}xx (rel 4)", NCR53c7xx_detect, \
NULL, /* info */ NULL, /* command, deprecated */ NULL, \
NCR53c7xx_queue_command, NCR53c7xx_abort, NCR53c7xx_reset, \
NULL /* slave attach */, scsicam_bios_param, /* can queue */ 1, \
NULL /* slave attach */, scsicam_bios_param, /* can queue */ 1, \
/* id */ 7, 127 /* old SG_ALL */, /* cmd per lun */ 1 , \
/* present */ 0, /* unchecked isa dma */ 0, DISABLE_CLUSTERING}
/* present */ 0, /* unchecked isa dma */ 0, DISABLE_CLUSTERING}
#endif /* defined(HOSTS_C) || defined(MODULE) */
#ifndef HOSTS_C
......@@ -385,9 +388,9 @@ extern int NCR53c7xx_release(struct Scsi_Host *);
/* 0x80 - 0x04 are reserved */
#define CTEST0_700_RTRG 0x02 /* Real target mode */
#define CTEST0_700_DDIR 0x01 /* Data direction, 1 =
* SCSI bus to host, 0 =
* host to SCSI.
*/
* SCSI bus to host, 0 =
* host to SCSI.
*/
#define CTEST1_REG_700 0x15 /* Chip test 1 ro */
#define CTEST1_REG_800 0x19 /* Chip test 1 ro */
......@@ -544,7 +547,7 @@ extern int NCR53c7xx_release(struct Scsi_Host *);
#define CTEST7_EVP 0x04 /* 1 = host bus even parity, 0 = odd */
#define CTEST7_10_TT1 0x02 /* Transfer type */
#define CTEST7_00_DC 0x02 /* Set to drive DC low during instruction
fetch */
fetch */
#define CTEST7_DIFF 0x01 /* Differential mode */
#define CTEST7_SAVE ( CTEST7_EVP | CTEST7_DIFF )
......@@ -620,8 +623,8 @@ extern int NCR53c7xx_release(struct Scsi_Host *);
* speeds.
*/
#define CTEST8_0066_DAS 0x02 /* Disable automatic target/initiator
* switching.
*/
* switching.
*/
#define CTEST8_0066_LDE 0x01 /* Last disconnect enable.
* The status of pending
* disconnect is maintained by
......@@ -980,11 +983,12 @@ struct NCR53c7x0_cmd {
volatile struct NCR53c7x0_cmd *next, *prev;
/* Linux maintained lists. Note that
/* Linux maintained lists. Note that
hostdata->free is a singly linked
list; the rest are doubly linked */
long dsa_size; /* Size of DSA structure */
u32 *data_transfer_start; /* Start of data transfer routines */
u32 *data_transfer_end; /* Address after end of data transfer o
......@@ -1058,7 +1062,7 @@ struct NCR53c7x0_hostdata {
* NCR53c700-66 = 70066
* NCR53c710 = 710
* NCR53c720 = 720
* NCR53c810 = 810
* NCR53c810 = 810
*/
/*
......@@ -1216,7 +1220,7 @@ struct NCR53c7x0_hostdata {
to other target/lun combinations */
int debug_count_limit; /* Number of commands to execute
before puking to limit debugging
before puking to limit debugging
output */
......@@ -1364,7 +1368,7 @@ struct NCR53c7x0_hostdata {
(offset)]); \
}
#define patch_abs_rwri_data(script, offset, symbol, value) \
#define patch_abs_rwri_data(script, offset, symbol, value) \
for (i = 0; i < (sizeof (A_##symbol##_used) / sizeof \
(u32)); ++i) \
(script)[A_##symbol##_used[i] - (offset)] = \
......
Mon May 15 19:33:14 1995 Michael Neuffer <neuffer@goofy.zdv.uni-mainz.de>
* scsi.c: Added native multichannel and wide scsi support.
* proc.c (dispatch_scsi_info) (build_proc_dir_hba_entries):
Updated /proc/scsi interface.
Thu May 4 17:58:48 1995 Michael Neuffer <neuffer@goofy.zdv.uni-mainz.de>
* sd.c (requeue_sd_request): zero out the scatterlist only if
scsi_malloc returned memory for it.
* eata_dma.c (register_HBA) (eata_queue): add support for
large scatter/gatter tables and set use_clustering accordingly
* hosts.c: make use_clustering changable in the Scsi_Host structure.
Wed Apr 12 15:25:52 1995 Eric Youngdale (eric@andante)
* Linux 1.2.5 released.
......@@ -7,7 +23,12 @@ Wed Apr 12 15:25:52 1995 Eric Youngdale (eric@andante)
complete commands per interrupt. Seems to come up with faster
cards.
* eata_dma.c: Modularize. Update to 2.3.5r.
* eata_dma.c: Update to 2.3.5r. Modularize. Improved error handling
thruout and fixed bug interrupt routine which resulted in shifted
status bytes. Added blink LED state checks for ISA and EISA HBAs.
Memory mamagement bug seems to have disapeared ==> increasing
C_P_L_CURRENT_MAX to 16 for now. Decreasing C_P_L_DIV to 3 for
performance reasons.
* scsi.c: If we get a FMK, EOM, or ILI when attempting to scan
the bus, assume that it was just noise on the bus, and ignore
......@@ -86,11 +107,11 @@ Mon Feb 20 08:57:17 1995 Eric Youngdale (eric@andante)
* hosts.h: Change io_port to long int from short.
* 53c7,8xx.c: crash on AEN fixed, SCSI reset is no longer a NOP,
NULL pointer panic on odd UDCs fixed, two bugs in diagnostic output
fixed, should initialize correctly if left running, now loadable,
new memory allocation, extraneous diagnostic output suppressed,
splx() replaced with save/restore flags. [ Drew ]
* 53c7,8xx.c: crash on AEN fixed, SCSI reset is no longer a NOP,
NULL pointer panic on odd UDCs fixed, two bugs in diagnostic output
fixed, should initialize correctly if left running, now loadable,
new memory allocation, extraneous diagnostic output suppressed,
splx() replaced with save/restore flags. [ Drew ]
* hosts.c, hosts.h, scsi_ioctl.c, sd.c, sd_ioctl.c, sg.c, sr.c,
sr_ioctl.c: Add special junk at end that Emacs will use for
......@@ -119,7 +140,10 @@ Wed Feb 15 10:52:56 1995 Eric Youngdale (eric@andante)
* eata.c: Update to 1.17.
* eata_dma.c: Add more support for /proc/scsi, add HBA_interpret flag.
* eata_dma.c: Update to 2.31a. Add more support for /proc/scsi.
Continuing modularization. Less crashes because of the bug in the
memory management ==> increase C_P_L_CURRENT_MAX to 10
and decrease C_P_L_DIV to 4.
* hosts.c: If we remove last host registered, reuse host number.
When freeing memory from host being deregistered, free extra_bytes
......@@ -188,8 +212,12 @@ Wed Feb 1 09:20:45 1995 Eric Youngdale (eric@andante)
* NCR5380.c: Update interrupt handler with new arglist. Minor
cleanups.
* eata_dma.c: Modularize. Add hooks for /proc/scsi.
New version 2.3.0a.
* eata_dma.c: Begin to modularize. Add hooks for /proc/scsi.
New version 2.3.0a. Add code in interrupt handler to allow
certain CDROM drivers to be detected which return a
CHECK_CONDITION during SCSI bus scan. Add opcode check to get
all DATA IN and DATA OUT phases right. Utilize HBA_interpret flag.
Improvements in HBA identification. Various other minor stuff.
* hosts.c: Initialize ->dma_channel and ->io_port when registering
a new host.
......@@ -238,7 +266,9 @@ Mon Jan 23 23:53:10 1995 Eric Youngdale (eric@andante)
* 53c7,8xx.h: Change SG size to 127.
* eata_dma: Update to version 0i.
* eata_dma: Update to version 2.10i. Remove bug in the registration
of multiple HBAs and channels. Minor other improvements and stylistic
changes.
* scsi.c: Test for Toshiba XM-3401TA and exclude from detection
as toshiba drive - photo cd does not work with this drive.
......@@ -262,7 +292,9 @@ Sun Jan 22 22:08:46 1995 Eric Youngdale (eric@andante)
* aha152x.c: Update to version 1.8 from Juergen.
* eata_dma.c: Update from Michael Neuffer
* eata_dma.c: Update from Michael Neuffer.
Remove hard limit of 2 commands per lun and make it better
configurable. Improvements in HBA identification.
* in2000.c: Fix biosparam to support large disks.
......@@ -278,7 +310,7 @@ Wed Jan 18 23:33:09 1995 Eric Youngdale (eric@andante)
* buslogic.c: Likewise.
* eata_dma.c: Use min of 2 cmd_per_lun for OCS_enabled boards.
* scsi.c: Make RECOVERED_ERROR a SUGGEST_IS_OK.
* sd.c: Fail if we are opening a non-existent partition.
......@@ -290,7 +322,7 @@ Wed Jan 18 23:33:09 1995 Eric Youngdale (eric@andante)
* sr_ioctl.c: Remove CDROMMULTISESSION_SYS ioctl.
* ultrastor.c: Fix bug in call to ultrastor_interrupt (wrong #args).
Mon Jan 16 07:18:23 1995 Eric Youngdale (eric@andante)
* Linux 1.1.82 released.
......
This diff is collapsed.
This diff is collapsed.
......@@ -293,10 +293,10 @@ static void NCR5380_reselect (struct Scsi_Host *instance);
static int NCR5380_select (struct Scsi_Host *instance, Scsi_Cmnd *cmd, int tag);
#if defined(PSEUDO_DMA) || defined(REAL_DMA) || defined(REAL_DMA_POLL)
static int NCR5380_transfer_dma (struct Scsi_Host *instance,
unsigned char *phase, int *count, unsigned char **data);
unsigned char *phase, int *count, unsigned char **data);
#endif
static int NCR5380_transfer_pio (struct Scsi_Host *instance,
unsigned char *phase, int *count, unsigned char **data);
unsigned char *phase, int *count, unsigned char **data);
#if (defined(REAL_DMA) || defined(REAL_DMA_POLL)) && defined(i386)
static __inline__ int NCR5380_i386_dma_setup (struct Scsi_Host *instance,
......
The 274x/284x support is basically the same as in the kernel, with
some minor structural changes. The 294x support is preliminary, with
a few things still hardwired (like the SCSI ID and FIFO threshold).
You have been warned.
To function properly, you must use this with a kernel version 1.1.68
or above - these have the SCSI changes in the kernel which support
varying numbers of outstanding SCSI commands per driver instance (they
also contain the Adaptec PCI definitions).
You can find instructions in the SCSI-HOWTO on how to install SCSI
drivers into the kernel. In a nutshell, find all the aha274x stuff
and change it to aic7xxx.
Please direct all problems to the AIC7770 mailing list - see the README
for details.
:ja
This diff is collapsed.
......@@ -18,6 +18,8 @@ int aha152x_abort(Scsi_Cmnd *);
int aha152x_reset(Scsi_Cmnd *);
int aha152x_biosparam(Disk *, int, int*);
extern int generic_proc_info(char *, char **, off_t, int, int, int);
/* number of queueable commands
(unless we support more than 1 cmd_per_lun this should do) */
#define AHA152X_MAXQUEUE 7
......@@ -27,22 +29,25 @@ int aha152x_biosparam(Disk *, int, int*);
/* Initial value of Scsi_Host entry */
#define AHA152X { /* next */ NULL, \
/* usage_count */ NULL, \
generic_proc_info, \
"aha152x", \
PROC_SCSI_AHA152X, \
/* name */ AHA152X_REVID, \
/* detect */ aha152x_detect, \
/* release */ NULL, \
/* info */ NULL, \
/* info */ NULL, \
/* command */ aha152x_command, \
/* queuecommand */ aha152x_queue, \
/* abort */ aha152x_abort, \
/* reset */ aha152x_reset, \
/* slave_attach */ /* NULL */ 0, \
/* bios_param */ aha152x_biosparam, \
/* abort */ aha152x_abort, \
/* reset */ aha152x_reset, \
/* slave_attach */ /* NULL */ 0, \
/* bios_param */ aha152x_biosparam, \
/* can_queue */ 1, \
/* this_id */ 7, \
/* sg_tablesize */ SG_ALL, \
/* cmd_per_lun */ 1, \
/* present */ 0, \
/* unchecked_isa_dma */ 0, \
/* this_id */ 7, \
/* sg_tablesize */ SG_ALL, \
/* cmd_per_lun */ 1, \
/* present */ 0, \
/* unchecked_isa_dma */ 0, \
/* use_clustering */ DISABLE_CLUSTERING }
#endif
......@@ -150,12 +155,12 @@ int aha152x_biosparam(Disk *, int, int*);
/* SCSI transfer count */
#define GETSTCNT() ( (GETPORT(STCNT2)<<16) \
+ (GETPORT(STCNT1)<< 8) \
+ GETPORT(STCNT0) )
+ (GETPORT(STCNT1)<< 8) \
+ GETPORT(STCNT0) )
#define SETSTCNT(X) { SETPORT(STCNT2, ((X) & 0xFF0000) >> 16); \
SETPORT(STCNT1, ((X) & 0x00FF00) >> 8); \
SETPORT(STCNT0, ((X) & 0x0000FF) ); }
SETPORT(STCNT1, ((X) & 0x00FF00) >> 8); \
SETPORT(STCNT0, ((X) & 0x0000FF) ); }
/* SCSI interrupt status */
#define TARGET 0x80
......@@ -339,22 +344,22 @@ typedef union {
#ifdef DEBUG_AHA152X
enum {
debug_skipports =0x0001,
debug_queue =0x0002,
debug_intr =0x0004,
debug_selection =0x0008,
debug_msgo =0x0010,
debug_msgi =0x0020,
debug_status =0x0040,
debug_cmd =0x0080,
debug_datai =0x0100,
debug_datao =0x0200,
debug_abort =0x0400,
debug_done =0x0800,
debug_biosparam =0x1000,
debug_phases =0x2000,
debug_queues =0x4000,
debug_reset =0x8000,
debug_skipports =0x0001,
debug_queue =0x0002,
debug_intr =0x0004,
debug_selection =0x0008,
debug_msgo =0x0010,
debug_msgi =0x0020,
debug_status =0x0040,
debug_cmd =0x0080,
debug_datai =0x0100,
debug_datao =0x0200,
debug_abort =0x0400,
debug_done =0x0800,
debug_biosparam =0x1000,
debug_phases =0x2000,
debug_queues =0x4000,
debug_reset =0x8000,
};
#endif
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -89,7 +89,7 @@
#include <linux/ioport.h>
#include <linux/delay.h>
#include <linux/config.h>
#include <linux/proc_fs.h>
#include <asm/io.h>
#include <asm/system.h>
#include <asm/dma.h>
......
......@@ -12,7 +12,12 @@ const char *buslogic_info(struct Scsi_Host *);
int buslogic_reset(Scsi_Cmnd *);
int buslogic_biosparam(Disk *, int, int *);
extern int generic_proc_info(char *, char **, off_t, int, int, int);
#define BUSLOGIC { NULL, NULL, \
generic_proc_info, \
"buslogic", \
PROC_SCSI_BUSLOGIC, \
"BusLogic", \
buslogic_detect, \
0, /* no release func */ \
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
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