Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 75123
b: refs/heads/master
c: 2d192d9
h: refs/heads/master
i:
  75121: 5399f62
  75119: 5ef6038
v: v3
  • Loading branch information
Michael Wu authored and David S. Miller committed Dec 20, 2007
1 parent f09ba54 commit 36ffa68
Show file tree
Hide file tree
Showing 26 changed files with 64 additions and 116 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a4c80d2ae2cac531c6655f75658dae02c488abc7
refs/heads/master: 2d192d9552881f4cf88e62072047c72ef2b5aa7f
2 changes: 1 addition & 1 deletion trunk/Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
VERSION = 2
PATCHLEVEL = 6
SUBLEVEL = 24
EXTRAVERSION = -rc6
EXTRAVERSION = -rc5
NAME = Arr Matey! A Hairy Bilge Rat!

# *DOCUMENTATION*
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/sparc/kernel/ptrace.c
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* Based upon code written by Ross Biro, Linus Torvalds, Bob Manson,
* and David Mosberger.
*
* Added Linux support -miguel (weird, eh?, the original code was meant
* Added Linux support -miguel (weird, eh?, the orignal code was meant
* to emulate SunOS).
*/

Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/sparc64/kernel/pci_schizo.c
Original file line number Diff line number Diff line change
Expand Up @@ -850,7 +850,7 @@ static int pbm_routes_this_ino(struct pci_pbm_info *pbm, u32 ino)
/* How the Tomatillo IRQs are routed around is pure guesswork here.
*
* All the Tomatillo devices I see in prtconf dumps seem to have only
* a single PCI bus unit attached to it. It would seem they are separate
* a single PCI bus unit attached to it. It would seem they are seperate
* devices because their PortID (ie. JBUS ID) values are all different
* and thus the registers are mapped to totally different locations.
*
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/kernel/apic_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -849,7 +849,7 @@ void __init init_bsp_APIC(void)
/**
* setup_local_APIC - setup the local APIC
*/
void __cpuinit setup_local_APIC(void)
void __devinit setup_local_APIC(void)
{
unsigned long oldvalue, value, maxlvt, integrated;
int i, j;
Expand Down
1 change: 0 additions & 1 deletion trunk/arch/x86/kernel/cpu/intel_cacheinfo.c
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ static struct _cache_table cache_table[] __cpuinitdata =
{ 0x3c, LVL_2, 256 }, /* 4-way set assoc, sectored cache, 64 byte line size */
{ 0x3d, LVL_2, 384 }, /* 6-way set assoc, sectored cache, 64 byte line size */
{ 0x3e, LVL_2, 512 }, /* 4-way set assoc, sectored cache, 64 byte line size */
{ 0x3f, LVL_2, 256 }, /* 2-way set assoc, 64 byte line size */
{ 0x41, LVL_2, 128 }, /* 4-way set assoc, 32 byte line size */
{ 0x42, LVL_2, 256 }, /* 4-way set assoc, 32 byte line size */
{ 0x43, LVL_2, 512 }, /* 4-way set assoc, 32 byte line size */
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/kernel/process_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ static void mwait_idle(void)
mwait_idle_with_hints(0, 0);
}

void __cpuinit select_idle_routine(const struct cpuinfo_x86 *c)
void __devinit select_idle_routine(const struct cpuinfo_x86 *c)
{
if (cpu_has(c, X86_FEATURE_MWAIT)) {
printk("monitor/mwait feature present.\n");
Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/kernel/setup_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
address, and must not be in the .bss segment! */
unsigned long init_pg_tables_end __initdata = ~0UL;

int disable_pse __cpuinitdata = 0;
int disable_pse __devinitdata = 0;

/*
* Machine setup..
Expand Down
6 changes: 3 additions & 3 deletions trunk/arch/x86/kernel/smpboot_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
#include <asm/mtrr.h>

/* Set if we find a B stepping CPU */
static int __cpuinitdata smp_b_stepping;
static int __devinitdata smp_b_stepping;

/* Number of siblings per CPU package */
int smp_num_siblings = 1;
Expand Down Expand Up @@ -745,8 +745,8 @@ static inline int alloc_cpu_id(void)
}

#ifdef CONFIG_HOTPLUG_CPU
static struct task_struct * __cpuinitdata cpu_idle_tasks[NR_CPUS];
static inline struct task_struct * __cpuinit alloc_idle_task(int cpu)
static struct task_struct * __devinitdata cpu_idle_tasks[NR_CPUS];
static inline struct task_struct * alloc_idle_task(int cpu)
{
struct task_struct *idle;

Expand Down
2 changes: 1 addition & 1 deletion trunk/arch/x86/kernel/smpboot_64.c
Original file line number Diff line number Diff line change
Expand Up @@ -141,8 +141,8 @@ static void __cpuinit smp_store_cpu_info(int id)
struct cpuinfo_x86 *c = &cpu_data(id);

*c = boot_cpu_data;
identify_cpu(c);
c->cpu_index = id;
identify_cpu(c);
print_cpu_info(c);
}

Expand Down
7 changes: 4 additions & 3 deletions trunk/arch/x86/kernel/traps_32.c
Original file line number Diff line number Diff line change
Expand Up @@ -373,13 +373,14 @@ void die(const char * str, struct pt_regs * regs, long err)

if (die.lock_owner != raw_smp_processor_id()) {
console_verbose();
raw_local_irq_save(flags);
__raw_spin_lock(&die.lock);
raw_local_save_flags(flags);
die.lock_owner = smp_processor_id();
die.lock_owner_depth = 0;
bust_spinlocks(1);
} else
raw_local_irq_save(flags);
}
else
raw_local_save_flags(flags);

if (++die.lock_owner_depth < 3) {
unsigned long esp;
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/md/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ config DM_MULTIPATH_RDAC

config DM_MULTIPATH_HP
tristate "HP MSA multipath support (EXPERIMENTAL)"
depends on DM_MULTIPATH && BLK_DEV_DM && SCSI && EXPERIMENTAL
depends on DM_MULTIPATH && BLK_DEV_DM && EXPERIMENTAL
---help---
Multipath support for HP MSA (Active/Passive) series hardware.

Expand Down
31 changes: 16 additions & 15 deletions trunk/drivers/md/dm-crypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -398,8 +398,7 @@ static struct bio *crypt_alloc_buffer(struct dm_crypt_io *io, unsigned size)
struct bio *clone;
unsigned int nr_iovecs = (size + PAGE_SIZE - 1) >> PAGE_SHIFT;
gfp_t gfp_mask = GFP_NOIO | __GFP_HIGHMEM;
unsigned i, len;
struct page *page;
unsigned int i;

clone = bio_alloc_bioset(GFP_NOIO, nr_iovecs, cc->bs);
if (!clone)
Expand All @@ -408,8 +407,10 @@ static struct bio *crypt_alloc_buffer(struct dm_crypt_io *io, unsigned size)
clone_init(io, clone);

for (i = 0; i < nr_iovecs; i++) {
page = mempool_alloc(cc->page_pool, gfp_mask);
if (!page)
struct bio_vec *bv = bio_iovec_idx(clone, i);

bv->bv_page = mempool_alloc(cc->page_pool, gfp_mask);
if (!bv->bv_page)
break;

/*
Expand All @@ -420,14 +421,15 @@ static struct bio *crypt_alloc_buffer(struct dm_crypt_io *io, unsigned size)
if (i == (MIN_BIO_PAGES - 1))
gfp_mask = (gfp_mask | __GFP_NOWARN) & ~__GFP_WAIT;

len = (size > PAGE_SIZE) ? PAGE_SIZE : size;

if (!bio_add_page(clone, page, len, 0)) {
mempool_free(page, cc->page_pool);
break;
}
bv->bv_offset = 0;
if (size > PAGE_SIZE)
bv->bv_len = PAGE_SIZE;
else
bv->bv_len = size;

size -= len;
clone->bi_size += bv->bv_len;
clone->bi_vcnt++;
size -= bv->bv_len;
}

if (!clone->bi_size) {
Expand Down Expand Up @@ -509,9 +511,6 @@ static void crypt_endio(struct bio *clone, int error)
struct crypt_config *cc = io->target->private;
unsigned read_io = bio_data_dir(clone) == READ;

if (unlikely(!bio_flagged(clone, BIO_UPTODATE) && !error))
error = -EIO;

/*
* free the processed pages
*/
Expand All @@ -520,8 +519,10 @@ static void crypt_endio(struct bio *clone, int error)
goto out;
}

if (unlikely(error))
if (unlikely(!bio_flagged(clone, BIO_UPTODATE))) {
error = -EIO;
goto out;
}

bio_put(clone);
kcryptd_queue_crypt(io);
Expand Down
12 changes: 7 additions & 5 deletions trunk/drivers/md/dm-ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -332,8 +332,6 @@ static int dm_hash_rename(const char *old, const char *new)
dm_table_put(table);
}

dm_kobject_uevent(hc->md);

dm_put(hc->md);
up_write(&_hash_lock);
kfree(old_name);
Expand Down Expand Up @@ -1252,17 +1250,21 @@ static int target_message(struct dm_ioctl *param, size_t param_size)
if (!table)
goto out_argv;

ti = dm_table_find_target(table, tmsg->sector);
if (!dm_target_is_valid(ti)) {
if (tmsg->sector >= dm_table_get_size(table)) {
DMWARN("Target message sector outside device.");
r = -EINVAL;
} else if (ti->type->message)
goto out_table;
}

ti = dm_table_find_target(table, tmsg->sector);
if (ti->type->message)
r = ti->type->message(ti, argc, argv);
else {
DMWARN("Target type does not support messages");
r = -EINVAL;
}

out_table:
dm_table_put(table);
out_argv:
kfree(argv);
Expand Down
16 changes: 1 addition & 15 deletions trunk/drivers/md/dm-table.c
Original file line number Diff line number Diff line change
Expand Up @@ -99,9 +99,6 @@ static void combine_restrictions_low(struct io_restrictions *lhs,
lhs->max_segment_size =
min_not_zero(lhs->max_segment_size, rhs->max_segment_size);

lhs->max_hw_sectors =
min_not_zero(lhs->max_hw_sectors, rhs->max_hw_sectors);

lhs->seg_boundary_mask =
min_not_zero(lhs->seg_boundary_mask, rhs->seg_boundary_mask);

Expand Down Expand Up @@ -192,10 +189,8 @@ static int alloc_targets(struct dm_table *t, unsigned int num)

/*
* Allocate both the target array and offset array at once.
* Append an empty entry to catch sectors beyond the end of
* the device.
*/
n_highs = (sector_t *) dm_vcalloc(num + 1, sizeof(struct dm_target) +
n_highs = (sector_t *) dm_vcalloc(num, sizeof(struct dm_target) +
sizeof(sector_t));
if (!n_highs)
return -ENOMEM;
Expand Down Expand Up @@ -569,9 +564,6 @@ void dm_set_device_limits(struct dm_target *ti, struct block_device *bdev)
rs->max_segment_size =
min_not_zero(rs->max_segment_size, q->max_segment_size);

rs->max_hw_sectors =
min_not_zero(rs->max_hw_sectors, q->max_hw_sectors);

rs->seg_boundary_mask =
min_not_zero(rs->seg_boundary_mask,
q->seg_boundary_mask);
Expand Down Expand Up @@ -709,8 +701,6 @@ static void check_for_valid_limits(struct io_restrictions *rs)
{
if (!rs->max_sectors)
rs->max_sectors = SAFE_MAX_SECTORS;
if (!rs->max_hw_sectors)
rs->max_hw_sectors = SAFE_MAX_SECTORS;
if (!rs->max_phys_segments)
rs->max_phys_segments = MAX_PHYS_SEGMENTS;
if (!rs->max_hw_segments)
Expand Down Expand Up @@ -877,9 +867,6 @@ struct dm_target *dm_table_get_target(struct dm_table *t, unsigned int index)

/*
* Search the btree for the correct target.
*
* Caller should check returned pointer with dm_target_is_valid()
* to trap I/O beyond end of device.
*/
struct dm_target *dm_table_find_target(struct dm_table *t, sector_t sector)
{
Expand Down Expand Up @@ -909,7 +896,6 @@ void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q)
q->max_hw_segments = t->limits.max_hw_segments;
q->hardsect_size = t->limits.hardsect_size;
q->max_segment_size = t->limits.max_segment_size;
q->max_hw_sectors = t->limits.max_hw_sectors;
q->seg_boundary_mask = t->limits.seg_boundary_mask;
q->bounce_pfn = t->limits.bounce_pfn;
if (t->limits.no_cluster)
Expand Down
31 changes: 7 additions & 24 deletions trunk/drivers/md/dm.c
Original file line number Diff line number Diff line change
Expand Up @@ -672,19 +672,13 @@ static struct bio *clone_bio(struct bio *bio, sector_t sector,
return clone;
}

static int __clone_and_map(struct clone_info *ci)
static void __clone_and_map(struct clone_info *ci)
{
struct bio *clone, *bio = ci->bio;
struct dm_target *ti;
sector_t len = 0, max;
struct dm_target *ti = dm_table_find_target(ci->map, ci->sector);
sector_t len = 0, max = max_io_len(ci->md, ci->sector, ti);
struct dm_target_io *tio;

ti = dm_table_find_target(ci->map, ci->sector);
if (!dm_target_is_valid(ti))
return -EIO;

max = max_io_len(ci->md, ci->sector, ti);

/*
* Allocate a target io object.
*/
Expand Down Expand Up @@ -742,9 +736,6 @@ static int __clone_and_map(struct clone_info *ci)
do {
if (offset) {
ti = dm_table_find_target(ci->map, ci->sector);
if (!dm_target_is_valid(ti))
return -EIO;

max = max_io_len(ci->md, ci->sector, ti);

tio = alloc_tio(ci->md);
Expand All @@ -768,8 +759,6 @@ static int __clone_and_map(struct clone_info *ci)

ci->idx++;
}

return 0;
}

/*
Expand All @@ -778,7 +767,6 @@ static int __clone_and_map(struct clone_info *ci)
static int __split_bio(struct mapped_device *md, struct bio *bio)
{
struct clone_info ci;
int error = 0;

ci.map = dm_get_table(md);
if (unlikely(!ci.map))
Expand All @@ -796,11 +784,11 @@ static int __split_bio(struct mapped_device *md, struct bio *bio)
ci.idx = bio->bi_idx;

start_io_acct(ci.io);
while (ci.sector_count && !error)
error = __clone_and_map(&ci);
while (ci.sector_count)
__clone_and_map(&ci);

/* drop the extra reference count */
dec_pending(ci.io, error);
dec_pending(ci.io, 0);
dm_table_put(ci.map);

return 0;
Expand Down Expand Up @@ -1514,7 +1502,7 @@ int dm_resume(struct mapped_device *md)

dm_table_unplug_all(map);

dm_kobject_uevent(md);
kobject_uevent(&md->disk->kobj, KOBJ_CHANGE);

r = 0;

Expand All @@ -1528,11 +1516,6 @@ int dm_resume(struct mapped_device *md)
/*-----------------------------------------------------------------
* Event notification.
*---------------------------------------------------------------*/
void dm_kobject_uevent(struct mapped_device *md)
{
kobject_uevent(&md->disk->kobj, KOBJ_CHANGE);
}

uint32_t dm_next_uevent_seq(struct mapped_device *md)
{
return atomic_add_return(1, &md->uevent_seq);
Expand Down
7 changes: 0 additions & 7 deletions trunk/drivers/md/dm.h
Original file line number Diff line number Diff line change
Expand Up @@ -112,11 +112,6 @@ int dm_table_resume_targets(struct dm_table *t);
int dm_table_any_congested(struct dm_table *t, int bdi_bits);
void dm_table_unplug_all(struct dm_table *t);

/*
* To check the return value from dm_table_find_target().
*/
#define dm_target_is_valid(t) ((t)->table)

/*-----------------------------------------------------------------
* A registry of target types.
*---------------------------------------------------------------*/
Expand Down Expand Up @@ -187,6 +182,4 @@ union map_info *dm_get_mapinfo(struct bio *bio);
int dm_open_count(struct mapped_device *md);
int dm_lock_for_deletion(struct mapped_device *md);

void dm_kobject_uevent(struct mapped_device *md);

#endif
1 change: 1 addition & 0 deletions trunk/fs/binfmt_aout.c
Original file line number Diff line number Diff line change
Expand Up @@ -319,6 +319,7 @@ static int load_aout_binary(struct linux_binprm * bprm, struct pt_regs * regs)
current->mm->free_area_cache = current->mm->mmap_base;
current->mm->cached_hole_size = 0;

current->mm->mmap = NULL;
compute_creds(bprm);
current->flags &= ~PF_FORKNOEXEC;
#ifdef __sparc__
Expand Down
Loading

0 comments on commit 36ffa68

Please sign in to comment.