Commit c6c91a46 authored by Paul Mackerras's avatar Paul Mackerras

Merge samba.org:/home/paulus/kernel/linux-2.5

into samba.org:/home/paulus/kernel/for-linus-ppc
parents ff2bdcb0 9fb72010
......@@ -1337,6 +1337,12 @@ S: 998 East 900 South, Suite 26
S: Provo, Utah 84606-5607
S: USA
N: Marcel Holtmann
E: marcel@holtmann.org
W: http://www.holtmann.org
D: Author of the Linux Bluetooth Subsystem PC Card drivers
S: Germany
N: Rob W. W. Hooft
E: hooft@EMBL-Heidelberg.DE
D: Shared libs for graphics-tools and for the f2c compiler
......
......@@ -88,9 +88,9 @@ IMG-parportbook := parport-share.fig parport-multi.fig parport-structure.fig
IMG-parportbook2 := $(addprefix Documentation/DocBook/,$(IMG-parportbook))
EPS-parportbook := $(patsubst %.fig,%.eps, $(IMG-parportbook2))
PNG-parportbook := $(patsubst %.fig,%.png, $(IMG-parportbook2))
Documentation/DocBook/parportbook.ps: $(EPS-parportbook)
Documentation/DocBook/parportbook.html Documentation/DocBook/parportbook.pdf:\
$(PNG-parportbook)
Documentation/DocBook/parportbook.html: $(PNG-parportbook)
Documentation/DocBook/parportbook.ps Documentation/DocBook/parportbook.pdf:\
$(EPS-parportbook)
###
# Rules to generate postscript, PDF and HTML
......@@ -99,48 +99,44 @@ Documentation/DocBook/parportbook.html Documentation/DocBook/parportbook.pdf:\
@(which db2ps > /dev/null 2>&1) || \
(echo "*** You need to install DocBook stylesheets ***"; \
exit 1)
@echo ' DB2PS $@'
@db2ps -o $(dir $@) $<
$(call do_cmd,DB2PS $@,db2ps -o $(dir $@) $<)
%.pdf : %.sgml
@(which db2pdf > /dev/null 2>&1) || \
(echo "*** You need to install DocBook stylesheets ***"; \
exit 1)
@echo ' DB2PDF $@'
@db2pdf -o $(dir $@) $<
$(call do_cmd,DB2PDF $@,db2pdf -o $(dir $@) $<)
%.html: %.sgml
@(which db2html > /dev/null 2>&1) || \
(echo "*** You need to install DocBook stylesheets ***"; \
exit 1)
@rm -rf $@ $(patsubst %.html,%,$@)
@echo ' DB2HTML $@'
@db2html -o $(patsubst %.html,%,$@) $< && \
$(call do_cmd,DB2HTML $@,db2html -o $(patsubst %.html,%,$@) $< && \
echo '<a HREF="$(patsubst %.html,%,$(notdir $@))/book1.html">\
Goto $(patsubst %.html,%,$(notdir $@))</a><p>' > $@
Goto $(patsubst %.html,%,$(notdir $@))</a><p>' > $@)
@if [ ! -z "$(PNG-$(basename $(notdir $@)))" ]; then \
cp $(PNG-$(basename $(notdir $@))) $(patsubst %.html,%,$@); fi
###
# Rules to generate postscripts and PNG imgages from .fig format files
%.eps: %.fig
@echo ' FIG2DEV -Leps $@'
@fig2dev -Leps $< $@
$(call do_cmd,FIG2DEV -Leps $@,fig2dev -Leps $< $@)
%.png: %.fig
@echo ' FIG2DEV -Lpng $@'
fig2dev -Lpng $< $@
$(call do_cmd,FIG2DEV -Lpng $@,fig2dev -Lpng $< $@)
###
# Rule to convert a .c file to inline SGML documentation
%.sgml: %.c
@echo ' Generating $@'
@echo "<programlisting>" > $@
@expand --tabs=8 < $< | \
@( \
echo "<programlisting>"; \
expand --tabs=8 < $< | \
sed -e "s/&/\\&amp;/g" \
-e "s/</\\&lt;/g" \
-e "s/>/\\&gt;/g" >> $@
@echo "</programlisting>" >> $@
-e "s/>/\\&gt;/g"; \
echo "</programlisting>") > $@
###
# Help targets as used by the top-level makefile
......
Information regarding the Enhanced IDE drive in Linux 2.5
==============================================================================
......@@ -301,6 +298,53 @@ There may be more options than shown -- use the source, Luke!
Everything else is rejected with a "BAD OPTION" message.
================================================================================
IDE ATAPI streaming tape driver
-------------------------------
This driver is a part of the Linux ide driver and works in co-operation
with linux/drivers/block/ide.c.
The driver, in co-operation with ide.c, basically traverses the
request-list for the block device interface. The character device
interface, on the other hand, creates new requests, adds them
to the request-list of the block device, and waits for their completion.
Pipelined operation mode is now supported on both reads and writes.
The block device major and minor numbers are determined from the
tape's relative position in the ide interfaces, as explained in ide.c.
The character device interface consists of the following devices:
ht0 major 37, minor 0 first IDE tape, rewind on close.
ht1 major 37, minor 1 second IDE tape, rewind on close.
...
nht0 major 37, minor 128 first IDE tape, no rewind on close.
nht1 major 37, minor 129 second IDE tape, no rewind on close.
...
Run linux/scripts/MAKEDEV.ide to create the above entries.
The general magnetic tape commands compatible interface, as defined by
include/linux/mtio.h, is accessible through the character device.
General ide driver configuration options, such as the interrupt-unmask
flag, can be configured by issuing an ioctl to the block device interface,
as any other ide device.
Our own ide-tape ioctl's can be issued to either the block device or
the character device interface.
Maximal throughput with minimal bus load will usually be achieved in the
following scenario:
1. ide-tape is operating in the pipelined operation mode.
2. No buffering is performed by the user backup program.
================================================================================
Some Terminology
......
......@@ -270,6 +270,12 @@ M: maxk@qualcomm.com
W: http://bluez.sf.net
S: Maintained
BLUETOOTH SUBSYSTEM (PC Card Drivers)
P: Marcel Holtmann
M: marcel@holtmann.org
W: http://www.holtmann.org/linux/bluetooth/
S: Maintained
BTTV VIDEO4LINUX DRIVER
P: Gerd Knorr
M: kraxel@bytesex.org
......
......@@ -279,7 +279,6 @@ define rule_link_vmlinux
mv -f .tmpversion .version
+$(MAKE) -C init
$(call cmd,link_vmlinux)
$(cmd_link_vmlinux)
echo 'cmd_$@ := $(cmd_link_vmlinux)' > $(@D)/.$(@F).cmd
$(NM) vmlinux | grep -v '\(compiled\)\|\(\.o$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | sort > System.map
endef
......
......@@ -553,3 +553,22 @@ if_changed_rule = $(if $(strip $? \
# If quiet is set, only print short version of command
cmd = @$(if $($(quiet)cmd_$(1)),echo ' $($(quiet)cmd_$(1))' &&) $(cmd_$(1))
# do_cmd is a shorthand used to support both compressed, verbose
# and silent output in a single line.
# Compared to cmd described avobe, do_cmd does no rely on any variables
# previously assigned a value.
#
# Usage $(call do_cmd,CMD $@,cmd_to_execute bla bla)
# Example:
# $(call do_cmd,CP $@,cp -b $< $@)
# make -s => nothing will be printed
# make KBUILD_VERBOSE=1 => cp -b path/to/src.file path/to/dest.file
# make KBUILD_VERBOSE=0 => CP path/to/dest.file
define do_cmd
@$(if $(filter quiet_,$(quiet)), echo ' $(1)' &&,
$(if $(filter silent_,$(quiet)),,
echo "$(2)" &&)) \
$(2)
endef
......@@ -6,7 +6,7 @@ EXTRA_TARGETS := kernel.o head.o init_task.o
O_TARGET := kernel.o
export-objs := mca.o mtrr.o msr.o cpuid.o microcode.o i386_ksyms.o time.o
export-objs := mca.o mtrr.o i386_ksyms.o time.o
obj-y := process.o semaphore.o signal.o entry.o traps.o irq.o vm86.o \
ptrace.o i8259.o ioport.o ldt.o setup.o time.o sys_i386.o \
......
......@@ -475,33 +475,43 @@ void show_regs(struct pt_regs * regs)
show_trace(&regs->esp);
}
/*
* This gets run with %ebx containing the
* function to call, and %edx containing
* the "args".
*/
extern void kernel_thread_helper(void);
__asm__(".align 4\n"
"kernel_thread_helper:\n\t"
"movl %edx,%eax\n\t"
"pushl %edx\n\t"
"call *%ebx\n\t"
"pushl %eax\n\t"
"call do_exit");
/*
* Create a kernel thread
*/
int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags)
{
long retval, d0;
__asm__ __volatile__(
"movl %%esp,%%esi\n\t"
"int $0x80\n\t" /* Linux/i386 system call */
"cmpl %%esp,%%esi\n\t" /* child or parent? */
"je 1f\n\t" /* parent - jump */
/* Load the argument into eax, and push it. That way, it does
* not matter whether the called function is compiled with
* -mregparm or not. */
"movl %4,%%eax\n\t"
"pushl %%eax\n\t"
"call *%5\n\t" /* call fn */
"movl %3,%0\n\t" /* exit */
"int $0x80\n"
"1:\t"
:"=&a" (retval), "=&S" (d0)
:"0" (__NR_clone), "i" (__NR_exit),
"r" (arg), "r" (fn),
"b" (flags | CLONE_VM)
: "memory");
return retval;
struct task_struct *p;
struct pt_regs regs;
memset(&regs, 0, sizeof(regs));
regs.ebx = (unsigned long) fn;
regs.edx = (unsigned long) arg;
regs.xds = __KERNEL_DS;
regs.xes = __KERNEL_DS;
regs.orig_eax = -1;
regs.eip = (unsigned long) kernel_thread_helper;
regs.xcs = __KERNEL_CS;
regs.eflags = 0x286;
/* Ok, create the new process.. */
p = do_fork(flags | CLONE_VM, 0, &regs, 0);
return IS_ERR(p) ? PTR_ERR(p) : p->pid;
}
/*
......
......@@ -4,7 +4,7 @@
L_TARGET = lib.a
export-objs := io.o swiotlb.o
export-objs := swiotlb.o
obj-y := __divsi3.o __udivsi3.o __modsi3.o __umodsi3.o \
__divdi3.o __udivdi3.o __moddi3.o __umoddi3.o \
......
......@@ -18,7 +18,7 @@ EXTRA_CFLAGS := -DLITTLE_ENDIAN
O_TARGET := sgiio.o
ifeq ($(CONFIG_MODULES),y)
export-objs = pciio.o hcl.o pci_dma.o
export-objs = pciio.o hcl.o
endif
obj-y := stubs.o sgi_if.o pciio.o xtalk.o xbow.o xswitch.o klgraph_hack.o \
......
......@@ -5,7 +5,7 @@
O_TARGET := baget.a
export-objs := vacserial.o vacrtc.o
export-objs := vacserial.o
obj-y := baget.o print.o setup.o time.o irq.o bagetIRQ.o \
reset.o wbflush.o
obj-$(CONFIG_SERIAL) += vacserial.o
......
......@@ -6,6 +6,7 @@
O_TARGET := kernel.o
EXTRA_TARGETS := head.o init_task.o
export-objs := mips_ksyms.o
obj-y += branch.o process.o signal.o entry.o \
traps.o ptrace.o vm86.o ioport.o reset.o \
......@@ -27,14 +28,12 @@ endif
obj-$(CONFIG_SMP) += smp.o
# Old style irq support, going to die in 2.5.
export-objs += old-irq.o
obj-$(CONFIG_NEW_IRQ) += irq.o
obj-$(CONFIG_ROTTEN_IRQ) += old-irq.o
obj-$(CONFIG_I8259) += i8259.o
# transition from old time.c to new time.c
# some boards uses old-time.c, some use time.c, and some use their own ones
export-objs += old-time.o time.o
obj-$(CONFIG_OLD_TIME_C) += old-time.o
obj-$(CONFIG_NEW_TIME_C) += time.o
......
......@@ -11,6 +11,8 @@
O_TARGET := 8xx_io.o
export-objs := fec.o
obj-y := commproc.o uart.o
obj-$(CONFIG_FEC_ENET) += fec.o
......
......@@ -9,7 +9,7 @@ KHEAD := head.o
O_TARGET := kernel.o
EXTRA_TARGETS := $(KHEAD)
export-objs := ppc_ksyms.o setup.o
export-objs := ppc_ksyms.o
obj-y := ppc_ksyms.o setup.o entry.o traps.o irq.o idle.o \
time.o process.o signal.o syscalls.o misc.o ptrace.o \
......
......@@ -5,7 +5,8 @@
O_TARGET := kernel.o
EXTRA_TARGETS := head.o init_task.o
export-objs := io.o io_generic.o io_hd64461.o setup_hd64461.o sh_ksyms.o
export-objs := io.o io_generic.o io_hd64465.o setup_hd64465.o sh_ksyms.o \
io_adx.o io_bigsur.o io_cat68701.o hd64465_gpio.o
obj-y := process.o signal.o entry.o traps.o irq.o irq_ipr.o \
ptrace.o setup.o time.o sys_sh.o semaphore.o \
......
......@@ -5,7 +5,7 @@
O_TARGET := kernel.o
EXTRA_TARGETS := head.o head64.o init_task.o
export-objs := mtrr.o msr.o cpuid.o x8664_ksyms.o
export-objs := mtrr.o x8664_ksyms.o
obj-y := process.o semaphore.o signal.o entry.o traps.o irq.o \
ptrace.o i8259.o ioport.o ldt.o setup.o time.o sys_x86_64.o \
......
......@@ -3,8 +3,6 @@
#
# All the objects that export symbols.
export-objs := mouse_rpc.o
obj-arc := keyb_arc.o
obj-rpc := keyb_ps2.o
obj-clps7500 := keyb_ps2.o defkeymap-acorn.o
......
......@@ -8,7 +8,8 @@
# In the future, some of these should be built conditionally.
#
export-objs := elevator.o ll_rw_blk.o blkpg.o loop.o DAC960.o genhd.o block_ioctl.o
export-objs := elevator.o ll_rw_blk.o blkpg.o loop.o genhd.o \
block_ioctl.o acsi.o
obj-y := elevator.o ll_rw_blk.o blkpg.o genhd.o block_ioctl.o
......
......@@ -62,6 +62,20 @@ CONFIG_BLUEZ_HCIDTL1
Say Y here to compile support for HCI DTL1 devices into the
kernel or say M to compile it as module (dtl1_cs.o).
HCI BT3C (PC Card) device driver
CONFIG_BLUEZ_HCIBT3C
Bluetooth HCI BT3C (PC Card) driver.
This driver provides support for Bluetooth PCMCIA devices with
3Com BT3C interface:
3Com Bluetooth Card (3CRWB6096)
HP Bluetooth Card
The HCI BT3C driver uses external firmware loader program provided in
the BlueFW package. For more information, see <http://bluez.sf.net>.
Say Y here to compile support for HCI BT3C devices into the
kernel or say M to compile it as module (bt3c_cs.o).
HCI BlueCard (PC Card) device driver
CONFIG_BLUEZ_HCIBLUECARD
Bluetooth HCI BlueCard (PC Card) driver.
......
......@@ -14,6 +14,8 @@ fi
dep_tristate 'HCI DTL1 (PC Card) driver' CONFIG_BLUEZ_HCIDTL1 $CONFIG_PCMCIA $CONFIG_BLUEZ
dep_tristate 'HCI BT3C (PC Card) driver' CONFIG_BLUEZ_HCIBT3C $CONFIG_PCMCIA $CONFIG_BLUEZ
dep_tristate 'HCI BlueCard (PC Card) driver' CONFIG_BLUEZ_HCIBLUECARD $CONFIG_PCMCIA $CONFIG_BLUEZ
dep_tristate 'HCI VHCI (Virtual HCI device) driver' CONFIG_BLUEZ_HCIVHCI $CONFIG_BLUEZ
......
......@@ -6,6 +6,7 @@ obj-$(CONFIG_BLUEZ_HCIUSB) += hci_usb.o
obj-$(CONFIG_BLUEZ_HCIVHCI) += hci_vhci.o
obj-$(CONFIG_BLUEZ_HCIUART) += hci_uart.o
obj-$(CONFIG_BLUEZ_HCIDTL1) += dtl1_cs.o
obj-$(CONFIG_BLUEZ_HCIBT3C) += bt3c_cs.o
obj-$(CONFIG_BLUEZ_HCIBLUECARD) += bluecard_cs.o
hci_uart-y := hci_ldisc.o
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -107,13 +107,14 @@ static inline void out_reg(u8 data, u8 reg)
* Set PIO mode for the specified drive.
* This function computes timing parameters
* and sets controller registers accordingly.
* It assumes IRQ's are disabled or at least that no other process will
* attempt to access the IDE registers concurrently.
*/
static void ali14xx_tune_drive(struct ata_device *drive, u8 pio)
{
int drive_num;
int time1, time2;
u8 param1, param2, param3, param4;
unsigned long flags;
struct ata_timing *t;
if (pio == 255)
......@@ -140,15 +141,12 @@ static void ali14xx_tune_drive(struct ata_device *drive, u8 pio)
/* stuff timing parameters into controller registers */
drive_num = (drive->channel->index << 1) + drive->select.b.unit;
save_flags(flags); /* all CPUs */
cli(); /* all CPUs */
outb_p(reg_on, base_port);
out_reg(param1, reg_tab[drive_num].reg1);
out_reg(param2, reg_tab[drive_num].reg2);
out_reg(param3, reg_tab[drive_num].reg3);
out_reg(param4, reg_tab[drive_num].reg4);
outb_p(reg_off, base_port);
restore_flags(flags); /* all CPUs */
}
/*
......
......@@ -218,6 +218,7 @@ static unsigned int __init pci_init_cs5530(struct pci_dev *dev)
}
}
}
if (!master_0) {
printk("%s: unable to locate PCI MASTER function\n", dev->name);
return 0;
......@@ -227,15 +228,13 @@ static unsigned int __init pci_init_cs5530(struct pci_dev *dev)
return 0;
}
save_flags(flags);
cli(); /* all CPUs (there should only be one CPU with this chipset) */
/*
* Enable BusMaster and MemoryWriteAndInvalidate for the cs5530:
* --> OR 0x14 into 16-bit PCI COMMAND reg of function 0 of the cs5530
*/
pci_read_config_word (cs5530_0, PCI_COMMAND, &pcicmd);
pci_write_config_word(cs5530_0, PCI_COMMAND, pcicmd | PCI_COMMAND_MASTER | PCI_COMMAND_INVALIDATE);
pci_set_master(cs5530_0);
pci_set_mwi(cs5530_0);
/*
* Set PCI CacheLineSize to 16-bytes:
......@@ -274,8 +273,6 @@ static unsigned int __init pci_init_cs5530(struct pci_dev *dev)
pci_write_config_byte(master_0, 0x42, 0x00);
pci_write_config_byte(master_0, 0x43, 0xc1);
restore_flags(flags);
return 0;
}
......
......@@ -66,21 +66,18 @@ static void sub22 (char b, char c)
}
}
/* Assumes IRQ's are disabled or at least that no other process will
attempt to access the IDE registers concurrently. */
static void tune_dtc2278(struct ata_device *drive, u8 pio)
{
unsigned long flags;
pio = ata_timing_mode(drive, XFER_PIO | XFER_EPIO) - XFER_PIO_0;
if (pio >= 3) {
save_flags(flags); /* all CPUs */
cli(); /* all CPUs */
/*
* This enables PIO mode4 (3?) on the first interface
*/
sub22(1,0xc3);
sub22(0,0xa0);
restore_flags(flags); /* all CPUs */
} else {
/* we don't know how to set it back again.. */
}
......
/*
* linux/drivers/ide/hd.c
*
* Copyright (C) 1991, 1992 Linus Torvalds
*/
/*
*
* This is the low-level hd interrupt support. It traverses the
* request-list, using interrupts to jump between functions. As
* all the functions are called within interrupts, we may not
......@@ -37,7 +33,6 @@
#include <linux/fs.h>
#include <linux/devfs_fs_kernel.h>
#include <linux/kernel.h>
#include <linux/hdreg.h>
#include <linux/genhd.h>
#include <linux/slab.h>
#include <linux/string.h>
......@@ -45,6 +40,7 @@
#include <linux/mc146818rtc.h> /* CMOS defines */
#include <linux/init.h>
#include <linux/blkpg.h>
#include <linux/hdreg.h>
#define REALLY_SLOW_IO
#include <asm/system.h>
......@@ -55,6 +51,15 @@
#define DEVICE_NR(device) (minor(device)>>6)
#include <linux/blk.h>
/* ATA commands we use.
*/
#define WIN_SPECIFY 0x91 /* set drive geometry translation */
#define WIN_RESTORE 0x10
#define WIN_READ 0x20 /* 28-Bit */
#define WIN_WRITE 0x30 /* 28-Bit */
#define HD_IRQ 14 /* the standard disk interrupt */
#ifdef __arm__
#undef HD_IRQ
#endif
......@@ -63,6 +68,45 @@
#define HD_IRQ IRQ_HARDDISK
#endif
/* Hd controller regster ports */
#define HD_DATA 0x1f0 /* _CTL when writing */
#define HD_ERROR 0x1f1 /* see err-bits */
#define HD_NSECTOR 0x1f2 /* nr of sectors to read/write */
#define HD_SECTOR 0x1f3 /* starting sector */
#define HD_LCYL 0x1f4 /* starting cylinder */
#define HD_HCYL 0x1f5 /* high byte of starting cyl */
#define HD_CURRENT 0x1f6 /* 101dhhhh , d=drive, hhhh=head */
#define HD_STATUS 0x1f7 /* see status-bits */
#define HD_FEATURE HD_ERROR /* same io address, read=error, write=feature */
#define HD_PRECOMP HD_FEATURE /* obsolete use of this port - predates IDE */
#define HD_COMMAND HD_STATUS /* same io address, read=status, write=cmd */
#define HD_CMD 0x3f6 /* used for resets */
#define HD_ALTSTATUS 0x3f6 /* same as HD_STATUS but doesn't clear irq */
/* Bits of HD_STATUS */
#define ERR_STAT 0x01
#define INDEX_STAT 0x02
#define ECC_STAT 0x04 /* Corrected error */
#define DRQ_STAT 0x08
#define SEEK_STAT 0x10
#define SERVICE_STAT SEEK_STAT
#define WRERR_STAT 0x20
#define READY_STAT 0x40
#define BUSY_STAT 0x80
/* Bits for HD_ERROR */
#define MARK_ERR 0x01 /* Bad address mark */
#define TRK0_ERR 0x02 /* couldn't find track 0 */
#define ABRT_ERR 0x04 /* Command aborted */
#define MCR_ERR 0x08 /* media change request */
#define ID_ERR 0x10 /* ID field not found */
#define MC_ERR 0x20 /* media changed */
#define ECC_ERR 0x40 /* Uncorrectable ECC error */
#define BBD_ERR 0x80 /* pre-EIDE meaning: block marked bad */
#define ICRC_ERR 0x80 /* new meaning: CRC error during transfer */
static spinlock_t hd_lock = SPIN_LOCK_UNLOCKED;
static int revalidate_hddisk(kdev_t, int);
......@@ -162,12 +206,9 @@ void __init hd_setup(char *str, int *ints)
static void dump_status (const char *msg, unsigned int stat)
{
unsigned long flags;
char devc;
devc = !blk_queue_empty(QUEUE) ? 'a' + DEVICE_NR(CURRENT->rq_dev) : '?';
save_flags (flags);
sti();
#ifdef VERBOSE_ERRORS
printk("hd%c: %s: status=0x%02x { ", devc, msg, stat & 0xff);
if (stat & BUSY_STAT) printk("Busy ");
......@@ -207,8 +248,7 @@ static void dump_status (const char *msg, unsigned int stat)
hd_error = inb(HD_ERROR);
printk("hd%c: %s: error=0x%02x.\n", devc, msg, hd_error & 0xff);
}
#endif /* verbose errors */
restore_flags (flags);
#endif
}
void check_status(void)
......@@ -467,7 +507,7 @@ static void write_intr(void)
if (i > 0) {
SET_HANDLER(&write_intr);
outsw(HD_DATA,CURRENT->buffer,256);
sti();
local_irq_enable();
} else {
#if (HD_DELAY > 0)
last_req = read_timer();
......@@ -500,7 +540,7 @@ static void hd_times_out(unsigned long dummy)
return;
disable_irq(HD_IRQ);
sti();
local_irq_enable();
reset = 1;
dev = DEVICE_NR(CURRENT->rq_dev);
printk("hd%c: timeout\n", dev+'a');
......@@ -510,7 +550,7 @@ static void hd_times_out(unsigned long dummy)
#endif
end_request(CURRENT, 0);
}
cli();
local_irq_disable();
hd_request();
enable_irq(HD_IRQ);
}
......@@ -548,7 +588,7 @@ static void hd_request(void)
return;
repeat:
del_timer(&device_timer);
sti();
local_irq_enable();
if (blk_queue_empty(QUEUE)) {
do_hd = NULL;
......@@ -556,7 +596,7 @@ static void hd_request(void)
}
if (reset) {
cli();
local_irq_disable();
reset_hd();
return;
}
......@@ -688,7 +728,7 @@ static void hd_interrupt(int irq, void *dev_id, struct pt_regs *regs)
if (!handler)
handler = unexpected_hd_interrupt;
handler();
sti();
local_irq_enable();
}
static struct block_device_operations hd_fops = {
......
......@@ -249,12 +249,8 @@ static u8 ht_pio2timings(struct ata_device *drive, u8 pio)
*/
static void ht_set_prefetch(struct ata_device *drive, u8 state)
{
unsigned long flags;
int t = HT_PREFETCH_MODE << 8;
save_flags (flags); /* all CPUs */
cli(); /* all CPUs */
/*
* Prefetch mode and unmask irq seems to conflict
*/
......@@ -267,16 +263,16 @@ static void ht_set_prefetch(struct ata_device *drive, u8 state)
drive->channel->no_unmask = 0;
}
restore_flags (flags); /* all CPUs */
#ifdef DEBUG
printk("ht6560b: drive %s prefetch mode %sabled\n", drive->name, (state ? "en" : "dis"));
#endif
}
/* Assumes IRQ's are disabled or at least that no other process will attempt to
* access the IDE registers concurrently.
*/
static void tune_ht6560b(struct ata_device *drive, u8 pio)
{
unsigned long flags;
u8 timing;
switch (pio) {
......@@ -288,14 +284,9 @@ static void tune_ht6560b(struct ata_device *drive, u8 pio)
timing = ht_pio2timings(drive, pio);
save_flags (flags); /* all CPUs */
cli(); /* all CPUs */
drive->drive_data &= 0xff00;
drive->drive_data |= timing;
restore_flags (flags); /* all CPUs */
#ifdef DEBUG
printk("ht6560b: drive %s tuned to pio mode %#x timing=%#x\n", drive->name, pio, timing);
#endif
......
......@@ -305,8 +305,9 @@
#include <linux/interrupt.h>
#include <linux/errno.h>
#include <linux/cdrom.h>
#include <linux/ide.h>
#include <linux/completion.h>
#include <linux/hdreg.h>
#include <linux/ide.h>
#include <asm/irq.h>
#include <asm/io.h>
......@@ -2914,7 +2915,7 @@ int ide_cdrom_cleanup(struct ata_device *drive)
struct cdrom_info *info = drive->driver_data;
struct cdrom_device_info *devinfo = &info->devinfo;
if (ide_unregister_subdriver (drive))
if (ata_unregister_device(drive))
return 1;
if (info->buffer != NULL)
kfree(info->buffer);
......@@ -2973,7 +2974,7 @@ static void ide_cdrom_attach(struct ata_device *drive)
printk(KERN_ERR "%s: Can't allocate a cdrom structure\n", drive->name);
return;
}
if (ide_register_subdriver (drive, &ide_cdrom_driver)) {
if (ata_register_device(drive, &ide_cdrom_driver)) {
printk(KERN_ERR "%s: Failed to register the driver with ide.c\n", drive->name);
kfree (info);
return;
......
......@@ -1279,7 +1279,7 @@ static int idedisk_cleanup(struct ata_device *drive)
printk (KERN_INFO "%s: Write Cache FAILED Flushing!\n",
drive->name);
}
ret = ide_unregister_subdriver(drive);
ret = ata_unregister_device(drive);
/* FIXME: This is killing the kernel with BUG 185 at asm/spinlocks.h
* horribly. Check whatever we did REGISTER the device properly
......@@ -1471,8 +1471,8 @@ static void idedisk_attach(struct ata_device *drive)
if (req[0] != '\0' && strcmp(req, "ide-disk"))
return;
if (ide_register_subdriver(drive, &idedisk_driver)) {
printk (KERN_ERR "ide-disk: %s: Failed to register the driver with ide.c\n", drive->name);
if (ata_register_device(drive, &idedisk_driver)) {
printk(KERN_ERR "%s: Failed to register the driver with ide.c\n", drive->name);
return;
}
......
......@@ -94,9 +94,10 @@
#include <linux/genhd.h>
#include <linux/slab.h>
#include <linux/cdrom.h>
#include <linux/buffer_head.h>
#include <linux/hdreg.h>
#include <linux/ide.h>
#include <linux/atapi.h>
#include <linux/buffer_head.h>
#include <asm/byteorder.h>
#include <asm/irq.h>
......@@ -1722,10 +1723,10 @@ static int idefloppy_cleanup(struct ata_device *drive)
{
idefloppy_floppy_t *floppy = drive->driver_data;
if (ide_unregister_subdriver (drive))
if (ata_unregister_device(drive))
return 1;
drive->driver_data = NULL;
kfree (floppy);
kfree(floppy);
return 0;
}
......@@ -1779,7 +1780,7 @@ static void idefloppy_attach(struct ata_device *drive)
drive->name);
return;
}
if (ide_register_subdriver(drive, &idefloppy_driver)) {
if (ata_register_device(drive, &idefloppy_driver)) {
printk(KERN_ERR "ide-floppy: %s: Failed to register the driver with ide.c\n", drive->name);
kfree (floppy);
return;
......
......@@ -550,7 +550,8 @@ static void __init hpt374_device_order_fixup (struct pci_dev *dev, struct ata_pc
if (!dev2) {
return;
} else {
byte irq = 0, irq2 = 0;
u8 irq = 0;
u8 irq2 = 0;
pci_read_config_byte(dev, PCI_INTERRUPT_LINE, &irq);
pci_read_config_byte(dev2, PCI_INTERRUPT_LINE, &irq2);
if (irq != irq2) {
......
This diff is collapsed.
......@@ -33,6 +33,15 @@
#include "ioctl.h"
/* BIG GEOMETRY - dying, used only by HDIO_GETGEO_BIG_RAW */
struct hd_big_geometry {
u8 heads;
u8 sectors;
u32 cylinders;
unsigned long start;
};
/*
* Implement generic ioctls invoked from userspace to imlpement specific
* functionality.
......
......@@ -89,10 +89,7 @@ static void it8172_tune_drive (struct ata_device *drive, u8 pio)
drive_enables |= 0x0006;
}
save_flags(flags);
cli();
pci_write_config_word(dev, master_port, master_data);
restore_flags(flags);
}
#if defined(CONFIG_BLK_DEV_IDEDMA) && defined(CONFIG_IT8172_TUNING)
......
......@@ -191,7 +191,11 @@ static void init_hwif_data(struct ata_channel *ch, unsigned int index)
ch->noprobe = !ch->io_ports[IDE_DATA_OFFSET];
#ifdef CONFIG_BLK_DEV_HD
if (ch->io_ports[IDE_DATA_OFFSET] == HD_DATA)
/* Ignore disks for which handling by the legacy driver was requested
* by the used.
*/
if (ch->io_ports[IDE_DATA_OFFSET] == 0x1f0)
ch->noprobe = 1; /* may be overridden by ide_setup() */
#endif
......@@ -361,7 +365,7 @@ void ide_unregister(struct ata_channel *ch)
if (ata_ops(drive)->cleanup(drive))
goto abort;
} else
ide_unregister_subdriver(drive);
ata_unregister_device(drive);
}
}
ch->present = 0;
......@@ -701,79 +705,46 @@ static void __init init_global_data(void)
/*
* This gets called VERY EARLY during initialization, to handle kernel "command
* line" strings beginning with "hdx=" or "ide".It gets called even before the
* actual module gets initialized.
* line" strings beginning with "hdx=". It gets called even before the actual
* module gets initialized.
*
* Please look at Documentation/ide.txt to see the complete list of supported
* options.
*/
int __init ide_setup(char *s)
static int __init ata_hd_setup(char *s)
{
int i, vals[4];
struct ata_channel *ch;
int vals[4];
struct ata_channel *ch; /* FIXME: Channel parms should not be accessed in ata_hd_setup */
struct ata_device *drive;
unsigned int hw, unit;
const char max_drive = 'a' + ((MAX_HWIFS * MAX_DRIVES) - 1);
const char max_ch = '0' + (MAX_HWIFS - 1);
if (!strncmp(s, "hd=", 3)) /* hd= is for hd.c driver and not us */
if (s[0] == '=') /* hd= is for hd.c driver and not us */
return 0;
if (strncmp(s,"ide",3) &&
strncmp(s,"hd",2)) /* hdx= & hdxlun= */
return 0;
printk(KERN_INFO "ide_setup: %s", s);
printk(KERN_INFO "hd%s", s);
init_global_data();
#ifdef CONFIG_BLK_DEV_IDEDOUBLER
if (!strcmp(s, "ide=doubler")) {
extern int ide_doubler;
printk(KERN_INFO" : Enabled support for IDE doublers\n");
ide_doubler = 1;
return 1;
}
#endif
if (!strcmp(s, "ide=nodma")) {
printk(KERN_INFO "ATA: Prevented DMA\n");
noautodma = 1;
return 1;
}
#ifdef CONFIG_PCI
if (!strcmp(s, "ide=reverse")) {
ide_scan_direction = 1;
printk(" : Enabled support for IDE inverse scan order.\n");
return 1;
}
#endif
/*
* Look for drive options: "hdx="
*/
if (!strncmp(s, "hd", 2) && s[2] >= 'a' && s[2] <= max_drive) {
const char *hd_words[] = {"none", "noprobe", "nowerr", "cdrom",
if (s[0] >= 'a' && s[0] <= max_drive) {
static const char *hd_words[] = {"none", "noprobe", "nowerr", "cdrom",
"serialize", "autotune", "noautotune",
"slow", "flash", "remap", "noremap", "scsi", NULL};
unit = s[2] - 'a';
unit = s[0] - 'a';
hw = unit / MAX_DRIVES;
unit = unit % MAX_DRIVES;
ch = &ide_hwifs[hw];
drive = &ch->drives[unit];
if (!strncmp(s+3, "=ide-", 5)) {
strncpy(drive->driver_req, s + 4, 9);
/* Look for hdx=ide-* */
if (!strncmp(s+1, "=ide-", 5)) {
strncpy(drive->driver_req, s+2, 9);
goto done;
}
/*
* Look for last lun option: "hdxlun="
*/
if (!strncmp(s+3, "lun=", 4)) {
if (*get_options(s+7, 2, vals) || vals[0]!=1)
if (!strncmp(s+1, "lun=", 4)) {
if (*get_options(s+5, 2, vals) || vals[0]!=1)
goto bad_option;
if (vals[1] >= 0 && vals[1] <= 7) {
drive->last_lun = vals[1];
......@@ -782,7 +753,7 @@ int __init ide_setup(char *s)
printk(" -- BAD LAST LUN! Expected value from 0 to 7");
goto done;
}
switch (match_parm(s+3, hd_words, vals, 3)) {
switch (match_parm(s+1, hd_words, vals, 3)) {
case -1: /* "none" */
drive->nobios = 1; /* drop into "noprobe" */
case -2: /* "noprobe" */
......@@ -790,16 +761,16 @@ int __init ide_setup(char *s)
goto done;
case -3: /* "nowerr" */
drive->bad_wstat = BAD_R_STAT;
ch->noprobe = 0;
ch->noprobe = 0; /* FIXME: Channel parm */
goto done;
case -4: /* "cdrom" */
drive->present = 1;
drive->type = ATA_ROM;
ch->noprobe = 0;
ch->noprobe = 0; /* FIXME: Channel parm */
goto done;
case -5: /* "serialize" */
printk(" -- USE \"ide%d=serialize\" INSTEAD", hw);
goto do_serialize;
goto bad_option;
case -6: /* "autotune" */
drive->autotune = 1;
goto done;
......@@ -807,7 +778,7 @@ int __init ide_setup(char *s)
drive->autotune = 2;
goto done;
case -8: /* "slow" */
ch->slow = 1;
ch->slow = 1; /* FIXME: Channel parm */
goto done;
case -9: /* "flash" */
drive->ata_flash = 1;
......@@ -840,11 +811,63 @@ int __init ide_setup(char *s)
}
}
bad_option:
printk(" -- BAD OPTION\n");
return 1;
done:
printk("\n");
return 1;
}
/*
* This gets called VERY EARLY during initialization, to handle kernel "command
* line" strings beginning with "ide". It gets called even before the actual
* module gets initialized.
*
* Please look at Documentation/ide.txt to see the complete list of supported
* options.
*/
int __init ide_setup(char *s)
{
int i, vals[4];
struct ata_channel *ch;
unsigned int hw;
const char max_ch = '0' + (MAX_HWIFS - 1);
printk(KERN_INFO "ide_setup: ide%s", s);
init_global_data();
#ifdef CONFIG_BLK_DEV_IDEDOUBLER
if (!strcmp(s, "=doubler")) {
extern int ide_doubler;
printk(KERN_INFO" : Enabled support for IDE doublers\n");
ide_doubler = 1;
return 1;
}
#endif
if (!strcmp(s, "=nodma")) {
printk(KERN_INFO "ATA: Prevented DMA\n");
noautodma = 1;
return 1;
}
#ifdef CONFIG_PCI
if (!strcmp(s, "=reverse")) {
ide_scan_direction = 1;
printk(" : Enabled support for IDE inverse scan order.\n");
return 1;
}
#endif
/*
* Look for bus speed option: "idebus="
*/
if (!strncmp(s, "idebus=", 7)) {
if (*get_options(s+7, 2, vals) || vals[0] != 1)
if (!strncmp(s, "bus=", 4)) {
if (*get_options(s+4, 2, vals) || vals[0] != 1)
goto bad_option;
idebus_parameter = vals[1];
goto done;
......@@ -853,7 +876,7 @@ int __init ide_setup(char *s)
/*
* Look for interface options: "idex="
*/
if (!strncmp(s, "ide", 3) && s[3] >= '0' && s[3] <= max_ch) {
if (s[0] >= '0' && s[0] <= max_ch) {
/*
* Be VERY CAREFUL changing this: note hardcoded indexes below
*/
......@@ -861,11 +884,11 @@ int __init ide_setup(char *s)
"noprobe", "serialize", "autotune", "noautotune", "reset", "dma", "ata66", NULL };
const char *ide_words[] = {
"qd65xx", "ht6560b", "cmd640_vlb", "dtc2278", "umc8672", "ali14xx", "dc4030", NULL };
hw = s[3] - '0';
hw = s[0] - '0';
ch = &ide_hwifs[hw];
switch (match_parm(s+4, ide_options, vals, 1)) {
switch (match_parm(s+1, ide_options, vals, 1)) {
case -7: /* ata66 */
#ifdef CONFIG_PCI
ch->udma_four = 1;
......@@ -889,7 +912,6 @@ int __init ide_setup(char *s)
ch->drives[1].autotune = 1;
goto done;
case -2: /* "serialize" */
do_serialize:
{
struct ata_channel *mate;
......@@ -904,7 +926,10 @@ int __init ide_setup(char *s)
goto done;
}
i = match_parm(&s[4], ide_words, vals, 3);
/*
* Check for specific chipset name
*/
i = match_parm(s+1, ide_words, vals, 3);
/*
* Cryptic check to ensure chipset not already set for a channel:
......@@ -1012,10 +1037,7 @@ int __init ide_setup(char *s)
/****************************************************************************/
/*
* This is in fact registering a device not a driver.
*/
int ide_register_subdriver(struct ata_device *drive, struct ata_operations *driver)
int ata_register_device(struct ata_device *drive, struct ata_operations *driver)
{
unsigned long flags;
......@@ -1027,12 +1049,9 @@ int ide_register_subdriver(struct ata_device *drive, struct ata_operations *driv
return 1;
}
/* FIXME: This will be pushed to the drivers! Thus allowing us to
* save one parameter here and to separate this out.
*/
drive->driver = driver;
spin_unlock_irqrestore(&ide_lock, flags);
/* Default autotune or requested autotune */
if (drive->autotune != 2) {
struct ata_channel *ch = drive->channel;
......@@ -1046,11 +1065,13 @@ int ide_register_subdriver(struct ata_device *drive, struct ata_operations *driv
* PARANOIA!!!
*/
spin_lock_irqsave(ch->lock, flags);
udma_enable(drive, 0, 0);
ch->udma_setup(drive, ch->modes_map);
#ifdef CONFIG_BLK_DEV_IDE_TCQ_DEFAULT
udma_tcq_enable(drive, 1);
#endif
spin_unlock_irqrestore(ch->lock, flags);
}
/* Only CD-ROMs and tape drives support DSC overlap. But only
......@@ -1078,13 +1099,8 @@ int ide_register_subdriver(struct ata_device *drive, struct ata_operations *driv
*
* FIXME: Check whatever we maybe don't call it twice!.
*/
int ide_unregister_subdriver(struct ata_device *drive)
int ata_unregister_device(struct ata_device *drive)
{
#if 0
if (__MOD_IN_USE(ata_ops(drive)->owner))
return 1;
#endif
if (drive->usage || drive->busy || !ata_ops(drive))
return 1;
......@@ -1156,8 +1172,8 @@ EXPORT_SYMBOL(ide_lock);
devfs_handle_t ide_devfs_handle;
EXPORT_SYMBOL(ide_register_subdriver);
EXPORT_SYMBOL(ide_unregister_subdriver);
EXPORT_SYMBOL(ata_register_device);
EXPORT_SYMBOL(ata_unregister_device);
EXPORT_SYMBOL(ata_revalidate);
EXPORT_SYMBOL(ide_register_hw);
EXPORT_SYMBOL(ide_unregister);
......@@ -1432,9 +1448,15 @@ static int __init init_ata(void)
while ((options = next) != NULL) {
if ((next = strchr(options,' ')) != NULL)
*next++ = 0;
if (!ide_setup(options))
if (!strncmp(options,"hd",2)) {
if (!ata_hd_setup(options+2))
printk(KERN_ERR "Unknown option '%s'\n", options);
}
else if (!strncmp(options,"ide",3)) {
if (!ide_setup(options+3))
printk(KERN_ERR "Unknown option '%s'\n", options);
}
}
}
return ata_module_init();
}
......@@ -1457,6 +1479,7 @@ module_exit(cleanup_ata);
#ifndef MODULE
/* command line option parser */
__setup("", ide_setup);
__setup("ide", ide_setup);
__setup("hd", ata_hd_setup);
#endif
......@@ -244,13 +244,15 @@ static void compute_clocks(int pio, pio_clocks_t *clks)
}
/* Main tune procedure, called from tuneproc. */
/* Main tune procedure, called from tuneproc.
Assumes IRQ's are disabled or at least that no other process will
attempt to access the IDE registers concurrently.
*/
static void opti621_tune_drive(struct ata_device *drive, u8 pio)
{
/* primary and secondary drives share some registers,
* so we have to program both drives
*/
unsigned long flags;
u8 pio1, pio2;
pio_clocks_t first, second;
int ax, drdy;
......@@ -281,9 +283,6 @@ static void opti621_tune_drive(struct ata_device *drive, u8 pio)
hwif->name, ax, second.data_time, second.recovery_time, drdy);
#endif
save_flags(flags); /* all CPUs */
cli(); /* all CPUs */
reg_base = hwif->io_ports[IDE_DATA_OFFSET];
outb(0xc0, reg_base+CNTRL_REG); /* allow Register-B */
outb(0xff, reg_base+5); /* hmm, setupvic.exe does this ;-) */
......@@ -306,8 +305,6 @@ static void opti621_tune_drive(struct ata_device *drive, u8 pio)
write_reg(misc, MISC_REG); /* set address setup, DRDY timings, */
/* and read prefetch for both drives */
restore_flags(flags); /* all CPUs */
}
/*
......
......@@ -1082,7 +1082,12 @@ static void channel_init(struct ata_channel *ch)
}
}
#ifdef CONFIG_BLK_DEV_HD
if (ch->irq == HD_IRQ && ch->io_ports[IDE_DATA_OFFSET] != HD_DATA) {
/* The first "legacy" HD gets distinguished by the IRQ it is attached
* to and the IO port it takes.
*/
if (ch->irq == 14 && ch->io_ports[IDE_DATA_OFFSET] != 0x1f0) {
printk("%s: CANNOT SHARE IRQ WITH OLD HARDDISK DRIVER (hd.c)\n", ch->name);
return;
......
/*
* Copyright (C) 1996-2001 Linus Torvalds & author (see below)
*/
/*
*
* Version 0.03 Cleaned auto-tune, added probe
* Version 0.04 Added second channel tuning
* Version 0.05 Enhanced tuning ; added qd6500 support
......@@ -86,31 +84,7 @@
static int timings[4]={-1,-1,-1,-1}; /* stores current timing for each timer */
static void qd_write_reg(u8 content, unsigned int reg)
{
unsigned long flags;
save_flags(flags); /* all CPUs */
cli(); /* all CPUs */
outb(content,reg);
restore_flags(flags); /* all CPUs */
}
static u8 __init qd_read_reg(unsigned int reg)
{
unsigned long flags;
u8 read;
save_flags(flags); /* all CPUs */
cli(); /* all CPUs */
read = inb(reg);
restore_flags(flags); /* all CPUs */
return read;
}
/*
* qd_select:
*
* This routine is invoked from ide.c to prepare for access to a given drive.
*/
......@@ -120,12 +94,10 @@ static void qd_select(struct ata_device *drive)
(QD_TIMREG(drive) & 0x02);
if (timings[index] != QD_TIMING(drive))
qd_write_reg(timings[index] = QD_TIMING(drive), QD_TIMREG(drive));
outb(timings[index] = QD_TIMING(drive), QD_TIMREG(drive));
}
/*
* qd6500_compute_timing
*
* computes the timing value where
* lower nibble represents active time, in count of VLB clocks
* upper nibble represents recovery time, in count of VLB clocks
......@@ -147,8 +119,6 @@ static u8 qd6500_compute_timing(struct ata_channel *hwif, int active_time, int r
}
/*
* qd6580_compute_timing
*
* idem for qd6580
*/
......@@ -161,8 +131,6 @@ static u8 qd6580_compute_timing(int active_time, int recovery_time)
}
/*
* qd_find_disk_type
*
* tries to find timing from dos driver's table
*/
......@@ -187,8 +155,6 @@ static int qd_find_disk_type(struct ata_device *drive,
}
/*
* qd_timing_ok:
*
* check whether timings don't conflict
*/
......@@ -201,8 +167,6 @@ static int qd_timing_ok(struct ata_device drives[])
}
/*
* qd_set_timing:
*
* records the timing, and enables selectproc as needed
*/
......@@ -221,10 +185,6 @@ static void qd_set_timing(struct ata_device *drive, u8 timing)
printk(KERN_DEBUG "%s: %#x\n", drive->name, timing);
}
/*
* qd6500_tune_drive
*/
static void qd6500_tune_drive(struct ata_device *drive, u8 pio)
{
int active_time = 175;
......@@ -242,10 +202,6 @@ static void qd6500_tune_drive(struct ata_device *drive, u8 pio)
qd_set_timing(drive, qd6500_compute_timing(drive->channel, active_time, recovery_time));
}
/*
* qd6580_tune_drive
*/
static void qd6580_tune_drive(struct ata_device *drive, u8 pio)
{
struct ata_timing *t;
......@@ -291,7 +247,7 @@ static void qd6580_tune_drive(struct ata_device *drive, u8 pio)
}
if (!drive->channel->unit && drive->type != ATA_DISK) {
qd_write_reg(0x5f, QD_CONTROL_PORT);
outb(0x5f, QD_CONTROL_PORT);
printk(KERN_WARNING "%s: ATAPI: disabled read-ahead FIFO and post-write buffer on %s.\n", drive->name, drive->channel->name);
}
......@@ -299,8 +255,6 @@ static void qd6580_tune_drive(struct ata_device *drive, u8 pio)
}
/*
* qd_testreg
*
* tests if the given port is a register
*/
......@@ -329,8 +283,6 @@ static int __init qd_testreg(int port)
}
/*
* qd_setup:
*
* called to setup an ata channel : adjusts attributes & links for tuning
*/
......@@ -349,8 +301,6 @@ void __init qd_setup(int unit, int base, int config, unsigned int data0, unsigne
}
/*
* qd_unsetup:
*
* called to unsetup an ata channel : back to default values, unlinks tuning
*/
void __init qd_unsetup(int unit) {
......@@ -368,13 +318,13 @@ void __init qd_unsetup(int unit) {
if (tuneproc == (void *) qd6500_tune_drive) {
// will do it for both
qd_write_reg(QD6500_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
outb(QD6500_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
} else if (tuneproc == (void *) qd6580_tune_drive) {
if (QD_CONTROL(hwif) & QD_CONTR_SEC_DISABLED) {
qd_write_reg(QD6580_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
qd_write_reg(QD6580_DEF_DATA2, QD_TIMREG(&hwif->drives[1]));
outb(QD6580_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
outb(QD6580_DEF_DATA2, QD_TIMREG(&hwif->drives[1]));
} else {
qd_write_reg(unit?QD6580_DEF_DATA2:QD6580_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
outb(unit ? QD6580_DEF_DATA2 : QD6580_DEF_DATA, QD_TIMREG(&hwif->drives[0]));
}
} else {
printk(KERN_WARNING "Unknown qd65xx tuning fonction !\n");
......@@ -383,8 +333,6 @@ void __init qd_unsetup(int unit) {
}
/*
* qd_probe:
*
* looks at the specified baseport, and if qd found, registers & initialises it
* return 1 if another qd may be probed
*/
......@@ -394,7 +342,7 @@ int __init qd_probe(int base)
u8 config;
int unit;
config = qd_read_reg(QD_CONFIG_PORT);
config = inb(QD_CONFIG_PORT);
if (! ((config & QD_CONFIG_BASEPORT) >> 1 == (base == 0xb0)) ) return 1;
......@@ -425,7 +373,7 @@ int __init qd_probe(int base)
/* qd6580 found */
control = qd_read_reg(QD_CONTROL_PORT);
control = inb(QD_CONTROL_PORT);
printk(KERN_NOTICE "qd6580 at %#x\n", base);
printk(KERN_DEBUG "qd6580: config=%#x, control=%#x, ID3=%u\n", config, control, QD_ID3);
......@@ -434,7 +382,7 @@ int __init qd_probe(int base)
/* secondary disabled */
printk(KERN_INFO "%s: qd6580: single IDE board\n", ide_hwifs[unit].name);
qd_setup(unit, base, config | (control << 8), QD6580_DEF_DATA, QD6580_DEF_DATA2, &qd6580_tune_drive);
qd_write_reg(QD_DEF_CONTR, QD_CONTROL_PORT);
outb(QD_DEF_CONTR, QD_CONTROL_PORT);
return 1;
} else {
......@@ -443,7 +391,7 @@ int __init qd_probe(int base)
qd_setup(ATA_PRIMARY, base, config | (control << 8), QD6580_DEF_DATA, QD6580_DEF_DATA, &qd6580_tune_drive);
qd_setup(ATA_SECONDARY, base, config | (control << 8), QD6580_DEF_DATA2, QD6580_DEF_DATA2, &qd6580_tune_drive);
qd_write_reg(QD_DEF_CONTR, QD_CONTROL_PORT);
outb(QD_DEF_CONTR, QD_CONTROL_PORT);
return 0; /* no other qd65xx possible */
}
......@@ -454,8 +402,6 @@ int __init qd_probe(int base)
#ifndef MODULE
/*
* init_qd65xx:
*
* called by ide.c when parsing command line
*/
......
......@@ -4,7 +4,7 @@
# Objects that export symbols.
export-objs := adb.o rtc.o mac_hid.o via-pmu.o
export-objs := adb.o mac_hid.o via-pmu.o
# Object file lists.
......
......@@ -43,7 +43,7 @@ EXTRA_CFLAGS += -I. ${MPT_CFLAGS}
#=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-} LSI_LOGIC
export-objs := mptbase.o mptscsih.o mptlan.o mptctl.o isense.o
export-objs := mptbase.o
obj-$(CONFIG_FUSION) += mptbase.o mptscsih.o
obj-$(CONFIG_FUSION_ISENSE) += isense.o
......
......@@ -6,7 +6,7 @@
#
export-objs := z85230.o syncppp.o comx.o sdladrv.o cycx_drv.o hdlc_generic.o \
dlci.o pc300_drv.o
dlci.o
wanpipe-y := sdlamain.o sdla_ft1.o
wanpipe-$(CONFIG_WANPIPE_X25) += sdla_x25.o
......
......@@ -2852,7 +2852,7 @@ static void process_route (sdla_t *card)
#endif
if(err) {
printk(KERN_INFO
"%s: Remove route %s failed, (err %d)\n",
"%s: Remove route %u.%u.%u.%u failed, (err %d)\n",
card->devname, NIPQUAD(remote_IP_addr),
err);
} else {
......
......@@ -2,7 +2,7 @@
# Makefile for the kernel pcmcia subsystem (c/o David Hinds)
#
export-objs := ds.o cs.o yenta.o pci_socket.o
export-objs := ds.o cs.o yenta.o
obj-$(CONFIG_PCMCIA) += pcmcia_core.o ds.o
ifeq ($(CONFIG_CARDBUS),y)
......
......@@ -8,6 +8,6 @@ obj-y += airq.o blacklist.o cio.o ioinfo.o misc.o requestirq.o s390io.o
obj-$(CONFIG_CHSC) += chsc.o
obj-$(CONFIG_PROC_FS) += proc.o
export-objs += airq.o cio.o ioinfo.o misc.o requestirq.o s390io.o
export-objs += airq.o cio.o ioinfo.o requestirq.o s390io.o
include $(TOPDIR)/Rules.make
/*
* Copyright (C) 1996 - 1999 Gadi Oxman <gadio@netvision.net.il>
*/
/*
*
* Emulation of a SCSI host adapter for IDE ATAPI devices.
*
* With this driver, one can use the Linux SCSI drivers instead of the
* native IDE ATAPI drivers.
*
* Ver 0.1 Dec 3 96 Initial version.
* Ver 0.2 Jan 26 97 Fixed bug in cleanup_module() and added emulation
* of MODE_SENSE_6/MODE_SELECT_6 for cdroms. Thanks
* to Janos Farkas for pointing this out.
* Avoid using bitfields in structures for m68k.
* Added Scatter/Gather and DMA support.
* Ver 0.4 Dec 7 97 Add support for ATAPI PD/CD drives.
* Use variable timeout for each command.
* Ver 0.5 Jan 2 98 Fix previous PD/CD support.
* Allow disabling of SCSI-6 to SCSI-10 transformation.
* Ver 0.6 Jan 27 98 Allow disabling of SCSI command translation layer
* for access through /dev/sg.
* Fix MODE_SENSE_6/MODE_SELECT_6/INQUIRY translation.
* Ver 0.7 Dec 04 98 Ignore commands where lun != 0 to avoid multiple
* detection of devices with CONFIG_SCSI_MULTI_LUN
* Ver 0.8 Feb 05 99 Optical media need translation too. Reverse 0.7.
* Ver 0.9 Jul 04 99 Fix a bug in SG_SET_TRANSFORM.
*/
#define IDESCSI_VERSION "0.9"
#include <linux/module.h>
#include <linux/types.h>
#include <linux/string.h>
......@@ -495,9 +474,8 @@ static void idescsi_release(struct inode *inode, struct file *filp, struct ata_d
static Scsi_Host_Template template;
static int idescsi_cleanup (struct ata_device *drive)
{
if (ide_unregister_subdriver (drive)) {
if (ata_unregister_device(drive))
return 1;
}
scsi_unregister_host(&template);
return 0;
......@@ -762,7 +740,7 @@ static void idescsi_attach(struct ata_device *drive)
host = scsi_register(&template, sizeof(idescsi_scsi_t));
if (!host) {
printk (KERN_ERR
printk(KERN_ERR
"ide-scsi: %s: Can't allocate a scsi host structure\n",
drive->name);
return;
......@@ -771,8 +749,8 @@ static void idescsi_attach(struct ata_device *drive)
host->max_lun = drive->last_lun + 1;
host->max_id = 1;
if (ide_register_subdriver(drive, &ata_ops)) {
printk (KERN_ERR "ide-scsi: %s: Failed to register the driver with ide.c\n", drive->name);
if (ata_register_device(drive, &ata_ops)) {
printk(KERN_ERR "ide-scsi: %s: Failed to register the driver with ide.c\n", drive->name);
scsi_unregister(host);
return;
}
......
......@@ -2,7 +2,7 @@
# Makefile for the linux kernel.
#
export-objs := newport.o shmiq.o sgicons.o usema.o
export-objs := newport.o shmiq.o sgicons.o usema.o rrm.o
obj-y := newport.o shmiq.o sgicons.o usema.o streamable.o
obj-$(CONFIG_SGI_SERIAL) += sgiserial.o
......
......@@ -2,7 +2,7 @@
# Makefile for USB Core files and filesystem
#
export-objs := usb.o hcd.o hcd-pci.o urb.o message.o config.o file.o
export-objs := usb.o hcd.o hcd-pci.o urb.o message.o file.o
usbcore-objs := usb.o usb-debug.o hub.o hcd.o urb.o message.o \
config.o file.o
......
......@@ -3,8 +3,6 @@
# framework and drivers
#
export-objs := usb-ohci.o
obj-$(CONFIG_USB_EHCI_HCD) += ehci-hcd.o
obj-$(CONFIG_USB_OHCI_HCD) += ohci-hcd.o
obj-$(CONFIG_USB_UHCI_HCD_ALT) += uhci-hcd.o
......
......@@ -40,43 +40,47 @@
static void pdump (void *, int);
#endif
/* Bits of HD_STATUS */
#define ERR_STAT 0x01
#define DRQ_STAT 0x08
struct freecom_udata {
__u8 buffer[64]; /* Common command block. */
u8 buffer[64]; /* Common command block. */
};
typedef struct freecom_udata *freecom_udata_t;
/* All of the outgoing packets are 64 bytes long. */
struct freecom_cb_wrap {
__u8 Type; /* Command type. */
__u8 Timeout; /* Timeout in seconds. */
__u8 Atapi[12]; /* An ATAPI packet. */
__u8 Filler[50]; /* Padding Data. */
u8 Type; /* Command type. */
u8 Timeout; /* Timeout in seconds. */
u8 Atapi[12]; /* An ATAPI packet. */
u8 Filler[50]; /* Padding Data. */
};
struct freecom_xfer_wrap {
__u8 Type; /* Command type. */
__u8 Timeout; /* Timeout in seconds. */
__u32 Count; /* Number of bytes to transfer. */
__u8 Pad[58];
u8 Type; /* Command type. */
u8 Timeout; /* Timeout in seconds. */
u32 Count; /* Number of bytes to transfer. */
u8 Pad[58];
} __attribute__ ((packed));
struct freecom_ide_out {
__u8 Type; /* Type + IDE register. */
__u8 Pad;
__u16 Value; /* Value to write. */
__u8 Pad2[60];
u8 Type; /* Type + IDE register. */
u8 Pad;
u16 Value; /* Value to write. */
u8 Pad2[60];
};
struct freecom_ide_in {
__u8 Type; /* Type | IDE register. */
__u8 Pad[63];
u8 Type; /* Type | IDE register. */
u8 Pad[63];
};
struct freecom_status {
__u8 Status;
__u8 Reason;
__u16 Count;
__u8 Pad[60];
u8 Status;
u8 Reason;
u16 Count;
u8 Pad[60];
};
/* Freecom stuffs the interrupt status in the INDEX_STAT bit of the ide
......
export-objs := atyfb_base.o mach64_accel.o
obj-$(CONFIG_FB_ATY) += atyfb.o
atyfb-y := atyfb_base.o mach64_accel.o ../cfbimgblt.o
......
......@@ -7,8 +7,7 @@
O_TARGET := fs.o
export-objs := filesystems.o open.o dcache.o buffer.o bio.o inode.o dquot.o \
mpage.o
export-objs := open.o dcache.o buffer.o bio.o inode.o dquot.o mpage.o
obj-y := open.o read_write.o devices.o file_table.o buffer.o \
bio.o super.o block_dev.o char_dev.o stat.o exec.o pipe.o \
......
......@@ -477,27 +477,21 @@ static void locks_insert_lock(struct file_lock **pos, struct file_lock *fl)
}
/*
* Remove lock from the lock lists
* Delete a lock and then free it.
* Wake up processes that are blocked waiting for this lock,
* notify the FS that the lock has been cleared and
* finally free the lock.
*/
static inline void _unhash_lock(struct file_lock **thisfl_p)
static void locks_delete_lock(struct file_lock **thisfl_p)
{
struct file_lock *fl = *thisfl_p;
*thisfl_p = fl->fl_next;
fl->fl_next = NULL;
list_del_init(&fl->fl_link);
}
/*
* Wake up processes that are blocked waiting for this lock,
* notify the FS that the lock has been cleared and
* finally free the lock.
*/
static inline void _delete_lock(struct file_lock *fl)
{
fasync_helper(0, fl->fl_file, 0, &fl->fl_fasync);
if (fl->fl_fasync != NULL){
if (fl->fl_fasync != NULL) {
printk(KERN_ERR "locks_delete_lock: fasync == %p\n", fl->fl_fasync);
fl->fl_fasync = NULL;
}
......@@ -509,36 +503,6 @@ static inline void _delete_lock(struct file_lock *fl)
locks_free_lock(fl);
}
/*
* Delete a lock and then free it.
*/
static void locks_delete_lock(struct file_lock **thisfl_p)
{
struct file_lock *fl = *thisfl_p;
_unhash_lock(thisfl_p);
_delete_lock(fl);
}
/*
* Call back client filesystem in order to get it to unregister a lock,
* then delete lock. Essentially useful only in locks_remove_*().
* Note: this must be called with the semaphore already held!
*/
static inline void locks_unlock_delete(struct file_lock **thisfl_p)
{
struct file_lock *fl = *thisfl_p;
int (*lock)(struct file *, int, struct file_lock *);
_unhash_lock(thisfl_p);
if (fl->fl_file->f_op &&
(lock = fl->fl_file->f_op->lock) != NULL) {
fl->fl_type = F_UNLCK;
lock(fl->fl_file, F_SETLK, fl);
}
_delete_lock(fl);
}
/* Determine if lock sys_fl blocks lock caller_fl. Common functionality
* checks for shared/exclusive status of overlapping locks.
*/
......@@ -1638,37 +1602,27 @@ int fcntl_setlk64(struct file *filp, unsigned int cmd, struct flock64 *l)
/*
* This function is called when the file is being removed
* from the task's fd array.
* from the task's fd array. POSIX locks belonging to this task
* are deleted at this time.
*/
void locks_remove_posix(struct file *filp, fl_owner_t owner)
{
struct inode * inode = filp->f_dentry->d_inode;
struct file_lock *fl;
struct file_lock **before;
struct file_lock lock;
/*
* For POSIX locks we free all locks on this file for the given task.
*/
if (!inode->i_flock) {
/*
* Notice that something might be grabbing a lock right now.
* Consider it as a race won by us - event is async, so even if
* we miss the lock added we can trivially consider it as added
* after we went through this call.
*/
return;
}
lock_kernel();
before = &inode->i_flock;
while ((fl = *before) != NULL) {
if (IS_POSIX(fl) && fl->fl_owner == owner) {
locks_unlock_delete(before);
before = &inode->i_flock;
continue;
}
before = &fl->fl_next;
lock.fl_type = F_UNLCK;
lock.fl_flags = FL_POSIX;
lock.fl_start = 0;
lock.fl_end = OFFSET_MAX;
lock.fl_owner = owner;
lock.fl_pid = current->pid;
lock.fl_file = filp;
if (filp->f_op && filp->f_op->lock != NULL) {
filp->f_op->lock(filp, F_SETLK, &lock);
/* Ignore any error -- we must remove the locks anyway */
}
unlock_kernel();
posix_lock_file(filp, &lock, 0);
}
/*
......
......@@ -51,22 +51,22 @@ extern int ncp_symlink(struct inode *, struct dentry *, const char *);
struct file_operations ncp_dir_operations =
{
read: generic_read_dir,
readdir: ncp_readdir,
ioctl: ncp_ioctl,
.read = generic_read_dir,
.readdir = ncp_readdir,
.ioctl = ncp_ioctl,
};
struct inode_operations ncp_dir_inode_operations =
{
create: ncp_create,
lookup: ncp_lookup,
unlink: ncp_unlink,
symlink: ncp_symlink,
mkdir: ncp_mkdir,
rmdir: ncp_rmdir,
mknod: ncp_mknod,
rename: ncp_rename,
setattr: ncp_notify_change,
.create = ncp_create,
.lookup = ncp_lookup,
.unlink = ncp_unlink,
.symlink = ncp_symlink,
.mkdir = ncp_mkdir,
.rmdir = ncp_rmdir,
.mknod = ncp_mknod,
.rename = ncp_rename,
.setattr = ncp_notify_change,
};
/*
......@@ -79,17 +79,17 @@ static int ncp_delete_dentry(struct dentry *);
static struct dentry_operations ncp_dentry_operations =
{
d_revalidate: ncp_lookup_validate,
d_hash: ncp_hash_dentry,
d_compare: ncp_compare_dentry,
d_delete: ncp_delete_dentry,
.d_revalidate = ncp_lookup_validate,
.d_hash = ncp_hash_dentry,
.d_compare = ncp_compare_dentry,
.d_delete = ncp_delete_dentry,
};
struct dentry_operations ncp_root_dentry_operations =
{
d_hash: ncp_hash_dentry,
d_compare: ncp_compare_dentry,
d_delete: ncp_delete_dentry,
.d_hash = ncp_hash_dentry,
.d_compare = ncp_compare_dentry,
.d_delete = ncp_delete_dentry,
};
......
......@@ -296,16 +296,16 @@ static int ncp_release(struct inode *inode, struct file *file) {
struct file_operations ncp_file_operations =
{
llseek: remote_llseek,
read: ncp_file_read,
write: ncp_file_write,
ioctl: ncp_ioctl,
mmap: ncp_mmap,
release: ncp_release,
fsync: ncp_fsync,
.llseek = remote_llseek,
.read = ncp_file_read,
.write = ncp_file_write,
.ioctl = ncp_ioctl,
.mmap = ncp_mmap,
.release = ncp_release,
.fsync = ncp_fsync,
};
struct inode_operations ncp_file_inode_operations =
{
setattr: ncp_notify_change,
.setattr = ncp_notify_change,
};
......@@ -83,12 +83,12 @@ static void destroy_inodecache(void)
static struct super_operations ncp_sops =
{
alloc_inode: ncp_alloc_inode,
destroy_inode: ncp_destroy_inode,
drop_inode: generic_delete_inode,
delete_inode: ncp_delete_inode,
put_super: ncp_put_super,
statfs: ncp_statfs,
.alloc_inode = ncp_alloc_inode,
.destroy_inode = ncp_destroy_inode,
.drop_inode = generic_delete_inode,
.delete_inode = ncp_delete_inode,
.put_super = ncp_put_super,
.statfs = ncp_statfs,
};
extern struct dentry_operations ncp_root_dentry_operations;
......@@ -792,10 +792,10 @@ static struct super_block *ncp_get_sb(struct file_system_type *fs_type,
}
static struct file_system_type ncp_fs_type = {
owner: THIS_MODULE,
name: "ncpfs",
get_sb: ncp_get_sb,
kill_sb: kill_anon_super,
.owner = THIS_MODULE,
.name = "ncpfs",
.get_sb = ncp_get_sb,
.kill_sb = kill_anon_super,
};
static int __init init_ncp_fs(void)
......
......@@ -74,7 +74,7 @@ unsigned long get_wchan(struct task_struct *p);
#define KSTK_ESP(tsk) \
((tsk) == current ? rdusp() : (tsk)->thread_info->pcb.usp)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#define ARCH_HAS_PREFETCH
#define ARCH_HAS_PREFETCHW
......
......@@ -59,7 +59,7 @@ extern void release_thread(struct task_struct *);
unsigned long get_wchan(struct task_struct *p);
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
/*
* Create a new kernel thread
......
......@@ -142,6 +142,6 @@ extern inline unsigned long thread_saved_pc(struct thread_struct *t)
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif /* __ASM_CRIS_PROCESSOR_H */
......@@ -616,7 +616,7 @@ ia64_set_lrr0 (unsigned long val)
asm volatile ("mov cr.lrr0=%0;; srlz.d" :: "r"(val) : "memory");
}
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
static inline void
......
......@@ -137,6 +137,6 @@ unsigned long get_wchan(struct task_struct *p);
eip; })
#define KSTK_ESP(tsk) ((tsk) == current ? rdusp() : (tsk)->thread.usp)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif
......@@ -259,7 +259,7 @@ unsigned long get_wchan(struct task_struct *p);
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif /* !defined (_LANGUAGE_ASSEMBLY) */
#endif /* __KERNEL__ */
......
......@@ -290,7 +290,7 @@ unsigned long get_wchan(struct task_struct *p);
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif /* !defined (_LANGUAGE_ASSEMBLY) */
#endif /* __KERNEL__ */
......
......@@ -333,7 +333,7 @@ extern inline unsigned long get_wchan(struct task_struct *p)
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif /* __ASM_PARISC_PROCESSOR_H */
......@@ -771,7 +771,7 @@ void _nmask_and_or_msr(unsigned long nmask, unsigned long or_val);
#define have_of (_machine == _MACH_chrp || _machine == _MACH_Pmac)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
/*
* Prefetch macros.
......
......@@ -692,7 +692,7 @@ unsigned long get_wchan(struct task_struct *p);
#define KSTK_EIP(tsk) ((tsk)->thread.regs? (tsk)->thread.regs->nip: 0)
#define KSTK_ESP(tsk) ((tsk)->thread.regs? (tsk)->thread.regs->gpr[1]: 0)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
/*
* Prefetch macros.
......
......@@ -134,7 +134,7 @@ unsigned long get_wchan(struct task_struct *p);
#define KSTK_EIP(tsk) (__KSTK_PTREGS(tsk)->psw.addr)
#define KSTK_ESP(tsk) (__KSTK_PTREGS(tsk)->gprs[15])
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
/*
* Set of msr bits that gdb can change on behalf of a process.
......
......@@ -151,7 +151,7 @@ unsigned long get_wchan(struct task_struct *p);
#define KSTK_EIP(tsk) (__KSTK_PTREGS(tsk)->psw.addr)
#define KSTK_ESP(tsk) (__KSTK_PTREGS(tsk)->gprs[15])
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
/*
* Set of msr bits that gdb can change on behalf of a process.
......
......@@ -222,6 +222,6 @@ extern void free_task_struct(struct task_struct *);
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif /* __ASM_SH_PROCESSOR_H */
......@@ -201,7 +201,7 @@ BTFIXUPDEF_CALL(void, get_task_struct, struct task_struct *)
#define init_task (init_task_union.task)
#define init_stack (init_task_union.stack)
#define cpu_relax() do { } while (0)
#define cpu_relax() barrier()
#endif
......
......@@ -225,7 +225,7 @@ __out: __ret; \
#define KSTK_EIP(tsk) ((tsk)->thread_info->kregs->tpc)
#define KSTK_ESP(tsk) ((tsk)->thread_info->kregs->u_regs[UREG_FP])
#define cpu_relax() udelay(1 + smp_processor_id())
#define cpu_relax() do { udelay(1 + smp_processor_id()); barrier(); } while (0)
#endif /* !(__ASSEMBLY__) */
......
......@@ -367,7 +367,7 @@ extern unsigned long get_wchan(struct task_struct *p);
/* REP NOP (PAUSE) is a good thing to insert into busy-wait loops. */
extern inline void rep_nop(void)
{
__asm__ __volatile__("rep;nop");
__asm__ __volatile__("rep;nop": : :"memory");
}
#define cpu_has_fpu 1
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -6,6 +6,7 @@ export-objs := llc_macinit.o p8022.o psnap.o
obj-y := p8023.o
# Check the p8022 selections against net/core/Makefile.
obj-$(CONFIG_SYSCTL) += sysctl_net_802.o
obj-$(CONFIG_LLC) += p8022.o psnap.o llc_sendpdu.o llc_utility.o \
cl2llc.o llc_macinit.o
......
......@@ -2,7 +2,7 @@
# Makefile for the Linux networking core.
#
export-objs := ext8022.o netfilter.o profile.o
export-objs := ext8022.o
obj-y := sock.o skbuff.o iovec.o datagram.o scm.o
......@@ -16,7 +16,8 @@ obj-$(CONFIG_FILTER) += filter.o
obj-$(CONFIG_NET) += dev.o dev_mcast.o dst.o neighbour.o rtnetlink.o utils.o
ifneq ($(CONFIG_LLC),n)
# See p8022 in net/802/Makefile for config options to check
ifneq ($(CONFIG_LLC)$(CONFIG_TR)$(CONFIG_IPX)$(CONFIG_ATALK),)
obj-y += ext8022.o
endif
......
......@@ -2,8 +2,6 @@
# Makefile for the Linux TCP/IP (INET) layer.
#
export-objs = ipip.o ip_gre.o
obj-y := utils.o route.o inetpeer.o proc.o protocol.o \
ip_input.o ip_fragment.o ip_forward.o ip_options.o \
ip_output.o ip_sockglue.o \
......
......@@ -2,7 +2,7 @@
# Makefile for the Linux IPX layer.
#
export-objs = af_ipx.o af_spx.o
export-objs = af_ipx.o
obj-$(CONFIG_IPX) += ipx.o
......
......@@ -2,8 +2,6 @@
# Makefile for the netlink driver.
#
export-objs := af_netlink.o
obj-y := af_netlink.o
obj-$(CONFIG_NETLINK_DEV) += netlink_dev.o
......
......@@ -213,7 +213,7 @@ void use_config(char *m, int slen)
void parse_config_file(char *map, size_t len)
{
int *end = (int *) (map + len);
// start at +1, so that p can never be < map
/* start at +1, so that p can never be < map */
int *m = (int *) map + 1;
char *p, *q;
......@@ -283,7 +283,7 @@ void do_config_file(char *filename)
void parse_dep_file(void *map, size_t len)
{
char *m = map;
char *end = map + len;
char *end = m + len;
char *p;
char s[PATH_MAX];
......
......@@ -3,6 +3,20 @@ ARCH=$2
SMP=$3
CC=$4
# If compile.h exists already and we don't own autoconf.h
# (i.e. we're not the same user who did make *config), don't
# modify compile.h
# So "sudo make install" won't change the "compiled by <user>"
# do "compiled by root"
if [ -r $TARGET -a ! -O ../include/linux/autoconf.h ]; then
echo ' (not modified)'
exit 0
fi
# Do not expand names
set -f
if [ -r ../.version ]; then
VERSION=`cat ../.version`
else
......
......@@ -366,7 +366,7 @@ static int dummy_file_mprotect (struct vm_area_struct *vma, unsigned long prot)
return 0;
}
static int dummy_file_lock (struct file *file, unsigned int cmd, int blocking)
static int dummy_file_lock (struct file *file, unsigned int cmd)
{
return 0;
}
......
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