Commit 07b08a16 authored by 's avatar Committed by Jeff Garzik

Automatic merge of...

Automatic merge of rsync://rsync.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git branch HEAD
parents 462cee29 254feb88
......@@ -1163,7 +1163,7 @@ config PCI_DIRECT
config PCI_MMCONFIG
bool
depends on PCI && (PCI_GOMMCONFIG || (PCI_GOANY && ACPI))
depends on PCI && ACPI && (PCI_GOMMCONFIG || PCI_GOANY)
select ACPI_BOOT
default y
......
......@@ -1029,7 +1029,6 @@ void pcibios_penalize_isa_irq(int irq)
static int pirq_enable_irq(struct pci_dev *dev)
{
u8 pin;
extern int via_interrupt_line_quirk;
struct pci_dev *temp_dev;
pci_read_config_byte(dev, PCI_INTERRUPT_PIN, &pin);
......@@ -1084,10 +1083,6 @@ static int pirq_enable_irq(struct pci_dev *dev)
printk(KERN_WARNING "PCI: No IRQ known for interrupt pin %c of device %s.%s\n",
'A' + pin, pci_name(dev), msg);
}
/* VIA bridges use interrupt line for apic/pci steering across
the V-Link */
else if (via_interrupt_line_quirk)
pci_write_config_byte(dev, PCI_INTERRUPT_LINE, dev->irq & 15);
return 0;
}
......
......@@ -421,7 +421,7 @@ config PCI_DIRECT
config PCI_MMCONFIG
bool "Support mmconfig PCI config space access"
depends on PCI
depends on PCI && ACPI
select ACPI_BOOT
config UNORDERED_IO
......
......@@ -40,13 +40,12 @@ config ACPI
available at:
<http://www.acpi.info>
if ACPI
config ACPI_BOOT
bool
depends on ACPI || X86_HT
default y
if ACPI
config ACPI_INTERPRETER
bool
depends on !IA64_SGI_SN
......
......@@ -391,7 +391,6 @@ acpi_pci_irq_enable (
u8 pin = 0;
int edge_level = ACPI_LEVEL_SENSITIVE;
int active_high_low = ACPI_ACTIVE_LOW;
extern int via_interrupt_line_quirk;
char *link = NULL;
ACPI_FUNCTION_TRACE("acpi_pci_irq_enable");
......@@ -444,9 +443,6 @@ acpi_pci_irq_enable (
}
}
if (via_interrupt_line_quirk)
pci_write_config_byte(dev, PCI_INTERRUPT_LINE, irq & 15);
dev->irq = acpi_register_gsi(irq, edge_level, active_high_low);
printk(KERN_INFO PREFIX "PCI Interrupt %s[%c] -> ",
......
......@@ -1932,8 +1932,11 @@ static ide_startstop_t cdrom_do_block_pc(ide_drive_t *drive, struct request *rq)
/*
* check if dma is safe
*
* NOTE! The "len" and "addr" checks should possibly have
* separate masks.
*/
if ((rq->data_len & 3) || (addr & mask))
if ((rq->data_len & mask) || (addr & mask))
info->dma = 0;
}
......
......@@ -18,6 +18,7 @@
#include <linux/pci.h>
#include <linux/init.h>
#include <linux/delay.h>
#include <linux/acpi.h>
#include "pci.h"
/* Deal with broken BIOS'es that neglect to enable passive release,
......@@ -467,9 +468,6 @@ DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_AMD, PCI_DEVICE_ID_AMD_8131_APIC,
* non-x86 architectures (yes Via exists on PPC among other places),
* we must mask the PCI_INTERRUPT_LINE value versus 0xf to get
* interrupts delivered properly.
*
* TODO: When we have device-specific interrupt routers,
* quirk_via_irqpic will go away from quirks.
*/
/*
......@@ -494,6 +492,29 @@ static void __devinit quirk_via_acpi(struct pci_dev *d)
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C586_3, quirk_via_acpi );
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C686_4, quirk_via_acpi );
static void quirk_via_irqpic(struct pci_dev *dev)
{
u8 irq, new_irq;
#ifdef CONFIG_X86_IO_APIC
if (nr_ioapics && !skip_ioapic_setup)
return;
#endif
#ifdef CONFIG_ACPI
if (acpi_irq_model != ACPI_IRQ_MODEL_PIC)
return;
#endif
new_irq = dev->irq & 0xf;
pci_read_config_byte(dev, PCI_INTERRUPT_LINE, &irq);
if (new_irq != irq) {
printk(KERN_INFO "PCI: Via PIC IRQ fixup for %s, from %d to %d\n",
pci_name(dev), irq, new_irq);
udelay(15); /* unknown if delay really needed */
pci_write_config_byte(dev, PCI_INTERRUPT_LINE, new_irq);
}
}
DECLARE_PCI_FIXUP_ENABLE(PCI_VENDOR_ID_VIA, PCI_ANY_ID, quirk_via_irqpic);
/*
* PIIX3 USB: We have to disable USB interrupts that are
* hardwired to PIRQD# and may be shared with an
......@@ -683,19 +704,6 @@ static void __init quirk_disable_pxb(struct pci_dev *pdev)
}
DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_82454NX, quirk_disable_pxb );
/*
* VIA northbridges care about PCI_INTERRUPT_LINE
*/
int via_interrupt_line_quirk;
static void __devinit quirk_via_bridge(struct pci_dev *pdev)
{
if(pdev->devfn == 0) {
printk(KERN_INFO "PCI: Via IRQ fixup\n");
via_interrupt_line_quirk = 1;
}
}
DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_ANY_ID, quirk_via_bridge );
/*
* Serverworks CSB5 IDE does not fully support native mode
......
ifneq ($(KERNELRELEASE),)
pwc-objs := pwc-if.o pwc-misc.o pwc-ctrl.o pwc-uncompress.o pwc-dec1.o pwc-dec23.o pwc-kiara.o pwc-timon.o
pwc-objs := pwc-if.o pwc-misc.o pwc-ctrl.o pwc-uncompress.o pwc-timon.o pwc-kiara.o
obj-$(CONFIG_USB_PWC) += pwc.o
......
......@@ -246,7 +246,7 @@ static inline int set_video_mode_Nala(struct pwc_device *pdev, int size, int fra
switch(pdev->type) {
case 645:
case 646:
pwc_dec1_init(pdev->type, pdev->release, buf, pdev->decompress_data);
/* pwc_dec1_init(pdev->type, pdev->release, buf, pdev->decompress_data); */
break;
case 675:
......@@ -256,7 +256,7 @@ static inline int set_video_mode_Nala(struct pwc_device *pdev, int size, int fra
case 730:
case 740:
case 750:
pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data);
/* pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data); */
break;
}
}
......@@ -318,8 +318,8 @@ static inline int set_video_mode_Timon(struct pwc_device *pdev, int size, int fr
if (ret < 0)
return ret;
if (pChoose->bandlength > 0 && pdev->vpalette != VIDEO_PALETTE_RAW)
pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data);
/* if (pChoose->bandlength > 0 && pdev->vpalette != VIDEO_PALETTE_RAW)
pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data); */
pdev->cmd_len = 13;
memcpy(pdev->cmd_buf, buf, 13);
......@@ -397,8 +397,8 @@ static inline int set_video_mode_Kiara(struct pwc_device *pdev, int size, int fr
if (ret < 0)
return ret;
if (pChoose->bandlength > 0 && pdev->vpalette != VIDEO_PALETTE_RAW)
pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data);
/* if (pChoose->bandlength > 0 && pdev->vpalette != VIDEO_PALETTE_RAW)
pwc_dec23_init(pdev->type, pdev->release, buf, pdev->decompress_data); */
pdev->cmd_len = 12;
memcpy(pdev->cmd_buf, buf, 12);
......
/* Linux driver for Philips webcam
Decompression for chipset version 1
(C) 2004 Luc Saillard (luc@saillard.org)
NOTE: this version of pwc is an unofficial (modified) release of pwc & pcwx
driver and thus may have bugs that are not present in the original version.
Please send bug reports and support requests to <luc@saillard.org>.
The decompression routines have been implemented by reverse-engineering the
Nemosoft binary pwcx module. Caveat emptor.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#include "pwc-dec1.h"
void pwc_dec1_init(int type, int release, void *buffer, void *table)
{
}
void pwc_dec1_exit(void)
{
}
/* Linux driver for Philips webcam
(C) 2004 Luc Saillard (luc@saillard.org)
NOTE: this version of pwc is an unofficial (modified) release of pwc & pcwx
driver and thus may have bugs that are not present in the original version.
Please send bug reports and support requests to <luc@saillard.org>.
The decompression routines have been implemented by reverse-engineering the
Nemosoft binary pwcx module. Caveat emptor.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef PWC_DEC1_H
#define PWC_DEC1_H
void pwc_dec1_init(int type, int release, void *buffer, void *private_data);
void pwc_dec1_exit(void);
#endif
This diff is collapsed.
/* Linux driver for Philips webcam
(C) 2004 Luc Saillard (luc@saillard.org)
NOTE: this version of pwc is an unofficial (modified) release of pwc & pcwx
driver and thus may have bugs that are not present in the original version.
Please send bug reports and support requests to <luc@saillard.org>.
The decompression routines have been implemented by reverse-engineering the
Nemosoft binary pwcx module. Caveat emptor.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*/
#ifndef PWC_DEC23_H
#define PWC_DEC23_H
struct pwc_dec23_private
{
unsigned char xx,yy,zz,zzmask;
unsigned char table_0004[2*0x4000];
unsigned char table_8004[2*0x1000];
unsigned int table_a004[256*12];
unsigned char table_d004[8*256];
unsigned int table_d800[256];
unsigned int table_dc00[256];
};
void pwc_dec23_init(int type, int release, unsigned char *buffer, void *private_data);
void pwc_dec23_exit(void);
void pwc_dec23_decompress(const struct pwc_coord *image,
const struct pwc_coord *view,
const struct pwc_coord *offset,
const void *src,
void *dst,
int flags,
const void *data,
int bandlength);
#endif
......@@ -68,8 +68,6 @@
#include "pwc-ioctl.h"
#include "pwc-kiara.h"
#include "pwc-timon.h"
#include "pwc-dec23.h"
#include "pwc-dec1.h"
#include "pwc-uncompress.h"
/* Function prototypes and driver templates */
......@@ -322,6 +320,7 @@ static int pwc_allocate_buffers(struct pwc_device *pdev)
case 730:
case 740:
case 750:
#if 0
Trace(TRACE_MEMORY,"private_data(%zu)\n",sizeof(struct pwc_dec23_private));
kbuf = kmalloc(sizeof(struct pwc_dec23_private), GFP_KERNEL); /* Timon & Kiara */
break;
......@@ -330,6 +329,8 @@ static int pwc_allocate_buffers(struct pwc_device *pdev)
/* TODO & FIXME */
kbuf = kmalloc(sizeof(struct pwc_dec23_private), GFP_KERNEL);
break;
#endif
;
}
if (kbuf == NULL) {
Err("Failed to allocate decompress table.\n");
......@@ -1131,11 +1132,11 @@ static int pwc_video_close(struct inode *inode, struct file *file)
case 730:
case 740:
case 750:
pwc_dec23_exit(); /* Timon & Kiara */
/* pwc_dec23_exit(); *//* Timon & Kiara */
break;
case 645:
case 646:
pwc_dec1_exit();
/* pwc_dec1_exit(); */
break;
}
......
This diff is collapsed.
This diff is collapsed.
......@@ -122,6 +122,7 @@ int pwc_decompress(struct pwc_device *pdev)
switch (pdev->type)
{
#if 0
case 675:
case 680:
case 690:
......@@ -137,6 +138,7 @@ int pwc_decompress(struct pwc_device *pdev)
case 645:
case 646:
/* TODO & FIXME */
#endif
return -ENXIO; /* No such device or address: missing decompressor */
break;
}
......
......@@ -886,7 +886,6 @@ xfs_page_state_convert(
SetPageUptodate(page);
if (startio) {
WARN_ON(page_dirty);
xfs_submit_page(page, wbc, bh_arr, cnt, 0, !page_dirty);
}
......
......@@ -565,7 +565,7 @@ struct file_operations linvfs_file_operations = {
.sendfile = linvfs_sendfile,
.unlocked_ioctl = linvfs_ioctl,
#ifdef CONFIG_COMPAT
.compat_ioctl = xfs_compat_ioctl,
.compat_ioctl = linvfs_compat_ioctl,
#endif
.mmap = linvfs_file_mmap,
.open = linvfs_open,
......@@ -587,7 +587,7 @@ struct file_operations linvfs_invis_file_operations = {
.sendfile = linvfs_sendfile,
.unlocked_ioctl = linvfs_ioctl_invis,
#ifdef CONFIG_COMPAT
.compat_ioctl = xfs_compat_invis_ioctl,
.compat_ioctl = linvfs_compat_invis_ioctl,
#endif
.mmap = linvfs_file_mmap,
.open = linvfs_open,
......@@ -600,6 +600,9 @@ struct file_operations linvfs_dir_operations = {
.read = generic_read_dir,
.readdir = linvfs_readdir,
.unlocked_ioctl = linvfs_ioctl,
#ifdef CONFIG_COMPAT
.compat_ioctl = linvfs_compat_ioctl,
#endif
.fsync = linvfs_fsync,
};
......
/*
* Copyright (c) 2004 Silicon Graphics, Inc. All Rights Reserved.
* Copyright (c) 2004-2005 Silicon Graphics, Inc. All Rights Reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of version 2 of the GNU General Public License as
......@@ -58,8 +58,9 @@ typedef struct xfs_fsop_bulkreq32 {
__s32 ocount; /* output count pointer */
} xfs_fsop_bulkreq32_t;
static unsigned long
xfs_ioctl32_bulkstat(unsigned long arg)
STATIC unsigned long
xfs_ioctl32_bulkstat(
unsigned long arg)
{
xfs_fsop_bulkreq32_t __user *p32 = (void __user *)arg;
xfs_fsop_bulkreq_t __user *p = compat_alloc_user_space(sizeof(*p));
......@@ -78,11 +79,11 @@ xfs_ioctl32_bulkstat(unsigned long arg)
}
#endif
static long
__xfs_compat_ioctl(int mode, struct file *f, unsigned cmd, unsigned long arg)
STATIC long
__linvfs_compat_ioctl(int mode, struct file *f, unsigned cmd, unsigned long arg)
{
int error;
struct inode *inode = f->f_dentry->d_inode;
struct inode *inode = f->f_dentry->d_inode;
vnode_t *vp = LINVFS_GET_VP(inode);
switch (cmd) {
......@@ -152,12 +153,20 @@ __xfs_compat_ioctl(int mode, struct file *f, unsigned cmd, unsigned long arg)
return error;
}
long xfs_compat_ioctl(struct file *f, unsigned cmd, unsigned long arg)
long
linvfs_compat_ioctl(
struct file *f,
unsigned cmd,
unsigned long arg)
{
return __xfs_compat_ioctl(0, f, cmd, arg);
return __linvfs_compat_ioctl(0, f, cmd, arg);
}
long xfs_compat_invis_ioctl(struct file *f, unsigned cmd, unsigned long arg)
long
linvfs_compat_invis_ioctl(
struct file *f,
unsigned cmd,
unsigned long arg)
{
return __xfs_compat_ioctl(IO_INVIS, f, cmd, arg);
return __linvfs_compat_ioctl(IO_INVIS, f, cmd, arg);
}
/*
* Copyright (c) 2004 Silicon Graphics, Inc. All Rights Reserved.
* Copyright (c) 2004-2005 Silicon Graphics, Inc. All Rights Reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of version 2 of the GNU General Public License as
......@@ -30,5 +30,5 @@
* http://oss.sgi.com/projects/GenInfo/SGIGPLNoticeExplan/
*/
long xfs_compat_ioctl(struct file *f, unsigned cmd, unsigned long arg);
long xfs_compat_invis_ioctl(struct file *f, unsigned cmd, unsigned long arg);
long linvfs_compat_ioctl(struct file *f, unsigned cmd, unsigned long arg);
long linvfs_compat_invis_ioctl(struct file *f, unsigned cmd, unsigned long arg);
/*
* Copyright (c) 2000-2004 Silicon Graphics, Inc. All Rights Reserved.
* Copyright (c) 2000-2005 Silicon Graphics, Inc. All Rights Reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms of version 2 of the GNU General Public License as
......@@ -66,7 +66,6 @@
#include "xfs_buf_item.h"
#include "xfs_utils.h"
#include "xfs_version.h"
#include "xfs_ioctl32.h"
#include <linux/namei.h>
#include <linux/init.h>
......
......@@ -278,7 +278,9 @@ phase2:
switch (flags & (BMAPI_WRITE|BMAPI_ALLOCATE|BMAPI_UNWRITTEN)) {
case BMAPI_WRITE:
/* If we found an extent, return it */
if (nimaps && (imap.br_startblock != HOLESTARTBLOCK)) {
if (nimaps &&
(imap.br_startblock != HOLESTARTBLOCK) &&
(imap.br_startblock != DELAYSTARTBLOCK)) {
xfs_iomap_map_trace(XFS_IOMAP_WRITE_MAP, io,
offset, count, iomapp, &imap, flags);
break;
......
......@@ -5,9 +5,7 @@
#define FASTCALL(x) x __attribute__((regparm(3)))
#define fastcall __attribute__((regparm(3)))
#ifdef CONFIG_REGPARM
# define prevent_tail_call(ret) __asm__ ("" : "=r" (ret) : "0" (ret))
#endif
#define prevent_tail_call(ret) __asm__ ("" : "=r" (ret) : "0" (ret))
#ifdef CONFIG_X86_ALIGNMENT_16
#define __ALIGN .align 16,0x90
......
......@@ -25,6 +25,8 @@
#ifndef _LINUX_ACPI_H
#define _LINUX_ACPI_H
#ifdef CONFIG_ACPI
#ifndef _LINUX
#define _LINUX
#endif
......@@ -533,4 +535,5 @@ static inline int acpi_get_pxm(acpi_handle handle)
extern int pnpacpi_disabled;
#endif /*_LINUX_ACPI_H*/
#endif /* CONFIG_ACPI */
#endif /*_LINUX_ACPI_H*/
......@@ -166,9 +166,8 @@ static struct super_block *cpuset_sb = NULL;
* The hooks from fork and exit, cpuset_fork() and cpuset_exit(), don't
* (usually) grab cpuset_sem. These are the two most performance
* critical pieces of code here. The exception occurs on exit(),
* if the last task using a cpuset exits, and the cpuset was marked
* notify_on_release. In that case, the cpuset_sem is taken, the
* path to the released cpuset calculated, and a usermode call made
* when a task in a notify_on_release cpuset exits. Then cpuset_sem
* is taken, and if the cpuset count is zero, a usermode call made
* to /sbin/cpuset_release_agent with the name of the cpuset (path
* relative to the root of cpuset file system) as the argument.
*
......@@ -1404,6 +1403,18 @@ void cpuset_fork(struct task_struct *tsk)
*
* Description: Detach cpuset from @tsk and release it.
*
* Note that cpusets marked notify_on_release force every task
* in them to take the global cpuset_sem semaphore when exiting.
* This could impact scaling on very large systems. Be reluctant
* to use notify_on_release cpusets where very high task exit
* scaling is required on large systems.
*
* Don't even think about derefencing 'cs' after the cpuset use
* count goes to zero, except inside a critical section guarded
* by the cpuset_sem semaphore. If you don't hold cpuset_sem,
* then a zero cpuset use count is a license to any other task to
* nuke the cpuset immediately.
*
**/
void cpuset_exit(struct task_struct *tsk)
......@@ -1415,10 +1426,13 @@ void cpuset_exit(struct task_struct *tsk)
tsk->cpuset = NULL;
task_unlock(tsk);
if (atomic_dec_and_test(&cs->count)) {
if (notify_on_release(cs)) {
down(&cpuset_sem);
check_for_release(cs);
if (atomic_dec_and_test(&cs->count))
check_for_release(cs);
up(&cpuset_sem);
} else {
atomic_dec(&cs->count);
}
}
......
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