You've already forked linux-apfs
mirror of
https://github.com/linux-apfs/linux-apfs.git
synced 2026-05-01 15:00:59 -07:00
Merge branch 'master'
This commit is contained in:
+1
-1
@@ -69,7 +69,7 @@ obj-$(CONFIG_EISA) += eisa/
|
||||
obj-$(CONFIG_CPU_FREQ) += cpufreq/
|
||||
obj-$(CONFIG_MMC) += mmc/
|
||||
obj-$(CONFIG_INFINIBAND) += infiniband/
|
||||
obj-$(CONFIG_SGI_IOC4) += sn/
|
||||
obj-$(CONFIG_SGI_SN) += sn/
|
||||
obj-y += firmware/
|
||||
obj-$(CONFIG_CRYPTO) += crypto/
|
||||
obj-$(CONFIG_SUPERH) += sh/
|
||||
|
||||
@@ -94,7 +94,9 @@ static int set_max_cstate(struct dmi_system_id *id)
|
||||
return 0;
|
||||
}
|
||||
|
||||
static struct dmi_system_id __initdata processor_power_dmi_table[] = {
|
||||
/* Actually this shouldn't be __cpuinitdata, would be better to fix the
|
||||
callers to only run once -AK */
|
||||
static struct dmi_system_id __cpuinitdata processor_power_dmi_table[] = {
|
||||
{ set_max_cstate, "IBM ThinkPad R40e", {
|
||||
DMI_MATCH(DMI_BIOS_VENDOR,"IBM"),
|
||||
DMI_MATCH(DMI_BIOS_VERSION,"1SET60WW")}, (void *)1},
|
||||
@@ -899,7 +901,7 @@ static int acpi_processor_power_verify(struct acpi_processor *pr)
|
||||
case ACPI_STATE_C3:
|
||||
acpi_processor_power_verify_c3(pr, cx);
|
||||
#ifdef ARCH_APICTIMER_STOPS_ON_C3
|
||||
if (c->x86_vendor == X86_VENDOR_INTEL) {
|
||||
if (cx->valid && c->x86_vendor == X86_VENDOR_INTEL) {
|
||||
on_each_cpu(switch_APIC_timer_to_ipi,
|
||||
&mask, 1, 1);
|
||||
}
|
||||
|
||||
@@ -8,6 +8,7 @@ obj-y += power/
|
||||
obj-$(CONFIG_FW_LOADER) += firmware_class.o
|
||||
obj-$(CONFIG_NUMA) += node.o
|
||||
obj-$(CONFIG_MEMORY_HOTPLUG) += memory.o
|
||||
obj-$(CONFIG_SMP) += topology.o
|
||||
|
||||
ifeq ($(CONFIG_DEBUG_DRIVER),y)
|
||||
EXTRA_CFLAGS += -DDEBUG
|
||||
|
||||
@@ -19,6 +19,10 @@ extern void bus_remove_driver(struct device_driver *);
|
||||
extern void driver_detach(struct device_driver * drv);
|
||||
extern int driver_probe_device(struct device_driver *, struct device *);
|
||||
|
||||
extern void sysdev_shutdown(void);
|
||||
extern int sysdev_suspend(pm_message_t state);
|
||||
extern int sysdev_resume(void);
|
||||
|
||||
static inline struct class_device *to_class_dev(struct kobject *obj)
|
||||
{
|
||||
return container_of(obj, struct class_device, kobj);
|
||||
|
||||
@@ -133,6 +133,8 @@ static struct kobj_type ktype_bus = {
|
||||
decl_subsys(bus, &ktype_bus, NULL);
|
||||
|
||||
|
||||
#ifdef CONFIG_HOTPLUG
|
||||
|
||||
/* Manually detach a device from its associated driver. */
|
||||
static int driver_helper(struct device *dev, void *data)
|
||||
{
|
||||
@@ -193,6 +195,7 @@ static ssize_t driver_bind(struct device_driver *drv,
|
||||
}
|
||||
static DRIVER_ATTR(bind, S_IWUSR, NULL, driver_bind);
|
||||
|
||||
#endif
|
||||
|
||||
static struct device * next_device(struct klist_iter * i)
|
||||
{
|
||||
|
||||
@@ -303,7 +303,7 @@ static int block_size_init(void)
|
||||
*/
|
||||
#ifdef CONFIG_ARCH_MEMORY_PROBE
|
||||
static ssize_t
|
||||
memory_probe_store(struct class *class, const char __user *buf, size_t count)
|
||||
memory_probe_store(struct class *class, const char *buf, size_t count)
|
||||
{
|
||||
u64 phys_addr;
|
||||
int ret;
|
||||
|
||||
@@ -9,10 +9,9 @@
|
||||
*/
|
||||
|
||||
#include <linux/device.h>
|
||||
#include "../base.h"
|
||||
#include "power.h"
|
||||
|
||||
extern int sysdev_resume(void);
|
||||
|
||||
|
||||
/**
|
||||
* resume_device - Restore state for one device.
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
#include <linux/device.h>
|
||||
#include <asm/semaphore.h>
|
||||
|
||||
#include "../base.h"
|
||||
#include "power.h"
|
||||
|
||||
#define to_dev(node) container_of(node, struct device, kobj.entry)
|
||||
@@ -28,7 +29,6 @@ extern struct subsystem devices_subsys;
|
||||
* they only get one called once when interrupts are disabled.
|
||||
*/
|
||||
|
||||
extern int sysdev_shutdown(void);
|
||||
|
||||
/**
|
||||
* device_shutdown - call ->shutdown() on each device to shutdown.
|
||||
|
||||
@@ -9,10 +9,9 @@
|
||||
*/
|
||||
|
||||
#include <linux/device.h>
|
||||
#include "../base.h"
|
||||
#include "power.h"
|
||||
|
||||
extern int sysdev_suspend(pm_message_t state);
|
||||
|
||||
/*
|
||||
* The entries in the dpm_active list are in a depth first order, simply
|
||||
* because children are guaranteed to be discovered after parents, and
|
||||
|
||||
@@ -27,22 +27,30 @@
|
||||
|
||||
static ssize_t state_show(struct device * dev, struct device_attribute *attr, char * buf)
|
||||
{
|
||||
return sprintf(buf, "%u\n", dev->power.power_state.event);
|
||||
if (dev->power.power_state.event)
|
||||
return sprintf(buf, "2\n");
|
||||
else
|
||||
return sprintf(buf, "0\n");
|
||||
}
|
||||
|
||||
static ssize_t state_store(struct device * dev, struct device_attribute *attr, const char * buf, size_t n)
|
||||
{
|
||||
pm_message_t state;
|
||||
char * rest;
|
||||
int error = 0;
|
||||
int error = -EINVAL;
|
||||
|
||||
state.event = simple_strtoul(buf, &rest, 10);
|
||||
if (*rest)
|
||||
return -EINVAL;
|
||||
if (state.event)
|
||||
state.event = PM_EVENT_SUSPEND;
|
||||
/* Older apps expected to write "3" here - confused with PCI D3 */
|
||||
if ((n == 1) && !strcmp(buf, "3"))
|
||||
error = dpm_runtime_suspend(dev, state);
|
||||
else
|
||||
|
||||
if ((n == 1) && !strcmp(buf, "2"))
|
||||
error = dpm_runtime_suspend(dev, state);
|
||||
|
||||
if ((n == 1) && !strcmp(buf, "0")) {
|
||||
dpm_runtime_resume(dev);
|
||||
error = 0;
|
||||
}
|
||||
|
||||
return error ? error : n;
|
||||
}
|
||||
|
||||
|
||||
@@ -21,8 +21,11 @@
|
||||
#include <linux/slab.h>
|
||||
#include <linux/string.h>
|
||||
#include <linux/pm.h>
|
||||
#include <linux/device.h>
|
||||
#include <asm/semaphore.h>
|
||||
|
||||
#include "base.h"
|
||||
|
||||
extern struct subsystem devices_subsys;
|
||||
|
||||
#define to_sysdev(k) container_of(k, struct sys_device, kobj)
|
||||
|
||||
@@ -0,0 +1,148 @@
|
||||
/*
|
||||
* driver/base/topology.c - Populate sysfs with cpu topology information
|
||||
*
|
||||
* Written by: Zhang Yanmin, Intel Corporation
|
||||
*
|
||||
* Copyright (C) 2006, Intel Corp.
|
||||
*
|
||||
* All rights reserved.
|
||||
*
|
||||
* 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, GOOD TITLE or
|
||||
* NON INFRINGEMENT. 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., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*
|
||||
*/
|
||||
#include <linux/sysdev.h>
|
||||
#include <linux/init.h>
|
||||
#include <linux/mm.h>
|
||||
#include <linux/cpu.h>
|
||||
#include <linux/module.h>
|
||||
#include <linux/topology.h>
|
||||
|
||||
#define define_one_ro(_name) \
|
||||
static SYSDEV_ATTR(_name, 0444, show_##_name, NULL)
|
||||
|
||||
#define define_id_show_func(name) \
|
||||
static ssize_t show_##name(struct sys_device *dev, char *buf) \
|
||||
{ \
|
||||
unsigned int cpu = dev->id; \
|
||||
return sprintf(buf, "%d\n", topology_##name(cpu)); \
|
||||
}
|
||||
|
||||
#define define_siblings_show_func(name) \
|
||||
static ssize_t show_##name(struct sys_device *dev, char *buf) \
|
||||
{ \
|
||||
ssize_t len = -1; \
|
||||
unsigned int cpu = dev->id; \
|
||||
len = cpumask_scnprintf(buf, NR_CPUS+1, topology_##name(cpu)); \
|
||||
return (len + sprintf(buf + len, "\n")); \
|
||||
}
|
||||
|
||||
#ifdef topology_physical_package_id
|
||||
define_id_show_func(physical_package_id);
|
||||
define_one_ro(physical_package_id);
|
||||
#define ref_physical_package_id_attr &attr_physical_package_id.attr,
|
||||
#else
|
||||
#define ref_physical_package_id_attr
|
||||
#endif
|
||||
|
||||
#ifdef topology_core_id
|
||||
define_id_show_func(core_id);
|
||||
define_one_ro(core_id);
|
||||
#define ref_core_id_attr &attr_core_id.attr,
|
||||
#else
|
||||
#define ref_core_id_attr
|
||||
#endif
|
||||
|
||||
#ifdef topology_thread_siblings
|
||||
define_siblings_show_func(thread_siblings);
|
||||
define_one_ro(thread_siblings);
|
||||
#define ref_thread_siblings_attr &attr_thread_siblings.attr,
|
||||
#else
|
||||
#define ref_thread_siblings_attr
|
||||
#endif
|
||||
|
||||
#ifdef topology_core_siblings
|
||||
define_siblings_show_func(core_siblings);
|
||||
define_one_ro(core_siblings);
|
||||
#define ref_core_siblings_attr &attr_core_siblings.attr,
|
||||
#else
|
||||
#define ref_core_siblings_attr
|
||||
#endif
|
||||
|
||||
static struct attribute *default_attrs[] = {
|
||||
ref_physical_package_id_attr
|
||||
ref_core_id_attr
|
||||
ref_thread_siblings_attr
|
||||
ref_core_siblings_attr
|
||||
NULL
|
||||
};
|
||||
|
||||
static struct attribute_group topology_attr_group = {
|
||||
.attrs = default_attrs,
|
||||
.name = "topology"
|
||||
};
|
||||
|
||||
/* Add/Remove cpu_topology interface for CPU device */
|
||||
static int __cpuinit topology_add_dev(struct sys_device * sys_dev)
|
||||
{
|
||||
sysfs_create_group(&sys_dev->kobj, &topology_attr_group);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int __cpuinit topology_remove_dev(struct sys_device * sys_dev)
|
||||
{
|
||||
sysfs_remove_group(&sys_dev->kobj, &topology_attr_group);
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int __cpuinit topology_cpu_callback(struct notifier_block *nfb,
|
||||
unsigned long action, void *hcpu)
|
||||
{
|
||||
unsigned int cpu = (unsigned long)hcpu;
|
||||
struct sys_device *sys_dev;
|
||||
|
||||
sys_dev = get_cpu_sysdev(cpu);
|
||||
switch (action) {
|
||||
case CPU_ONLINE:
|
||||
topology_add_dev(sys_dev);
|
||||
break;
|
||||
case CPU_DEAD:
|
||||
topology_remove_dev(sys_dev);
|
||||
break;
|
||||
}
|
||||
return NOTIFY_OK;
|
||||
}
|
||||
|
||||
static struct notifier_block topology_cpu_notifier =
|
||||
{
|
||||
.notifier_call = topology_cpu_callback,
|
||||
};
|
||||
|
||||
static int __cpuinit topology_sysfs_init(void)
|
||||
{
|
||||
int i;
|
||||
|
||||
for_each_online_cpu(i) {
|
||||
topology_cpu_callback(&topology_cpu_notifier, CPU_ONLINE,
|
||||
(void *)(long)i);
|
||||
}
|
||||
|
||||
register_cpu_notifier(&topology_cpu_notifier);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
device_initcall(topology_sysfs_init);
|
||||
|
||||
@@ -433,12 +433,12 @@ config CDROM_PKTCDVD_BUFFERS
|
||||
This controls the maximum number of active concurrent packets. More
|
||||
concurrent packets can increase write performance, but also require
|
||||
more memory. Each concurrent packet will require approximately 64Kb
|
||||
of non-swappable kernel memory, memory which will be allocated at
|
||||
pktsetup time.
|
||||
of non-swappable kernel memory, memory which will be allocated when
|
||||
a disc is opened for writing.
|
||||
|
||||
config CDROM_PKTCDVD_WCACHE
|
||||
bool "Enable write caching"
|
||||
depends on CDROM_PKTCDVD
|
||||
bool "Enable write caching (EXPERIMENTAL)"
|
||||
depends on CDROM_PKTCDVD && EXPERIMENTAL
|
||||
help
|
||||
If enabled, write caching will be set for the CD-R/W device. For now
|
||||
this option is dangerous unless the CD-RW media is known good, as we
|
||||
|
||||
@@ -2183,6 +2183,7 @@ static void cciss_softirq_done(struct request *rq)
|
||||
{
|
||||
CommandList_struct *cmd = rq->completion_data;
|
||||
ctlr_info_t *h = hba[cmd->ctlr];
|
||||
unsigned long flags;
|
||||
u64bit temp64;
|
||||
int i, ddir;
|
||||
|
||||
@@ -2205,10 +2206,10 @@ static void cciss_softirq_done(struct request *rq)
|
||||
printk("Done with %p\n", rq);
|
||||
#endif /* CCISS_DEBUG */
|
||||
|
||||
spin_lock_irq(&h->lock);
|
||||
spin_lock_irqsave(&h->lock, flags);
|
||||
end_that_request_last(rq, rq->errors);
|
||||
cmd_free(h, cmd,1);
|
||||
spin_unlock_irq(&h->lock);
|
||||
spin_unlock_irqrestore(&h->lock, flags);
|
||||
}
|
||||
|
||||
/* checks the status of the job and calls complete buffers to mark all
|
||||
|
||||
+29
-29
@@ -43,8 +43,6 @@
|
||||
*
|
||||
*************************************************************************/
|
||||
|
||||
#define VERSION_CODE "v0.2.0a 2004-07-14 Jens Axboe (axboe@suse.de) and petero2@telia.com"
|
||||
|
||||
#include <linux/pktcdvd.h>
|
||||
#include <linux/config.h>
|
||||
#include <linux/module.h>
|
||||
@@ -131,7 +129,7 @@ static struct bio *pkt_bio_alloc(int nr_iovecs)
|
||||
/*
|
||||
* Allocate a packet_data struct
|
||||
*/
|
||||
static struct packet_data *pkt_alloc_packet_data(void)
|
||||
static struct packet_data *pkt_alloc_packet_data(int frames)
|
||||
{
|
||||
int i;
|
||||
struct packet_data *pkt;
|
||||
@@ -140,11 +138,12 @@ static struct packet_data *pkt_alloc_packet_data(void)
|
||||
if (!pkt)
|
||||
goto no_pkt;
|
||||
|
||||
pkt->w_bio = pkt_bio_alloc(PACKET_MAX_SIZE);
|
||||
pkt->frames = frames;
|
||||
pkt->w_bio = pkt_bio_alloc(frames);
|
||||
if (!pkt->w_bio)
|
||||
goto no_bio;
|
||||
|
||||
for (i = 0; i < PAGES_PER_PACKET; i++) {
|
||||
for (i = 0; i < frames / FRAMES_PER_PAGE; i++) {
|
||||
pkt->pages[i] = alloc_page(GFP_KERNEL|__GFP_ZERO);
|
||||
if (!pkt->pages[i])
|
||||
goto no_page;
|
||||
@@ -152,7 +151,7 @@ static struct packet_data *pkt_alloc_packet_data(void)
|
||||
|
||||
spin_lock_init(&pkt->lock);
|
||||
|
||||
for (i = 0; i < PACKET_MAX_SIZE; i++) {
|
||||
for (i = 0; i < frames; i++) {
|
||||
struct bio *bio = pkt_bio_alloc(1);
|
||||
if (!bio)
|
||||
goto no_rd_bio;
|
||||
@@ -162,14 +161,14 @@ static struct packet_data *pkt_alloc_packet_data(void)
|
||||
return pkt;
|
||||
|
||||
no_rd_bio:
|
||||
for (i = 0; i < PACKET_MAX_SIZE; i++) {
|
||||
for (i = 0; i < frames; i++) {
|
||||
struct bio *bio = pkt->r_bios[i];
|
||||
if (bio)
|
||||
bio_put(bio);
|
||||
}
|
||||
|
||||
no_page:
|
||||
for (i = 0; i < PAGES_PER_PACKET; i++)
|
||||
for (i = 0; i < frames / FRAMES_PER_PAGE; i++)
|
||||
if (pkt->pages[i])
|
||||
__free_page(pkt->pages[i]);
|
||||
bio_put(pkt->w_bio);
|
||||
@@ -186,12 +185,12 @@ static void pkt_free_packet_data(struct packet_data *pkt)
|
||||
{
|
||||
int i;
|
||||
|
||||
for (i = 0; i < PACKET_MAX_SIZE; i++) {
|
||||
for (i = 0; i < pkt->frames; i++) {
|
||||
struct bio *bio = pkt->r_bios[i];
|
||||
if (bio)
|
||||
bio_put(bio);
|
||||
}
|
||||
for (i = 0; i < PAGES_PER_PACKET; i++)
|
||||
for (i = 0; i < pkt->frames / FRAMES_PER_PAGE; i++)
|
||||
__free_page(pkt->pages[i]);
|
||||
bio_put(pkt->w_bio);
|
||||
kfree(pkt);
|
||||
@@ -206,17 +205,17 @@ static void pkt_shrink_pktlist(struct pktcdvd_device *pd)
|
||||
list_for_each_entry_safe(pkt, next, &pd->cdrw.pkt_free_list, list) {
|
||||
pkt_free_packet_data(pkt);
|
||||
}
|
||||
INIT_LIST_HEAD(&pd->cdrw.pkt_free_list);
|
||||
}
|
||||
|
||||
static int pkt_grow_pktlist(struct pktcdvd_device *pd, int nr_packets)
|
||||
{
|
||||
struct packet_data *pkt;
|
||||
|
||||
INIT_LIST_HEAD(&pd->cdrw.pkt_free_list);
|
||||
INIT_LIST_HEAD(&pd->cdrw.pkt_active_list);
|
||||
spin_lock_init(&pd->cdrw.active_list_lock);
|
||||
BUG_ON(!list_empty(&pd->cdrw.pkt_free_list));
|
||||
|
||||
while (nr_packets > 0) {
|
||||
pkt = pkt_alloc_packet_data();
|
||||
pkt = pkt_alloc_packet_data(pd->settings.size >> 2);
|
||||
if (!pkt) {
|
||||
pkt_shrink_pktlist(pd);
|
||||
return 0;
|
||||
@@ -951,7 +950,7 @@ try_next_bio:
|
||||
|
||||
pd->current_sector = zone + pd->settings.size;
|
||||
pkt->sector = zone;
|
||||
pkt->frames = pd->settings.size >> 2;
|
||||
BUG_ON(pkt->frames != pd->settings.size >> 2);
|
||||
pkt->write_size = 0;
|
||||
|
||||
/*
|
||||
@@ -1639,7 +1638,7 @@ static int pkt_probe_settings(struct pktcdvd_device *pd)
|
||||
pd->settings.size = be32_to_cpu(ti.fixed_packet_size) << 2;
|
||||
if (pd->settings.size == 0) {
|
||||
printk("pktcdvd: detected zero packet size!\n");
|
||||
pd->settings.size = 128;
|
||||
return -ENXIO;
|
||||
}
|
||||
if (pd->settings.size > PACKET_MAX_SECTORS) {
|
||||
printk("pktcdvd: packet size is too big\n");
|
||||
@@ -1987,8 +1986,14 @@ static int pkt_open_dev(struct pktcdvd_device *pd, int write)
|
||||
if ((ret = pkt_set_segment_merging(pd, q)))
|
||||
goto out_unclaim;
|
||||
|
||||
if (write)
|
||||
if (write) {
|
||||
if (!pkt_grow_pktlist(pd, CONFIG_CDROM_PKTCDVD_BUFFERS)) {
|
||||
printk("pktcdvd: not enough memory for buffers\n");
|
||||
ret = -ENOMEM;
|
||||
goto out_unclaim;
|
||||
}
|
||||
printk("pktcdvd: %lukB available on disc\n", lba << 1);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
||||
@@ -2014,6 +2019,8 @@ static void pkt_release_dev(struct pktcdvd_device *pd, int flush)
|
||||
pkt_set_speed(pd, MAX_SPEED, MAX_SPEED);
|
||||
bd_release(pd->bdev);
|
||||
blkdev_put(pd->bdev);
|
||||
|
||||
pkt_shrink_pktlist(pd);
|
||||
}
|
||||
|
||||
static struct pktcdvd_device *pkt_find_dev_from_minor(int dev_minor)
|
||||
@@ -2379,12 +2386,6 @@ static int pkt_new_dev(struct pktcdvd_device *pd, dev_t dev)
|
||||
/* This is safe, since we have a reference from open(). */
|
||||
__module_get(THIS_MODULE);
|
||||
|
||||
if (!pkt_grow_pktlist(pd, CONFIG_CDROM_PKTCDVD_BUFFERS)) {
|
||||
printk("pktcdvd: not enough memory for buffers\n");
|
||||
ret = -ENOMEM;
|
||||
goto out_mem;
|
||||
}
|
||||
|
||||
pd->bdev = bdev;
|
||||
set_blocksize(bdev, CD_FRAMESIZE);
|
||||
|
||||
@@ -2395,7 +2396,7 @@ static int pkt_new_dev(struct pktcdvd_device *pd, dev_t dev)
|
||||
if (IS_ERR(pd->cdrw.thread)) {
|
||||
printk("pktcdvd: can't start kernel thread\n");
|
||||
ret = -ENOMEM;
|
||||
goto out_thread;
|
||||
goto out_mem;
|
||||
}
|
||||
|
||||
proc = create_proc_entry(pd->name, 0, pkt_proc);
|
||||
@@ -2406,8 +2407,6 @@ static int pkt_new_dev(struct pktcdvd_device *pd, dev_t dev)
|
||||
DPRINTK("pktcdvd: writer %s mapped to %s\n", pd->name, bdevname(bdev, b));
|
||||
return 0;
|
||||
|
||||
out_thread:
|
||||
pkt_shrink_pktlist(pd);
|
||||
out_mem:
|
||||
blkdev_put(bdev);
|
||||
/* This is safe: open() is still holding a reference. */
|
||||
@@ -2503,6 +2502,10 @@ static int pkt_setup_dev(struct pkt_ctrl_command *ctrl_cmd)
|
||||
goto out_mem;
|
||||
pd->disk = disk;
|
||||
|
||||
INIT_LIST_HEAD(&pd->cdrw.pkt_free_list);
|
||||
INIT_LIST_HEAD(&pd->cdrw.pkt_active_list);
|
||||
spin_lock_init(&pd->cdrw.active_list_lock);
|
||||
|
||||
spin_lock_init(&pd->lock);
|
||||
spin_lock_init(&pd->iosched.lock);
|
||||
sprintf(pd->name, "pktcdvd%d", idx);
|
||||
@@ -2567,8 +2570,6 @@ static int pkt_remove_dev(struct pkt_ctrl_command *ctrl_cmd)
|
||||
|
||||
blkdev_put(pd->bdev);
|
||||
|
||||
pkt_shrink_pktlist(pd);
|
||||
|
||||
remove_proc_entry(pd->name, pkt_proc);
|
||||
DPRINTK("pktcdvd: writer %s unmapped\n", pd->name);
|
||||
|
||||
@@ -2678,7 +2679,6 @@ static int __init pkt_init(void)
|
||||
|
||||
pkt_proc = proc_mkdir("pktcdvd", proc_root_driver);
|
||||
|
||||
DPRINTK("pktcdvd: %s\n", VERSION_CODE);
|
||||
return 0;
|
||||
|
||||
out:
|
||||
|
||||
@@ -882,7 +882,7 @@ static int __devinit mm_pci_probe(struct pci_dev *dev, const struct pci_device_i
|
||||
card->card_number, dev->bus->number, dev->devfn);
|
||||
|
||||
if (pci_set_dma_mask(dev, 0xffffffffffffffffLL) &&
|
||||
!pci_set_dma_mask(dev, 0xffffffffLL)) {
|
||||
pci_set_dma_mask(dev, 0xffffffffLL)) {
|
||||
printk(KERN_WARNING "MM%d: NO suitable DMA found\n",num_cards);
|
||||
return -ENOMEM;
|
||||
}
|
||||
|
||||
@@ -42,8 +42,6 @@
|
||||
#include <linux/proc_fs.h>
|
||||
#include <linux/seq_file.h>
|
||||
|
||||
#include <asm/bug.h>
|
||||
|
||||
#include <asm/vio.h>
|
||||
#include <asm/scatterlist.h>
|
||||
#include <asm/iseries/hv_types.h>
|
||||
|
||||
@@ -222,7 +222,7 @@ config SYNCLINKMP
|
||||
|
||||
config SYNCLINK_GT
|
||||
tristate "SyncLink GT/AC support"
|
||||
depends on SERIAL_NONSTANDARD
|
||||
depends on SERIAL_NONSTANDARD && PCI
|
||||
help
|
||||
Support for SyncLink GT and SyncLink AC families of
|
||||
synchronous and asynchronous serial adapters
|
||||
|
||||
@@ -1233,7 +1233,7 @@ cyy_interrupt(int irq, void *dev_id, struct pt_regs *regs)
|
||||
}
|
||||
info->idle_stats.recv_idle = jiffies;
|
||||
}
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
/* end of service */
|
||||
cy_writeb(base_addr+(CyRIR<<index), (save_xir & 0x3f));
|
||||
@@ -1606,7 +1606,7 @@ cyz_handle_rx(struct cyclades_port *info,
|
||||
}
|
||||
#endif
|
||||
info->idle_stats.recv_idle = jiffies;
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
/* Update rx_get */
|
||||
cy_writel(&buf_ctrl->rx_get, new_rx_get);
|
||||
@@ -1809,7 +1809,7 @@ cyz_handle_cmd(struct cyclades_card *cinfo)
|
||||
if(delta_count)
|
||||
cy_sched_event(info, Cy_EVENT_DELTA_WAKEUP);
|
||||
if(special_count)
|
||||
schedule_delayed_work(&tty->buf.work, 1);
|
||||
tty_schedule_flip(tty);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -59,17 +59,16 @@ static void *drm_ati_alloc_pcigart_table(void)
|
||||
int i;
|
||||
DRM_DEBUG("%s\n", __FUNCTION__);
|
||||
|
||||
address = __get_free_pages(GFP_KERNEL, ATI_PCIGART_TABLE_ORDER);
|
||||
address = __get_free_pages(GFP_KERNEL | __GFP_COMP,
|
||||
ATI_PCIGART_TABLE_ORDER);
|
||||
if (address == 0UL) {
|
||||
return 0;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
page = virt_to_page(address);
|
||||
|
||||
for (i = 0; i < ATI_PCIGART_TABLE_PAGES; i++, page++) {
|
||||
get_page(page);
|
||||
for (i = 0; i < ATI_PCIGART_TABLE_PAGES; i++, page++)
|
||||
SetPageReserved(page);
|
||||
}
|
||||
|
||||
DRM_DEBUG("%s: returning 0x%08lx\n", __FUNCTION__, address);
|
||||
return (void *)address;
|
||||
@@ -83,10 +82,8 @@ static void drm_ati_free_pcigart_table(void *address)
|
||||
|
||||
page = virt_to_page((unsigned long)address);
|
||||
|
||||
for (i = 0; i < ATI_PCIGART_TABLE_PAGES; i++, page++) {
|
||||
__put_page(page);
|
||||
for (i = 0; i < ATI_PCIGART_TABLE_PAGES; i++, page++)
|
||||
ClearPageReserved(page);
|
||||
}
|
||||
|
||||
free_pages((unsigned long)address, ATI_PCIGART_TABLE_ORDER);
|
||||
}
|
||||
@@ -127,7 +124,7 @@ int drm_ati_pcigart_cleanup(drm_device_t *dev, drm_ati_pcigart_info *gart_info)
|
||||
if (gart_info->gart_table_location == DRM_ATI_GART_MAIN
|
||||
&& gart_info->addr) {
|
||||
drm_ati_free_pcigart_table(gart_info->addr);
|
||||
gart_info->addr = 0;
|
||||
gart_info->addr = NULL;
|
||||
}
|
||||
|
||||
return 1;
|
||||
@@ -168,7 +165,7 @@ int drm_ati_pcigart_init(drm_device_t *dev, drm_ati_pcigart_info *gart_info)
|
||||
if (bus_address == 0) {
|
||||
DRM_ERROR("unable to map PCIGART pages!\n");
|
||||
drm_ati_free_pcigart_table(address);
|
||||
address = 0;
|
||||
address = NULL;
|
||||
goto done;
|
||||
}
|
||||
} else {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user