VERSION = 2
PATCHLEVEL = 2
SUBLEVEL = 17
-EXTRAVERSION = pre14
+EXTRAVERSION = pre15
ARCH := $(shell uname -m | sed -e s/i.86/i386/ -e s/sun4u/sparc64/ -e s/arm.*/arm/ -e s/sa110/arm/)
-/* $Id: sparc_ksyms.c,v 1.77.2.4 1999/09/28 16:47:30 davem Exp $
+/* $Id: sparc_ksyms.c,v 1.77.2.5 2000/07/17 18:44:26 jj Exp $
* arch/sparc/kernel/ksyms.c: Sparc specific ksyms support.
*
* Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu)
__EXPORT_SYMBOL(__sparc_dot_ ## sym, "." #sym)
#define EXPORT_SYMBOL_PRIVATE(sym) \
-extern int __sparc_priv_ ## sym (int) __asm__("__" ## #sym); \
+extern int __sparc_priv_ ## sym (int) __asm__("__" #sym); \
const struct module_symbol __export_priv_##sym \
__attribute__((section("__ksymtab"))) = \
-{ (unsigned long) &__sparc_priv_ ## sym, "__" ## #sym }
+{ (unsigned long) &__sparc_priv_ ## sym, "__" #sym }
/* used by various drivers */
EXPORT_SYMBOL(sparc_cpu_model);
-# $Id: config.in,v 1.67.2.5 1999/10/19 16:49:37 davem Exp $
+# $Id: config.in,v 1.67.2.11 2000/07/27 01:50:59 davem Exp $
# For a description of the syntax of this configuration file,
# see Documentation/kbuild/config-language.txt.
#
fi
fi
tristate 'SUNW,envctrl support' CONFIG_ENVCTRL
+ tristate '7-Segment Display support' CONFIG_DISPLAY7SEG
fi
endmenu
-/* $Id: ebus.c,v 1.36.2.4 1999/11/08 23:25:45 davem Exp $
+/* $Id: ebus.c,v 1.36.2.5 2000/07/27 01:50:59 davem Exp $
* ebus.c: PCI to EBus bridge device.
*
* Copyright (C) 1997 Eddie C. Dost (ecd@skynet.be)
#ifdef CONFIG_ENVCTRL
extern int envctrl_init(void);
#endif
+#ifdef CONFIG_DISPLAY7SEG
+extern int d7s_init(void);
+#endif
static inline unsigned long ebus_alloc(size_t size)
{
#endif
#ifdef CONFIG_OBP_FLASH
flash_init();
+#endif
+#ifdef CONFIG_DISPLAY7SEG
+ d7s_init();
#endif
clock_probe();
power_init();
-/* $Id: ioctl32.c,v 1.62.2.12 2000/05/27 04:46:26 davem Exp $
+/* $Id: ioctl32.c,v 1.62.2.13 2000/07/27 01:50:59 davem Exp $
* ioctl32.c: Conversion between 32bit and 64bit native ioctls.
*
* Copyright (C) 1997 Jakub Jelinek (jj@sunsite.mff.cuni.cz)
#include <asm/envctrl.h>
#include <asm/audioio.h>
#include <asm/ethtool.h>
+#include <asm/display7seg.h>
#include <linux/soundcard.h>
case _IOR('v' , BASE_VIDIOCPRIVATE+6, int):
case _IOR('v' , BASE_VIDIOCPRIVATE+7, int):
- /* Little p (/dev/rtc, /dev/envctrl, etc.) */
+ /* Little p (/dev/rtc, /dev/envctrl, /dev/d7s, etc.) */
case RTCGET:
case RTCSET:
case ENVCTRL_RD_WARNING_TEMPERATURE:
case ENVCTRL_RD_ETHERNET_TEMPERATURE:
case ENVCTRL_RD_MTHRBD_TEMPERATURE:
case ENVCTRL_RD_CPU_VOLTAGE:
+ case D7SIOCWR:
+ /* case D7SIOCRD: Same value as ENVCTRL_RD_VOLTAGE_STATUS */
+ case D7SIOCTM:
/* Little m */
-/* $Id: psycho.c,v 1.85.2.9 2000/05/01 06:33:49 davem Exp $
+/* $Id: psycho.c,v 1.85.2.10 2000/06/14 07:41:19 davem Exp $
* psycho.c: Ultra/AX U2P PCI controller support.
*
* Copyright (C) 1997 David S. Miller (davem@caipfs.rutgers.edu)
-/* $Id: rtrap.S,v 1.45 1998/11/09 15:33:29 davem Exp $
+/* $Id: rtrap.S,v 1.45.2.1 2000/07/28 02:10:55 davem Exp $
* rtrap.S: Preparing for return from trap on Sparc V9.
*
* Copyright (C) 1997,1998 Jakub Jelinek (jj@sunsite.mff.cuni.cz)
add %sp, STACK_BIAS + REGWIN_SZ, %o1
clr %l6
+ /* Signal delivery can change ptregs->tstate so we must
+ * reload it into %l1 here.
+ */
+ ldx [%sp + PTREGS_OFF + PT_V9_TSTATE], %l1
+ sethi %hi(0xf << 20), %l4
+ and %l1, %l4, %l4
+ andn %l1, %l4, %l1
+
/* We must not take any traps between here and the actual
* return to user-space. If we do we risk having windows
* saved to the thread struct between the test and the
-/* $Id: sparc64_ksyms.c,v 1.58.2.7 2000/05/27 04:46:26 davem Exp $
+/* $Id: sparc64_ksyms.c,v 1.58.2.8 2000/06/14 07:41:19 davem Exp $
* arch/sparc64/kernel/sparc64_ksyms.c: Sparc64 specific ksyms support.
*
* Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu)
-/* $Id: blockops.S,v 1.16.2.2 2000/03/03 23:50:32 davem Exp $
+/* $Id: blockops.S,v 1.16.2.4 2000/07/14 01:11:29 davem Exp $
* blockops.S: UltraSparc block zero optimized routines.
*
* Copyright (C) 1996,1998 David S. Miller (davem@caip.rutgers.edu)
sethi %hi(DCACHE_SIZE), %o1
add %o0, %o3, %o0
add %o0, %o1, %o1
- sethi %hi(TLBTEMP_ENT1), %o3
+ mov TLBTEMP_ENT1, %o3
rdpr %pstate, %g3
wrpr %g3, PSTATE_IE, %pstate
/* Spitfire Errata #32 workaround */
mov 0x8, %o4
stxa %g0, [%o4] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %o4
+ flush %o4
ldxa [%o3] ASI_DTLB_TAG_READ, %o4
/* Spitfire Errata #32 workaround */
mov 0x8, %o5
stxa %g0, [%o5] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %o5
+ flush %o5
ldxa [%o3] ASI_DTLB_DATA_ACCESS, %o5
stxa %o0, [%o2] ASI_DMMU
/* Spitfire Errata #32 workaround */
mov 0x8, %g5
stxa %g0, [%g5] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %g5
+ flush %g5
ldxa [%o3] ASI_DTLB_TAG_READ, %g5
/* Spitfire Errata #32 workaround */
mov 0x8, %g7
stxa %g0, [%g7] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %g7
+ flush %g7
ldxa [%o3] ASI_DTLB_DATA_ACCESS, %g7
stxa %o1, [%o2] ASI_DMMU
mov TLB_TAG_ACCESS, %o2
sethi %hi(TLBTEMP_BASE), %o3
add %o0, %o3, %o0
- sethi %hi(TLBTEMP_ENT2), %o3
+ mov TLBTEMP_ENT2, %o3
rdpr %pstate, %g3
wrpr %g3, PSTATE_IE, %pstate
/* Spitfire Errata #32 workaround */
mov 0x8, %g5
stxa %g0, [%g5] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %g5
+ flush %g5
ldxa [%o3] ASI_DTLB_TAG_READ, %g5
/* Spitfire Errata #32 workaround */
mov 0x8, %g7
stxa %g0, [%g7] ASI_DMMU
- flush %g6
+ sethi %hi(empty_zero_page), %g7
+ flush %g7
ldxa [%o3] ASI_DTLB_DATA_ACCESS, %g7
stxa %o0, [%o2] ASI_DMMU
case 5:
board.port = (unsigned char *)ints[index];
- if (board.port <= 0)
+ if ((signed long)board.port <= 0)
{
printk(KERN_ERR "<Error> - epca_setup: Invalid io port 0x%x\n", (unsigned int)board.port);
invalid_lilo_config = 1;
case 6:
board.membase = (unsigned char *)ints[index];
- if (board.membase <= 0)
+ if ((signed long)board.membase <= 0)
{
printk(KERN_ERR "<Error> - epca_setup: Invalid memory base 0x%x\n",(unsigned int)board.membase);
invalid_lilo_config = 1;
struct sk_buff *skb;
unsigned ApplId;
- unsigned MsgLen;
+ signed MsgLen;
unsigned DataB3Len;
unsigned NCCI;
unsigned WindowSize;
struct capi_ctr *ctrl = cinfo->capi_ctrl;
struct sk_buff *skb;
void *p = dma->recvbuf+4;
- __u32 ApplId, MsgLen, DataB3Len, NCCI, WindowSize;
+ __u32 ApplId, DataB3Len, NCCI, WindowSize;
+ __s32 MsgLen;
__u8 b1cmd = _get_byte(&p);
#ifdef CONFIG_B1DMA_DEBUG
avmctrl_info *cinfo;
struct sk_buff *skb;
void *p = dma->recvbuf;
- __u32 ApplId, MsgLen, DataB3Len, NCCI, WindowSize;
+ __u32 ApplId, DataB3Len, NCCI, WindowSize;
+ __s32 MsgLen;
__u8 b1cmd = _get_byte(&p);
__u32 cidx;
struct sk_buff *skb;
unsigned ApplId;
- unsigned MsgLen;
+ signed MsgLen;
unsigned DataB3Len;
unsigned NCCI;
unsigned WindowSize;
if (hdlc->mode==MODE_NONE)
return -ENOSYS;
- result=hdlc->open(hdlc);
- if (result)
- return result;
-
memset(&(hdlc->stats), 0, sizeof(struct net_device_stats));
if (mode_is(hdlc, MODE_FR | MODE_SOFT) ||
result = sppp_open(dev);
if (result) {
sppp_detach(dev);
- hdlc->close(hdlc);
return result;
}
}
- return 0;
+ result=hdlc->open(hdlc);
+ if (result) {
+ if (mode_is(hdlc, MODE_FR | MODE_SOFT) ||
+ mode_is(hdlc, MODE_CISCO | MODE_SOFT))
+ fr_cisco_close(hdlc);
+
+ else if (mode_is(hdlc, MODE_PPP | MODE_SOFT)) {
+ sppp_close(dev);
+ sppp_detach(dev);
+ dev->rebuild_header=NULL;
+ dev->change_mtu=hdlc_change_mtu;
+ dev->mtu=HDLC_MAX_MTU;
+ dev->hard_header_len=16;
+ }
+
+ }
+
+ return result;
}
{
hdlc_device *hdlc=dev_to_hdlc(dev);
+ hdlc->close(hdlc);
+
if (mode_is(hdlc, MODE_FR | MODE_SOFT) ||
mode_is(hdlc, MODE_CISCO | MODE_SOFT))
fr_cisco_close(hdlc);
dev->hard_header_len=16;
}
- hdlc->close(hdlc);
return 0;
}
endif
endif
+ifeq ($(CONFIG_DISPLAY7SEG),y)
+O_OBJS += display7seg.o
+else
+ ifeq ($(CONFIG_DISPLAY7SEG),m)
+ M_OBJS += display7seg.o
+ endif
+endif
+
endif # eq($(CONFIG_PCI,y)
ifeq ($(CONFIG_OBP_FLASH),y)
--- /dev/null
+/* $Id: display7seg.c,v 1.1.2.1 2000/07/27 01:50:59 davem Exp $
+ *
+ * display7seg - Driver implementation for the 7-segment display
+ * present on Sun Microsystems CP1400 and CP1500
+ *
+ * Copyright (c) 2000 Eric Brower (ebrower@usa.net)
+ *
+ */
+
+#include <linux/kernel.h>
+#include <linux/module.h>
+#include <linux/version.h>
+#include <linux/fs.h>
+#include <linux/errno.h>
+#include <linux/major.h>
+#include <linux/init.h>
+#include <linux/miscdevice.h>
+#include <linux/ioport.h> /* request_region, check_region */
+#include <asm/ebus.h> /* EBus device */
+#include <asm/oplib.h> /* OpenProm Library */
+#include <asm/uaccess.h> /* put_/get_user_ret */
+
+#include <asm/display7seg.h>
+
+#define D7S_MINOR 193
+#define D7S_OBPNAME "display7seg"
+#define D7S_DEVNAME "d7s"
+
+static int sol_compat = 0; /* Solaris compatibility mode */
+
+#ifdef MODULE
+EXPORT_NO_SYMBOLS;
+
+/* Solaris compatibility flag -
+ * The Solaris implementation omits support for several
+ * documented driver features (ref Sun doc 806-0180-03).
+ * By default, this module supports the documented driver
+ * abilities, rather than the Solaris implementation:
+ *
+ * 1) Device ALWAYS reverts to OBP-specified FLIPPED mode
+ * upon closure of device or module unload.
+ * 2) Device ioctls D7SIOCRD/D7SIOCWR honor toggling of
+ * FLIP bit
+ *
+ * If you wish the device to operate as under Solaris,
+ * omitting above features, set this parameter to non-zero.
+ */
+MODULE_PARM
+ (sol_compat, "1i");
+MODULE_PARM_DESC
+ (sol_compat,
+ "Disables documented functionality omitted from Solaris driver");
+
+MODULE_AUTHOR
+ ("Eric Brower <ebrower@usa.net>");
+MODULE_DESCRIPTION
+ ("7-Segment Display driver for Sun Microsystems CP1400/1500");
+MODULE_SUPPORTED_DEVICE
+ ("d7s");
+#endif /* ifdef MODULE */
+
+/*
+ * Register block- see header for details
+ * -----------------------------------------
+ * | DP | ALARM | FLIP | 4 | 3 | 2 | 1 | 0 |
+ * -----------------------------------------
+ *
+ * DP - Toggles decimal point on/off
+ * ALARM - Toggles "Alarm" LED green/red
+ * FLIP - Inverts display for upside-down mounted board
+ * bits 0-4 - 7-segment display contents
+ */
+
+struct d7s_regs {
+ volatile __u8 regblk;
+};
+
+volatile struct d7s_regs *regs;
+
+static inline void d7s_free(void)
+{
+ release_region((unsigned long)regs, sizeof(*regs));
+}
+
+static inline int d7s_obpflipped(void)
+{
+ int opt_node, ret;
+
+ opt_node = prom_getchild(prom_root_node);
+ opt_node = prom_searchsiblings(opt_node, "options");
+
+ ret = prom_getintdefault(opt_node, "d7s-flipped?", -1);
+ if (ret != -1)
+ ret = 0;
+ else
+ ret = 1;
+
+ return ret;
+}
+
+static int d7s_open(struct inode *inode, struct file *f)
+{
+ if (D7S_MINOR != MINOR(inode->i_rdev))
+ return -ENODEV;
+
+ MOD_INC_USE_COUNT;
+ return 0;
+}
+
+static int d7s_release(struct inode *inode, struct file *f)
+{
+ if (D7S_MINOR != MINOR(inode->i_rdev))
+ return -ENODEV;
+
+ MOD_DEC_USE_COUNT;
+
+ /* Reset flipped state to OBP default only if
+ * no other users have the device open and we
+ * are not operating in solaris-compat mode.
+ */
+ if (MOD_IN_USE == 0 && sol_compat == 0) {
+ if (d7s_obpflipped() == 0)
+ regs->regblk |= D7S_FLIP;
+ else
+ regs->regblk &= ~D7S_FLIP;
+ }
+
+ return 0;
+}
+
+static int d7s_ioctl(struct inode *inode, struct file *f,
+ unsigned int cmd, unsigned long arg)
+{
+ __u8 ireg = 0;
+
+ if (D7S_MINOR != MINOR(inode->i_rdev))
+ return -ENODEV;
+
+ switch (cmd) {
+ case D7SIOCWR:
+ /* Assign device register values,
+ * we mask-out D7S_FLIP if in sol_compat mode.
+ */
+ get_user_ret(ireg, (int *) arg, -EFAULT);
+ if (sol_compat != 0) {
+ if (regs->regblk & D7S_FLIP)
+ ireg |= D7S_FLIP;
+ else
+ ireg &= ~D7S_FLIP;
+ }
+ regs->regblk = ireg;
+ break;
+ case D7SIOCRD:
+ /* Retrieve device register values.
+ *
+ * NOTE: Solaris implementation returns D7S_FLIP bit
+ * as toggled by user, even though it does not honor it.
+ * This driver will not misinform you about the state
+ * of your hardware while in sol_compat mode.
+ */
+ put_user_ret(regs->regblk, (int *) arg, -EFAULT);
+ break;
+ case D7SIOCTM:
+ /* Toggle device mode-- flip display orientation. */
+ if (regs->regblk & D7S_FLIP)
+ regs->regblk &= ~D7S_FLIP;
+ else
+ regs->regblk |= D7S_FLIP;
+ break;
+ };
+
+ return 0;
+}
+
+static struct file_operations d7s_fops = {
+ NULL, /* lseek */
+ NULL, /* read */
+ NULL, /* write */
+ NULL, /* readdir */
+ NULL, /* select */
+ d7s_ioctl,
+ NULL, /* mmap */
+ d7s_open,
+ NULL, /* flush */
+ d7s_release,
+ NULL, /* fsync */
+ NULL, /* fasync */
+ NULL, /* chk media chg*/
+ NULL, /* revalidate */
+ NULL, /* lock */
+};
+
+static struct miscdevice d7s_miscdev = { D7S_MINOR, D7S_DEVNAME, &d7s_fops };
+
+#ifdef MODULE
+int init_module(void)
+#else
+__initfunc(int d7s_init(void))
+#endif
+{
+ struct linux_ebus *ebus = NULL;
+ struct linux_ebus_device *edev = NULL;
+ int iTmp = 0;
+
+ for_each_ebus(ebus) {
+ for_each_ebusdev(edev, ebus) {
+ if (!strcmp(edev->prom_name, D7S_OBPNAME))
+ goto ebus_done;
+ }
+ }
+
+ebus_done:
+ if (!edev) {
+ printk("%s: unable to locate device\n", D7S_DEVNAME);
+ return -ENODEV;
+ }
+
+ if (check_region(edev->base_address[0], sizeof(*regs))) {
+ printk("%s: Can't get region %lx, %d\n",
+ __FUNCTION__, edev->base_address[0], (int)sizeof(*regs));
+ return -ENODEV;
+ }
+
+ regs = (struct d7s_regs *) edev->base_address[0];
+ request_region((unsigned long) regs, sizeof(*regs), D7S_OBPNAME);
+ iTmp = misc_register(&d7s_miscdev);
+ if (iTmp != 0) {
+ printk("%s: unable to acquire miscdevice minor %i\n",
+ D7S_DEVNAME, D7S_MINOR);
+ return iTmp;
+ }
+
+ /* OBP option "d7s-flipped?" is honored as default
+ * for the device, and reset default when detached
+ */
+ iTmp = d7s_obpflipped();
+ if (iTmp == 0)
+ regs->regblk |= D7S_FLIP;
+ else
+ regs->regblk &= ~D7S_FLIP;
+
+ printk("%s: 7-Segment Display%s at 0x%lx %s\n",
+ D7S_DEVNAME,
+ (iTmp == 0) ? (" (FLIPPED)") : (""),
+ edev->base_address[0],
+ (sol_compat != 0) ? ("in sol_compat mode") : (""));
+ return 0;
+}
+
+#ifdef MODULE
+void cleanup_module(void)
+{
+ /* Honor OBP d7s-flipped? unless operating in solaris-compat mode. */
+ if (sol_compat == 0) {
+ if (d7s_obpflipped() == 0)
+ regs->regblk |= D7S_FLIP;
+ else
+ regs->regblk &= ~D7S_FLIP;
+ }
+
+ misc_deregister(&d7s_miscdev);
+ d7s_free();
+}
+#endif
3w-xxxx.c -- 3ware Storage Controller device driver for Linux.
Written By: Adam Radford <linux@3ware.com>
- Modifications By: Joel Jacobson <linux@3ware.com>
-
Copyright (C) 1999-2000 3ware Inc.
Kernel compatablity By: Andre Hedrick <andre@suse.com>
For more information, goto:
http://www.3ware.com
-
- History
- -------
- 0.1.000 - Initial release.
- 0.4.000 - Added support for Asynchronous Event Notification through
- ioctls for 3DM.
- 1.0.000 - Added DPO & FUA bit support for WRITE_10 & WRITE_6 cdb
- to disable drive write-cache before writes.
- 1.1.000 - Fixed performance bug with DPO & FUA not existing for WRITE_6.
- 1.2.000 - Added support for clean shutdown notification/feature table.
- 1.02.00.001 - Added support for full command packet posts through ioctls
- for 3DM.
- Bug fix so hot spare drives don't show up.
*/
#include <linux/module.h>
#include <linux/string.h>
#include <linux/delay.h>
#include <linux/smp.h>
-#include <linux/reboot.h>
#include <asm/spinlock.h>
#include <asm/errno.h>
static int tw_copy_info(TW_Info *info, char *fmt, ...);
static void tw_copy_mem_info(TW_Info *info, char *data, int len);
static void tw_interrupt(int irq, void *dev_instance, struct pt_regs *regs);
-static int tw_halt(struct notifier_block *nb, ulong event, void *buf);
-
-/* Notifier block to get a notify on system shutdown/halt/reboot */
-static struct notifier_block tw_notifier = {
- tw_halt, NULL, 0
-};
struct proc_dir_entry tw_scsi_proc_entry = {
PROC_SCSI_3W_XXXX,
};
/* Globals */
-char *tw_driver_version="1.02.00.001";
+char *tw_driver_version="1.1.000";
TW_Device_Extension *tw_device_extension_list[TW_MAX_SLOT];
int tw_device_extension_count = 0;
if (command_packet->status != 0) {
if (command_packet->flags != TW_AEN_TABLE_UNDEFINED) {
/* Bad response */
- printk(KERN_WARNING "3w-xxxx: tw_aen_drain_queue(): Bad response, status = 0x%x, flags = 0x%x.\n", command_packet->status, command_packet->flags);
+ printk(KERN_WARNING "3w-xxxx: tw_aen_drain_queue(): Bad response, flags = 0x%x.\n", command_packet->flags);
return 1;
} else {
/* We know this is a 3w-1x00, and doesn't support aen's */
TW_Device_Extension *tw_dev2;
struct pci_dev *tw_pci_dev = pci_devices;
u32 status_reg_value;
- unsigned char c = 1;
dprintk(KERN_NOTICE "3w-xxxx: tw_findcards()\n");
while ((tw_pci_dev = pci_find_device(TW_VENDOR_ID, TW_DEVICE_ID, tw_pci_dev))) {
continue;
}
- error = tw_initconnection(tw_dev, TW_INIT_MESSAGE_CREDITS);
+ error = tw_initconnection(tw_dev);
if (error) {
printk(KERN_WARNING "3w-xxxx: tw_findcards(): Couldn't initconnection for card %d.\n", numcards);
release_region((tw_dev->tw_pci_dev->base_address[0]), TW_IO_ADDRESS_RANGE);
/* Free the temporary device extension */
if (tw_dev)
kfree(tw_dev);
- /* Tell the firmware we support shutdown notification*/
- tw_setfeature(tw_dev, 2, 1, &c);
}
if (numcards == 0)
printk(KERN_WARNING "3w-xxxx: tw_findcards(): No cards found.\n");
- else
- register_reboot_notifier(&tw_notifier);
return numcards;
} /* End tw_findcards() */
}
} /* End tw_free_device_extension() */
-/* Clean shutdown routine */
-static int tw_halt(struct notifier_block *nb, ulong event, void *buf)
-{
- int i;
-
- for (i=0;i<tw_device_extension_count;i++) {
- printk(KERN_NOTICE "3w-xxxx: Notifying card #%d\n", i);
- tw_shutdown_device(tw_device_extension_list[i]);
- }
- unregister_reboot_notifier(&tw_notifier);
-
- return NOTIFY_OK;
-} /* End tw_halt() */
-
/* This function will send an initconnection command to controller */
-int tw_initconnection(TW_Device_Extension *tw_dev, int message_credits)
+int tw_initconnection(TW_Device_Extension *tw_dev)
{
u32 command_que_addr, command_que_value;
u32 status_reg_addr, status_reg_value;
command_packet->byte3.host_id = 0x0;
command_packet->status = 0x0;
command_packet->flags = 0x0;
- command_packet->byte6.message_credits = message_credits;
+ command_packet->byte6.message_credits = TW_INIT_MESSAGE_CREDITS;
command_packet->byte8.init_connection.response_queue_pointer = 0x0;
command_que_value = tw_dev->command_packet_physical_address[request_id];
}
if (command_packet->status != 0) {
/* bad response */
- printk(KERN_WARNING "3w-xxxx: tw_initconnection(): Bad response, status = 0x%x, flags = 0x%x.\n", command_packet->status, command_packet->flags);
+ printk(KERN_WARNING "3w-xxxx: tw_initconnection(): Bad response, flags = 0x%x.\n", command_packet->flags);
return 1;
}
break; /* Response was okay, so we exit */
}
if (command_packet->status != 0) {
/* bad response */
- printk(KERN_WARNING "3w-xxxx: tw_initialize_units(): Bad response, status = 0x%x, flags = 0x%x.\n", command_packet->status, command_packet->flags);
+ printk(KERN_WARNING "3w-xxxx: tw_initialize_units(): Bad response, flags = 0x%x.\n", command_packet->flags);
return 1;
}
found = 1;
if (is_unit_present[i] == 0) {
tw_dev->is_unit_present[i] = FALSE;
} else {
- if (is_unit_present[i] & TW_UNIT_ONLINE) {
dprintk(KERN_NOTICE "3w-xxxx: tw_initialize_units(): Unit %d found.\n", i);
tw_dev->is_unit_present[i] = TRUE;
num_units++;
- }
}
}
tw_dev->num_units = num_units;
request_id = response_que.u.response_id;
command_packet = (TW_Command *)tw_dev->command_packet_virtual_address[request_id];
if (command_packet->status != 0) {
- printk(KERN_WARNING "3w-xxxx: tw_interrupt(): Bad response, status = 0x%x, flags = 0x%x.\n", command_packet->status, command_packet->flags);
+ printk(KERN_WARNING "3w-xxxx: tw_interrupt(): Bad response, flags = 0x%x.\n", command_packet->flags);
}
if (tw_dev->state[request_id] != TW_S_POSTED) {
printk(KERN_WARNING "3w-xxxx: tw_interrupt(): Received a request id (%d) (opcode = 0x%x) that wasn't posted.\n", request_id, command_packet->byte0.opcode);
/* Initialize command packet */
command_packet = (TW_Command *)tw_dev->command_packet_virtual_address[request_id];
if (command_packet == NULL) {
- printk(KERN_WARNING "3w-xxxx: tw_ioctl(): Bad command packet virtual address.\n");
+ printk(KERN_WARNING "3w-xxxx: twioctl(): Bad command packet virtual address.\n");
tw_dev->state[request_id] = TW_S_COMPLETED;
tw_state_request_finish(tw_dev, request_id);
tw_dev->srb[request_id]->result = (DID_OK << 16);
tw_dev->srb[request_id]->result = (DID_OK << 16);
tw_dev->srb[request_id]->scsi_done(tw_dev->srb[request_id]);
return 0;
- case TW_CMD_PACKET:
- memcpy(command_packet, ioctl->data, sizeof(TW_Command));
- command_packet->request_id = request_id;
- tw_post_command_packet(tw_dev, request_id);
-
- return 0;
default:
printk(KERN_WARNING "3w-xxxx: Unknown ioctl 0x%x.\n", opcode);
tw_dev->state[request_id] = TW_S_COMPLETED;
return 1;
}
- error = tw_initconnection(tw_dev, TW_INIT_MESSAGE_CREDITS);
+ error = tw_initconnection(tw_dev);
if (error) {
printk(KERN_WARNING "3w-xxxx: tw_reset_sequence(): Couldn't initconnection for card %d.\n", tw_dev->host->host_no);
return 1;
/* Tell kernel scsi-layer we are gone */
scsi_unregister(tw_host);
- /* Fake like we just shut down, so notify the card that
- * we "shut down cleanly".
- */
- tw_halt(0, 0, 0); // parameters aren't actually used
-
return 0;
} /* End tw_scsi_release() */
if (is_unit_present[i] == 0) {
tw_dev->is_unit_present[i] = FALSE;
} else {
- if (is_unit_present[i] & TW_UNIT_ONLINE) {
tw_dev->is_unit_present[i] = TRUE;
dprintk(KERN_NOTICE "3w-xxxx: tw_scsiop_inquiry_complete: Unit %d found.\n", i);
- }
}
}
return 0;
} /* End tw_scsiop_test_unit_ready() */
-/* Set a value in the features table */
-int tw_setfeature(TW_Device_Extension *tw_dev, int parm, int param_size,
- unsigned char *val)
-{
- TW_Param *param;
- TW_Command *command_packet;
- TW_Response_Queue response_queue;
- int request_id = 0;
- u32 command_que_value, command_que_addr;
- u32 status_reg_addr, status_reg_value;
- u32 response_que_addr;
- u32 param_value;
- int imax, i;
-
- /* Initialize SetParam command packet */
- if (tw_dev->command_packet_virtual_address[request_id] == NULL) {
- printk(KERN_WARNING "3w-xxxx: tw_setfeature(): Bad command packet virtual address.\n");
- return 1;
- }
- command_packet = (TW_Command *)tw_dev->command_packet_virtual_address[request_id];
- memset(command_packet, 0, sizeof(TW_Sector));
- param = (TW_Param *)tw_dev->alignment_virtual_address[request_id];
-
- command_packet->byte0.opcode = TW_OP_SET_PARAM;
- command_packet->byte0.sgl_offset = 2;
- param->table_id = 0x404; /* Features table */
- param->parameter_id = parm;
- param->parameter_size_bytes = param_size;
- memcpy(param->data, val, param_size);
-
- param_value = tw_dev->alignment_physical_address[request_id];
- if (param_value == 0) {
- printk(KERN_WARNING "3w-xxxx: tw_ioctl(): Bad alignment physical address.\n");
- tw_dev->state[request_id] = TW_S_COMPLETED;
- tw_state_request_finish(tw_dev, request_id);
- tw_dev->srb[request_id]->result = (DID_OK << 16);
- tw_dev->srb[request_id]->scsi_done(tw_dev->srb[request_id]);
- }
- command_packet->byte8.param.sgl[0].address = param_value;
- command_packet->byte8.param.sgl[0].length = sizeof(TW_Sector);
-
- command_packet->size = 4;
- command_packet->request_id = request_id;
- command_packet->byte6.parameter_count = 1;
-
- command_que_value = tw_dev->command_packet_physical_address[request_id];
- if (command_que_value == 0) {
- printk(KERN_WARNING "3w-xxxx: tw_setfeature(): Bad command packet physical address.\n");
- return 1;
- }
- command_que_addr = tw_dev->registers.command_que_addr;
- status_reg_addr = tw_dev->registers.status_reg_addr;
- response_que_addr = tw_dev->registers.response_que_addr;
-
- /* Send command packet to the board */
- outl(command_que_value, command_que_addr);
-
- /* Poll for completion */
- imax = TW_POLL_MAX_RETRIES;
- for (i=0;i<imax;i++) {
- mdelay(10);
- status_reg_value = inl(status_reg_addr);
- if (tw_check_bits(status_reg_value)) {
- printk(KERN_WARNING "3w-xxxx: tw_setfeature(): Unexpected bits.\n");
- return 1;
- }
- if ((status_reg_value & TW_STATUS_RESPONSE_QUEUE_EMPTY) == 0) {
- response_queue.value = inl(response_que_addr);
- request_id = (unsigned char)response_queue.u.response_id;
- if (request_id != 0) {
- /* unexpected request id */
- printk(KERN_WARNING "3w-xxxx: tw_setfeature(): Unexpected request id.\n");
- return 1;
- }
- if (command_packet->status != 0) {
- /* bad response */
- printk(KERN_WARNING "3w-xxxx: tw_setfeature(): Bad response, status = 0x%x, flags = 0x%x.\n", command_packet->status, command_packet->flags);
- return 1;
- }
- break; /* Response was okay, so we exit */
- }
- }
-
- return 0;
-} /* End tw_setfeature() */
-
/* This function will setup the interrupt handler */
int tw_setup_irq(TW_Device_Extension *tw_dev)
{
return 0;
} /* End tw_setup_irq() */
-/* This function will tell the controller we're shutting down by sending
- initconnection with a 1 */
-int tw_shutdown_device(TW_Device_Extension *tw_dev)
-{
- int error;
-
- /* Disable interrupts */
- tw_disable_interrupts(tw_dev);
-
- /* poke the board */
- error = tw_initconnection(tw_dev, 1);
- if (error) {
- printk(KERN_WARNING "3w-xxxx: tw_shutdown_device(): Couldn't initconnection for card %d.\n", tw_dev->host->host_no);
- } else {
- printk(KERN_NOTICE "3w-xxxx shutdown succeeded\n");
- }
-
- /* Re-enable interrupts */
- tw_enable_interrupts(tw_dev);
-
- return 0;
-} /* End tw_shutdown_device() */
-
/* This function will soft reset the controller */
void tw_soft_reset(TW_Device_Extension *tw_dev)
{
3w-xxxx.h -- 3ware Storage Controller device driver for Linux.
Written By: Adam Radford <linux@3ware.com>
- Modifications By: Joel Jacobson <linux@3ware.com>
-
- Copyright (C) 1999, 2000 3ware Inc.
+ Copyright (C) 1999 3ware Inc.
Kernel compatablity By: Andre Hedrick <andre@suse.com>
Non-Copyright (C) 2000 Andre Hedrick <andre@suse.com>
#define TW_OP_SET_PARAM 0x13
#define TW_OP_SECTOR_INFO 0x1a
#define TW_OP_AEN_LISTEN 0x1c
-#define TW_CMD_PACKET 0x1d
/* Asynchronous Event Notification (AEN) Codes */
#define TW_AEN_QUEUE_EMPTY 0x0000
#define TW_BLOCK_SIZE 0x200 /* 512-byte blocks */
#define TW_IOCTL 0x80
#define TW_MAX_AEN_TRIES 100
-#define TW_UNIT_ONLINE 1
+
#define TW_IN_INTR 1
/* Macros */
void tw_enable_interrupts(TW_Device_Extension *tw_dev);
int tw_findcards(Scsi_Host_Template *tw_host);
void tw_free_device_extension(TW_Device_Extension *tw_dev);
-int tw_initconnection(TW_Device_Extension *tw_dev, int message_credits);
+int tw_initconnection(TW_Device_Extension *tw_dev);
int tw_initialize_device_extension(TW_Device_Extension *tw_dev);
int tw_initialize_units(TW_Device_Extension *tw_dev);
int tw_ioctl(TW_Device_Extension *tw_dev, int request_id);
int tw_scsiop_read_capacity_complete(TW_Device_Extension *tw_dev, int request_id);
int tw_scsiop_read_write(TW_Device_Extension *tw_dev, int request_id);
int tw_scsiop_test_unit_ready(TW_Device_Extension *tw_dev, int request_id);
-int tw_setfeature(TW_Device_Extension *tw_dev, int parm, int param_size, unsigned char *val);
int tw_setup_irq(TW_Device_Extension *tw_dev);
-int tw_shutdown_device(TW_Device_Extension *tw_dev);
void tw_soft_reset(TW_Device_Extension *tw_dev);
int tw_state_request_finish(TW_Device_Extension *tw_dev,int request_id);
int tw_state_request_start(TW_Device_Extension *tw_dev, int *request_id);
eh_strategy_handler : NULL, \
eh_abort_handler : tw_scsi_eh_abort, \
eh_device_reset_handler : NULL, \
- eh_bus_reset_handler : NULL, \
- eh_host_reset_handler : tw_scsi_eh_reset, \
abort : NULL, \
reset : NULL, \
slave_attach : NULL, \
dmabuf->ready = 0;
if(val)
dmabuf->fmt |= CS_FMT_STEREO;
+#if 0
+ /* Needs extra work to support this */
else
dmabuf->fmt &= ~CS_FMT_STEREO;
+#endif
}
return 0;
}
case SNDCTL_DSP_GETFMTS: /* Returns a mask of supported sample format*/
- return put_user(AFMT_S16_LE|AFMT_U8, (int *)arg);
+ return put_user(AFMT_S16_LE, (int *)arg);
case SNDCTL_DSP_SETFMT: /* Select sample format */
get_user_ret(val, (int *)arg, -EFAULT);
if (val != AFMT_QUERY) {
- if(val==AFMT_S16_LE || val==AFMT_U8)
+ if(val==AFMT_S16_LE/* || val==AFMT_U8*/)
{
if (file->f_mode & FMODE_WRITE) {
stop_dac(state);
if (file->f_mode & FMODE_WRITE) {
stop_dac(state);
dmabuf->ready = 0;
+ if(val>1)
+ dmabuf->fmt |= CS_FMT_STEREO;
+ else
+ dmabuf->fmt &= ~CS_FMT_STEREO;
}
if (file->f_mode & FMODE_READ) {
stop_adc(state);
dmabuf->ready = 0;
}
}
- return put_user(2, (int *)arg);
+ return put_user((dmabuf->fmt & CS_FMT_STEREO) ? 2 : 1,
+ (int *)arg);
case SNDCTL_DSP_POST:
/* FIXME: the same as RESET ?? */
return 0;
case SNDCTL_DSP_GETCAPS:
- return put_user(DSP_CAP_REALTIME|DSP_CAP_TRIGGER|DSP_CAP_MMAP,
+ return put_user(DSP_CAP_REALTIME|DSP_CAP_TRIGGER|DSP_CAP_MMAP,
(int *)arg);
case SNDCTL_DSP_GETTRIGGER:
should be default to unsigned 8-bits, mono, with sample rate 8kHz and
/dev/dspW will accept 16-bits sample */
if (file->f_mode & FMODE_WRITE) {
+ /* Output is 16bit only mono or stereo */
dmabuf->fmt &= ~CS_FMT_MASK;
dmabuf->fmt |= CS_FMT_16BIT;
dmabuf->ossfragshift = 0;
dmabuf->ossmaxfrags = 0;
dmabuf->subdivision = 0;
- cs_set_dac_rate(state, 48000);
+ cs_set_dac_rate(state, 8000);
}
if (file->f_mode & FMODE_READ) {
+ /* Input is 16bit stereo only */
dmabuf->fmt &= ~CS_FMT_MASK;
- dmabuf->fmt |= CS_FMT_16BIT;
+ dmabuf->fmt |= CS_FMT_16BIT|CS_FMT_STEREO;
dmabuf->ossfragshift = 0;
dmabuf->ossmaxfrags = 0;
dmabuf->subdivision = 0;
- cs_set_adc_rate(state, 48000);
+ cs_set_adc_rate(state, 8000);
}
state->open_mode |= file->f_mode & (FMODE_READ | FMODE_WRITE);
break;
current->state = TASK_UNINTERRUPTIBLE;
schedule_timeout(1);
- } while (end_time - (signed long)jiffies >= 0);
+ } while (time_before(end_time, jiffies));
/*
* Make sure CODEC is READY.
break;
current->state = TASK_UNINTERRUPTIBLE;
schedule_timeout(1);
- } while (end_time - (signed long)jiffies >= 0);
+ } while (time_before(end_time, jiffies));
/*
* Make sure input slots 3 and 4 are valid. If not, then return
{
struct pci_dev *dev;
int count = 0, found, i;
-
+#ifdef CONFIG_PCI
list_add_tail(&drv->node, &pci_drivers);
pci_for_each_dev(dev) {
found = 0;
if (!found)
count += pci_announce_device(drv, dev);
}
+#endif
return count;
}
{
struct pci_dev *dev;
int i, found;
-
+#ifdef CONFIG_PCI
list_del(&drv->node);
pci_for_each_dev(dev) {
found = 0;
drvmap[i].dev = NULL;
}
}
+#endif
}
unsigned long pci_compat_get_size (struct pci_dev *dev, int n_base)
/*
*
- * Trident 4D-Wave/SiS 7018 OSS driver for Linux 2.2.x
+ * Trident 4D-Wave/SiS 7018/ALi 5451 OSS driver for Linux 2.2.x
*
* Driver: Alan Cox <alan@redhat.com>
*
* Hacked up by:
* Aaron Holtzman <aholtzma@ess.engr.uvic.ca>
* Ollie Lho <ollie@sis.com.tw> SiS 7018 Audio Core Support
+ * Ching Ling Lee <cling-li@ali.com.tw> ALi 5451 Audio Core Support
*
*
* This program is free software; you can redistribute it and/or modify
ixj_WriteDSPCommand(0x0700, board);
}
- if (ixj[board].play_mode != -1 && ixj[board].rec_mode != -1);
+ if (ixj[board].play_mode != -1 && ixj[board].rec_mode != -1)
{
ixj_WriteDSPCommand(0xB002, board); // AEC Stop
bool ' G100/G200 support' CONFIG_FB_MATROX_G100
bool ' Multihead support' CONFIG_FB_MATROX_MULTIHEAD
fi
- #bool 'ATI Rage128 display support' CONFIG_FB_ATY128
+ bool 'ATI Rage128 display support' CONFIG_FB_ATY128
fi
fi
if [ "$ARCH" = "sparc" -o "$ARCH" = "sparc64" ]; then
#define GI_CHIP_ID 0x4749 /* RAGE PRO, BGA, PCI33 only */
#define GP_CHIP_ID 0x4750 /* RAGE PRO, PQFP, PCI33, full 3D */
#define GQ_CHIP_ID 0x4751 /* RAGE PRO, PQFP, PCI33, limited 3D */
-#define LN_CHIP_ID 0x4c4d /* RAGE Mobility AGP */
+#define LM_CHIP_ID 0x4c4d /* RAGE Mobility PCI */
+#define LN_CHIP_ID 0x4c4e /* RAGE Mobility AGP */
/* Mach64 major ASIC revisions */
-/* $Id: atyfb.c,v 1.106.2.8 2000/04/28 04:40:09 davem Exp $
+/* $Id: atyfb.c,v 1.106.2.9 2000/06/23 12:06:38 davem Exp $
* linux/drivers/video/atyfb.c -- Frame buffer device for ATI Mach64
*
* Copyright (C) 1997-1998 Geert Uytterhoeven
{ 0x4749, 0x4749, "3D RAGE PRO (BGA, PCI)" },
{ 0x4750, 0x4750, "3D RAGE PRO (PQFP, PCI)" },
{ 0x4751, 0x4751, "3D RAGE PRO (PQFP, PCI, limited 3D)" },
- { 0x4c4e, 0x4c4e, "3D RAGE Mobility (AGP)" }, /* Doesn't quite work yet */
+ { 0x4c4d, 0x4c4d, "3D RAGE Mobility (PCI)" },
+ { 0x4c4e, 0x4c4e, "3D RAGE Mobility (AGP)" },
};
static const char *aty_gx_ram[8] __initdata = {
} else if ((Gx == VT_CHIP_ID) || (Gx == VU_CHIP_ID)) {
aty_st_le32(DAC_CNTL, 0x87010184, info);
aty_st_le32(BUS_CNTL, 0x680000f9, info);
- } else if (Gx == LN_CHIP_ID) {
+ } else if ((Gx == LN_CHIP_ID) || (Gx == LM_CHIP_ID)) {
aty_st_le32(DAC_CNTL, 0x80010102, info);
aty_st_le32(BUS_CNTL, 0x7b33a040, info);
} else {
/* Rage LT */
pll = 230;
mclk = 63;
- } else if (Gx == LN_CHIP_ID) {
- /* Rage mobility */
+ } else if ((Gx == LN_CHIP_ID) || (Gx == LM_CHIP_ID)) {
+ /* Rage mobility M1 */
pll = 230;
- mclk = 100;
+ mclk = 50;
} else {
/* other RAGE */
pll = 135;
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:
#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;
}
case 15:
case 16:
sw = &fbcon_cfb16;
- display->dispsw_data = fbcon_cmap.cfb16;
+ display->dispsw_data = info->fbcon_cmap.cfb16;
break;
#endif
#ifdef FBCON_HAS_CFB24
case 24:
sw = &fbcon_cfb24;
- display->dispsw_data = fbcon_cmap.cfb24;
+ display->dispsw_data = info->fbcon_cmap.cfb24;
break;
#endif
#ifdef FBCON_HAS_CFB32
case 32:
sw = &fbcon_cfb32;
- display->dispsw_data = fbcon_cmap.cfb32;
+ display->dispsw_data = info->fbcon_cmap.cfb32;
break;
#endif
default:
/*
* Fill the binprm structure from the inode.
- * Check permissions, then read the first 512 bytes
+ * Check permissions, then read the first 128 bytes
*/
int prepare_binprm(struct linux_binprm *bprm)
{
--- /dev/null
+/* $Id: display7seg.h,v 1.1.2.1 2000/07/27 01:50:59 davem Exp $
+ *
+ * display7seg - Driver interface for the 7-segment display
+ * present on Sun Microsystems CP1400 and CP1500
+ *
+ * Copyright (c) 2000 Eric Brower <ebrower@usa.net>
+ *
+ */
+
+#ifndef __display7seg_h__
+#define __display7seg_h__
+
+#define D7S_IOC 'p'
+
+#define D7SIOCRD _IOR(D7S_IOC, 0x45, int) /* Read device state */
+#define D7SIOCWR _IOW(D7S_IOC, 0x46, int) /* Write device state */
+#define D7SIOCTM _IO (D7S_IOC, 0x47) /* Translate mode (FLIP)*/
+
+/*
+ * ioctl flag definitions
+ *
+ * POINT - Toggle decimal point (0=absent 1=present)
+ * ALARM - Toggle alarm LED (0=green 1=red)
+ * FLIP - Toggle inverted mode (0=normal 1=flipped)
+ * bits 0-4 - Character displayed (see definitions below)
+ *
+ * Display segments are defined as follows,
+ * subject to D7S_FLIP register state:
+ *
+ * a
+ * ---
+ * f| |b
+ * -g-
+ * e| |c
+ * ---
+ * d
+ */
+
+#define D7S_POINT (1 << 7) /* Decimal point*/
+#define D7S_ALARM (1 << 6) /* Alarm LED */
+#define D7S_FLIP (1 << 5) /* Flip display */
+
+#define D7S_0 0x00 /* Numerals 0-9 */
+#define D7S_1 0x01
+#define D7S_2 0x02
+#define D7S_3 0x03
+#define D7S_4 0x04
+#define D7S_5 0x05
+#define D7S_6 0x06
+#define D7S_7 0x07
+#define D7S_8 0x08
+#define D7S_9 0x09
+#define D7S_A 0x0A /* Letters A-F, H, L, P */
+#define D7S_B 0x0B
+#define D7S_C 0x0C
+#define D7S_D 0x0D
+#define D7S_E 0x0E
+#define D7S_F 0x0F
+#define D7S_H 0x10
+#define D7S_E2 0x11
+#define D7S_L 0x12
+#define D7S_P 0x13
+#define D7S_SEGA 0x14 /* Individual segments */
+#define D7S_SEGB 0x15
+#define D7S_SEGC 0x16
+#define D7S_SEGD 0x17
+#define D7S_SEGE 0x18
+#define D7S_SEGF 0x19
+#define D7S_SEGG 0x1A
+#define D7S_SEGABFG 0x1B /* Segment groupings */
+#define D7S_SEGCDEG 0x1C
+#define D7S_SEGBCEF 0x1D
+#define D7S_SEGADG 0x1E
+#define D7S_BLANK 0x1F /* Clear all segments */
+
+#define D7S_MIN_VAL 0x0
+#define D7S_MAX_VAL 0x1F
+
+#endif /* ifndef __display7seg_h__ */
-/* $Id: pbm.h,v 1.16 1999/03/14 18:13:03 davem Exp $
+/* $Id: pbm.h,v 1.16.2.1 2000/06/14 07:41:19 davem Exp $
* pbm.h: U2P PCI bus module pseudo driver software state.
*
* Copyright (C) 1997 David S. Miller (davem@caip.rutgers.edu)
#define FB_ACCEL_SUN_CGTHREE 24 /* Sun cgthree */
#define FB_ACCEL_SUN_TCX 25 /* Sun tcx */
#define FB_ACCEL_MATROX_MGAG400 26 /* Matrox G400 */
+#define FB_ACCEL_ATI_RAGE128 32 /* ATI Rage 128 */
struct fb_fix_screeninfo {
char id[16]; /* identification string eg "TT Builtin" */
#define PCI_DEVICE_ID_ATI_215LG 0x4c47
#define PCI_DEVICE_ID_ATI_264LT 0x4c54
#define PCI_DEVICE_ID_ATI_264VT 0x5654
+#define PCI_DEVICE_ID_ATI_RAGE128_RE 0x5245
+#define PCI_DEVICE_ID_ATI_RAGE128_RF 0x5246
+#define PCI_DEVICE_ID_ATI_RAGE128_RK 0x524b
+#define PCI_DEVICE_ID_ATI_RAGE128_RL 0x524c
+#define PCI_DEVICE_ID_ATI_RAGE128_PF 0x5046
+#define PCI_DEVICE_ID_ATI_RAGE128_PR 0x5052
+#define PCI_DEVICE_ID_ATI_RAGE128_LE 0x4c45
+#define PCI_DEVICE_ID_ATI_RAGE128_LF 0x4c46
#define PCI_VENDOR_ID_VLSI 0x1004
#define PCI_DEVICE_ID_VLSI_82C592 0x0005
break;
case BRCMD_IF_ENABLE:
bcf.arg1 = br_find_port(bcf.arg1);
- if (bcf.arg1 < 0)
+ if ((signed)bcf.arg1 < 0)
return(bcf.arg1);
case BRCMD_PORT_ENABLE:
if (port_info[bcf.arg1].dev == 0)
break;
case BRCMD_IF_DISABLE:
bcf.arg1 = br_find_port(bcf.arg1);
- if (bcf.arg1 < 0)
+ if ((signed)bcf.arg1 < 0)
return(bcf.arg1);
case BRCMD_PORT_DISABLE:
if (port_info[bcf.arg1].dev == 0)
break;
case BRCMD_SET_IF_PRIORITY:
bcf.arg1 = br_find_port(bcf.arg1);
- if (bcf.arg1 < 0)
+ if ((signed)bcf.arg1 < 0)
return(bcf.arg1);
case BRCMD_SET_PORT_PRIORITY:
if((port_info[bcf.arg1].dev == 0)
break;
case BRCMD_SET_IF_PATH_COST:
bcf.arg1 = br_find_port(bcf.arg1);
- if (bcf.arg1 < 0)
+ if ((signed)bcf.arg1 < 0)
return(bcf.arg1);
case BRCMD_SET_PATH_COST:
if (port_info[bcf.arg1].dev == 0)