Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 264280
b: refs/heads/master
c: cb2d0f3
h: refs/heads/master
v: v3
  • Loading branch information
David Ward authored and David S. Miller committed Oct 5, 2011
1 parent 5a8fbb8 commit c20d324
Show file tree
Hide file tree
Showing 17 changed files with 38 additions and 89 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: 29cf7a30f8a0ce4af2406d93d5a332099be26923
refs/heads/master: cb2d0f3e968bff7c6d262aca3e3ab8d4184e69b2
11 changes: 0 additions & 11 deletions trunk/arch/x86/pci/acpi.c
Original file line number Diff line number Diff line change
Expand Up @@ -43,17 +43,6 @@ static const struct dmi_system_id pci_use_crs_table[] __initconst = {
DMI_MATCH(DMI_PRODUCT_NAME, "ALiveSATA2-GLAN"),
},
},
/* https://bugzilla.kernel.org/show_bug.cgi?id=30552 */
/* 2006 AMD HT/VIA system with two host bridges */
{
.callback = set_use_crs,
.ident = "ASUS M2V-MX SE",
.matches = {
DMI_MATCH(DMI_BOARD_VENDOR, "ASUSTeK Computer INC."),
DMI_MATCH(DMI_BOARD_NAME, "M2V-MX SE"),
DMI_MATCH(DMI_BIOS_VENDOR, "American Megatrends Inc."),
},
},
{}
};

Expand Down
7 changes: 5 additions & 2 deletions trunk/drivers/input/tablet/wacom_wac.c
Original file line number Diff line number Diff line change
Expand Up @@ -1124,8 +1124,11 @@ void wacom_setup_input_capabilities(struct input_dev *input_dev,
for (i = 0; i < 8; i++)
__set_bit(BTN_0 + i, input_dev->keybit);

input_set_abs_params(input_dev, ABS_RX, 0, 4096, 0, 0);
input_set_abs_params(input_dev, ABS_RY, 0, 4096, 0, 0);
if (wacom_wac->features.type != WACOM_21UX2) {
input_set_abs_params(input_dev, ABS_RX, 0, 4096, 0, 0);
input_set_abs_params(input_dev, ABS_RY, 0, 4096, 0, 0);
}

input_set_abs_params(input_dev, ABS_Z, -900, 899, 0, 0);

__set_bit(INPUT_PROP_DIRECT, input_dev->propbit);
Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/md/dm-crypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -1698,8 +1698,6 @@ static int crypt_ctr(struct dm_target *ti, unsigned int argc, char **argv)
}

ti->num_flush_requests = 1;
ti->discard_zeroes_data_unsupported = 1;

return 0;

bad:
Expand Down
4 changes: 1 addition & 3 deletions trunk/drivers/md/dm-flakey.c
Original file line number Diff line number Diff line change
Expand Up @@ -81,10 +81,8 @@ static int parse_features(struct dm_arg_set *as, struct flakey_c *fc,
* corrupt_bio_byte <Nth_byte> <direction> <value> <bio_flags>
*/
if (!strcasecmp(arg_name, "corrupt_bio_byte")) {
if (!argc) {
if (!argc)
ti->error = "Feature corrupt_bio_byte requires parameters";
return -EINVAL;
}

r = dm_read_arg(_args + 1, as, &fc->corrupt_bio_byte, &ti->error);
if (r)
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/md/dm-raid.c
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ static int parse_raid_params(struct raid_set *rs, char **argv,
rs->ti->error = "write_mostly option is only valid for RAID1";
return -EINVAL;
}
if (value >= rs->md.raid_disks) {
if (value > rs->md.raid_disks) {
rs->ti->error = "Invalid write_mostly drive index given";
return -EINVAL;
}
Expand Down
32 changes: 6 additions & 26 deletions trunk/drivers/md/dm-table.c
Original file line number Diff line number Diff line change
Expand Up @@ -1238,15 +1238,14 @@ static void dm_table_set_integrity(struct dm_table *t)
return;

template_disk = dm_table_get_integrity_disk(t, true);
if (template_disk)
blk_integrity_register(dm_disk(t->md),
blk_get_integrity(template_disk));
else if (blk_integrity_is_initialized(dm_disk(t->md)))
if (!template_disk &&
blk_integrity_is_initialized(dm_disk(t->md))) {
DMWARN("%s: device no longer has a valid integrity profile",
dm_device_name(t->md));
else
DMWARN("%s: unable to establish an integrity profile",
dm_device_name(t->md));
return;
}
blk_integrity_register(dm_disk(t->md),
blk_get_integrity(template_disk));
}

static int device_flush_capable(struct dm_target *ti, struct dm_dev *dev,
Expand Down Expand Up @@ -1283,22 +1282,6 @@ static bool dm_table_supports_flush(struct dm_table *t, unsigned flush)
return 0;
}

static bool dm_table_discard_zeroes_data(struct dm_table *t)
{
struct dm_target *ti;
unsigned i = 0;

/* Ensure that all targets supports discard_zeroes_data. */
while (i < dm_table_get_num_targets(t)) {
ti = dm_table_get_target(t, i++);

if (ti->discard_zeroes_data_unsupported)
return 0;
}

return 1;
}

void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q,
struct queue_limits *limits)
{
Expand All @@ -1321,9 +1304,6 @@ void dm_table_set_restrictions(struct dm_table *t, struct request_queue *q,
}
blk_queue_flush(q, flush);

if (!dm_table_discard_zeroes_data(t))
q->limits.discard_zeroes_data = 0;

dm_table_set_integrity(t);

/*
Expand Down
22 changes: 3 additions & 19 deletions trunk/drivers/md/md.c
Original file line number Diff line number Diff line change
Expand Up @@ -61,11 +61,6 @@
static void autostart_arrays(int part);
#endif

/* pers_list is a list of registered personalities protected
* by pers_lock.
* pers_lock does extra service to protect accesses to
* mddev->thread when the mutex cannot be held.
*/
static LIST_HEAD(pers_list);
static DEFINE_SPINLOCK(pers_lock);

Expand Down Expand Up @@ -744,12 +739,7 @@ static void mddev_unlock(mddev_t * mddev)
} else
mutex_unlock(&mddev->reconfig_mutex);

/* was we've dropped the mutex we need a spinlock to
* make sur the thread doesn't disappear
*/
spin_lock(&pers_lock);
md_wakeup_thread(mddev->thread);
spin_unlock(&pers_lock);
}

static mdk_rdev_t * find_rdev_nr(mddev_t *mddev, int nr)
Expand Down Expand Up @@ -6439,18 +6429,11 @@ mdk_thread_t *md_register_thread(void (*run) (mddev_t *), mddev_t *mddev,
return thread;
}

void md_unregister_thread(mdk_thread_t **threadp)
void md_unregister_thread(mdk_thread_t *thread)
{
mdk_thread_t *thread = *threadp;
if (!thread)
return;
dprintk("interrupting MD-thread pid %d\n", task_pid_nr(thread->tsk));
/* Locking ensures that mddev_unlock does not wake_up a
* non-existent thread
*/
spin_lock(&pers_lock);
*threadp = NULL;
spin_unlock(&pers_lock);

kthread_stop(thread->tsk);
kfree(thread);
Expand Down Expand Up @@ -7357,7 +7340,8 @@ static void reap_sync_thread(mddev_t *mddev)
mdk_rdev_t *rdev;

/* resync has finished, collect result */
md_unregister_thread(&mddev->sync_thread);
md_unregister_thread(mddev->sync_thread);
mddev->sync_thread = NULL;
if (!test_bit(MD_RECOVERY_INTR, &mddev->recovery) &&
!test_bit(MD_RECOVERY_REQUESTED, &mddev->recovery)) {
/* success...*/
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/md/md.h
Original file line number Diff line number Diff line change
Expand Up @@ -560,7 +560,7 @@ extern int register_md_personality(struct mdk_personality *p);
extern int unregister_md_personality(struct mdk_personality *p);
extern mdk_thread_t * md_register_thread(void (*run) (mddev_t *mddev),
mddev_t *mddev, const char *name);
extern void md_unregister_thread(mdk_thread_t **threadp);
extern void md_unregister_thread(mdk_thread_t *thread);
extern void md_wakeup_thread(mdk_thread_t *thread);
extern void md_check_recovery(mddev_t *mddev);
extern void md_write_start(mddev_t *mddev, struct bio *bi);
Expand Down
3 changes: 2 additions & 1 deletion trunk/drivers/md/multipath.c
Original file line number Diff line number Diff line change
Expand Up @@ -514,7 +514,8 @@ static int multipath_stop (mddev_t *mddev)
{
multipath_conf_t *conf = mddev->private;

md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
mddev->thread = NULL;
blk_sync_queue(mddev->queue); /* the unplug fn references 'conf'*/
mempool_destroy(conf->pool);
kfree(conf->multipaths);
Expand Down
3 changes: 2 additions & 1 deletion trunk/drivers/md/raid1.c
Original file line number Diff line number Diff line change
Expand Up @@ -2562,7 +2562,8 @@ static int stop(mddev_t *mddev)
raise_barrier(conf);
lower_barrier(conf);

md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
mddev->thread = NULL;
if (conf->r1bio_pool)
mempool_destroy(conf->r1bio_pool);
kfree(conf->mirrors);
Expand Down
5 changes: 3 additions & 2 deletions trunk/drivers/md/raid10.c
Original file line number Diff line number Diff line change
Expand Up @@ -2955,7 +2955,7 @@ static int run(mddev_t *mddev)
return 0;

out_free_conf:
md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
if (conf->r10bio_pool)
mempool_destroy(conf->r10bio_pool);
safe_put_page(conf->tmppage);
Expand All @@ -2973,7 +2973,8 @@ static int stop(mddev_t *mddev)
raise_barrier(conf, 0);
lower_barrier(conf);

md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
mddev->thread = NULL;
blk_sync_queue(mddev->queue); /* the unplug fn references 'conf'*/
if (conf->r10bio_pool)
mempool_destroy(conf->r10bio_pool);
Expand Down
6 changes: 4 additions & 2 deletions trunk/drivers/md/raid5.c
Original file line number Diff line number Diff line change
Expand Up @@ -4941,7 +4941,8 @@ static int run(mddev_t *mddev)

return 0;
abort:
md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
mddev->thread = NULL;
if (conf) {
print_raid5_conf(conf);
free_conf(conf);
Expand All @@ -4955,7 +4956,8 @@ static int stop(mddev_t *mddev)
{
raid5_conf_t *conf = mddev->private;

md_unregister_thread(&mddev->thread);
md_unregister_thread(mddev->thread);
mddev->thread = NULL;
if (mddev->queue)
mddev->queue->backing_dev_info.congested_fn = NULL;
free_conf(conf);
Expand Down
2 changes: 1 addition & 1 deletion trunk/drivers/net/macvlan.c
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ static int macvlan_queue_xmit(struct sk_buff *skb, struct net_device *dev)
dest = macvlan_hash_lookup(port, eth->h_dest);
if (dest && dest->mode == MACVLAN_MODE_BRIDGE) {
/* send to lowerdev first for its network taps */
vlan->forward(vlan->lowerdev, skb);
dev_forward_skb(vlan->lowerdev, skb);

return NET_XMIT_SUCCESS;
}
Expand Down
10 changes: 4 additions & 6 deletions trunk/drivers/scsi/libsas/sas_expander.c
Original file line number Diff line number Diff line change
Expand Up @@ -1769,12 +1769,10 @@ static void sas_unregister_devs_sas_addr(struct domain_device *parent,
sas_disable_routing(parent, phy->attached_sas_addr);
}
memset(phy->attached_sas_addr, 0, SAS_ADDR_SIZE);
if (phy->port) {
sas_port_delete_phy(phy->port, phy->phy);
if (phy->port->num_phys == 0)
sas_port_delete(phy->port);
phy->port = NULL;
}
sas_port_delete_phy(phy->port, phy->phy);
if (phy->port->num_phys == 0)
sas_port_delete(phy->port);
phy->port = NULL;
}

static int sas_discover_bfs_by_root_level(struct domain_device *root,
Expand Down
9 changes: 4 additions & 5 deletions trunk/drivers/scsi/qla2xxx/qla_os.c
Original file line number Diff line number Diff line change
Expand Up @@ -1328,9 +1328,10 @@ qla2x00_abort_all_cmds(scsi_qla_host_t *vha, int res)
qla2x00_sp_compl(ha, sp);
} else {
ctx = sp->ctx;
if (ctx->type == SRB_ELS_CMD_RPT ||
ctx->type == SRB_ELS_CMD_HST ||
ctx->type == SRB_CT_CMD) {
if (ctx->type == SRB_LOGIN_CMD ||
ctx->type == SRB_LOGOUT_CMD) {
ctx->u.iocb_cmd->free(sp);
} else {
struct fc_bsg_job *bsg_job =
ctx->u.bsg_job;
if (bsg_job->request->msgcode
Expand All @@ -1342,8 +1343,6 @@ qla2x00_abort_all_cmds(scsi_qla_host_t *vha, int res)
kfree(sp->ctx);
mempool_free(sp,
ha->srb_mempool);
} else {
ctx->u.iocb_cmd->free(sp);
}
}
}
Expand Down
5 changes: 0 additions & 5 deletions trunk/include/linux/device-mapper.h
Original file line number Diff line number Diff line change
Expand Up @@ -197,11 +197,6 @@ struct dm_target {
* whether or not its underlying devices have support.
*/
unsigned discards_supported:1;

/*
* Set if this target does not return zeroes on discarded blocks.
*/
unsigned discard_zeroes_data_unsupported:1;
};

/* Each target can link one of these into the table */
Expand Down

0 comments on commit c20d324

Please sign in to comment.