Commit 908920b1 authored by Linus Torvalds's avatar Linus Torvalds

v2.5.1.9 -> v2.5.1.10

- Kai Germaschewski: ISDN updates
- Al Viro: start moving buffer cache indexing to "struct block_device *"
- Greg KH: USB update
- Russell King: fix up some ARM merge issues
- Ingo Molnar: scalable scheduler
parent d01b7e92
......@@ -527,6 +527,16 @@ S: 14509 NE 39th Street #1096
S: Bellevue, Washington 98007
S: USA
N: Christopher L. Cheney
E: ccheney@debian.org
E: ccheney@cheney.cx
W: http://www.cheney.cx
P: 1024D/8E384AF2 2D31 1927 87D7 1F24 9FF9 1BC5 D106 5AB3 8E38 4AF2
D: Vista Imaging usb webcam driver
S: 314 Prince of Wales
S: Conroe, TX 77304
S: USA
N: Stuart Cheshire
E: cheshire@cs.stanford.edu
D: Author of Starmode Radio IP (STRIP) driver
......@@ -1946,9 +1956,10 @@ S: 64289 Darmstadt
S: Germany
N: Mark W. McClelland
E: mwm@i.am
E: mmcclell@bigfoot.com
E: mark@alpha.dyndns.org
W: http://alpha.dyndns.org/ov511/
P: 1024D/357375CC 317C 58AC 1B39 2AB0 AB96 EB38 0B6F 731F 3573 75CC
D: OV511 driver
S: (address available on request)
S: USA
......@@ -2107,6 +2118,10 @@ S: 22 Seaview St
S: Fullarton 5063
S: South Australia
N. Wolfgang Muees
E: wmues@nexgo.de
D: Auerswald USB driver
N: Ian A. Murdock
E: imurdock@gnu.ai.mit.edu
D: Creator of Debian distribution
......
......@@ -13514,6 +13514,16 @@ CONFIG_USB_RIO500
The module will be called rio500.o. If you want to compile it as
a module, say M here and read <file:Documentation/modules.txt>.
USB Auerswald ISDN device support
CONFIG_USB_AUERSWALD
Say Y here if you want to connect an Auerswald USB ISDN Device
to your computer's USB port.
This code is also available as a module ( = code which can be
inserted in and removed from the running kernel whenever you want).
The module will be called auerswald.o. If you want to compile it as
a module, say M here and read <file:Documentation/modules.txt>.
D-Link DSB-R100 FM radio support
CONFIG_USB_DSBR
Say Y here if you want to connect this type of radio to your
......
Auerswald USB kernel driver
===========================
What is it? What can I do with it?
==================================
The auerswald USB kernel driver connects your linux 2.4.x
system to the auerswald usb-enabled devices.
There are two types of auerswald usb devices:
a) small PBX systems (ISDN)
b) COMfort system telephones (ISDN)
The driver installation creates the devices
/dev/usb/auer0..15. These devices carry a vendor-
specific protocol. You may run all auerswald java
software on it. The java software needs a native
library "libAuerUsbJNINative.so" installed on
your system. This library is available from
auerswald and shipped as part of the java software.
You may create the devices with:
mknod -m 666 /dev/usb/auer0 c 180 80
...
mknod -m 666 /dev/usb/auer15 c 180 95
Future plans
============
- Connection to ISDN4LINUX (the hisax interface)
The maintainer of this driver is wmues@nexgo.de
......@@ -1596,7 +1596,7 @@ S: Maintained
USB OV511 DRIVER
P: Mark McClelland
M: mwm@i.am
M: mmcclell@bigfoot.com
L: linux-usb-users@lists.sourceforge.net
L: linux-usb-devel@lists.sourceforge.net
W: http://alpha.dyndns.org/ov511/
......@@ -1654,6 +1654,13 @@ L: linux-usb-users@lists.sourceforge.net
L: linux-usb-devel@lists.sourceforge.net
S: Supported
USB AUERSWALD DRIVER
P: Wolfgang Muees
M: wmues@nexgo.de
L: linux-usb-users@lists.sourceforge.net
L: linux-usb-devel@lists.sourceforge.net
S: Maintained
USB SERIAL EMPEG EMPEG-CAR MARK I/II DRIVER
P: Gary Brubaker
M: xavyer@ix.netcom.com
......
VERSION = 2
PATCHLEVEL = 5
SUBLEVEL = 2
EXTRAVERSION =-pre9
EXTRAVERSION =-pre10
KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION)
......
File moved
File moved
/*
* linux/arch/arm/kernel/irq-arch.c
*
* Copyright (C) 1995-2000 Russell King.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*
* We contain the architecture-specific parts of interrupt handling
* in this file. In 2.5, it will move into the various arch/arm/mach-*
* directories.
*/
#include <linux/ptrace.h>
#include <linux/kernel_stat.h>
#include <linux/signal.h>
#include <linux/sched.h>
#include <linux/ioport.h>
#include <linux/interrupt.h>
#include <linux/slab.h>
#include <linux/random.h>
#include <linux/smp.h>
#include <linux/init.h>
#include <asm/hardware.h>
#include <asm/io.h>
#include <asm/system.h>
#include <asm/mach/irq.h>
/*
* Get architecture specific interrupt handlers
* and interrupt initialisation.
*/
#include <asm/arch/irq.h>
void __init genarch_init_irq(void)
{
irq_init_irq();
}
File moved
File moved
File moved
......@@ -1981,7 +1981,7 @@ static int etrax_rh_submit_urb(urb_t *urb)
struct usb_device *usb_dev = urb->dev;
etrax_hc_t *hc = usb_dev->bus->hcpriv;
unsigned int pipe = urb->pipe;
devrequest *cmd = (devrequest *) urb->setup_packet;
struct usb_ctrlrequest *cmd = (struct usb_ctrlrequest *) urb->setup_packet;
void *data = urb->transfer_buffer;
int leni = urb->transfer_buffer_length;
int len = 0;
......@@ -2009,10 +2009,10 @@ static int etrax_rh_submit_urb(urb_t *urb)
return 0;
}
bmRType_bReq = cmd->requesttype | cmd->request << 8;
wValue = le16_to_cpu(cmd->value);
wIndex = le16_to_cpu(cmd->index);
wLength = le16_to_cpu(cmd->length);
bmRType_bReq = cmd->bRequestType | cmd->bRequest << 8;
wValue = le16_to_cpu(cmd->wValue);
wIndex = le16_to_cpu(cmd->wIndex);
wLength = le16_to_cpu(cmd->wLength);
dbg_rh("bmRType_bReq : 0x%04X (%d)", bmRType_bReq, bmRType_bReq);
dbg_rh("wValue : 0x%04X (%d)", wValue, wValue);
......
......@@ -825,6 +825,7 @@ CONFIG_USB_STORAGE=y
# USB Miscellaneous drivers
#
# CONFIG_USB_RIO500 is not set
# CONFIG_USB_AUERSWALD is not set
#
# Kernel hacking
......
......@@ -792,8 +792,7 @@ void setup_APIC_timer(void * data)
*/
slice = clocks / (smp_num_cpus+1);
printk("cpu: %d, clocks: %d, slice: %d\n",
smp_processor_id(), clocks, slice);
printk("cpu: %d, clocks: %d, slice: %d\n", smp_processor_id(), clocks, slice);
/*
* Wait for IRQ0's slice:
......@@ -816,8 +815,7 @@ void setup_APIC_timer(void * data)
__setup_APIC_LVTT(clocks);
printk("CPU%d<T0:%d,T1:%d,D:%d,S:%d,C:%d>\n",
smp_processor_id(), t0, t1, delta, slice, clocks);
printk("CPU%d<T0:%d,T1:%d,D:%d,S:%d,C:%d>\n", smp_processor_id(), t0, t1, delta, slice, clocks);
__restore_flags(flags);
}
......
......@@ -283,7 +283,7 @@ void nmi_watchdog_tick (struct pt_regs * regs)
* to get a message out.
*/
bust_spinlocks(1);
printk("NMI Watchdog detected LOCKUP on CPU%d, registers:\n", cpu);
printk("NMI Watchdog detected LOCKUP on CPU%d, eip %08lx, registers:\n", cpu, regs->eip);
show_registers(regs);
printk("console shuts up ...\n");
console_silent();
......
......@@ -123,9 +123,6 @@ static void poll_idle (void)
void cpu_idle (void)
{
/* endless idle loop with no priority at all */
init_idle();
current->nice = 20;
while (1) {
void (*idle)(void) = pm_idle;
if (!idle)
......
......@@ -105,7 +105,7 @@
/* The 'big kernel lock' */
spinlock_t kernel_flag __cacheline_aligned_in_smp = SPIN_LOCK_UNLOCKED;
struct tlb_state cpu_tlbstate[NR_CPUS] = {[0 ... NR_CPUS-1] = { &init_mm, 0 }};
struct tlb_state cpu_tlbstate[NR_CPUS] __cacheline_aligned = {[0 ... NR_CPUS-1] = { &init_mm, 0, }};
/*
* the following functions deal with sending IPIs between CPUs.
......@@ -490,12 +490,22 @@ void flush_tlb_all(void)
* it goes straight through and wastes no time serializing
* anything. Worst case is that we lose a reschedule ...
*/
void smp_send_reschedule(int cpu)
{
send_IPI_mask(1 << cpu, RESCHEDULE_VECTOR);
}
/*
* this function sends a reschedule IPI to all (other) CPUs.
* This should only be used if some 'global' task became runnable,
* such as a RT task, that must be handled now. The first CPU
* that manages to grab the task will run it.
*/
void smp_send_reschedule_all(void)
{
send_IPI_allbutself(RESCHEDULE_VECTOR);
}
/*
* Structure and data for smp_call_function(). This is designed to minimise
* static memory requirements. It also looks cleaner.
......
......@@ -308,14 +308,14 @@ static void __init synchronize_tsc_bp (void)
if (tsc_values[i] < avg)
realdelta = -realdelta;
printk("BIOS BUG: CPU#%d improperly initialized, has %ld usecs TSC skew! FIXED.\n",
i, realdelta);
printk("BIOS BUG: CPU#%d improperly initialized, has %ld usecs TSC skew! FIXED.\n", i, realdelta);
}
sum += delta;
}
if (!buggy)
printk("passed.\n");
;
}
static void __init synchronize_tsc_ap (void)
......@@ -365,7 +365,7 @@ void __init smp_callin(void)
* (This works even if the APIC is not enabled.)
*/
phys_id = GET_APIC_ID(apic_read(APIC_ID));
cpuid = current->processor;
cpuid = smp_processor_id();
if (test_and_set_bit(cpuid, &cpu_online_map)) {
printk("huh, phys CPU#%d, CPU#%d already present??\n",
phys_id, cpuid);
......@@ -471,6 +471,7 @@ int __init start_secondary(void *unused)
*/
local_flush_tlb();
init_idle();
return cpu_idle();
}
......@@ -803,16 +804,13 @@ static void __init do_boot_cpu (int apicid)
if (!idle)
panic("No idle process for CPU %d", cpu);
idle->processor = cpu;
idle->cpus_runnable = 1 << cpu; /* we schedule the first task manually */
idle->cpu = cpu;
map_cpu_to_boot_apicid(cpu, apicid);
idle->thread.eip = (unsigned long) start_secondary;
del_from_runqueue(idle);
unhash_process(idle);
init_tasks[cpu] = idle;
/* start_eip had better be page-aligned! */
start_eip = setup_trampoline();
......@@ -1020,8 +1018,7 @@ void __init smp_boot_cpus(void)
map_cpu_to_boot_apicid(0, boot_cpu_apicid);
global_irq_holder = 0;
current->processor = 0;
init_idle();
current->cpu = 0;
smp_tune_scheduling();
/*
......
......@@ -88,8 +88,7 @@ int __verify_write(const void * addr, unsigned long size)
out_of_memory:
if (current->pid == 1) {
current->policy |= SCHED_YIELD;
schedule();
yield();
goto survive;
}
goto bad_area;
......@@ -344,8 +343,7 @@ asmlinkage void do_page_fault(struct pt_regs *regs, unsigned long error_code)
out_of_memory:
up_read(&mm->mmap_sem);
if (tsk->pid == 1) {
tsk->policy |= SCHED_YIELD;
schedule();
yield();
down_read(&mm->mmap_sem);
goto survive;
}
......
......@@ -517,7 +517,7 @@ static inline void loop_handle_bio(struct loop_device *lo, struct bio *bio)
ret = do_bio_blockbacked(lo, bio, rbh);
bio_endio(rbh, !ret, bio_sectors(bio));
bio_endio(rbh, !ret, bio_sectors(rbh));
loop_put_buffer(bio);
}
}
......@@ -543,8 +543,7 @@ static int loop_thread(void *data)
flush_signals(current);
spin_unlock_irq(&current->sigmask_lock);
current->policy = SCHED_OTHER;
current->nice = -20;
set_user_nice(current, -20);
spin_lock_irq(&lo->lo_lock);
lo->lo_state = Lo_bound;
......
......@@ -437,18 +437,18 @@ static void hci_usb_bulk_read(struct urb *urb)
static int hci_usb_ctrl_msg(struct hci_usb *husb, struct sk_buff *skb)
{
struct urb *urb = husb->ctrl_urb;
devrequest *dr = &husb->dev_req;
struct usb_ctrlrequest *dr = &husb->dev_req;
int pipe, status;
DBG("%s len %d", husb->hdev.name, skb->len);
pipe = usb_sndctrlpipe(husb->udev, 0);
dr->requesttype = HCI_CTRL_REQ;
dr->request = 0;
dr->index = 0;
dr->value = 0;
dr->length = cpu_to_le16(skb->len);
dr->bRequestType = HCI_CTRL_REQ;
dr->bRequest = 0;
dr->wIndex = 0;
dr->wValue = 0;
dr->wLength = cpu_to_le16(skb->len);
FILL_CONTROL_URB(urb, husb->udev, pipe, (void*)dr, skb->data, skb->len,
hci_usb_ctrl, skb);
......
......@@ -134,7 +134,7 @@ struct iforce {
#ifdef IFORCE_USB
struct usb_device *usbdev; /* USB transfer */
struct urb irq, out, ctrl;
devrequest dr;
struct usb_ctrlrequest dr;
#endif
/* Force Feedback */
wait_queue_head_t wait;
......@@ -283,7 +283,7 @@ static int get_id_packet(struct iforce *iforce, char *packet)
#ifdef IFORCE_USB
case IFORCE_USB:
iforce->dr.request = packet[0];
iforce->dr.bRequest = packet[0];
iforce->ctrl.dev = iforce->usbdev;
set_current_state(TASK_INTERRUPTIBLE);
......@@ -1027,9 +1027,9 @@ static void *iforce_usb_probe(struct usb_device *dev, unsigned int ifnum,
iforce->bus = IFORCE_USB;
iforce->usbdev = dev;
iforce->dr.requesttype = USB_TYPE_VENDOR | USB_DIR_IN | USB_RECIP_INTERFACE;
iforce->dr.index = 0;
iforce->dr.length = 16;
iforce->dr.bRequestType = USB_TYPE_VENDOR | USB_DIR_IN | USB_RECIP_INTERFACE;
iforce->dr.wIndex = 0;
iforce->dr.wLength = 16;
FILL_INT_URB(&iforce->irq, dev, usb_rcvintpipe(dev, epirq->bEndpointAddress),
iforce->data, 16, iforce_usb_irq, iforce, epirq->bInterval);
......
......@@ -279,7 +279,6 @@ static int mwave_ioctl(struct inode *inode, struct file *file,
pDrvData->IPCs[ipcnum].bIsHere = FALSE;
pDrvData->IPCs[ipcnum].bIsEnabled = TRUE;
#if LINUX_VERSION_CODE >= KERNEL_VERSION(2,4,0)
current->nice = -20; /* boost to provide priority timing */
#else
current->priority = 0x28; /* boost to provide priority timing */
#endif
......
......@@ -121,11 +121,8 @@ struct buffer_head *ataraid_get_bhead(void)
void *ptr = NULL;
while (!ptr) {
ptr=kmalloc(sizeof(struct buffer_head),GFP_NOIO);
if (!ptr) {
__set_current_state(TASK_RUNNING);
current->policy |= SCHED_YIELD;
schedule();
}
if (!ptr)
yield();
}
return ptr;
}
......@@ -137,11 +134,8 @@ struct ataraid_bh_private *ataraid_get_private(void)
void *ptr = NULL;
while (!ptr) {
ptr=kmalloc(sizeof(struct ataraid_bh_private),GFP_NOIO);
if (!ptr) {
__set_current_state(TASK_RUNNING);
current->policy |= SCHED_YIELD;
schedule();
}
if (!ptr)
yield();
}
return ptr;
}
......
......@@ -30,7 +30,7 @@ static char *revision = "$Revision: 1.1.4.1.2.1 $";
/* ------------------------------------------------------------- */
static struct pci_device_id b1pci_pci_tbl[] __initdata = {
static struct pci_device_id b1pci_pci_tbl[] __devinitdata = {
{ PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_B1, PCI_ANY_ID, PCI_ANY_ID },
{ } /* Terminating entry */
};
......@@ -404,7 +404,8 @@ static struct capi_driver b1pciv4_driver = {
static int ncards = 0;
static int add_card(struct pci_dev *dev)
static int __devinit b1pci_probe(struct pci_dev *dev,
const struct pci_device_id *ent)
{
struct capi_driver *driver = &b1pci_driver;
struct capicardparams param;
......@@ -456,13 +457,18 @@ static int add_card(struct pci_dev *dev)
return retval;
}
static struct pci_driver b1pci_pci_driver = {
name: "b1pci",
id_table: b1pci_pci_tbl,
probe: b1pci_probe,
};
static int __init b1pci_init(void)
{
struct capi_driver *driver = &b1pci_driver;
#ifdef CONFIG_ISDN_DRV_AVMB1_B1PCIV4
struct capi_driver *driverv4 = &b1pciv4_driver;
#endif
struct pci_dev *dev = NULL;
char *p;
MOD_INC_USE_COUNT;
......@@ -505,10 +511,7 @@ static int __init b1pci_init(void)
}
#endif
while ((dev = pci_find_device(PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_B1, dev))) {
if (add_card(dev) == 0)
ncards++;
}
ncards = pci_register_driver(&b1pci_pci_driver);
if (ncards) {
printk(KERN_INFO "%s: %d B1-PCI card(s) detected\n",
driver->name, ncards);
......@@ -516,6 +519,7 @@ static int __init b1pci_init(void)
return 0;
}
printk(KERN_ERR "%s: NO B1-PCI card detected\n", driver->name);
pci_unregister_driver(&b1pci_pci_driver);
detach_capi_driver(driver);
#ifdef CONFIG_ISDN_DRV_AVMB1_B1PCIV4
detach_capi_driver(driverv4);
......@@ -526,9 +530,10 @@ static int __init b1pci_init(void)
static void __exit b1pci_exit(void)
{
detach_capi_driver(&b1pci_driver);
pci_unregister_driver(&b1pci_pci_driver);
detach_capi_driver(&b1pci_driver);
#ifdef CONFIG_ISDN_DRV_AVMB1_B1PCIV4
detach_capi_driver(&b1pciv4_driver);
detach_capi_driver(&b1pciv4_driver);
#endif
}
......
......@@ -38,9 +38,9 @@ static char *revision = "$Revision: 1.1.4.1.2.1 $";
static int suppress_pollack;
static struct pci_device_id c4_pci_tbl[] __initdata = {
{ PCI_VENDOR_ID_DEC,PCI_DEVICE_ID_DEC_21285, PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_C4 },
{ PCI_VENDOR_ID_DEC,PCI_DEVICE_ID_DEC_21285, PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_C2 },
static struct pci_device_id c4_pci_tbl[] __devinitdata = {
{ PCI_VENDOR_ID_DEC, PCI_DEVICE_ID_DEC_21285, PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_C4, 4 },
{ PCI_VENDOR_ID_DEC, PCI_DEVICE_ID_DEC_21285, PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_C2, 2 },
{ } /* Terminating entry */
};
......@@ -1284,8 +1284,6 @@ static struct capi_driver c4_driver = {
add_card: 0, /* no add_card function */
};
static int ncards = 0;
static int c4_attach_driver (struct capi_driver * driver)
{
char *p;
......@@ -1308,46 +1306,49 @@ static int c4_attach_driver (struct capi_driver * driver)
return 0;
}
static int __init search_cards(struct capi_driver * driver,
int pci_id, int nr)
static int __devinit c4_probe(struct pci_dev *dev,
const struct pci_device_id *ent)
{
struct pci_dev * dev = NULL;
int retval = 0;
while ((dev = pci_find_subsys(
PCI_VENDOR_ID_DEC, PCI_DEVICE_ID_DEC_21285,
PCI_VENDOR_ID_AVM, pci_id, dev))) {
struct capicardparams param;
if (pci_enable_device(dev) < 0) {
printk(KERN_ERR "%s: failed to enable AVM-C%d\n",
driver->name, nr);
continue;
}
pci_set_master(dev);
param.port = pci_resource_start(dev, 1);
param.irq = dev->irq;
param.membase = pci_resource_start(dev, 0);
printk(KERN_INFO
"%s: PCI BIOS reports AVM-C%d at i/o %#x, irq %d, mem %#x\n",
driver->name, nr, param.port, param.irq, param.membase);
retval = c4_add_card(driver, &param, dev, nr);
if (retval != 0) {
printk(KERN_ERR
"%s: no AVM-C%d at i/o %#x, irq %d detected, mem %#x\n",
driver->name, nr, param.port, param.irq, param.membase);
continue;
}
ncards++;
int nr = ent->driver_data;
struct capi_driver *driver = (nr == 2) ? &c2_driver : &c4_driver;
int retval = 0;
struct capicardparams param;
if (pci_enable_device(dev) < 0) {
printk(KERN_ERR "%s: failed to enable AVM-C%d\n",
driver->name, nr);
return -ENODEV;
}
return retval;
pci_set_master(dev);
param.port = pci_resource_start(dev, 1);
param.irq = dev->irq;
param.membase = pci_resource_start(dev, 0);
printk(KERN_INFO
"%s: PCI BIOS reports AVM-C%d at i/o %#x, irq %d, mem %#x\n",
driver->name, nr, param.port, param.irq, param.membase);
retval = c4_add_card(driver, &param, dev, nr);
if (retval != 0) {
printk(KERN_ERR
"%s: no AVM-C%d at i/o %#x, irq %d detected, mem %#x\n",
driver->name, nr, param.port, param.irq, param.membase);
return -ENODEV;
}
return 0;
}
static struct pci_driver c4_pci_driver = {
name: "c4",
id_table: c4_pci_tbl,
probe: c4_probe,
};
static int __init c4_init(void)
{
int retval;
int ncards;
MOD_INC_USE_COUNT;
......@@ -1363,21 +1364,7 @@ static int __init c4_init(void)
return retval;
}
retval = search_cards(&c4_driver, PCI_DEVICE_ID_AVM_C4, 4);
if (retval && ncards == 0) {
detach_capi_driver(&c2_driver);
detach_capi_driver(&c4_driver);
MOD_DEC_USE_COUNT;
return retval;
}
retval = search_cards(&c2_driver, PCI_DEVICE_ID_AVM_C2, 2);
if (retval && ncards == 0) {
detach_capi_driver(&c2_driver);
detach_capi_driver(&c4_driver);
MOD_DEC_USE_COUNT;
return retval;
}
ncards = pci_register_driver(&c4_pci_driver);
if (ncards) {
printk(KERN_INFO "%s: %d C4/C2 card(s) detected\n",
c4_driver.name, ncards);
......@@ -1385,6 +1372,7 @@ static int __init c4_init(void)
return 0;
}
printk(KERN_ERR "%s: NO C4/C2 card detected\n", c4_driver.name);
pci_unregister_driver(&c4_pci_driver);
detach_capi_driver(&c4_driver);
detach_capi_driver(&c2_driver);
MOD_DEC_USE_COUNT;
......@@ -1393,8 +1381,9 @@ static int __init c4_init(void)
static void __exit c4_exit(void)
{
detach_capi_driver(&c2_driver);
detach_capi_driver(&c4_driver);
pci_unregister_driver(&c4_pci_driver);
detach_capi_driver(&c2_driver);
detach_capi_driver(&c4_driver);
}
module_init(c4_init);
......
This diff is collapsed.
......@@ -33,7 +33,7 @@ static char *revision = "$Revision: 1.1.4.1.2.1 $";
/* ------------------------------------------------------------- */
static struct pci_device_id t1pci_pci_tbl[] __initdata = {
static struct pci_device_id t1pci_pci_tbl[] __devinitdata = {
{ PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_T1, PCI_ANY_ID, PCI_ANY_ID },
{ } /* Terminating entry */
};
......@@ -225,27 +225,63 @@ static struct capi_driver t1pci_driver = {
add_card: 0, /* no add_card function */
};
static int ncards = 0;
/* ------------------------------------------------------------- */
static int __devinit t1pci_probe(struct pci_dev *dev,
const struct pci_device_id *ent)
{
struct capi_driver *driver = &t1pci_driver;
struct capicardparams param;
int retval;
if (pci_enable_device(dev) < 0) {
printk(KERN_ERR "%s: failed to enable AVM-T1-PCI\n",
driver->name);
return -ENODEV;
}
pci_set_master(dev);
param.port = pci_resource_start(dev, 1);
param.irq = dev->irq;
param.membase = pci_resource_start(dev, 0);
printk(KERN_INFO
"%s: PCI BIOS reports AVM-T1-PCI at i/o %#x, irq %d, mem %#x\n",
driver->name, param.port, param.irq, param.membase);
retval = t1pci_add_card(driver, &param, dev);
if (retval != 0) {
printk(KERN_ERR
"%s: no AVM-T1-PCI at i/o %#x, irq %d detected, mem %#x\n",
driver->name, param.port, param.irq, param.membase);
return -ENODEV;
}
return 0;
}
static struct pci_driver t1pci_pci_driver = {
name: "t1pci",
id_table: t1pci_pci_tbl,
probe: t1pci_probe,
};
static int __init t1pci_init(void)
{
struct capi_driver *driver = &t1pci_driver;
struct pci_dev *dev = NULL;
char *p;
int retval;
int ncards;
MOD_INC_USE_COUNT;
if ((p = strchr(revision, ':')) != 0 && p[1]) {
strncpy(driver->revision, p + 2, sizeof(driver->revision));
driver->revision[sizeof(driver->revision)-1] = 0;
strncpy(driver->revision, p + 2, sizeof(driver->revision) - 1);
if ((p = strchr(driver->revision, '$')) != 0 && p > driver->revision)
*(p-1) = 0;
}
printk(KERN_INFO "%s: revision %s\n", driver->name, driver->revision);
di = attach_capi_driver(driver);
di = attach_capi_driver(&t1pci_driver);
if (!di) {
printk(KERN_ERR "%s: failed to attach capi_driver\n",
driver->name);
......@@ -253,32 +289,7 @@ static int __init t1pci_init(void)
return -EIO;
}
while ((dev = pci_find_device(PCI_VENDOR_ID_AVM, PCI_DEVICE_ID_AVM_T1, dev))) {
struct capicardparams param;
if (pci_enable_device(dev) < 0) {
printk(KERN_ERR "%s: failed to enable AVM-T1-PCI\n",
driver->name);
continue;
}
pci_set_master(dev);
param.port = pci_resource_start(dev, 1);
param.irq = dev->irq;
param.membase = pci_resource_start(dev, 0);
printk(KERN_INFO
"%s: PCI BIOS reports AVM-T1-PCI at i/o %#x, irq %d, mem %#x\n",
driver->name, param.port, param.irq, param.membase);
retval = t1pci_add_card(driver, &param, dev);
if (retval != 0) {
printk(KERN_ERR
"%s: no AVM-T1-PCI at i/o %#x, irq %d detected, mem %#x\n",
driver->name, param.port, param.irq, param.membase);
continue;
}
ncards++;
}
ncards = pci_register_driver(&t1pci_pci_driver);
if (ncards) {
printk(KERN_INFO "%s: %d T1-PCI card(s) detected\n",
driver->name, ncards);
......@@ -286,6 +297,7 @@ static int __init t1pci_init(void)
return 0;
}
printk(KERN_ERR "%s: NO T1-PCI card detected\n", driver->name);
pci_unregister_driver(&t1pci_pci_driver);
detach_capi_driver(&t1pci_driver);
MOD_DEC_USE_COUNT;
return -ENODEV;
......@@ -293,7 +305,8 @@ static int __init t1pci_init(void)
static void __exit t1pci_exit(void)
{
detach_capi_driver(&t1pci_driver);
pci_unregister_driver(&t1pci_pci_driver);
detach_capi_driver(&t1pci_driver);
}
module_init(t1pci_init);
......
......@@ -309,7 +309,7 @@ static inline int fifo_remove(struct fifo *fifo)
typedef void (*ctrl_complete_t)(void *);
typedef struct ctrl_msg {
devrequest dr;
struct usb_ctrlrequest dr;
ctrl_complete_t complete;
void *context;
} ctrl_msg;
......
......@@ -41,9 +41,9 @@ static void usb_next_ctrl_msg(struct urb *urb,
(unsigned char *)&ctrl->msg_fifo.data[r_index];
DBG(1,"request=0x%02x,value=0x%04x,index=%x",
((struct ctrl_msg *)urb->setup_packet)->dr.request,
((struct ctrl_msg *)urb->setup_packet)->dr.value,
((struct ctrl_msg *)urb->setup_packet)->dr.index);
((struct ctrl_msg *)urb->setup_packet)->dr.bRequest,
((struct ctrl_msg *)urb->setup_packet)->dr.wValue,
((struct ctrl_msg *)urb->setup_packet)->dr.wIndex);
// Prepare the URB
urb->dev = adapter->usb_dev;
......@@ -69,11 +69,11 @@ void usb_ctrl_msg(struct st5481_adapter *adapter,
}
ctrl_msg = &ctrl->msg_fifo.data[w_index];
ctrl_msg->dr.requesttype = requesttype;
ctrl_msg->dr.request = request;
ctrl_msg->dr.value = cpu_to_le16p(&value);
ctrl_msg->dr.index = cpu_to_le16p(&index);
ctrl_msg->dr.length = 0;
ctrl_msg->dr.bRequestType = requesttype;
ctrl_msg->dr.bRequest = request;
ctrl_msg->dr.wValue = cpu_to_le16p(&value);
ctrl_msg->dr.wIndex = cpu_to_le16p(&index);
ctrl_msg->dr.wLength = 0;
ctrl_msg->complete = complete;
ctrl_msg->context = context;
......@@ -140,17 +140,17 @@ static void usb_ctrl_complete(struct urb *urb)
ctrl_msg = (struct ctrl_msg *)urb->setup_packet;
if (ctrl_msg->dr.request == USB_REQ_CLEAR_FEATURE) {
if (ctrl_msg->dr.bRequest == USB_REQ_CLEAR_FEATURE) {
/* Special case handling for pipe reset */
le16_to_cpus(&ctrl_msg->dr.index);
le16_to_cpus(&ctrl_msg->dr.wIndex);
usb_endpoint_running(adapter->usb_dev,
ctrl_msg->dr.index & ~USB_DIR_IN,
(ctrl_msg->dr.index & USB_DIR_IN) == 0);
ctrl_msg->dr.wIndex & ~USB_DIR_IN,
(ctrl_msg->dr.wIndex & USB_DIR_IN) == 0);
/* toggle is reset on clear */
usb_settoggle(adapter->usb_dev,
ctrl_msg->dr.index & ~USB_DIR_IN,
(ctrl_msg->dr.index & USB_DIR_IN) == 0,
ctrl_msg->dr.wIndex & ~USB_DIR_IN,
(ctrl_msg->dr.wIndex & USB_DIR_IN) == 0,
0);
......@@ -560,7 +560,7 @@ void st5481_release_in(struct st5481_in *in)
*/
int st5481_isoc_flatten(struct urb *urb)
{
piso_packet_descriptor_t pipd,pend;
iso_packet_descriptor_t *pipd,*pend;
unsigned char *src,*dst;
unsigned int len;
......
......@@ -2941,8 +2941,6 @@ int md_thread(void * arg)
* bdflush, otherwise bdflush will deadlock if there are too
* many dirty RAID5 blocks.
*/
current->policy = SCHED_OTHER;
current->nice = -20;
unlock_kernel();
complete(thread->event);
......@@ -3390,11 +3388,6 @@ int md_do_sync(mddev_t *mddev, mdp_disk_t *spare)
"(but not more than %d KB/sec) for reconstruction.\n",
sysctl_speed_limit_max);
/*
* Resync has low priority.
*/
current->nice = 19;
is_mddev_idle(mddev); /* this also initializes IO event counters */
for (m = 0; m < SYNC_MARKS; m++) {
mark[m] = jiffies;
......@@ -3471,16 +3464,13 @@ int md_do_sync(mddev_t *mddev, mdp_disk_t *spare)
currspeed = (j-mddev->resync_mark_cnt)/2/((jiffies-mddev->resync_mark)/HZ +1) +1;
if (currspeed > sysctl_speed_limit_min) {
current->nice = 19;
if ((currspeed > sysctl_speed_limit_max) ||
!is_mddev_idle(mddev)) {
current->state = TASK_INTERRUPTIBLE;
schedule_timeout(HZ/4);
goto repeat;
}
} else
current->nice = -20;
}
}
printk(KERN_INFO "md: md%d: sync done.\n",mdidx(mddev));
err = 0;
......
......@@ -1393,10 +1393,8 @@ cleanup_module(void)
/* First of all: check for active disciplines and hangup them.
*/
do {
if (busy) {
current->time_slice = 0;
schedule();
}
if (busy)
yield();
busy = 0;
local_bh_disable();
......
......@@ -28,19 +28,33 @@ static int setsize(unsigned long capacity, unsigned int *cyls, unsigned int *hds
unsigned char *scsi_bios_ptable(kdev_t dev)
{
struct block_device *bdev;
unsigned char *res = kmalloc(66, GFP_KERNEL);
kdev_t rdev = mk_kdev(major(dev), minor(dev) & ~0x0f);
if (res) {
struct buffer_head *bh = bread(rdev, 0, block_size(rdev));
if (bh) {
memcpy(res, bh->b_data + 0x1be, 66);
} else {
kfree(res);
res = NULL;
}
struct buffer_head *bh;
int err;
bdev = bdget(kdev_t_to_nr(rdev));
if (!bdev)
goto fail;
err = blkdev_get(bdev, FMODE_READ, 0, BDEV_FILE);
if (err)
goto fail;
bh = __bread(bdev, 0, block_size(rdev));
if (!bh)
goto fail2;
memcpy(res, bh->b_data + 0x1be, 66);
brelse(bh);
blkdev_put(bdev, BDEV_FILE);
}
return res;
fail2:
blkdev_put(bdev, BDEV_FILE);
fail:
kfree(res);
return NULL;
}
/*
......
......@@ -33,6 +33,9 @@ dep_tristate ' OHCI (Compaq, iMacs, OPTi, SiS, ALi, ...) support' CONFIG_USB_OH
comment 'USB Device Class drivers'
dep_tristate ' USB Audio support' CONFIG_USB_AUDIO $CONFIG_USB $CONFIG_SOUND
dep_tristate ' USB Bluetooth support (EXPERIMENTAL)' CONFIG_USB_BLUETOOTH $CONFIG_USB $CONFIG_EXPERIMENTAL
if [ "$CONFIG_SCSI" = "n" ]; then
comment ' SCSI support is needed for USB Storage'
fi
dep_tristate ' USB Mass Storage support' CONFIG_USB_STORAGE $CONFIG_USB $CONFIG_SCSI
dep_mbool ' USB Mass Storage verbose debug' CONFIG_USB_STORAGE_DEBUG $CONFIG_USB_STORAGE
dep_mbool ' Datafab MDCFE-B Compact Flash Reader support' CONFIG_USB_STORAGE_DATAFAB $CONFIG_USB_STORAGE $CONFIG_EXPERIMENTAL
......@@ -96,5 +99,6 @@ source drivers/usb/serial/Config.in
comment 'USB Miscellaneous drivers'
dep_tristate ' USB Diamond Rio500 support (EXPERIMENTAL)' CONFIG_USB_RIO500 $CONFIG_USB $CONFIG_EXPERIMENTAL
dep_tristate ' USB Auerswald ISDN support (EXPERIMENTAL)' CONFIG_USB_AUERSWALD $CONFIG_USB $CONFIG_EXPERIMENTAL
endmenu
......@@ -40,6 +40,12 @@ obj- :=
# Each configuration option enables a list of files.
obj-$(CONFIG_USB) += usbcore.o
# EHCI needs to be linked before the other HCD drivers
ifeq ($(CONFIG_USB_EHCI_HCD),y)
obj-y += hcd/ehci-hcd.o
endif
obj-$(CONFIG_USB_UHCI) += usb-uhci.o
obj-$(CONFIG_USB_UHCI_ALT) += uhci.o
obj-$(CONFIG_USB_OHCI) += usb-ohci.o
......@@ -73,6 +79,7 @@ obj-$(CONFIG_USB_MICROTEK) += microtek.o
obj-$(CONFIG_USB_HPUSBSCSI) += hpusbscsi.o
obj-$(CONFIG_USB_BLUETOOTH) += bluetooth.o
obj-$(CONFIG_USB_USBNET) += usbnet.o
obj-$(CONFIG_USB_AUERSWALD) += auerswald.o
# Object files in subdirectories
mod-subdirs := serial hcd
......@@ -81,10 +88,6 @@ subdir-$(CONFIG_USB_EHCI_HCD) += hcd
subdir-$(CONFIG_USB_SERIAL) += serial
subdir-$(CONFIG_USB_STORAGE) += storage
ifeq ($(CONFIG_USB_EHCI_HCD),y)
obj-y += hcd/ehci-hcd.o
endif
ifeq ($(CONFIG_USB_SERIAL),y)
obj-y += serial/usb-serial.o
endif
......
......@@ -184,7 +184,7 @@ static int acm_ctrl_msg(struct acm *acm, int request, int value, void *buf, int
static void acm_ctrl_irq(struct urb *urb)
{
struct acm *acm = urb->context;
devrequest *dr = urb->transfer_buffer;
struct usb_ctrlrequest *dr = urb->transfer_buffer;
unsigned char *data = (unsigned char *)(dr + 1);
int newctrl;
......@@ -195,7 +195,7 @@ static void acm_ctrl_irq(struct urb *urb)
return;
}
switch (dr->request) {
switch (dr->bRequest) {
case ACM_IRQ_NETWORK:
......@@ -223,7 +223,7 @@ static void acm_ctrl_irq(struct urb *urb)
default:
dbg("unknown control event received: request %d index %d len %d data0 %d data1 %d",
dr->request, dr->index, dr->length, data[0], data[1]);
dr->bRequest, dr->wIndex, dr->wLength, data[0], data[1]);
return;
}
}
......
This diff is collapsed.
......@@ -179,7 +179,7 @@ struct usb_bluetooth {
__u8 control_out_bInterfaceNum;
struct urb * control_urb_pool[NUM_CONTROL_URBS];
devrequest dr[NUM_CONTROL_URBS];
struct usb_ctrlrequest dr[NUM_CONTROL_URBS];
unsigned char * interrupt_in_buffer;
struct urb * interrupt_in_urb;
......@@ -288,7 +288,7 @@ static inline struct usb_bluetooth *get_bluetooth_by_minor (int minor)
static int bluetooth_ctrl_msg (struct usb_bluetooth *bluetooth, int request, int value, const unsigned char *buf, int len)
{
struct urb *urb = NULL;
devrequest *dr = NULL;
struct usb_ctrlrequest *dr = NULL;
int i;
int status;
......@@ -325,11 +325,11 @@ static int bluetooth_ctrl_msg (struct usb_bluetooth *bluetooth, int request, int
}
memcpy (urb->transfer_buffer, buf, len);
dr->requesttype = BLUETOOTH_CONTROL_REQUEST_TYPE;
dr->request = request;
dr->value = cpu_to_le16((u16) value);
dr->index = cpu_to_le16((u16) bluetooth->control_out_bInterfaceNum);
dr->length = cpu_to_le16((u16) len);
dr->bRequestType= BLUETOOTH_CONTROL_REQUEST_TYPE;
dr->bRequest = request;
dr->wValue = cpu_to_le16((u16) value);
dr->wIndex = cpu_to_le16((u16) bluetooth->control_out_bInterfaceNum);
dr->wLength = cpu_to_le16((u16) len);
FILL_CONTROL_URB (urb, bluetooth->dev, usb_sndctrlpipe(bluetooth->dev, 0),
(unsigned char*)dr, urb->transfer_buffer, len, bluetooth_ctrl_callback, bluetooth);
......
......@@ -159,7 +159,7 @@ struct catc {
u8 rx_buf[RX_MAX_BURST * (PKT_SZ + 2)];
u8 irq_buf[2];
u8 ctrl_buf[64];
devrequest ctrl_dr;
struct usb_ctrlrequest ctrl_dr;
struct timer_list timer;
u8 stats_buf[8];
......@@ -383,14 +383,14 @@ static void catc_ctrl_run(struct catc *catc)
struct ctrl_queue *q = catc->ctrl_queue + catc->ctrl_tail;
struct usb_device *usbdev = catc->usbdev;
struct urb *urb = &catc->ctrl_urb;
devrequest *dr = &catc->ctrl_dr;
struct usb_ctrlrequest *dr = &catc->ctrl_dr;
int status;
dr->request = q->request;
dr->requesttype = 0x40 | q->dir;
dr->value = cpu_to_le16(q->value);
dr->index = cpu_to_le16(q->index);
dr->length = cpu_to_le16(q->len);
dr->bRequest = q->request;
dr->bRequestType = 0x40 | q->dir;
dr->wValue = cpu_to_le16(q->value);
dr->wIndex = cpu_to_le16(q->index);
dr->wLength = cpu_to_le16(q->len);
urb->pipe = q->dir ? usb_rcvctrlpipe(usbdev, 0) : usb_sndctrlpipe(usbdev, 0);
urb->transfer_buffer_length = q->len;
......
......@@ -527,40 +527,40 @@ static int proc_control(struct dev_state *ps, void *arg)
if (copy_from_user(&ctrl, (void *)arg, sizeof(ctrl)))
return -EFAULT;
if ((ret = check_ctrlrecip(ps, ctrl.requesttype, ctrl.index)))
if ((ret = check_ctrlrecip(ps, ctrl.bRequestType, ctrl.wIndex)))
return ret;
if (ctrl.length > PAGE_SIZE)
if (ctrl.wLength > PAGE_SIZE)
return -EINVAL;
if (!(tbuf = (unsigned char *)__get_free_page(GFP_KERNEL)))
return -ENOMEM;
tmo = (ctrl.timeout * HZ + 999) / 1000;
if (ctrl.requesttype & 0x80) {
if (ctrl.length && !access_ok(VERIFY_WRITE, ctrl.data, ctrl.length)) {
if (ctrl.bRequestType & 0x80) {
if (ctrl.wLength && !access_ok(VERIFY_WRITE, ctrl.data, ctrl.wLength)) {
free_page((unsigned long)tbuf);
return -EINVAL;
}
i = usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), ctrl.request, ctrl.requesttype,
ctrl.value, ctrl.index, tbuf, ctrl.length, tmo);
if ((i > 0) && ctrl.length) {
if (copy_to_user(ctrl.data, tbuf, ctrl.length)) {
i = usb_control_msg(dev, usb_rcvctrlpipe(dev, 0), ctrl.bRequest, ctrl.bRequestType,
ctrl.wValue, ctrl.wIndex, tbuf, ctrl.wLength, tmo);
if ((i > 0) && ctrl.wLength) {
if (copy_to_user(ctrl.data, tbuf, ctrl.wLength)) {
free_page((unsigned long)tbuf);
return -EFAULT;
}
}
} else {
if (ctrl.length) {
if (copy_from_user(tbuf, ctrl.data, ctrl.length)) {
if (ctrl.wLength) {
if (copy_from_user(tbuf, ctrl.data, ctrl.wLength)) {
free_page((unsigned long)tbuf);
return -EFAULT;
}
}
i = usb_control_msg(dev, usb_sndctrlpipe(dev, 0), ctrl.request, ctrl.requesttype,
ctrl.value, ctrl.index, tbuf, ctrl.length, tmo);
i = usb_control_msg(dev, usb_sndctrlpipe(dev, 0), ctrl.bRequest, ctrl.bRequestType,
ctrl.wValue, ctrl.wIndex, tbuf, ctrl.wLength, tmo);
}
free_page((unsigned long)tbuf);
if (i<0) {
printk(KERN_DEBUG "usbdevfs: USBDEVFS_CONTROL failed dev %d rqt %u rq %u len %u ret %d\n",
dev->devnum, ctrl.requesttype, ctrl.request, ctrl.length, i);
dev->devnum, ctrl.bRequestType, ctrl.bRequest, ctrl.wLength, i);
}
return i;
}
......@@ -757,7 +757,7 @@ static int proc_submiturb(struct dev_state *ps, void *arg)
struct usbdevfs_iso_packet_desc *isopkt = NULL;
struct usb_endpoint_descriptor *ep_desc;
struct async *as;
devrequest *dr = NULL;
struct usb_ctrlrequest *dr = NULL;
unsigned int u, totlen, isofrmlen;
int ret;
......@@ -787,23 +787,23 @@ static int proc_submiturb(struct dev_state *ps, void *arg)
/* min 8 byte setup packet, max arbitrary */
if (uurb.buffer_length < 8 || uurb.buffer_length > PAGE_SIZE)
return -EINVAL;
if (!(dr = kmalloc(sizeof(devrequest), GFP_KERNEL)))
if (!(dr = kmalloc(sizeof(struct usb_ctrlrequest), GFP_KERNEL)))
return -ENOMEM;
if (copy_from_user(dr, (unsigned char*)uurb.buffer, 8)) {
kfree(dr);
return -EFAULT;
}
if (uurb.buffer_length < (le16_to_cpup(&dr->length) + 8)) {
if (uurb.buffer_length < (le16_to_cpup(&dr->wLength) + 8)) {
kfree(dr);
return -EINVAL;
}
if ((ret = check_ctrlrecip(ps, dr->requesttype, le16_to_cpup(&dr->index)))) {
if ((ret = check_ctrlrecip(ps, dr->bRequestType, le16_to_cpup(&dr->wIndex)))) {
kfree(dr);
return ret;
}
uurb.endpoint = (uurb.endpoint & ~USB_ENDPOINT_DIR_MASK) | (dr->requesttype & USB_ENDPOINT_DIR_MASK);
uurb.endpoint = (uurb.endpoint & ~USB_ENDPOINT_DIR_MASK) | (dr->bRequestType & USB_ENDPOINT_DIR_MASK);
uurb.number_of_packets = 0;
uurb.buffer_length = le16_to_cpup(&dr->length);
uurb.buffer_length = le16_to_cpup(&dr->wLength);
uurb.buffer += 8;
if (!access_ok((uurb.endpoint & USB_DIR_IN) ? VERIFY_WRITE : VERIFY_READ, uurb.buffer, uurb.buffer_length)) {
kfree(dr);
......
......@@ -268,16 +268,16 @@ static int rh_string (
/* Root hub control transfers execute synchronously */
static int rh_call_control (struct usb_hcd *hcd, struct urb *urb)
{
devrequest *cmd = (devrequest *) urb->setup_packet;
struct usb_ctrlrequest *cmd = (struct usb_ctrlrequest *) urb->setup_packet;
u16 typeReq, wValue, wIndex, wLength;
const u8 *bufp = 0;
u8 *ubuf = urb->transfer_buffer;
int len = 0;
typeReq = (cmd->requesttype << 8) | cmd->request;
wValue = le16_to_cpu (cmd->value);
wIndex = le16_to_cpu (cmd->index);
wLength = le16_to_cpu (cmd->length);
typeReq = (cmd->bRequestType << 8) | cmd->bRequest;
wValue = le16_to_cpu (cmd->wValue);
wIndex = le16_to_cpu (cmd->wIndex);
wLength = le16_to_cpu (cmd->wLength);
if (wLength > urb->transfer_buffer_length)
goto error;
......
......@@ -362,7 +362,7 @@ return retval;
/* SETUP for control urb? */
if (unlikely (QTD_PID (token) == 2))
pci_unmap_single (ehci->hcd.pdev,
qtd->buf_dma, sizeof (devrequest),
qtd->buf_dma, sizeof (struct usb_ctrlrequest),
PCI_DMA_TODEVICE);
/* another queued urb? */
......@@ -443,13 +443,13 @@ qh_urb_transaction (
qtd->buf_dma = pci_map_single (
ehci->hcd.pdev,
urb->setup_packet,
sizeof (devrequest),
sizeof (struct usb_ctrlrequest),
PCI_DMA_TODEVICE);
if (unlikely (!qtd->buf_dma))
goto cleanup;
/* SETUP pid */
qtd_fill (qtd, qtd->buf_dma, sizeof (devrequest),
qtd_fill (qtd, qtd->buf_dma, sizeof (struct usb_ctrlrequest),
token | (2 /* "setup" */ << 8));
/* ... and always at least one more pid */
......
......@@ -987,7 +987,7 @@ int hid_find_field(struct hid_device *hid, unsigned int type, unsigned int code,
static int hid_submit_out(struct hid_device *hid)
{
hid->urbout.transfer_buffer_length = le16_to_cpup(&hid->out[hid->outtail].dr.length);
hid->urbout.transfer_buffer_length = le16_to_cpup(&hid->out[hid->outtail].dr.wLength);
hid->urbout.transfer_buffer = hid->out[hid->outtail].buffer;
hid->urbout.setup_packet = (void *) &(hid->out[hid->outtail].dr);
hid->urbout.dev = hid->dev;
......@@ -1017,8 +1017,8 @@ void hid_write_report(struct hid_device *hid, struct hid_report *report)
{
hid_output_report(report, hid->out[hid->outhead].buffer);
hid->out[hid->outhead].dr.value = cpu_to_le16(0x200 | report->id);
hid->out[hid->outhead].dr.length = cpu_to_le16((report->size + 7) >> 3);
hid->out[hid->outhead].dr.wValue = cpu_to_le16(0x200 | report->id);
hid->out[hid->outhead].dr.wLength = cpu_to_le16((report->size + 7) >> 3);
hid->outhead = (hid->outhead + 1) & (HID_CONTROL_FIFO_SIZE - 1);
......@@ -1179,9 +1179,9 @@ static struct hid_device *usb_hid_configure(struct usb_device *dev, int ifnum)
hid->ifnum = interface->bInterfaceNumber;
for (n = 0; n < HID_CONTROL_FIFO_SIZE; n++) {
hid->out[n].dr.requesttype = USB_TYPE_CLASS | USB_RECIP_INTERFACE;
hid->out[n].dr.request = HID_REQ_SET_REPORT;
hid->out[n].dr.index = cpu_to_le16(hid->ifnum);
hid->out[n].dr.bRequestType = USB_TYPE_CLASS | USB_RECIP_INTERFACE;
hid->out[n].dr.bRequest = HID_REQ_SET_REPORT;
hid->out[n].dr.wIndex = cpu_to_le16(hid->ifnum);
}
hid->name[0] = 0;
......
......@@ -367,7 +367,7 @@ struct hid_report_enum {
#define HID_CONTROL_FIFO_SIZE 8
struct hid_control_fifo {
devrequest dr;
struct usb_ctrlrequest dr;
char buffer[HID_BUFFER_SIZE];
};
......
......@@ -110,8 +110,8 @@ static void *kaweth_probe(
);
static void kaweth_disconnect(struct usb_device *dev, void *ptr);
int kaweth_internal_control_msg(struct usb_device *usb_dev, unsigned int pipe,
devrequest *cmd, void *data, int len,
int timeout);
struct usb_ctrlrequest *cmd, void *data,
int len, int timeout);
/****************************************************************
* usb_device_id
......@@ -229,7 +229,7 @@ static int kaweth_control(struct kaweth_device *kaweth,
__u16 size,
int timeout)
{
devrequest *dr;
struct usb_ctrlrequest *dr;
kaweth_dbg("kaweth_control()");
......@@ -238,20 +238,19 @@ static int kaweth_control(struct kaweth_device *kaweth,
return -EBUSY;
}
dr = kmalloc(sizeof(devrequest),
dr = kmalloc(sizeof(struct usb_ctrlrequest),
in_interrupt() ? GFP_ATOMIC : GFP_KERNEL);
if(!dr)
{
if (!dr) {
kaweth_dbg("kmalloc() failed");
return -ENOMEM;
}
dr->requesttype = requesttype;
dr->request = request;
dr->value = cpu_to_le16p(&value);
dr->index = cpu_to_le16p(&index);
dr->length = cpu_to_le16p(&size);
dr->bRequestType= requesttype;
dr->bRequest = request;
dr->wValue = cpu_to_le16p(&value);
dr->wIndex = cpu_to_le16p(&index);
dr->wLength = cpu_to_le16p(&size);
return kaweth_internal_control_msg(kaweth->dev,
pipe,
......@@ -1015,7 +1014,8 @@ static int usb_start_wait_urb(urb_t *urb, int timeout, int* actual_length)
/*-------------------------------------------------------------------*/
// returns status (negative) or length (positive)
int kaweth_internal_control_msg(struct usb_device *usb_dev, unsigned int pipe,
devrequest *cmd, void *data, int len, int timeout)
struct usb_ctrlrequest *cmd, void *data, int len,
int timeout)
{
urb_t *urb;
int retv;
......
......@@ -142,11 +142,11 @@ static int get_registers(pegasus_t *pegasus, __u16 indx, __u16 size, void *data)
remove_wait_queue(&pegasus->ctrl_wait, &wait);
set_current_state(TASK_RUNNING);
pegasus->dr.requesttype = PEGASUS_REQT_READ;
pegasus->dr.request = PEGASUS_REQ_GET_REGS;
pegasus->dr.value = cpu_to_le16 (0);
pegasus->dr.index = cpu_to_le16p(&indx);
pegasus->dr.length = cpu_to_le16p(&size);
pegasus->dr.bRequestType = PEGASUS_REQT_READ;
pegasus->dr.bRequest = PEGASUS_REQ_GET_REGS;
pegasus->dr.wValue = cpu_to_le16 (0);
pegasus->dr.wIndex = cpu_to_le16p(&indx);
pegasus->dr.wLength = cpu_to_le16p(&size);
pegasus->ctrl_urb.transfer_buffer_length = size;
FILL_CONTROL_URB( &pegasus->ctrl_urb, pegasus->usb,
......@@ -192,11 +192,11 @@ static int set_registers(pegasus_t *pegasus, __u16 indx, __u16 size, void *data)
remove_wait_queue(&pegasus->ctrl_wait, &wait);
set_current_state(TASK_RUNNING);
pegasus->dr.requesttype = PEGASUS_REQT_WRITE;
pegasus->dr.request = PEGASUS_REQ_SET_REGS;
pegasus->dr.value = cpu_to_le16 (0);
pegasus->dr.index = cpu_to_le16p( &indx );
pegasus->dr.length = cpu_to_le16p( &size );
pegasus->dr.bRequestType = PEGASUS_REQT_WRITE;
pegasus->dr.bRequest = PEGASUS_REQ_SET_REGS;
pegasus->dr.wValue = cpu_to_le16 (0);
pegasus->dr.wIndex = cpu_to_le16p( &indx );
pegasus->dr.wLength = cpu_to_le16p( &size );
pegasus->ctrl_urb.transfer_buffer_length = size;
FILL_CONTROL_URB( &pegasus->ctrl_urb, pegasus->usb,
......@@ -242,11 +242,11 @@ static int set_register( pegasus_t *pegasus, __u16 indx, __u8 data )
remove_wait_queue(&pegasus->ctrl_wait, &wait);
set_current_state(TASK_RUNNING);
pegasus->dr.requesttype = PEGASUS_REQT_WRITE;
pegasus->dr.request = PEGASUS_REQ_SET_REG;
pegasus->dr.value = cpu_to_le16p( &dat);
pegasus->dr.index = cpu_to_le16p( &indx );
pegasus->dr.length = cpu_to_le16( 1 );
pegasus->dr.bRequestType = PEGASUS_REQT_WRITE;
pegasus->dr.bRequest = PEGASUS_REQ_SET_REG;
pegasus->dr.wValue = cpu_to_le16p( &dat);
pegasus->dr.wIndex = cpu_to_le16p( &indx );
pegasus->dr.wLength = cpu_to_le16( 1 );
pegasus->ctrl_urb.transfer_buffer_length = 1;
FILL_CONTROL_URB( &pegasus->ctrl_urb, pegasus->usb,
......@@ -275,11 +275,11 @@ static int update_eth_regs_async( pegasus_t *pegasus )
{
int ret;
pegasus->dr.requesttype = PEGASUS_REQT_WRITE;
pegasus->dr.request = PEGASUS_REQ_SET_REGS;
pegasus->dr.value = 0;
pegasus->dr.index = cpu_to_le16(EthCtrl0);
pegasus->dr.length = cpu_to_le16(3);
pegasus->dr.bRequestType = PEGASUS_REQT_WRITE;
pegasus->dr.bRequest = PEGASUS_REQ_SET_REGS;
pegasus->dr.wValue = 0;
pegasus->dr.wIndex = cpu_to_le16(EthCtrl0);
pegasus->dr.wLength = cpu_to_le16(3);
pegasus->ctrl_urb.transfer_buffer_length = 3;
FILL_CONTROL_URB( &pegasus->ctrl_urb, pegasus->usb,
......
......@@ -108,7 +108,7 @@ typedef struct pegasus {
int dev_index;
int intr_interval;
struct urb ctrl_urb, rx_urb, tx_urb, intr_urb;
devrequest dr;
struct usb_ctrlrequest dr;
wait_queue_head_t ctrl_wait;
struct semaphore ctrl_sem;
unsigned char ALIGN(rx_buff[PEGASUS_MAX_MTU]);
......
......@@ -281,7 +281,7 @@
* 0.4.7 11/28/2001
* - Fixed typo in Documentation/scanner.txt. Thanks to
* Karel <karel.vervaeke@pandora.be> for pointing it out.
* - Added ID's for a Memorex 6136u. Thanks to =C1lvaro Gaspar de
* - Added ID's for a Memorex 6136u. Thanks to Álvaro Gaspar de
* Valenzuela" <agaspard@utsi.edu>.
* - Added ID's for Agfa e25. Thanks to Heinrich
* Rust <Heinrich.Rust@gmx.de>. Also reported to work with
......@@ -746,8 +746,8 @@ ioctl_scanner(struct inode *inode, struct file *file,
case SCANNER_IOCTL_CTRLMSG:
{
struct ctrlmsg_ioctl {
devrequest req;
void *data;
struct usb_ctrlrequest req;
void *data;
} cmsg;
int pipe, nb, ret;
unsigned char buf[64];
......@@ -755,12 +755,12 @@ ioctl_scanner(struct inode *inode, struct file *file,
if (copy_from_user(&cmsg, (void *)arg, sizeof(cmsg)))
return -EFAULT;
nb = le16_to_cpup(&cmsg.req.length);
nb = le16_to_cpup(&cmsg.req.wLength);
if (nb > sizeof(buf))
return -EINVAL;
if ((cmsg.req.requesttype & 0x80) == 0) {
if ((cmsg.req.bRequestType & 0x80) == 0) {
pipe = usb_sndctrlpipe(dev, 0);
if (nb > 0 && copy_from_user(buf, cmsg.data, nb))
return -EFAULT;
......@@ -768,10 +768,10 @@ ioctl_scanner(struct inode *inode, struct file *file,
pipe = usb_rcvctrlpipe(dev, 0);
}
ret = usb_control_msg(dev, pipe, cmsg.req.request,
cmsg.req.requesttype,
le16_to_cpup(&cmsg.req.value),
le16_to_cpup(&cmsg.req.index),
ret = usb_control_msg(dev, pipe, cmsg.req.bRequest,
cmsg.req.bRequestType,
le16_to_cpup(&cmsg.req.wValue),
le16_to_cpup(&cmsg.req.wIndex),
buf, nb, HZ);
if (ret < 0) {
......@@ -779,7 +779,7 @@ ioctl_scanner(struct inode *inode, struct file *file,
return -EIO;
}
if (nb > 0 && (cmsg.req.requesttype & 0x80) && copy_to_user(cmsg.data, buf, nb))
if (nb > 0 && (cmsg.req.bRequestType & 0x80) && copy_to_user(cmsg.data, buf, nb))
return -EFAULT;
return 0;
......
......@@ -230,7 +230,7 @@ MODULE_DEVICE_TABLE (usb, scanner_device_ids);
#define SCANNER_IOCTL_VENDOR _IOR('U', 0x20, int)
#define SCANNER_IOCTL_PRODUCT _IOR('U', 0x21, int)
/* send/recv a control message to the scanner */
#define SCANNER_IOCTL_CTRLMSG _IOWR('U', 0x22, devrequest )
#define SCANNER_IOCTL_CTRLMSG _IOWR('U', 0x22, struct usb_ctrlrequest)
#define SCN_MAX_MNR 16 /* We're allocated 16 minors */
......
......@@ -119,6 +119,7 @@ MODULE_DEVICE_TABLE (usb, id_table_combined);
/* All of the device info needed for the serial converters */
static struct usb_serial_device_type belkin_device = {
owner: THIS_MODULE,
name: "Belkin / Peracom / GoHubs USB Serial Adapter",
id_table: id_table_combined,
num_interrupt_in: 1,
......@@ -209,7 +210,6 @@ static int belkin_sa_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
/*Start reading from the device*/
......@@ -264,7 +264,6 @@ static void belkin_sa_close (struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
} /* belkin_sa_close */
......
......@@ -77,6 +77,7 @@ static __devinitdata struct usb_device_id id_table [] = {
MODULE_DEVICE_TABLE (usb, id_table);
static struct usb_serial_device_type cyberjack_device = {
owner: THIS_MODULE,
name: "Reiner SCT Cyberjack USB card reader",
id_table: id_table,
num_interrupt_in: 1,
......@@ -148,8 +149,6 @@ static int cyberjack_open (struct usb_serial_port *port, struct file *filp)
if (port_paranoia_check (port, __FUNCTION__))
return -ENODEV;
MOD_INC_USE_COUNT;
dbg(__FUNCTION__ " - port %d", port->number);
down (&port->sem);
......@@ -204,7 +203,6 @@ static void cyberjack_close (struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
static int cyberjack_write (struct usb_serial_port *port, int from_user, const unsigned char *buf, int count)
......
......@@ -501,6 +501,7 @@ MODULE_DEVICE_TABLE (usb, id_table_combined);
/* device info needed for the Digi serial converter */
static struct usb_serial_device_type digi_acceleport_2_device = {
owner: THIS_MODULE,
name: "Digi USB",
id_table: id_table_2,
num_interrupt_in: 0,
......@@ -524,6 +525,7 @@ static struct usb_serial_device_type digi_acceleport_2_device = {
};
static struct usb_serial_device_type digi_acceleport_4_device = {
owner: THIS_MODULE,
name: "Digi USB",
id_table: id_table_4,
num_interrupt_in: 0,
......@@ -603,7 +605,6 @@ static void digi_wakeup_write_lock( struct usb_serial_port *port )
spin_lock_irqsave( &priv->dp_port_lock, flags );
digi_wakeup_write( port );
spin_unlock_irqrestore( &priv->dp_port_lock, flags );
MOD_DEC_USE_COUNT;
}
static void digi_wakeup_write( struct usb_serial_port *port )
......@@ -1410,9 +1411,7 @@ dbg( "digi_write_bulk_callback: TOP, urb->status=%d", urb->status );
/* also queue up a wakeup at scheduler time, in case we */
/* lost the race in write_chan(). */
MOD_INC_USE_COUNT;
if (schedule_task(&priv->dp_wakeup_task) == 0)
MOD_DEC_USE_COUNT;
schedule_task(&priv->dp_wakeup_task);
spin_unlock( &priv->dp_port_lock );
......@@ -1493,7 +1492,6 @@ dbg( "digi_open: TOP: port=%d, open_count=%d", priv->dp_port_num, port->open_cou
/* inc module use count before sleeping to wait for closes */
++port->open_count;
MOD_INC_USE_COUNT;
/* wait for a close in progress to finish */
while( priv->dp_in_close ) {
......@@ -1502,7 +1500,6 @@ dbg( "digi_open: TOP: port=%d, open_count=%d", priv->dp_port_num, port->open_cou
&priv->dp_port_lock, flags );
if( signal_pending(current) ) {
--port->open_count;
MOD_DEC_USE_COUNT;
return( -EINTR );
}
spin_lock_irqsave( &priv->dp_port_lock, flags );
......@@ -1562,7 +1559,6 @@ dbg( "digi_close: TOP: port=%d, open_count=%d", priv->dp_port_num, port->open_co
spin_lock_irqsave( &priv->dp_port_lock, flags );
if( port->open_count > 1 ) {
--port->open_count;
MOD_DEC_USE_COUNT;
spin_unlock_irqrestore( &priv->dp_port_lock, flags );
return;
} else if( port->open_count <= 0 ) {
......@@ -1642,7 +1638,6 @@ dbg( "digi_close: TOP: port=%d, open_count=%d", priv->dp_port_num, port->open_co
priv->dp_write_urb_in_use = 0;
priv->dp_in_close = 0;
--port->open_count;
MOD_DEC_USE_COUNT;
wake_up_interruptible( &priv->dp_close_wait );
spin_unlock_irqrestore( &priv->dp_port_lock, flags );
......@@ -1787,7 +1782,6 @@ dbg( "digi_shutdown: TOP, in_interrupt()=%d", in_interrupt() );
priv = serial->port[i].private;
spin_lock_irqsave( &priv->dp_port_lock, flags );
while( serial->port[i].open_count > 0 ) {
MOD_DEC_USE_COUNT;
--serial->port[i].open_count;
}
spin_unlock_irqrestore( &priv->dp_port_lock, flags );
......
......@@ -114,6 +114,7 @@ static __devinitdata struct usb_device_id id_table [] = {
MODULE_DEVICE_TABLE (usb, id_table);
static struct usb_serial_device_type empeg_device = {
owner: THIS_MODULE,
name: "Empeg",
id_table: id_table,
num_interrupt_in: 0,
......@@ -159,7 +160,6 @@ static int empeg_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
......@@ -224,8 +224,6 @@ static void empeg_close (struct usb_serial_port *port, struct file * filp)
/* Uncomment the following line if you want to see some statistics in your syslog */
/* info ("Bytes In = %d Bytes Out = %d", bytes_in, bytes_out); */
MOD_DEC_USE_COUNT;
}
......
......@@ -174,6 +174,7 @@ static void ftdi_sio_break_ctl (struct usb_serial_port *port, int break_state )
which share common code */
static struct usb_serial_device_type ftdi_sio_device = {
owner: THIS_MODULE,
name: "FTDI SIO",
id_table: id_table_sio,
num_interrupt_in: 0,
......@@ -318,7 +319,6 @@ static int ftdi_sio_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
MOD_INC_USE_COUNT;
++port->open_count;
if (port->open_count == 1){
......@@ -411,7 +411,6 @@ static void ftdi_sio_close (struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
} /* ftdi_sio_close */
......
......@@ -985,7 +985,6 @@ static int edge_open (struct usb_serial_port *port, struct file * filp)
return -ENODEV;
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
/* force low_latency on so that our tty_push actually forces the data through,
......@@ -999,7 +998,6 @@ static int edge_open (struct usb_serial_port *port, struct file * filp)
edge_serial = (struct edgeport_serial *)serial->private;
if (edge_serial == NULL) {
port->open_count = 0;
MOD_DEC_USE_COUNT;
return -ENODEV;
}
if (edge_serial->interrupt_in_buffer == NULL) {
......@@ -1062,7 +1060,6 @@ static int edge_open (struct usb_serial_port *port, struct file * filp)
err(__FUNCTION__" - error sending open port command");
edge_port->openPending = FALSE;
port->open_count = 0;
MOD_DEC_USE_COUNT;
return -ENODEV;
}
......@@ -1077,7 +1074,6 @@ static int edge_open (struct usb_serial_port *port, struct file * filp)
dbg(__FUNCTION__" - open timedout");
edge_port->openPending = FALSE;
port->open_count = 0;
MOD_DEC_USE_COUNT;
return -ENODEV;
}
......@@ -1283,7 +1279,6 @@ static void edge_close (struct usb_serial_port *port, struct file * filp)
port->open_count = 0;
}
MOD_DEC_USE_COUNT;
dbg(__FUNCTION__" exited");
}
......
......@@ -72,6 +72,7 @@ static __devinitdata struct usb_device_id id_table_combined [] = {
MODULE_DEVICE_TABLE (usb, id_table_combined);
static struct usb_serial_device_type edgeport_1port_device = {
owner: THIS_MODULE,
name: "Edgeport 1 port adapter",
id_table: edgeport_1port_id_table,
num_interrupt_in: 1,
......@@ -93,6 +94,7 @@ static struct usb_serial_device_type edgeport_1port_device = {
};
static struct usb_serial_device_type edgeport_2port_device = {
owner: THIS_MODULE,
name: "Edgeport 2 port adapter",
id_table: edgeport_2port_id_table,
num_interrupt_in: 1,
......@@ -114,6 +116,7 @@ static struct usb_serial_device_type edgeport_2port_device = {
};
static struct usb_serial_device_type edgeport_4port_device = {
owner: THIS_MODULE,
name: "Edgeport 4 port adapter",
id_table: edgeport_4port_id_table,
num_interrupt_in: 1,
......@@ -135,6 +138,7 @@ static struct usb_serial_device_type edgeport_4port_device = {
};
static struct usb_serial_device_type edgeport_8port_device = {
owner: THIS_MODULE,
name: "Edgeport 8 port adapter",
id_table: edgeport_8port_id_table,
num_interrupt_in: 1,
......
......@@ -91,6 +91,7 @@ MODULE_DEVICE_TABLE (usb, id_table);
struct usb_serial_device_type ir_device = {
owner: THIS_MODULE,
name: "IR Dongle",
id_table: id_table,
num_interrupt_in: 1,
......@@ -204,7 +205,6 @@ static int ir_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
if (buffer_size) {
......@@ -270,7 +270,6 @@ static void ir_close (struct usb_serial_port *port, struct file * filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
static int ir_write (struct usb_serial_port *port, int from_user, const unsigned char *buf, int count)
......
......@@ -877,8 +877,6 @@ static int keyspan_open (struct usb_serial_port *port, struct file *filp)
dbg("keyspan_open called for port%d.\n", port->number);
MOD_INC_USE_COUNT;
down (&port->sem);
already_active = port->open_count;
++port->open_count;
......@@ -960,8 +958,6 @@ static void keyspan_close(struct usb_serial_port *port, struct file *filp)
port->tty = 0;
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
......@@ -1789,7 +1785,6 @@ static void keyspan_shutdown (struct usb_serial *serial)
port = &serial->port[i];
while (port->open_count > 0) {
--port->open_count;
MOD_DEC_USE_COUNT;
}
kfree(port->private);
}
......
......@@ -449,6 +449,7 @@ static __devinitdata struct usb_device_id keyspan_usa49w_ids[] = {
/* Structs for the devices, pre and post renumeration. */
static struct usb_serial_device_type keyspan_usa18x_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA18X - (without firmware)",
id_table: keyspan_usa18x_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -459,6 +460,7 @@ static struct usb_serial_device_type keyspan_usa18x_pre_device = {
};
static struct usb_serial_device_type keyspan_usa19_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA19 - (without firmware)",
id_table: keyspan_usa19_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -470,6 +472,7 @@ static struct usb_serial_device_type keyspan_usa19_pre_device = {
static struct usb_serial_device_type keyspan_usa19w_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA19W - (without firmware)",
id_table: keyspan_usa19w_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -481,6 +484,7 @@ static struct usb_serial_device_type keyspan_usa19w_pre_device = {
static struct usb_serial_device_type keyspan_usa28_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA28 - (without firmware)",
id_table: keyspan_usa28_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -491,6 +495,7 @@ static struct usb_serial_device_type keyspan_usa28_pre_device = {
};
static struct usb_serial_device_type keyspan_usa28x_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA28X - (without firmware)",
id_table: keyspan_usa28x_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -501,6 +506,7 @@ static struct usb_serial_device_type keyspan_usa28x_pre_device = {
};
static struct usb_serial_device_type keyspan_usa28xa_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA28XA - (without firmware)",
id_table: keyspan_usa28xa_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -511,6 +517,7 @@ static struct usb_serial_device_type keyspan_usa28xa_pre_device = {
};
static struct usb_serial_device_type keyspan_usa28xb_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA28XB - (without firmware)",
id_table: keyspan_usa28xb_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -521,6 +528,7 @@ static struct usb_serial_device_type keyspan_usa28xb_pre_device = {
};
static struct usb_serial_device_type keyspan_usa49w_pre_device = {
owner: THIS_MODULE,
name: "Keyspan USA49W - (without firmware)",
id_table: keyspan_usa49w_pre_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -531,6 +539,7 @@ static struct usb_serial_device_type keyspan_usa49w_pre_device = {
};
static struct usb_serial_device_type keyspan_usa18x_device = {
owner: THIS_MODULE,
name: "Keyspan USA18X",
id_table: keyspan_usa18x_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -554,6 +563,7 @@ static struct usb_serial_device_type keyspan_usa18x_device = {
};
static struct usb_serial_device_type keyspan_usa19_device = {
owner: THIS_MODULE,
name: "Keyspan USA19",
id_table: keyspan_usa19_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -578,6 +588,7 @@ static struct usb_serial_device_type keyspan_usa19_device = {
static struct usb_serial_device_type keyspan_usa19w_device = {
owner: THIS_MODULE,
name: "Keyspan USA19W",
id_table: keyspan_usa19w_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -602,6 +613,7 @@ static struct usb_serial_device_type keyspan_usa19w_device = {
static struct usb_serial_device_type keyspan_usa28_device = {
owner: THIS_MODULE,
name: "Keyspan USA28",
id_table: keyspan_usa28_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -617,6 +629,7 @@ static struct usb_serial_device_type keyspan_usa28_device = {
static struct usb_serial_device_type keyspan_usa28x_device = {
owner: THIS_MODULE,
name: "Keyspan USA28X/XB",
id_table: keyspan_usa28x_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -641,6 +654,7 @@ static struct usb_serial_device_type keyspan_usa28x_device = {
};
static struct usb_serial_device_type keyspan_usa28xa_device = {
owner: THIS_MODULE,
name: "Keyspan USA28XA",
id_table: keyspan_usa28xa_ids,
num_interrupt_in: NUM_DONT_CARE,
......@@ -665,6 +679,7 @@ static struct usb_serial_device_type keyspan_usa28xa_device = {
};
static struct usb_serial_device_type keyspan_usa49w_device = {
owner: THIS_MODULE,
name: "Keyspan USA49W",
id_table: keyspan_usa49w_ids,
num_interrupt_in: NUM_DONT_CARE,
......
......@@ -193,7 +193,6 @@ static void keyspan_pda_wakeup_write( struct usb_serial_port *port )
/* wake up other tty processes */
wake_up_interruptible( &tty->write_wait );
/* For 2.2.16 backport -- wake_up_interruptible( &tty->poll_wait ); */
MOD_DEC_USE_COUNT;
}
static void keyspan_pda_request_unthrottle( struct usb_serial *serial )
......@@ -212,7 +211,6 @@ static void keyspan_pda_request_unthrottle( struct usb_serial *serial )
NULL,
0,
2*HZ);
MOD_DEC_USE_COUNT;
}
......@@ -261,9 +259,7 @@ static void keyspan_pda_rx_interrupt (struct urb *urb)
tty = serial->port[0].tty;
priv->tx_throttled = 0;
/* queue up a wakeup at scheduler time */
MOD_INC_USE_COUNT;
if (schedule_task(&priv->wakeup_task) == 0)
MOD_DEC_USE_COUNT;
schedule_task(&priv->wakeup_task);
break;
default:
break;
......@@ -602,9 +598,7 @@ static int keyspan_pda_write(struct usb_serial_port *port, int from_user,
if (request_unthrottle) {
priv->tx_throttled = 1; /* block writers */
MOD_INC_USE_COUNT;
if (schedule_task(&priv->unthrottle_task) == 0)
MOD_DEC_USE_COUNT;
schedule_task(&priv->unthrottle_task);
}
rc = count;
......@@ -631,9 +625,7 @@ static void keyspan_pda_write_bulk_callback (struct urb *urb)
}
/* queue up a wakeup at scheduler time */
MOD_INC_USE_COUNT;
if (schedule_task(&priv->wakeup_task) == 0)
MOD_DEC_USE_COUNT;
schedule_task(&priv->wakeup_task);
}
......@@ -672,7 +664,6 @@ static int keyspan_pda_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
MOD_INC_USE_COUNT;
++port->open_count;
if (port->open_count == 1) {
......@@ -721,7 +712,6 @@ static int keyspan_pda_open (struct usb_serial_port *port, struct file *filp)
return rc;
error:
--port->open_count;
MOD_DEC_USE_COUNT;
up (&port->sem);
return rc;
}
......@@ -749,7 +739,6 @@ static void keyspan_pda_close(struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
......
......@@ -144,6 +144,7 @@ MODULE_DEVICE_TABLE (usb, id_table_combined);
static struct usb_serial_device_type mct_u232_device = {
owner: THIS_MODULE,
name: "Magic Control Technology USB-RS232",
id_table: id_table_combined,
num_interrupt_in: 2,
......@@ -343,7 +344,6 @@ static int mct_u232_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
/* Compensate for a hardware bug: although the Sitecom U232-P25
......@@ -423,7 +423,6 @@ static void mct_u232_close (struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
} /* mct_u232_close */
......
......@@ -88,6 +88,7 @@ MODULE_DEVICE_TABLE (usb, id_table);
static struct usb_serial_device_type zyxel_omninet_device = {
owner: THIS_MODULE,
name: "ZyXEL - omni.net lcd plus usb",
id_table: id_table,
num_interrupt_in: 1,
......@@ -158,7 +159,6 @@ static int omninet_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
MOD_INC_USE_COUNT;
++port->open_count;
if (port->open_count == 1) {
......@@ -167,7 +167,6 @@ static int omninet_open (struct usb_serial_port *port, struct file *filp)
err(__FUNCTION__"- kmalloc(%Zd) failed.", sizeof(struct omninet_data));
port->open_count = 0;
up (&port->sem);
MOD_DEC_USE_COUNT;
return -ENOMEM;
}
......@@ -223,7 +222,6 @@ static void omninet_close (struct usb_serial_port *port, struct file * filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
......
......@@ -116,6 +116,7 @@ static void pl2303_shutdown (struct usb_serial *serial);
/* All of the device info needed for the PL2303 SIO serial converter */
static struct usb_serial_device_type pl2303_device = {
owner: THIS_MODULE,
name: "PL-2303",
id_table: id_table,
num_interrupt_in: NUM_DONT_CARE,
......@@ -369,7 +370,6 @@ static int pl2303_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
#define FISH(a,b,c,d) \
......@@ -480,7 +480,6 @@ static void pl2303_close (struct usb_serial_port *port, struct file *filp)
}
up (&port->sem);
MOD_DEC_USE_COUNT;
}
static int set_modem_info (struct usb_serial_port *port, unsigned int cmd, unsigned int *value)
......
......@@ -133,6 +133,7 @@ static int whiteheat_real_startup (struct usb_serial *serial);
static void whiteheat_real_shutdown (struct usb_serial *serial);
static struct usb_serial_device_type whiteheat_fake_device = {
owner: THIS_MODULE,
name: "Connect Tech - WhiteHEAT - (prerenumeration)",
id_table: id_table_prerenumeration,
num_interrupt_in: NUM_DONT_CARE,
......@@ -143,6 +144,7 @@ static struct usb_serial_device_type whiteheat_fake_device = {
};
static struct usb_serial_device_type whiteheat_device = {
owner: THIS_MODULE,
name: "Connect Tech - WhiteHEAT",
id_table: id_table_std,
num_interrupt_in: NUM_DONT_CARE,
......@@ -307,7 +309,6 @@ static int whiteheat_open (struct usb_serial_port *port, struct file *filp)
down (&port->sem);
++port->open_count;
MOD_INC_USE_COUNT;
if (port->open_count == 1) {
/* set up some stuff for our command port */
......@@ -359,7 +360,6 @@ static int whiteheat_open (struct usb_serial_port *port, struct file *filp)
error_exit:
--port->open_count;
MOD_DEC_USE_COUNT;
dbg(__FUNCTION__ " - error_exit");
up (&port->sem);
......@@ -391,7 +391,6 @@ static void whiteheat_close(struct usb_serial_port *port, struct file * filp)
usb_unlink_urb (port->read_urb);
port->open_count = 0;
}
MOD_DEC_USE_COUNT;
up (&port->sem);
}
......
......@@ -385,19 +385,19 @@ int usb_stor_control_msg(struct us_data *us, unsigned int pipe,
{
struct completion urb_done;
int status;
devrequest *dr;
struct usb_ctrlrequest *dr;
/* allocate the device request structure */
dr = kmalloc(sizeof(devrequest), GFP_NOIO);
dr = kmalloc(sizeof(struct usb_ctrlrequest), GFP_NOIO);
if (!dr)
return -ENOMEM;
/* fill in the structure */
dr->requesttype = requesttype;
dr->request = request;
dr->value = cpu_to_le16(value);
dr->index = cpu_to_le16(index);
dr->length = cpu_to_le16(size);
dr->bRequestType = requesttype;
dr->bRequest = request;
dr->wValue = cpu_to_le16(value);
dr->wIndex = cpu_to_le16(index);
dr->wLength = cpu_to_le16(size);
/* set up data structures for the wakeup system */
init_completion(&urb_done);
......
......@@ -646,7 +646,7 @@ static struct urb_priv *uhci_alloc_urb_priv(struct uhci *uhci, struct urb *urb)
if (usb_pipetype(urb->pipe) == PIPE_CONTROL && urb->setup_packet) {
urbp->setup_packet_dma_handle = pci_map_single(uhci->dev,
urb->setup_packet, sizeof(devrequest),
urb->setup_packet, sizeof(struct usb_ctrlrequest),
PCI_DMA_TODEVICE);
if (!urbp->setup_packet_dma_handle)
return NULL;
......@@ -715,7 +715,7 @@ static void uhci_destroy_urb_priv(struct urb *urb)
if (urbp->setup_packet_dma_handle)
pci_unmap_single(uhci->dev, urbp->setup_packet_dma_handle,
sizeof(devrequest), PCI_DMA_TODEVICE);
sizeof(struct usb_ctrlrequest), PCI_DMA_TODEVICE);
if (urbp->transfer_buffer_dma_handle)
pci_unmap_single(uhci->dev, urbp->transfer_buffer_dma_handle,
......@@ -2013,7 +2013,7 @@ static int rh_submit_urb(struct urb *urb)
{
struct uhci *uhci = (struct uhci *)urb->dev->bus->hcpriv;
unsigned int pipe = urb->pipe;
devrequest *cmd = (devrequest *)urb->setup_packet;
struct usb_ctrlrequest *cmd = (struct usb_ctrlrequest *)urb->setup_packet;
void *data = urb->transfer_buffer;
int leni = urb->transfer_buffer_length;
int len = 0;
......@@ -2036,10 +2036,10 @@ static int rh_submit_urb(struct urb *urb)
return -EINPROGRESS;
}
bmRType_bReq = cmd->requesttype | cmd->request << 8;
wValue = le16_to_cpu(cmd->value);
wIndex = le16_to_cpu(cmd->index);
wLength = le16_to_cpu(cmd->length);
bmRType_bReq = cmd->bRequestType | cmd->bRequest << 8;
wValue = le16_to_cpu(cmd->wValue);
wIndex = le16_to_cpu(cmd->wIndex);
wLength = le16_to_cpu(cmd->wLength);
for (i = 0; i < 8; i++)
uhci->rh.c_p_r[i] = 0;
......@@ -2276,7 +2276,7 @@ static void uhci_call_completion(struct urb *urb)
if (urbp->setup_packet_dma_handle)
pci_dma_sync_single(uhci->dev, urbp->setup_packet_dma_handle,
sizeof(devrequest), PCI_DMA_TODEVICE);
sizeof(struct usb_ctrlrequest), PCI_DMA_TODEVICE);
urb->dev = NULL;
if (urb->complete)
......
......@@ -1905,7 +1905,7 @@ static int rh_submit_urb (urb_t * urb)
struct usb_device * usb_dev = urb->dev;
ohci_t * ohci = usb_dev->bus->hcpriv;
unsigned int pipe = urb->pipe;
devrequest * cmd = (devrequest *) urb->setup_packet;
struct usb_ctrlrequest * cmd = (struct usb_ctrlrequest *) urb->setup_packet;
void * data = urb->transfer_buffer;
int leni = urb->transfer_buffer_length;
int len = 0;
......@@ -1929,10 +1929,10 @@ static int rh_submit_urb (urb_t * urb)
return 0;
}
bmRType_bReq = cmd->requesttype | (cmd->request << 8);
wValue = le16_to_cpu (cmd->value);
wIndex = le16_to_cpu (cmd->index);
wLength = le16_to_cpu (cmd->length);
bmRType_bReq = cmd->bRequestType | (cmd->bRequest << 8);
wValue = le16_to_cpu (cmd->wValue);
wIndex = le16_to_cpu (cmd->wIndex);
wLength = le16_to_cpu (cmd->wLength);
switch (bmRType_bReq) {
/* Request Destination:
......
......@@ -138,9 +138,37 @@ static struct usb_skel *minor_table[MAX_DEVICES];
/* lock to protect the minor_table structure */
static DECLARE_MUTEX (minor_table_mutex);
/* file operations needed when we register this driver */
/*
* File operations needed when we register this driver.
* This assumes that this driver NEEDS file operations,
* of course, which means that the driver is expected
* to have a node in the /dev directory. If the USB
* device were for a network interface then the driver
* would use "struct net_driver" instead, and a serial
* device would use "struct tty_driver".
*/
static struct file_operations skel_fops = {
/*
* The owner field is part of the module-locking
* mechanism. The idea is that the kernel knows
* which module to increment the use-counter of
* BEFORE it calls the device's open() function.
* This also means that the kernel can decrement
* the use-counter again before calling release()
* or should the open() function fail.
*
* Not all device structures have an "owner" field
* yet. "struct file_operations" and "struct net_device"
* do, while "struct tty_driver" does not. If the struct
* has an "owner" field, then initialize it to the value
* THIS_MODULE and the kernel will handle all module
* locking for you automatically. Otherwise, you must
* increment the use-counter in the open() function
* and decrement it again in the release() function
* yourself.
*/
owner: THIS_MODULE,
read: skel_read,
write: skel_write,
ioctl: skel_ioctl,
......@@ -215,7 +243,11 @@ static int skel_open (struct inode *inode, struct file *file)
return -ENODEV;
}
/* increment our usage count for the module */
/* Increment our usage count for the module.
* This is redundant here, because "struct file_operations"
* has an "owner" field. This line is included here soley as
* a reference for drivers using lesser structures... ;-)
*/
MOD_INC_USE_COUNT;
/* lock our minor table and get our local data for this minor */
......@@ -278,8 +310,8 @@ static int skel_release (struct inode *inode, struct file *file)
/* the device was unplugged before the file was released */
up (&dev->sem);
skel_delete (dev);
MOD_DEC_USE_COUNT;
up (&minor_table_mutex);
MOD_DEC_USE_COUNT;
return 0;
}
......
......@@ -1085,7 +1085,7 @@ _static void uhci_urb_dma_sync(uhci_t *s, urb_t *urb, urb_priv_t *urb_priv)
{
if (urb_priv->setup_packet_dma)
pci_dma_sync_single(s->uhci_pci, urb_priv->setup_packet_dma,
sizeof(devrequest), PCI_DMA_TODEVICE);
sizeof(struct usb_ctrlrequest), PCI_DMA_TODEVICE);
if (urb_priv->transfer_buffer_dma)
pci_dma_sync_single(s->uhci_pci, urb_priv->transfer_buffer_dma,
......@@ -1099,7 +1099,7 @@ _static void uhci_urb_dma_unmap(uhci_t *s, urb_t *urb, urb_priv_t *urb_priv)
{
if (urb_priv->setup_packet_dma) {
pci_unmap_single(s->uhci_pci, urb_priv->setup_packet_dma,
sizeof(devrequest), PCI_DMA_TODEVICE);
sizeof(struct usb_ctrlrequest), PCI_DMA_TODEVICE);
urb_priv->setup_packet_dma = 0;
}
if (urb_priv->transfer_buffer_dma) {
......@@ -1678,7 +1678,7 @@ _static int uhci_submit_urb (urb_t *urb)
if (type == PIPE_CONTROL)
urb_priv->setup_packet_dma = pci_map_single(s->uhci_pci, urb->setup_packet,
sizeof(devrequest), PCI_DMA_TODEVICE);
sizeof(struct usb_ctrlrequest), PCI_DMA_TODEVICE);
if (urb->transfer_buffer_length)
urb_priv->transfer_buffer_dma = pci_map_single(s->uhci_pci,
......@@ -1963,7 +1963,7 @@ _static int rh_submit_urb (urb_t *urb)
struct usb_device *usb_dev = urb->dev;
uhci_t *uhci = usb_dev->bus->hcpriv;
unsigned int pipe = urb->pipe;
devrequest *cmd = (devrequest *) urb->setup_packet;
struct usb_ctrlrequest *cmd = (struct usb_ctrlrequest *) urb->setup_packet;
void *data = urb->transfer_buffer;
int leni = urb->transfer_buffer_length;
int len = 0;
......@@ -1989,10 +1989,10 @@ _static int rh_submit_urb (urb_t *urb)
}
bmRType_bReq = cmd->requesttype | cmd->request << 8;
wValue = le16_to_cpu (cmd->value);
wIndex = le16_to_cpu (cmd->index);
wLength = le16_to_cpu (cmd->length);
bmRType_bReq = cmd->bRequestType | cmd->bRequest << 8;
wValue = le16_to_cpu (cmd->wValue);
wIndex = le16_to_cpu (cmd->wIndex);
wLength = le16_to_cpu (cmd->wLength);
for (i = 0; i < 8; i++)
uhci->rh.c_p_r[i] = 0;
......
......@@ -1287,7 +1287,7 @@ static int usb_start_wait_urb(urb_t *urb, int timeout, int* actual_length)
/*-------------------------------------------------------------------*/
// returns status (negative) or length (positive)
int usb_internal_control_msg(struct usb_device *usb_dev, unsigned int pipe,
devrequest *cmd, void *data, int len, int timeout)
struct usb_ctrlrequest *cmd, void *data, int len, int timeout)
{
urb_t *urb;
int retv;
......@@ -1331,17 +1331,17 @@ int usb_internal_control_msg(struct usb_device *usb_dev, unsigned int pipe,
int usb_control_msg(struct usb_device *dev, unsigned int pipe, __u8 request, __u8 requesttype,
__u16 value, __u16 index, void *data, __u16 size, int timeout)
{
devrequest *dr = kmalloc(sizeof(devrequest), GFP_KERNEL);
struct usb_ctrlrequest *dr = kmalloc(sizeof(struct usb_ctrlrequest), GFP_KERNEL);
int ret;
if (!dr)
return -ENOMEM;
dr->requesttype = requesttype;
dr->request = request;
dr->value = cpu_to_le16p(&value);
dr->index = cpu_to_le16p(&index);
dr->length = cpu_to_le16p(&size);
dr->bRequestType= requesttype;
dr->bRequest = request;
dr->wValue = cpu_to_le16p(&value);
dr->wIndex = cpu_to_le16p(&index);
dr->wLength = cpu_to_le16p(&size);
//dbg("usb_control_msg");
......@@ -1535,6 +1535,9 @@ static int usb_parse_interface(struct usb_interface *interface, unsigned char *b
}
ifp = interface->altsetting + interface->num_altsetting;
ifp->endpoint = NULL;
ifp->extra = NULL;
ifp->extralen = 0;
interface->num_altsetting++;
memcpy(ifp, buffer, USB_DT_INTERFACE_SIZE);
......@@ -1576,10 +1579,7 @@ static int usb_parse_interface(struct usb_interface *interface, unsigned char *b
/* Copy any unknown descriptors into a storage area for */
/* drivers to later parse */
len = (int)(buffer - begin);
if (!len) {
ifp->extra = NULL;
ifp->extralen = 0;
} else {
if (len) {
ifp->extra = kmalloc(len, GFP_KERNEL);
if (!ifp->extra) {
......
......@@ -74,7 +74,7 @@ struct usb_kbd {
unsigned char new[8];
unsigned char old[8];
struct urb irq, led;
devrequest dr;
struct usb_ctrlrequest dr;
unsigned char leds, newleds;
char name[128];
int open;
......@@ -218,11 +218,11 @@ static void *usb_kbd_probe(struct usb_device *dev, unsigned int ifnum,
FILL_INT_URB(&kbd->irq, dev, pipe, kbd->new, maxp > 8 ? 8 : maxp,
usb_kbd_irq, kbd, endpoint->bInterval);
kbd->dr.requesttype = USB_TYPE_CLASS | USB_RECIP_INTERFACE;
kbd->dr.request = HID_REQ_SET_REPORT;
kbd->dr.value = 0x200;
kbd->dr.index = interface->bInterfaceNumber;
kbd->dr.length = 1;
kbd->dr.bRequestType = USB_TYPE_CLASS | USB_RECIP_INTERFACE;
kbd->dr.bRequest = HID_REQ_SET_REPORT;
kbd->dr.wValue = 0x200;
kbd->dr.wIndex = interface->bInterfaceNumber;
kbd->dr.wLength = 1;
kbd->dev.name = kbd->name;
kbd->dev.idbus = BUS_USB;
......
......@@ -1119,7 +1119,7 @@ static int elf_core_dump(long signr, struct pt_regs * regs, struct file * file)
psinfo.pr_state = i;
psinfo.pr_sname = (i < 0 || i > 5) ? '.' : "RSDZTD"[i];
psinfo.pr_zomb = psinfo.pr_sname == 'Z';
psinfo.pr_nice = current->nice;
psinfo.pr_nice = current->__nice;
psinfo.pr_flag = current->flags;
psinfo.pr_uid = NEW_TO_OLD_UID(current->uid);
psinfo.pr_gid = NEW_TO_OLD_GID(current->gid);
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -224,6 +224,7 @@ struct tlb_state
{
struct mm_struct *active_mm;
int state;
char __cacheline_padding[24];
};
extern struct tlb_state cpu_tlbstate[NR_CPUS];
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment