Commit 55748633 authored by Richard Russon's avatar Richard Russon

Merge flatcap.org:/home/flatcap/backup/bk/linux-2.6

into flatcap.org:/home/flatcap/backup/bk/ntfs-2.6-devel
parents ecd731d4 088b4154
...@@ -1843,6 +1843,37 @@ void dump_stack(void) ...@@ -1843,6 +1843,37 @@ void dump_stack(void)
EXPORT_SYMBOL(dump_stack); EXPORT_SYMBOL(dump_stack);
static inline int is_kernel_stack(struct task_struct *task,
struct reg_window *rw)
{
unsigned long rw_addr = (unsigned long) rw;
unsigned long thread_base, thread_end;
if (rw_addr < PAGE_OFFSET) {
if (task != &init_task)
return 0;
}
thread_base = (unsigned long) task->thread_info;
thread_end = thread_base + sizeof(union thread_union);
if (rw_addr >= thread_base &&
rw_addr < thread_end &&
!(rw_addr & 0x7UL))
return 1;
return 0;
}
static inline struct reg_window *kernel_stack_up(struct reg_window *rw)
{
unsigned long fp = rw->ins[6];
if (!fp)
return NULL;
return (struct reg_window *) (fp + STACK_BIAS);
}
void die_if_kernel(char *str, struct pt_regs *regs) void die_if_kernel(char *str, struct pt_regs *regs)
{ {
static int die_counter; static int die_counter;
...@@ -1869,16 +1900,13 @@ void die_if_kernel(char *str, struct pt_regs *regs) ...@@ -1869,16 +1900,13 @@ void die_if_kernel(char *str, struct pt_regs *regs)
* find some badly aligned kernel stack. * find some badly aligned kernel stack.
*/ */
while (rw && while (rw &&
count++ < 30 && count++ < 30&&
(((unsigned long) rw) >= PAGE_OFFSET) && is_kernel_stack(current, rw)) {
(char *) rw < ((char *) current)
+ sizeof (union thread_union) &&
!(((unsigned long) rw) & 0x7)) {
printk("Caller[%016lx]", rw->ins[7]); printk("Caller[%016lx]", rw->ins[7]);
print_symbol(": %s", rw->ins[7]); print_symbol(": %s", rw->ins[7]);
printk("\n"); printk("\n");
rw = (struct reg_window *)
(rw->ins[6] + STACK_BIAS); rw = kernel_stack_up(rw);
} }
instruction_dump ((unsigned int *) regs->tpc); instruction_dump ((unsigned int *) regs->tpc);
} else { } else {
......
...@@ -209,7 +209,7 @@ int DRM(sg_free)( struct inode *inode, struct file *filp, ...@@ -209,7 +209,7 @@ int DRM(sg_free)( struct inode *inode, struct file *filp,
drm_scatter_gather_t request; drm_scatter_gather_t request;
drm_sg_mem_t *entry; drm_sg_mem_t *entry;
if (drm_core_check_feature(dev, DRIVER_SG)) if (!drm_core_check_feature(dev, DRIVER_SG))
return -EINVAL; return -EINVAL;
if ( copy_from_user( &request, if ( copy_from_user( &request,
......
...@@ -132,7 +132,7 @@ struct eth1394_node_info { ...@@ -132,7 +132,7 @@ struct eth1394_node_info {
}; };
/* Our ieee1394 highlevel driver */ /* Our ieee1394 highlevel driver */
#define ETH1394_DRIVER_NAME "ip1394" #define ETH1394_DRIVER_NAME "eth1394"
static const char driver_name[] = ETH1394_DRIVER_NAME; static const char driver_name[] = ETH1394_DRIVER_NAME;
static kmem_cache_t *packet_task_cache; static kmem_cache_t *packet_task_cache;
......
...@@ -200,7 +200,7 @@ source "drivers/net/arm/Kconfig" ...@@ -200,7 +200,7 @@ source "drivers/net/arm/Kconfig"
config MACE config MACE
tristate "MACE (Power Mac ethernet) support" tristate "MACE (Power Mac ethernet) support"
depends on NET_ETHERNET && PPC32 && PPC_PMAC depends on NET_ETHERNET && PPC_PMAC && PPC32
select CRC32 select CRC32
help help
Power Macintoshes and clones with Ethernet built-in on the Power Macintoshes and clones with Ethernet built-in on the
...@@ -223,7 +223,7 @@ config MACE_AAUI_PORT ...@@ -223,7 +223,7 @@ config MACE_AAUI_PORT
config BMAC config BMAC
tristate "BMAC (G3 ethernet) support" tristate "BMAC (G3 ethernet) support"
depends on NET_ETHERNET && PPC32 && PPC_PMAC depends on NET_ETHERNET && PPC_PMAC && PPC32
select CRC32 select CRC32
help help
Say Y for support of BMAC Ethernet interfaces. These are used on G3 Say Y for support of BMAC Ethernet interfaces. These are used on G3
......
...@@ -156,6 +156,7 @@ static struct pci_device_id rtl8169_pci_tbl[] = { ...@@ -156,6 +156,7 @@ static struct pci_device_id rtl8169_pci_tbl[] = {
MODULE_DEVICE_TABLE(pci, rtl8169_pci_tbl); MODULE_DEVICE_TABLE(pci, rtl8169_pci_tbl);
static int rx_copybreak = 200; static int rx_copybreak = 200;
static int use_dac;
enum RTL8169_registers { enum RTL8169_registers {
MAC0 = 0, /* Ethernet hardware address. */ MAC0 = 0, /* Ethernet hardware address. */
...@@ -358,6 +359,8 @@ MODULE_AUTHOR("Realtek"); ...@@ -358,6 +359,8 @@ MODULE_AUTHOR("Realtek");
MODULE_DESCRIPTION("RealTek RTL-8169 Gigabit Ethernet driver"); MODULE_DESCRIPTION("RealTek RTL-8169 Gigabit Ethernet driver");
MODULE_PARM(media, "1-" __MODULE_STRING(MAX_UNITS) "i"); MODULE_PARM(media, "1-" __MODULE_STRING(MAX_UNITS) "i");
MODULE_PARM(rx_copybreak, "i"); MODULE_PARM(rx_copybreak, "i");
MODULE_PARM(use_dac, "i");
MODULE_PARM_DESC(use_dac, "Enable PCI DAC. Unsafe on 32 bit PCI slot.");
MODULE_LICENSE("GPL"); MODULE_LICENSE("GPL");
static int rtl8169_open(struct net_device *dev); static int rtl8169_open(struct net_device *dev);
...@@ -375,7 +378,7 @@ static int rtl8169_poll(struct net_device *dev, int *budget); ...@@ -375,7 +378,7 @@ static int rtl8169_poll(struct net_device *dev, int *budget);
#endif #endif
static const u16 rtl8169_intr_mask = static const u16 rtl8169_intr_mask =
LinkChg | RxOverflow | RxFIFOOver | TxErr | TxOK | RxErr | RxOK; SYSErr | LinkChg | RxOverflow | RxFIFOOver | TxErr | TxOK | RxErr | RxOK;
static const u16 rtl8169_napi_event = static const u16 rtl8169_napi_event =
RxOK | RxOverflow | RxFIFOOver | TxOK | TxErr; RxOK | RxOverflow | RxFIFOOver | TxOK | TxErr;
static const unsigned int rtl8169_rx_config = static const unsigned int rtl8169_rx_config =
...@@ -984,7 +987,7 @@ rtl8169_init_board(struct pci_dev *pdev, struct net_device **dev_out, ...@@ -984,7 +987,7 @@ rtl8169_init_board(struct pci_dev *pdev, struct net_device **dev_out,
tp->cp_cmd = PCIMulRW | RxChkSum; tp->cp_cmd = PCIMulRW | RxChkSum;
if ((sizeof(dma_addr_t) > 4) && if ((sizeof(dma_addr_t) > 4) &&
!pci_set_dma_mask(pdev, DMA_64BIT_MASK)) !pci_set_dma_mask(pdev, DMA_64BIT_MASK) && use_dac)
tp->cp_cmd |= PCIDAC; tp->cp_cmd |= PCIDAC;
else { else {
rc = pci_set_dma_mask(pdev, DMA_32BIT_MASK); rc = pci_set_dma_mask(pdev, DMA_32BIT_MASK);
...@@ -1761,6 +1764,15 @@ rtl8169_interrupt(int irq, void *dev_instance, struct pt_regs *regs) ...@@ -1761,6 +1764,15 @@ rtl8169_interrupt(int irq, void *dev_instance, struct pt_regs *regs)
if (!(status & rtl8169_intr_mask)) if (!(status & rtl8169_intr_mask))
break; break;
if (unlikely(status & SYSErr)) {
printk(KERN_ERR PFX "%s: PCI error (status: 0x%04x)."
" Device disabled.\n", dev->name, status);
RTL_W8(ChipCmd, 0x00);
RTL_W16(IntrMask, 0x0000);
RTL_R16(IntrMask);
break;
}
if (status & LinkChg) if (status & LinkChg)
rtl8169_check_link_status(dev, tp, ioaddr); rtl8169_check_link_status(dev, tp, ioaddr);
......
This diff is collapsed.
...@@ -1309,7 +1309,7 @@ static int __init sunsu_kbd_ms_init(struct uart_sunsu_port *up, int channel) ...@@ -1309,7 +1309,7 @@ static int __init sunsu_kbd_ms_init(struct uart_sunsu_port *up, int channel)
#ifdef CONFIG_SERIO #ifdef CONFIG_SERIO
up->serio = serio = kmalloc(sizeof(struct serio), GFP_KERNEL); up->serio = serio = kmalloc(sizeof(struct serio), GFP_KERNEL);
if (serio) { if (serio) {
memset(serio, 0, sizeof(serio)); memset(serio, 0, sizeof(*serio));
serio->port_data = up; serio->port_data = up;
......
...@@ -1556,8 +1556,7 @@ static void __init sunzilog_register_serio(struct uart_sunzilog_port *up, int ch ...@@ -1556,8 +1556,7 @@ static void __init sunzilog_register_serio(struct uart_sunzilog_port *up, int ch
up->serio = serio = kmalloc(sizeof(struct serio), GFP_KERNEL); up->serio = serio = kmalloc(sizeof(struct serio), GFP_KERNEL);
if (serio) { if (serio) {
memset(serio, 0, sizeof(*serio));
memset(serio, 0, sizeof(serio));
serio->port_data = up; serio->port_data = up;
......
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