Merge branch 'master' into for-next
Sync with Linus' tree to be able to apply pending patches that are based on newer code already present upstream.
This commit is contained in:
@@ -609,6 +609,7 @@ static int apds990x_detect(struct apds990x_chip *chip)
|
||||
return ret;
|
||||
}
|
||||
|
||||
#if defined(CONFIG_PM) || defined(CONFIG_PM_RUNTIME)
|
||||
static int apds990x_chip_on(struct apds990x_chip *chip)
|
||||
{
|
||||
int err = regulator_bulk_enable(ARRAY_SIZE(chip->regs),
|
||||
@@ -624,6 +625,7 @@ static int apds990x_chip_on(struct apds990x_chip *chip)
|
||||
apds990x_mode_on(chip);
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
static int apds990x_chip_off(struct apds990x_chip *chip)
|
||||
{
|
||||
|
||||
@@ -47,7 +47,7 @@ static uint32_t sg_dwiter_read_buffer(struct sg_mapping_iter *miter)
|
||||
|
||||
static inline bool needs_unaligned_copy(const void *ptr)
|
||||
{
|
||||
#ifdef HAVE_EFFICIENT_UNALIGNED_ACCESS
|
||||
#ifdef CONFIG_HAVE_EFFICIENT_UNALIGNED_ACCESS
|
||||
return false;
|
||||
#else
|
||||
return ((ptr - NULL) & 3) != 0;
|
||||
|
||||
@@ -174,7 +174,7 @@ struct cs5535_mfgpt_timer *cs5535_mfgpt_alloc_timer(int timer_nr, int domain)
|
||||
timer_nr = t < max ? (int) t : -1;
|
||||
} else {
|
||||
/* check if the requested timer's available */
|
||||
if (test_bit(timer_nr, mfgpt->avail))
|
||||
if (!test_bit(timer_nr, mfgpt->avail))
|
||||
timer_nr = -1;
|
||||
}
|
||||
|
||||
|
||||
@@ -270,7 +270,7 @@ ioc4_variant(struct ioc4_driver_data *idd)
|
||||
return IOC4_VARIANT_PCI_RT;
|
||||
}
|
||||
|
||||
static void __devinit
|
||||
static void
|
||||
ioc4_load_modules(struct work_struct *work)
|
||||
{
|
||||
request_module("sgiioc4");
|
||||
|
||||
@@ -120,6 +120,7 @@ static int recur_count = REC_NUM_DEFAULT;
|
||||
static enum cname cpoint = CN_INVALID;
|
||||
static enum ctype cptype = CT_NONE;
|
||||
static int count = DEFAULT_COUNT;
|
||||
static DEFINE_SPINLOCK(count_lock);
|
||||
|
||||
module_param(recur_count, int, 0644);
|
||||
MODULE_PARM_DESC(recur_count, " Recursion level for the stack overflow test, "\
|
||||
@@ -230,11 +231,14 @@ static const char *cp_name_to_str(enum cname name)
|
||||
static int lkdtm_parse_commandline(void)
|
||||
{
|
||||
int i;
|
||||
unsigned long flags;
|
||||
|
||||
if (cpoint_count < 1 || recur_count < 1)
|
||||
return -EINVAL;
|
||||
|
||||
spin_lock_irqsave(&count_lock, flags);
|
||||
count = cpoint_count;
|
||||
spin_unlock_irqrestore(&count_lock, flags);
|
||||
|
||||
/* No special parameters */
|
||||
if (!cpoint_type && !cpoint_name)
|
||||
@@ -349,6 +353,9 @@ static void lkdtm_do_action(enum ctype which)
|
||||
|
||||
static void lkdtm_handler(void)
|
||||
{
|
||||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&count_lock, flags);
|
||||
count--;
|
||||
printk(KERN_INFO "lkdtm: Crash point %s of type %s hit, trigger in %d rounds\n",
|
||||
cp_name_to_str(cpoint), cp_type_to_str(cptype), count);
|
||||
@@ -357,6 +364,7 @@ static void lkdtm_handler(void)
|
||||
lkdtm_do_action(cptype);
|
||||
count = cpoint_count;
|
||||
}
|
||||
spin_unlock_irqrestore(&count_lock, flags);
|
||||
}
|
||||
|
||||
static int lkdtm_register_cpoint(enum cname which)
|
||||
|
||||
@@ -317,7 +317,8 @@ EXPORT_SYMBOL_GPL(pti_request_masterchannel);
|
||||
* a master, channel ID address
|
||||
* used to write to PTI HW.
|
||||
*
|
||||
* @mc: master, channel apeture ID address to be released.
|
||||
* @mc: master, channel apeture ID address to be released. This
|
||||
* will de-allocate the structure via kfree().
|
||||
*/
|
||||
void pti_release_masterchannel(struct pti_masterchannel *mc)
|
||||
{
|
||||
@@ -475,8 +476,10 @@ static int pti_tty_install(struct tty_driver *driver, struct tty_struct *tty)
|
||||
else
|
||||
pti_tty_data->mc = pti_request_masterchannel(2);
|
||||
|
||||
if (pti_tty_data->mc == NULL)
|
||||
if (pti_tty_data->mc == NULL) {
|
||||
kfree(pti_tty_data);
|
||||
return -ENXIO;
|
||||
}
|
||||
tty->driver_data = pti_tty_data;
|
||||
}
|
||||
|
||||
@@ -495,7 +498,7 @@ static void pti_tty_cleanup(struct tty_struct *tty)
|
||||
if (pti_tty_data == NULL)
|
||||
return;
|
||||
pti_release_masterchannel(pti_tty_data->mc);
|
||||
kfree(tty->driver_data);
|
||||
kfree(pti_tty_data);
|
||||
tty->driver_data = NULL;
|
||||
}
|
||||
|
||||
@@ -581,7 +584,7 @@ static int pti_char_open(struct inode *inode, struct file *filp)
|
||||
static int pti_char_release(struct inode *inode, struct file *filp)
|
||||
{
|
||||
pti_release_masterchannel(filp->private_data);
|
||||
kfree(filp->private_data);
|
||||
filp->private_data = NULL;
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
@@ -495,14 +495,14 @@ xpnet_dev_hard_start_xmit(struct sk_buff *skb, struct net_device *dev)
|
||||
}
|
||||
}
|
||||
|
||||
dev->stats.tx_packets++;
|
||||
dev->stats.tx_bytes += skb->len;
|
||||
|
||||
if (atomic_dec_return(&queued_msg->use_count) == 0) {
|
||||
dev_kfree_skb(skb);
|
||||
kfree(queued_msg);
|
||||
}
|
||||
|
||||
dev->stats.tx_packets++;
|
||||
dev->stats.tx_bytes += skb->len;
|
||||
|
||||
return NETDEV_TX_OK;
|
||||
}
|
||||
|
||||
|
||||
@@ -845,7 +845,7 @@ err_iounmap:
|
||||
err_iounmap_app:
|
||||
iounmap(config->va_app_base);
|
||||
err_kzalloc:
|
||||
kfree(config);
|
||||
kfree(target);
|
||||
err_rel_res:
|
||||
release_mem_region(res1->start, resource_size(res1));
|
||||
err_rel_res0:
|
||||
|
||||
@@ -605,7 +605,7 @@ long st_unregister(struct st_proto_s *proto)
|
||||
pr_debug("%s: %d ", __func__, proto->chnl_id);
|
||||
|
||||
st_kim_ref(&st_gdata, 0);
|
||||
if (proto->chnl_id >= ST_MAX_CHANNELS) {
|
||||
if (!st_gdata || proto->chnl_id >= ST_MAX_CHANNELS) {
|
||||
pr_err(" chnl_id %d not supported", proto->chnl_id);
|
||||
return -EPROTONOSUPPORT;
|
||||
}
|
||||
|
||||
@@ -245,9 +245,9 @@ void skip_change_remote_baud(unsigned char **ptr, long *len)
|
||||
pr_err("invalid action after change remote baud command");
|
||||
} else {
|
||||
*ptr = *ptr + sizeof(struct bts_action) +
|
||||
((struct bts_action *)nxt_action)->size;
|
||||
((struct bts_action *)cur_action)->size;
|
||||
*len = *len - (sizeof(struct bts_action) +
|
||||
((struct bts_action *)nxt_action)->size);
|
||||
((struct bts_action *)cur_action)->size);
|
||||
/* warn user on not commenting these in firmware */
|
||||
pr_warn("skipping the wait event of change remote baud");
|
||||
}
|
||||
@@ -604,6 +604,10 @@ void st_kim_ref(struct st_data_s **core_data, int id)
|
||||
struct kim_data_s *kim_gdata;
|
||||
/* get kim_gdata reference from platform device */
|
||||
pdev = st_get_plat_device(id);
|
||||
if (!pdev) {
|
||||
*core_data = NULL;
|
||||
return;
|
||||
}
|
||||
kim_gdata = dev_get_drvdata(&pdev->dev);
|
||||
*core_data = kim_gdata->core_data;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user