summaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/acpi/include/acenv.h1
-rw-r--r--drivers/atm/ambassador.c6
-rw-r--r--drivers/atm/iphase.c4
-rw-r--r--drivers/atm/nicstar.c2
-rw-r--r--drivers/block/cpqarray.c2
-rw-r--r--drivers/block/floppy.c27
-rw-r--r--drivers/block/ll_rw_blk.c2
-rw-r--r--drivers/block/ps2esdi.c2
-rw-r--r--drivers/cdrom/aztcd.c2
-rw-r--r--drivers/cdrom/cdu31a.c1
-rw-r--r--drivers/cdrom/mcdx.c1
-rw-r--r--drivers/char/console.c12
-rw-r--r--drivers/char/drm/proc.c2
-rw-r--r--drivers/char/n_hdlc.c80
-rw-r--r--drivers/i2o/i2o_block.c10
-rw-r--r--drivers/ide/ide-cs.c2
-rw-r--r--drivers/ide/ide.c45
-rw-r--r--drivers/isdn/avmb1/capi.c1
-rw-r--r--drivers/isdn/isdn_cards.c3
-rw-r--r--drivers/isdn/isdn_ppp.h1
-rw-r--r--drivers/mtd/doc1000.c3
-rw-r--r--drivers/mtd/docprobe.c1
-rw-r--r--drivers/mtd/mtdblock.c1
-rw-r--r--drivers/mtd/mtdcore.c1
-rw-r--r--drivers/mtd/nftl.c41
-rw-r--r--drivers/net/3c59x.c4
-rw-r--r--drivers/net/8139too.c2
-rw-r--r--drivers/net/acenic_firmware.h7
-rw-r--r--drivers/net/bonding.c2
-rw-r--r--drivers/net/pppoe.c6
-rw-r--r--drivers/net/slhc.c2
-rw-r--r--drivers/net/sunlance.c2
-rw-r--r--drivers/parport/init.c2
-rw-r--r--drivers/sbus/audio/audio.c2
-rw-r--r--drivers/sbus/char/jsflash.c2
-rw-r--r--drivers/sbus/char/sab82532.c4
-rw-r--r--drivers/sbus/char/zs.c18
-rw-r--r--drivers/scsi/fdomain.c2
-rw-r--r--drivers/scsi/inia100.c1
-rw-r--r--drivers/scsi/qlogicfc.c4
-rw-r--r--drivers/scsi/tmscsim.c1
-rw-r--r--drivers/sound/nm256_audio.c2
-rw-r--r--drivers/sound/trident.c4
-rw-r--r--drivers/usb/printer.c2
-rw-r--r--drivers/video/igafb.c7
45 files changed, 186 insertions, 143 deletions
diff --git a/drivers/acpi/include/acenv.h b/drivers/acpi/include/acenv.h
index f2738537f..c8db25702 100644
--- a/drivers/acpi/include/acenv.h
+++ b/drivers/acpi/include/acenv.h
@@ -71,7 +71,6 @@
#ifdef _LINUX
-#include <linux/config.h>
#include <linux/string.h>
#include <linux/kernel.h>
#include <linux/ctype.h>
diff --git a/drivers/atm/ambassador.c b/drivers/atm/ambassador.c
index 4fc415ea8..acf2c194c 100644
--- a/drivers/atm/ambassador.c
+++ b/drivers/atm/ambassador.c
@@ -376,13 +376,13 @@ static inline void dump_registers (const amb_dev * dev) {
u32 * i;
PRINTD (DBG_REGS, "reading PLX control: ");
for (i = (u32 *) 0x00; i < (u32 *) 0x30; ++i)
- rd_mem (dev, i);
+ rd_mem (dev, (size_t)i);
PRINTD (DBG_REGS, "reading mailboxes: ");
for (i = (u32 *) 0x40; i < (u32 *) 0x60; ++i)
- rd_mem (dev, i);
+ rd_mem (dev, (size_t)i);
PRINTD (DBG_REGS, "reading doorb irqev irqen reset:");
for (i = (u32 *) 0x60; i < (u32 *) 0x70; ++i)
- rd_mem (dev, i);
+ rd_mem (dev, (size_t)i);
}
#else
(void) dev;
diff --git a/drivers/atm/iphase.c b/drivers/atm/iphase.c
index c92345f00..053efbd30 100644
--- a/drivers/atm/iphase.c
+++ b/drivers/atm/iphase.c
@@ -2303,7 +2303,7 @@ __initfunc(static int ia_init(struct atm_dev *dev))
dev->number,error);
return -EINVAL;
}
- IF_INIT(printk(DEV_LABEL "(itf %d): rev.%d,realbase=0x%x,irq=%d\n",
+ IF_INIT(printk(DEV_LABEL "(itf %d): rev.%d,realbase=0x%lx,irq=%d\n",
dev->number, revision, real_base, iadev->irq);)
/* find mapping size of board */
@@ -2342,7 +2342,7 @@ __initfunc(static int ia_init(struct atm_dev *dev))
dev->number);
return error;
}
- IF_INIT(printk(DEV_LABEL " (itf %d): rev.%d,base=0x%x,irq=%d\n",
+ IF_INIT(printk(DEV_LABEL " (itf %d): rev.%d,base=0x%lx,irq=%d\n",
dev->number, revision, base, iadev->irq);)
/* filling the iphase dev structure */
diff --git a/drivers/atm/nicstar.c b/drivers/atm/nicstar.c
index dd39f4ccf..733487374 100644
--- a/drivers/atm/nicstar.c
+++ b/drivers/atm/nicstar.c
@@ -441,7 +441,7 @@ static void ns_write_sram(ns_dev *card, u32 sram_address, u32 *value, int count)
static int ns_init_card(int i, struct pci_dev *pcidev)
{
int j;
- struct ns_dev *card;
+ struct ns_dev *card=NULL;
unsigned short pci_command;
unsigned char pci_latency;
unsigned error;
diff --git a/drivers/block/cpqarray.c b/drivers/block/cpqarray.c
index 9ae6fa94c..b03429fae 100644
--- a/drivers/block/cpqarray.c
+++ b/drivers/block/cpqarray.c
@@ -169,7 +169,7 @@ static int ida_proc_get_info(char *buffer, char **start, off_t offset, int lengt
#else
static void ida_procinit(int i) {}
static int ida_proc_get_info(char *buffer, char **start, off_t offset,
- int length, int *eof, void *data) {}
+ int length, int *eof, void *data) { return 0;}
#endif
static void ida_geninit(int ctlr)
diff --git a/drivers/block/floppy.c b/drivers/block/floppy.c
index 18a2c6c91..b8426a6dd 100644
--- a/drivers/block/floppy.c
+++ b/drivers/block/floppy.c
@@ -852,10 +852,10 @@ static void set_fdc(int drive)
}
/* locks the driver */
-static int lock_fdc(int drive, int interruptible)
+static int _lock_fdc(int drive, int interruptible, int line)
{
if (!usage_count){
- printk(KERN_ERR "Trying to lock fdc while usage count=0\n");
+ printk(KERN_ERR "Trying to lock fdc while usage count=0 at line %d\n", line);
return -1;
}
if(floppy_grab_irq_and_dma()==-1)
@@ -889,6 +889,8 @@ static int lock_fdc(int drive, int interruptible)
return 0;
}
+#define lock_fdc(drive,interruptible) _lock_fdc(drive,interruptible, __LINE__)
+
#define LOCK_FDC(drive,interruptible) \
if (lock_fdc(drive,interruptible)) return -EINTR;
@@ -2601,6 +2603,11 @@ static int make_raw_rw_request(void)
int aligned_sector_t;
int max_sector, max_size, tracksize, ssize;
+ if(max_buffer_sectors == 0) {
+ printk("VFS: Block I/O scheduled on unopened device\n");
+ return 0;
+ }
+
set_fdc(DRIVE(CURRENT->rq_dev));
raw_cmd = &default_raw_cmd;
@@ -2955,6 +2962,11 @@ static void process_fd_request(void)
static void do_fd_request(request_queue_t * q)
{
+ if(max_buffer_sectors == 0) {
+ printk("VFS: do_fd_request called on non-open device\n");
+ return;
+ }
+
if (usage_count == 0) {
printk("warning: usage count=0, CURRENT=%p exiting\n", CURRENT);
printk("sect=%ld cmd=%d\n", CURRENT->sector, CURRENT->cmd);
@@ -3782,9 +3794,14 @@ static int check_floppy_change(kdev_t dev)
return 1;
if (UDP->checkfreq < (int)(jiffies - UDRS->last_checked)) {
+ if(floppy_grab_irq_and_dma()) {
+ return 1;
+ }
+
lock_fdc(drive,0);
poll_drive(0,0);
process_fd_request();
+ floppy_release_irq_and_dma();
}
if (UTESTF(FD_DISK_CHANGED) ||
@@ -3810,6 +3827,10 @@ static int floppy_revalidate(kdev_t dev)
UTESTF(FD_VERIFY) ||
test_bit(drive, &fake_change) ||
NO_GEOM){
+ if(usage_count == 0) {
+ printk("VFS: revalidate called on non-open device.\n");
+ return -EFAULT;
+ }
lock_fdc(drive,0);
cf = UTESTF(FD_DISK_CHANGED) || UTESTF(FD_VERIFY);
if (!(cf || test_bit(drive, &fake_change) || NO_GEOM)){
@@ -3831,7 +3852,7 @@ static int floppy_revalidate(kdev_t dev)
size = 1024;
if (!(bh = getblk(dev,0,size))){
process_fd_request();
- return 1;
+ return -ENXIO;
}
if (bh && !buffer_uptodate(bh))
ll_rw_block(READ, 1, &bh);
diff --git a/drivers/block/ll_rw_blk.c b/drivers/block/ll_rw_blk.c
index 7735594cb..37e50dbcd 100644
--- a/drivers/block/ll_rw_blk.c
+++ b/drivers/block/ll_rw_blk.c
@@ -37,6 +37,8 @@
extern int mac_floppy_init(void);
#endif
+extern int lvm_init(void);
+
/*
* For the allocated request tables
*/
diff --git a/drivers/block/ps2esdi.c b/drivers/block/ps2esdi.c
index fec570acb..61cb27ec7 100644
--- a/drivers/block/ps2esdi.c
+++ b/drivers/block/ps2esdi.c
@@ -121,7 +121,7 @@ static int ps2esdi_blocksizes[MAX_HD << 6] = {0,};
static int ps2esdi_drives = 0;
static struct hd_struct ps2esdi[MAX_HD << 6];
static u_short io_base;
-static struct timer_list esdi_timer = {NULL, NULL, 0, 0L, ps2esdi_reset_timer};
+static struct timer_list esdi_timer = {{NULL, NULL}, 0, 0L, ps2esdi_reset_timer};
static int reset_status;
static int ps2esdi_slot = -1;
int tp720esdi = 0; /* Is it Integrated ESDI of ThinkPad-720? */
diff --git a/drivers/cdrom/aztcd.c b/drivers/cdrom/aztcd.c
index b3b73f2fc..8b551a99d 100644
--- a/drivers/cdrom/aztcd.c
+++ b/drivers/cdrom/aztcd.c
@@ -310,7 +310,7 @@ static char azt_auto_eject = AZT_AUTO_EJECT;
static int AztTimeout, AztTries;
static DECLARE_WAIT_QUEUE_HEAD(azt_waitq);
-static struct timer_list delay_timer = { NULL, NULL, 0, 0, NULL };
+static struct timer_list delay_timer = { {NULL, NULL}, 0, 0, NULL };
static struct azt_DiskInfo DiskInfo;
static struct azt_Toc Toc[MAX_TRACKS];
diff --git a/drivers/cdrom/cdu31a.c b/drivers/cdrom/cdu31a.c
index 56054ae9e..27405b3c3 100644
--- a/drivers/cdrom/cdu31a.c
+++ b/drivers/cdrom/cdu31a.c
@@ -3245,6 +3245,7 @@ static struct cdrom_device_info scd_info = {
&scd_dops, /* device operations */
NULL, /* link */
NULL, /* handle */
+ 0, /* devfs */
0, /* dev */
0, /* mask */
2, /* maximum speed */
diff --git a/drivers/cdrom/mcdx.c b/drivers/cdrom/mcdx.c
index 574ee429e..ac667047b 100644
--- a/drivers/cdrom/mcdx.c
+++ b/drivers/cdrom/mcdx.c
@@ -297,6 +297,7 @@ static struct cdrom_device_info mcdx_info = {
&mcdx_dops, /* device operations */
NULL, /* link */
NULL, /* handle */
+ 0, /* de, devfs */
0, /* dev */
0, /* mask */
2, /* maximum speed */
diff --git a/drivers/char/console.c b/drivers/char/console.c
index 6e862ec53..e0c5b9064 100644
--- a/drivers/char/console.c
+++ b/drivers/char/console.c
@@ -587,10 +587,11 @@ void redraw_screen(int new_console, int is_switch)
if (redraw) {
set_origin(currcons);
- set_palette(currcons);
- if (sw->con_switch(vc_cons[currcons].d) && vcmode != KD_GRAPHICS)
+ if (sw->con_switch(vc_cons[currcons].d) && vcmode != KD_GRAPHICS) {
/* Update the screen contents */
+ set_palette(currcons);
do_update_region(currcons, origin, screenbuf_size/2);
+ }
}
set_cursor(currcons);
if (is_switch) {
@@ -2433,8 +2434,6 @@ void __init con_init(void)
* kmalloc is not running yet - we use the bootmem allocator.
*/
for (currcons = 0; currcons < MIN_NR_CONSOLES; currcons++) {
- int j, k ;
-
vc_cons[currcons].d = (struct vc_data *)
alloc_bootmem(sizeof(struct vc_data));
vt_cons[currcons] = (struct vt_struct *)
@@ -2444,11 +2443,6 @@ void __init con_init(void)
kmalloced = 0;
vc_init(currcons, video_num_lines, video_num_columns,
currcons || !sw->con_save_screen);
- for (j=k=0; j<16; j++) {
- vc_cons[currcons].d->vc_palette[k++] = default_red[j] ;
- vc_cons[currcons].d->vc_palette[k++] = default_grn[j] ;
- vc_cons[currcons].d->vc_palette[k++] = default_blu[j] ;
- }
}
currcons = fg_console = 0;
master_display_fg = vc_cons[currcons].d;
diff --git a/drivers/char/drm/proc.c b/drivers/char/drm/proc.c
index d44195539..7f85da2c9 100644
--- a/drivers/char/drm/proc.c
+++ b/drivers/char/drm/proc.c
@@ -225,7 +225,7 @@ static int _drm_queues_info(char *buf, char **start, off_t offset, int len,
atomic_inc(&q->use_count);
DRM_PROC_PRINT_RET(atomic_dec(&q->use_count),
"%5d/0x%03x %5d %5d"
- " %5d/%c%c/%c%c%c %5d %10d %10d %10d\n",
+ " %5d/%c%c/%c%c%c %5Zd %10d %10d %10d\n",
i,
q->flags,
atomic_read(&q->use_count),
diff --git a/drivers/char/n_hdlc.c b/drivers/char/n_hdlc.c
index 7a0df755e..e9585bcaa 100644
--- a/drivers/char/n_hdlc.c
+++ b/drivers/char/n_hdlc.c
@@ -9,7 +9,7 @@
* Al Longyear <longyear@netcom.com>, Paul Mackerras <Paul.Mackerras@cs.anu.edu.au>
*
* Original release 01/11/99
- * ==FILEDATE 19991217==
+ * ==FILEDATE 20000706==
*
* This code is released under the GNU General Public License (GPL)
*
@@ -78,7 +78,7 @@
*/
#define HDLC_MAGIC 0x239e
-#define HDLC_VERSION "1.13"
+#define HDLC_VERSION "1.16"
#include <linux/version.h>
#include <linux/config.h>
@@ -239,6 +239,7 @@ struct n_hdlc {
/* Queues for select() functionality */
wait_queue_head_t read_wait;
wait_queue_head_t write_wait;
+ wait_queue_head_t poll_wait;
int tbusy; /* reentrancy flag for tx wakeup code */
int woke_up;
@@ -317,6 +318,7 @@ static void n_hdlc_release (struct n_hdlc *n_hdlc)
/* Ensure that the n_hdlcd process is not hanging on select()/poll() */
wake_up_interruptible (&n_hdlc->read_wait);
+ wake_up_interruptible (&n_hdlc->poll_wait);
wake_up_interruptible (&n_hdlc->write_wait);
if (tty != NULL && tty->disc_data == n_hdlc)
@@ -463,9 +465,10 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
register int actual;
unsigned long flags;
N_HDLC_BUF *tbuf;
-
+
if (debuglevel >= DEBUG_LEVEL_INFO)
printk("%s(%d)n_hdlc_send_frames() called\n",__FILE__,__LINE__);
+ check_again:
save_flags(flags);
cli ();
@@ -475,6 +478,7 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
return;
}
n_hdlc->tbusy = 1;
+ n_hdlc->woke_up = 0;
restore_flags(flags);
/* get current transmit buffer or get new transmit */
@@ -490,7 +494,6 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
__FILE__,__LINE__,tbuf,tbuf->count);
/* Send the next block of data to device */
- n_hdlc->woke_up = 0;
tty->flags |= (1 << TTY_DO_WRITE_WAKEUP);
actual = tty->driver.write(tty, 0, tbuf->buf, tbuf->count);
@@ -512,6 +515,7 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
/* wait up sleeping writers */
wake_up_interruptible(&n_hdlc->write_wait);
+ wake_up_interruptible(&n_hdlc->poll_wait);
/* get next pending transmit buffer */
tbuf = n_hdlc_buf_get(&n_hdlc->tx_buf_list);
@@ -521,11 +525,6 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
__FILE__,__LINE__,tbuf);
/* buffer not accepted by driver */
-
- /* check if wake up code called since last write call */
- if (n_hdlc->woke_up)
- continue;
-
/* set this buffer as pending buffer */
n_hdlc->tbuf = tbuf;
break;
@@ -541,6 +540,9 @@ static void n_hdlc_send_frames (struct n_hdlc *n_hdlc, struct tty_struct *tty)
n_hdlc->tbusy = 0;
restore_flags(flags);
+ if (n_hdlc->woke_up)
+ goto check_again;
+
if (debuglevel >= DEBUG_LEVEL_INFO)
printk("%s(%d)n_hdlc_send_frames() exit\n",__FILE__,__LINE__);
@@ -568,11 +570,8 @@ static void n_hdlc_tty_wakeup (struct tty_struct *tty)
tty->flags &= ~(1 << TTY_DO_WRITE_WAKEUP);
return;
}
-
- if (!n_hdlc->tbuf)
- tty->flags &= ~(1 << TTY_DO_WRITE_WAKEUP);
- else
- n_hdlc_send_frames (n_hdlc, tty);
+
+ n_hdlc_send_frames (n_hdlc, tty);
} /* end of n_hdlc_tty_wakeup() */
@@ -659,11 +658,12 @@ static void n_hdlc_tty_receive(struct tty_struct *tty,
/* wake up any blocked reads and perform async signalling */
wake_up_interruptible (&n_hdlc->read_wait);
+ wake_up_interruptible (&n_hdlc->poll_wait);
if (n_hdlc->tty->fasync != NULL)
#if LINUX_VERSION_CODE < VERSION(2,3,0)
kill_fasync (n_hdlc->tty->fasync, SIGIO);
#else
- kill_fasync(&n_hdlc->tty->fasync, SIGIO, POLL_IN);
+ kill_fasync (&n_hdlc->tty->fasync, SIGIO, POLL_IN);
#endif
} /* end of n_hdlc_tty_receive() */
@@ -788,34 +788,31 @@ static rw_ret_t n_hdlc_tty_write (struct tty_struct *tty, struct file *file,
count = maxframe;
}
+ add_wait_queue(&n_hdlc->write_wait, &wait);
+ set_current_state(TASK_INTERRUPTIBLE);
+
/* Allocate transmit buffer */
- tbuf = n_hdlc_buf_get(&n_hdlc->tx_free_buf_list);
- if (!tbuf) {
- /* sleep until transmit buffer available */
- add_wait_queue(&n_hdlc->write_wait, &wait);
- while (!tbuf) {
- set_current_state(TASK_INTERRUPTIBLE);
- schedule();
-
- n_hdlc = tty2n_hdlc (tty);
- if (!n_hdlc || n_hdlc->magic != HDLC_MAGIC ||
- tty != n_hdlc->tty) {
- printk("n_hdlc_tty_write: %p invalid after wait!\n", n_hdlc);
- error = -EIO;
- break;
- }
+ /* sleep until transmit buffer available */
+ while (!(tbuf = n_hdlc_buf_get(&n_hdlc->tx_free_buf_list))) {
+ schedule();
- if (signal_pending(current)) {
- error = -EINTR;
- break;
- }
+ n_hdlc = tty2n_hdlc (tty);
+ if (!n_hdlc || n_hdlc->magic != HDLC_MAGIC ||
+ tty != n_hdlc->tty) {
+ printk("n_hdlc_tty_write: %p invalid after wait!\n", n_hdlc);
+ error = -EIO;
+ break;
+ }
- tbuf = n_hdlc_buf_get(&n_hdlc->tx_free_buf_list);
+ if (signal_pending(current)) {
+ error = -EINTR;
+ break;
}
- set_current_state(TASK_RUNNING);
- remove_wait_queue(&n_hdlc->write_wait, &wait);
}
+ set_current_state(TASK_RUNNING);
+ remove_wait_queue(&n_hdlc->write_wait, &wait);
+
if (!error) {
/* Retrieve the user's buffer */
COPY_FROM_USER (error, tbuf->buf, data, count);
@@ -978,8 +975,6 @@ static int n_hdlc_tty_select (struct tty_struct *tty, struct inode *inode,
* Return Value:
*
* bit mask containing info on which ops will not block
- *
- * Note: Called without the kernel lock held. Which is fine.
*/
static unsigned int n_hdlc_tty_poll (struct tty_struct *tty,
struct file *filp, poll_table * wait)
@@ -994,11 +989,9 @@ static unsigned int n_hdlc_tty_poll (struct tty_struct *tty,
/* queue current process into any wait queue that */
/* may awaken in the future (read and write) */
#if LINUX_VERSION_CODE < VERSION(2,1,89)
- poll_wait(&n_hdlc->read_wait, wait);
- poll_wait(&n_hdlc->write_wait, wait);
+ poll_wait(&n_hdlc->poll_wait, wait);
#else
- poll_wait(filp, &n_hdlc->read_wait, wait);
- poll_wait(filp, &n_hdlc->write_wait, wait);
+ poll_wait(filp, &n_hdlc->poll_wait, wait);
#endif
/* set bits for operations that wont block */
if(n_hdlc->rx_buf_list.head)
@@ -1062,6 +1055,7 @@ static struct n_hdlc *n_hdlc_alloc (void)
n_hdlc->flags = 0;
init_waitqueue_head(&n_hdlc->read_wait);
+ init_waitqueue_head(&n_hdlc->poll_wait);
init_waitqueue_head(&n_hdlc->write_wait);
return n_hdlc;
diff --git a/drivers/i2o/i2o_block.c b/drivers/i2o/i2o_block.c
index 2dc69ae33..76ddf7c38 100644
--- a/drivers/i2o/i2o_block.c
+++ b/drivers/i2o/i2o_block.c
@@ -83,10 +83,10 @@
/*
* Events that this OSM is interested in
*/
-#define I2OB_EVENT_MASK I2O_EVT_IND_BSA_VOLUME_LOAD | \
- I2O_EVT_IND_BSA_VOLUME_UNLOAD | \
- I2O_EVT_IND_BSA_VOLUME_UNLOAD_REQ | \
- I2O_EVT_IND_BSA_CAPACITY_CHANGE
+#define I2OB_EVENT_MASK (I2O_EVT_IND_BSA_VOLUME_LOAD | \
+ I2O_EVT_IND_BSA_VOLUME_UNLOAD | \
+ I2O_EVT_IND_BSA_VOLUME_UNLOAD_REQ | \
+ I2O_EVT_IND_BSA_CAPACITY_CHANGE)
/*
@@ -147,7 +147,7 @@ struct i2ob_request
struct i2ob_request *next;
struct request *req;
int num;
-} __cacheline_aligned;
+};
/*
* Per IOP requst queue information
diff --git a/drivers/ide/ide-cs.c b/drivers/ide/ide-cs.c
index 70da1321a..a7619eb8d 100644
--- a/drivers/ide/ide-cs.c
+++ b/drivers/ide/ide-cs.c
@@ -233,7 +233,7 @@ void ide_config(dev_link_t *link)
config_info_t conf;
cistpl_cftable_entry_t *cfg = &parse.cftable_entry;
cistpl_cftable_entry_t dflt = { 0 };
- int i, pass, last_ret, last_fn, hd, io_base, ctl_base;
+ int i, pass, last_ret, last_fn, hd=-1, io_base, ctl_base;
DEBUG(0, "ide_config(0x%p)\n", link);
diff --git a/drivers/ide/ide.c b/drivers/ide/ide.c
index c9c3cb120..43838c6dd 100644
--- a/drivers/ide/ide.c
+++ b/drivers/ide/ide.c
@@ -2858,6 +2858,15 @@ int __init ide_setup (char *s)
const char max_drive = 'a' + ((MAX_HWIFS * MAX_DRIVES) - 1);
const char max_hwif = '0' + (MAX_HWIFS - 1);
+ if (strncmp(s,"ide",3) &&
+ strncmp(s,"idebus",6) &&
+#ifdef CONFIG_BLK_DEV_VIA82CXXX
+ strncmp(s,"splitfifo",9) &&
+#endif /* CONFIG_BLK_DEV_VIA82CXXX */
+ strncmp(s,"hdxlun",6) &&
+ (strncmp(s,"hd",2) && s[2] != '='))
+ return 0;
+
printk("ide_setup: %s", s);
init_ide_data ();
@@ -2867,7 +2876,7 @@ int __init ide_setup (char *s)
printk(" : Enabled support for IDE doublers\n");
ide_doubler = 1;
- return 0;
+ return 1;
}
#endif /* CONFIG_BLK_DEV_IDEDOUBLER */
@@ -2875,7 +2884,7 @@ int __init ide_setup (char *s)
if (!strcmp(s, "ide=reverse")) {
ide_scan_direction = 1;
printk(" : Enabled support for IDE inverse scan order.\n");
- return 0;
+ return 1;
}
#endif /* CONFIG_BLK_DEV_IDEPCI */
@@ -3188,17 +3197,17 @@ int __init ide_setup (char *s)
case 0: goto bad_option;
default:
printk(" -- SUPPORT NOT CONFIGURED IN THIS KERNEL\n");
- return 0;
+ return 1;
}
}
bad_option:
printk(" -- BAD OPTION\n");
- return 0;
+ return 1;
bad_hwif:
printk("-- NOT SUPPORTED ON ide%d", hw);
done:
printk("\n");
- return 0;
+ return 1;
}
/*
@@ -3614,6 +3623,10 @@ int __init ide_init (void)
return 0;
}
+#ifdef MODULE
+char *options = NULL;
+MODULE_PARM(options,"s");
+
static void __init parse_options (char *line)
{
char *next = line;
@@ -3623,21 +3636,11 @@ static void __init parse_options (char *line)
while ((line = next) != NULL) {
if ((next = strchr(line,' ')) != NULL)
*next++ = 0;
- if (!strncmp(line,"ide",3) ||
- !strncmp(line,"idebus",6) ||
-#ifdef CONFIG_BLK_DEV_VIA82CXXX
- !strncmp(line,"splitfifo",9) ||
-#endif /* CONFIG_BLK_DEV_VIA82CXXX */
- !strncmp(line,"hdxlun",6) ||
- (!strncmp(line,"hd",2) && line[2] != '='))
- (void) ide_setup(line);
+ if (!ide_setup(line))
+ printk ("Unknown option '%s'\n", line);
}
}
-#ifdef MODULE
-char *options = NULL;
-MODULE_PARM(options,"s");
-
int init_module (void)
{
parse_options(options);
@@ -3664,12 +3667,6 @@ void cleanup_module (void)
#else /* !MODULE */
-static int parse_ide_setup (char *line)
-{
- parse_options(line);
- /* We MUST return 0 as otherwise no subsequent __setup option works... */
- return 0;
-}
-__setup("", parse_ide_setup);
+__setup("", ide_setup);
#endif /* MODULE */
diff --git a/drivers/isdn/avmb1/capi.c b/drivers/isdn/avmb1/capi.c
index 009010896..06ddc8199 100644
--- a/drivers/isdn/avmb1/capi.c
+++ b/drivers/isdn/avmb1/capi.c
@@ -171,6 +171,7 @@
*
*/
+#include <linux/config.h>
#include <linux/module.h>
#include <linux/errno.h>
#include <linux/kernel.h>
diff --git a/drivers/isdn/isdn_cards.c b/drivers/isdn/isdn_cards.c
index bdbcd4191..a17cd1f79 100644
--- a/drivers/isdn/isdn_cards.c
+++ b/drivers/isdn/isdn_cards.c
@@ -76,6 +76,9 @@ extern void capi_init(void);
extern void capidrv_init(void);
#endif
+extern int act2000_init(void);
+
+
void
isdn_cards_init(void)
{
diff --git a/drivers/isdn/isdn_ppp.h b/drivers/isdn/isdn_ppp.h
index 1a1dcfcfe..2de3035c1 100644
--- a/drivers/isdn/isdn_ppp.h
+++ b/drivers/isdn/isdn_ppp.h
@@ -76,6 +76,7 @@
*/
#include <linux/ppp_defs.h> /* for PPP_PROTOCOL */
+#include <linux/isdn_ppp.h> /* for isdn_ppp info */
extern void isdn_ppp_timer_timeout(void);
extern int isdn_ppp_read(int, struct file *, char *, int);
extern int isdn_ppp_write(int, struct file *, const char *, int);
diff --git a/drivers/mtd/doc1000.c b/drivers/mtd/doc1000.c
index 3b288b129..ce1b6fdd8 100644
--- a/drivers/mtd/doc1000.c
+++ b/drivers/mtd/doc1000.c
@@ -14,6 +14,7 @@
======================================================================*/
+#include <linux/config.h>
#include <linux/module.h>
#include <asm/uaccess.h>
#include <linux/types.h>
@@ -91,7 +92,7 @@ static inline int check_write(volatile u_char *addr);
static inline void block_erase (volatile u_char *addr);
static inline int check_erase(volatile u_char *addr);
-#ifdef __SMP__
+#ifdef CONFIG_SMP
#warning This is definitely not SMP safe. Lock the paging mechanism.
#endif
diff --git a/drivers/mtd/docprobe.c b/drivers/mtd/docprobe.c
index b2c4380d3..5feb64901 100644
--- a/drivers/mtd/docprobe.c
+++ b/drivers/mtd/docprobe.c
@@ -27,6 +27,7 @@
*/
+#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/kmod.h>
diff --git a/drivers/mtd/mtdblock.c b/drivers/mtd/mtdblock.c
index 2d7b5d5fe..a69ec9e65 100644
--- a/drivers/mtd/mtdblock.c
+++ b/drivers/mtd/mtdblock.c
@@ -10,7 +10,6 @@
#include <linux/types.h>
#include <linux/module.h>
-#include <linux/config.h>
#include <linux/mtd/mtd.h>
diff --git a/drivers/mtd/mtdcore.c b/drivers/mtd/mtdcore.c
index bbfc66eaa..7403b6b94 100644
--- a/drivers/mtd/mtdcore.c
+++ b/drivers/mtd/mtdcore.c
@@ -10,6 +10,7 @@
#define DEBUGLVL debug
#endif
+#include <linux/config.h>
#include <linux/module.h>
#include <linux/kernel.h>
#include <linux/sched.h>
diff --git a/drivers/mtd/nftl.c b/drivers/mtd/nftl.c
index 083b1219e..95e851b2c 100644
--- a/drivers/mtd/nftl.c
+++ b/drivers/mtd/nftl.c
@@ -1,10 +1,41 @@
/* Linux driver for NAND Flash Translation Layer */
/* (c) 1999 Machine Vision Holdings, Inc. */
-/* Author: David Woodhouse <dwmw2@infradead.org */
-/* $Id: nftl.c,v 1.34 2000/06/07 14:48:52 dwmw2 Exp $ */
+/* Author: David Woodhouse <dwmw2@infradead.org> */
+/* $Id: nftl.c,v 1.35 2000/07/06 14:35:01 dwmw2 Exp $ */
/*
+ The contents of this file are distributed under the GNU Public
+ Licence version 2 ("GPL"). The legal note below refers only to the
+ _use_ of the code in some jurisdictions, and does not in any way
+ affect the copying, distribution and modification of this code,
+ which is permitted under the terms of the GPL.
+
+ Section 0 of the GPL says:
+
+ "Activities other than copying, distribution and modification are not
+ covered by this License; they are outside its scope."
+
+ You may copy, distribute and modify this code to your hearts'
+ content - it's just that in some jurisdictions, you may only _use_
+ it under the terms of the licence below. This puts it in a similar
+ situation to the ISDN code, which you may need telco approval to
+ use, and indeed any code which has uses that may be restricted in
+ law. For example, certain malicious uses of the networking stack
+ may be illegal, but that doesn't prevent the networking code from
+ being under GPL.
+
+ In fact the ISDN case is worse than this, because modification of
+ the code automatically invalidates its approval. Modificiation,
+ unlike usage, _is_ one of the rights which is protected by the
+ GPL. Happily, the law in those places where approval is required
+ doesn't actually prevent you from modifying the code - it's just
+ that you may not be allowed to _use_ it once you've done so - and
+ because usage isn't addressed by the GPL, that's just fine.
+
+ dwmw2@infradead.org
+ 6/7/0
+
LEGAL NOTE: The NFTL format is patented by M-Systems. They have
granted a licence for its use with their DiskOnChip products:
@@ -16,8 +47,7 @@
A signed copy of this agreement from M-Systems is kept on file by
Red Hat UK Limited. In the unlikely event that you need access to it,
- please contact dwmw2@redhat.com for assistance.
-*/
+ please contact dwmw2@redhat.com for assistance. */
#define PRERELEASE
@@ -25,6 +55,7 @@
#define DEBUGLVL debug
#endif
+#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <asm/errno.h>
@@ -1267,7 +1298,7 @@ int __init init_nftl(void)
printk(KERN_NOTICE "M-Systems NAND Flash Translation Layer driver. (C) 1999 MVHI\n");
#ifdef PRERELEASE
- printk(KERN_INFO"$Id: nftl.c,v 1.34 2000/06/07 14:48:52 dwmw2 Exp $\n");
+ printk(KERN_INFO"$Id: nftl.c,v 1.35 2000/07/06 14:35:01 dwmw2 Exp $\n");
#endif
if (register_blkdev(NFTL_MAJOR, "nftl", &nftl_fops)){
diff --git a/drivers/net/3c59x.c b/drivers/net/3c59x.c
index 3f74c6537..9bb2fa52f 100644
--- a/drivers/net/3c59x.c
+++ b/drivers/net/3c59x.c
@@ -959,11 +959,11 @@ static int __devinit vortex_probe1(struct pci_dev *pdev,
#endif
if (pdev && vci->drv_flags & HAS_CB_FNS) {
- u32 fn_st_addr; /* Cardbus function status space */
+ unsigned long fn_st_addr; /* Cardbus function status space */
fn_st_addr = pci_resource_start (pdev, 2);
if (fn_st_addr)
vp->cb_fn_base = ioremap(fn_st_addr, 128);
- printk(KERN_INFO "%s: CardBus functions mapped %8.8x->%p\n",
+ printk(KERN_INFO "%s: CardBus functions mapped %8.8lx->%p\n",
dev->name, fn_st_addr, vp->cb_fn_base);
#if 1 /* AKPM: the 575_cb and 905B LEDs seem OK without this */
if (vortex_pci_tbl[chip_idx].device != 0x5257) {
diff --git a/drivers/net/8139too.c b/drivers/net/8139too.c
index 7bc5e03ce..6d06b0a5f 100644
--- a/drivers/net/8139too.c
+++ b/drivers/net/8139too.c
@@ -1332,7 +1332,6 @@ static void rtl8139_timer (unsigned long data)
{
struct net_device *dev = (struct net_device *) data;
struct rtl8139_private *tp = (struct rtl8139_private *) dev->priv;
- void *ioaddr = tp->mmio_addr;
int next_tick = 60 * HZ;
int mii_reg5;
@@ -1342,6 +1341,7 @@ static void rtl8139_timer (unsigned long data)
#if 0
if (!tp->duplex_lock && mii_reg5 != 0xffff) {
+ void *ioaddr = tp->mmio_addr;
int duplex = (mii_reg5 & 0x0100)
|| (mii_reg5 & 0x01C0) == 0x0040;
if (tp->full_duplex != duplex) {
diff --git a/drivers/net/acenic_firmware.h b/drivers/net/acenic_firmware.h
index cb2441285..df51afa30 100644
--- a/drivers/net/acenic_firmware.h
+++ b/drivers/net/acenic_firmware.h
@@ -17,9 +17,6 @@
#define tigonFwSbssLen 0x38
#define tigonFwBssAddr 0x00015dd0
#define tigonFwBssLen 0x2080
-u32 tigonFwText[];
-u32 tigonFwData[];
-u32 tigonFwRodata[];
#ifndef CONFIG_ACENIC_OMIT_TIGON_I
/* Generated by genfw.c */
u32 tigonFwText[(MAX_TEXT_LEN/4) + 1] __initdata = {
@@ -4595,6 +4592,10 @@ u32 tigonFwData[(MAX_DATA_LEN/4) + 1] __initdata = {
0x0, 0x0, 0x0, 0x2,
0x0, 0x0, 0x30001, 0x1,
0x30201, 0x0, 0x0, 0x0 };
+#else
+#define tigonFwText NULL
+#define tigonFwData NULL
+#define tigonFwRodata NULL
#endif
/* Generated by genfw.c */
#define tigon2FwReleaseMajor 0xc
diff --git a/drivers/net/bonding.c b/drivers/net/bonding.c
index c806f028d..0b9d33e10 100644
--- a/drivers/net/bonding.c
+++ b/drivers/net/bonding.c
@@ -180,7 +180,7 @@ static int bond_release(struct net_device *master, struct net_device *dev)
}
}
- return;
+ return 0;
}
/* It is pretty silly, SIOCSIFHWADDR exists to make this. */
diff --git a/drivers/net/pppoe.c b/drivers/net/pppoe.c
index 841c0e12c..a2da24437 100644
--- a/drivers/net/pppoe.c
+++ b/drivers/net/pppoe.c
@@ -5,7 +5,9 @@
* PPPoE --- PPP over Ethernet (RFC 2516)
*
*
- * Version: 0.5.0
+ * Version: 0.5.1
+ *
+ * 030700 : Fixed connect logic to allow for disconnect
*
* Author: Michal Ostrowski <mostrows@styx.uwaterloo.ca>
*
@@ -545,7 +547,7 @@ int pppoe_connect(struct socket *sock, struct sockaddr *uservaddr,
goto end;
error = -EBUSY;
- if (sk->state & PPPOX_CONNECTED)
+ if ((sk->state & PPPOX_CONNECTED) && sp->sa_addr.pppoe.sid)
goto end;
dev = dev_get_by_name(sp->sa_addr.pppoe.dev);
diff --git a/drivers/net/slhc.c b/drivers/net/slhc.c
index 10df97225..410bb59c9 100644
--- a/drivers/net/slhc.c
+++ b/drivers/net/slhc.c
@@ -56,6 +56,7 @@
#include <linux/string.h>
#include <linux/errno.h>
#include <linux/kernel.h>
+#include <net/slhc_vj.h>
#ifdef CONFIG_INET
/* Entire module is for IP only */
@@ -78,7 +79,6 @@
#include <asm/system.h>
#include <asm/uaccess.h>
#include <net/checksum.h>
-#include <net/slhc_vj.h>
#include <asm/unaligned.h>
int last_retran;
diff --git a/drivers/net/sunlance.c b/drivers/net/sunlance.c
index 5db78eb16..39d278bb1 100644
--- a/drivers/net/sunlance.c
+++ b/drivers/net/sunlance.c
@@ -1,4 +1,4 @@
-/* $Id: sunlance.c,v 1.101 2000/06/19 06:24:46 davem Exp $
+/* $Id: sunlance.c,v 1.102 2000/06/30 10:18:35 davem Exp $
* lance.c: Linux/Sparc/Lance driver
*
* Written 1995, 1996 by Miguel de Icaza
diff --git a/drivers/parport/init.c b/drivers/parport/init.c
index 8ad352774..416ca51cb 100644
--- a/drivers/parport/init.c
+++ b/drivers/parport/init.c
@@ -20,7 +20,9 @@
#ifndef MODULE
static int io[PARPORT_MAX+1] __initdata = { [0 ... PARPORT_MAX] = 0 };
+#ifdef CONFIG_PARPORT_PC
static int io_hi[PARPORT_MAX+1] __initdata = { [0 ... PARPORT_MAX] = 0 };
+#endif
static int irq[PARPORT_MAX] __initdata = { [0 ... PARPORT_MAX-1] = PARPORT_IRQ_PROBEONLY };
static int dma[PARPORT_MAX] __initdata = { [0 ... PARPORT_MAX-1] = PARPORT_DMA_NONE };
diff --git a/drivers/sbus/audio/audio.c b/drivers/sbus/audio/audio.c
index a4db8b9c4..be7e9de06 100644
--- a/drivers/sbus/audio/audio.c
+++ b/drivers/sbus/audio/audio.c
@@ -1,4 +1,4 @@
-/* $Id: audio.c,v 1.52 2000/06/22 11:42:27 davem Exp $
+/* $Id: audio.c,v 1.53 2000/07/06 01:41:34 davem Exp $
* drivers/sbus/audio/audio.c
*
* Copyright 1996 Thomas K. Dyas (tdyas@noc.rutgers.edu)
diff --git a/drivers/sbus/char/jsflash.c b/drivers/sbus/char/jsflash.c
index e197661f7..b01f26969 100644
--- a/drivers/sbus/char/jsflash.c
+++ b/drivers/sbus/char/jsflash.c
@@ -400,7 +400,7 @@ static int jsf_ioctl_program(unsigned long arg)
togo = abuf.size;
if ((togo & 3) || (p & 3)) return -EINVAL;
- uptr = (char *) abuf.data;
+ uptr = (char *) (unsigned long) abuf.data;
if (verify_area(VERIFY_READ, uptr, togo))
return -EFAULT;
while (togo != 0) {
diff --git a/drivers/sbus/char/sab82532.c b/drivers/sbus/char/sab82532.c
index 378148159..6fb6678f7 100644
--- a/drivers/sbus/char/sab82532.c
+++ b/drivers/sbus/char/sab82532.c
@@ -1,4 +1,4 @@
-/* $Id: sab82532.c,v 1.45 2000/05/08 22:23:08 ecd Exp $
+/* $Id: sab82532.c,v 1.46 2000/07/06 01:41:37 davem Exp $
* sab82532.c: ASYNC Driver for the SIEMENS SAB82532 DUSCC.
*
* Copyright (C) 1997 Eddie C. Dost (ecd@skynet.be)
@@ -2173,7 +2173,7 @@ static void __init sab82532_kgdb_hook(int line)
static inline void __init show_serial_version(void)
{
- char *revision = "$Revision: 1.45 $";
+ char *revision = "$Revision: 1.46 $";
char *version, *p;
version = strchr(revision, ' ');
diff --git a/drivers/sbus/char/zs.c b/drivers/sbus/char/zs.c
index f9512e12c..40284c603 100644
--- a/drivers/sbus/char/zs.c
+++ b/drivers/sbus/char/zs.c
@@ -1,4 +1,4 @@
-/* $Id: zs.c,v 1.57 2000/04/26 09:36:32 davem Exp $
+/* $Id: zs.c,v 1.58 2000/07/06 01:41:38 davem Exp $
* zs.c: Zilog serial port driver for the Sparc.
*
* Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu)
@@ -824,20 +824,6 @@ static void do_serial_hangup(void *private_)
tty_hangup(tty);
}
-
-/*
- * This subroutine is called when the RS_TIMER goes off. It is used
- * by the serial driver to handle ports that do not have an interrupt
- * (irq=0). This doesn't work at all for 16450's, as a sun has a Z8530.
- */
-
-static void zs_timer(void)
-{
- printk("zs_timer called\n");
- prom_halt();
- return;
-}
-
static int startup(struct sun_serial * info)
{
unsigned long flags;
@@ -1920,7 +1906,7 @@ int zs_open(struct tty_struct *tty, struct file * filp)
static void show_serial_version(void)
{
- char *revision = "$Revision: 1.57 $";
+ char *revision = "$Revision: 1.58 $";
char *version, *p;
version = strchr(revision, ' ');
diff --git a/drivers/scsi/fdomain.c b/drivers/scsi/fdomain.c
index 71cd7337a..9694cf5e7 100644
--- a/drivers/scsi/fdomain.c
+++ b/drivers/scsi/fdomain.c
@@ -693,7 +693,7 @@ static int fdomain_get_irq( int base )
static int fdomain_isa_detect( int *irq, int *iobase )
{
int i, j;
- int base;
+ int base = 0xdeadbeef;
int flag = 0;
#if DEBUG_DETECT
diff --git a/drivers/scsi/inia100.c b/drivers/scsi/inia100.c
index 6ca6ca7f9..984d9b6db 100644
--- a/drivers/scsi/inia100.c
+++ b/drivers/scsi/inia100.c
@@ -228,7 +228,6 @@ int orc_ReturnNumberOfAdapters(void)
};
unsigned int dRegValue;
- unsigned short command;
WORD wBIOS, wBASE;
BYTE bPCIBusNum, bInterrupt, bPCIDeviceNum;
diff --git a/drivers/scsi/qlogicfc.c b/drivers/scsi/qlogicfc.c
index 6200afafc..05fd57cb0 100644
--- a/drivers/scsi/qlogicfc.c
+++ b/drivers/scsi/qlogicfc.c
@@ -73,8 +73,8 @@ typedef dma_addr_t dma64_addr_t;
#define pci64_unmap_single(d,a,s,dir) pci_unmap_single((d),(a),(s),(dir))
#define pci64_unmap_sg(d,s,n,dir) pci_unmap_sg((d),(s),(n),(dir))
#if BITS_PER_LONG > 32
-#define pci64_dma_hi32(a) ((u32) (0xffffffff & (a>>32)))
-#define pci64_dma_lo32(a) ((u32) (0xffffffff & (a)))
+#define pci64_dma_hi32(a) ((u32) (0xffffffff & (((u64)(a))>>32)))
+#define pci64_dma_lo32(a) ((u32) (0xffffffff & (((u64)(a)))))
#else
#define pci64_dma_hi32(a) 0
#define pci64_dma_lo32(a) (a)
diff --git a/drivers/scsi/tmscsim.c b/drivers/scsi/tmscsim.c
index a1779ad10..47d1d0c2d 100644
--- a/drivers/scsi/tmscsim.c
+++ b/drivers/scsi/tmscsim.c
@@ -165,6 +165,7 @@
#include "constants.h"
#include "sd.h"
#include <linux/stat.h>
+#include <scsi/scsicam.h>
#include "dc390.h"
diff --git a/drivers/sound/nm256_audio.c b/drivers/sound/nm256_audio.c
index ef87c6293..887f4f53e 100644
--- a/drivers/sound/nm256_audio.c
+++ b/drivers/sound/nm256_audio.c
@@ -379,7 +379,7 @@ nm256_write_block (struct nm256_info *card, char *buffer, u32 amt)
card->abuf1 + card->curPlayPos,
rem);
if (amt > rem)
- nm256_writeBuffer8 (card, buffer, 1, card->abuf1,
+ nm256_writeBuffer8 (card, buffer + rem, 1, card->abuf1,
amt - rem);
}
else
diff --git a/drivers/sound/trident.c b/drivers/sound/trident.c
index 2eb458274..6e2b70791 100644
--- a/drivers/sound/trident.c
+++ b/drivers/sound/trident.c
@@ -538,7 +538,7 @@ static struct trident_channel *ali_alloc_rec_pcm_channel(struct trident_card *ca
}
-static void trident_free_pcm_channel(struct trident_card *card, int channel)
+static void trident_free_pcm_channel(struct trident_card *card, unsigned int channel)
{
int bank;
@@ -551,7 +551,7 @@ static void trident_free_pcm_channel(struct trident_card *card, int channel)
card->banks[bank].bitmap &= ~(1 << (channel));
}
-static void ali_free_pcm_channel(struct trident_card *card, int channel)
+static void ali_free_pcm_channel(struct trident_card *card, unsigned int channel)
{
int bank;
diff --git a/drivers/usb/printer.c b/drivers/usb/printer.c
index 638a91ed9..4dc11aee0 100644
--- a/drivers/usb/printer.c
+++ b/drivers/usb/printer.c
@@ -42,7 +42,7 @@
#include <linux/init.h>
#include <linux/malloc.h>
#include <linux/lp.h>
-#define DEBUG
+#undef DEBUG
#include <linux/usb.h>
#define USBLP_BUF_SIZE 8192
diff --git a/drivers/video/igafb.c b/drivers/video/igafb.c
index b9b1a1aed..5ce2f2648 100644
--- a/drivers/video/igafb.c
+++ b/drivers/video/igafb.c
@@ -356,7 +356,7 @@ static int iga_setcolreg(unsigned regno, unsigned red, unsigned green,
pci_outb(info, green, DAC_DATA);
pci_outb(info, blue, DAC_DATA);
- if (regno < 16)
+ if (regno < 16) {
switch (default_var.bits_per_pixel) {
#ifdef FBCON_HAS_CFB16
case 16:
@@ -372,11 +372,14 @@ static int iga_setcolreg(unsigned regno, unsigned red, unsigned green,
#endif
#ifdef FBCON_HAS_CFB32
case 32:
+ { int i;
i = (regno << 8) | regno;
info->fbcon_cmap.cfb32[regno] = (i << 16) | i;
+ }
break;
#endif
}
+ }
return 0;
}
@@ -510,6 +513,8 @@ static void igafb_set_disp(int con, struct fb_info_iga *info)
break;
#endif
default:
+ printk(KERN_WARNING "igafb_set_disp: unknown resolution %d\n",
+ default_var.bits_per_pixel);
return;
}
memcpy(&info->dispsw, sw, sizeof(*sw));