Skip to content

Commit be1066b

Browse files
committed
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6: Staging: vme: Re-introduce necessary brackets Staging: iio: fix up the iio_get_new_idr_val comment Staging: add Add Sitecom WL-349 to rtl8192su Staging: rt2860: add Belkin F5D8055 Wireless-N USB Dongle device id staging: rtl8192su: add Support for Belkin F5D8053 v6 Staging: dt3155: fix 50Hz configuration staging: usbip: Fix deadlock Staging: rtl8192su: add USB ID for 0bda:8171 Staging: hv: name network device ethX rather than sethX Staging: hv: Fix up memory leak on HvCleanup Staging: hv: Fix a bug affecting IPv6 staging: iio: ring_sw: Fix incorrect test on successful read of last value, causes infinite loop staging: iio: Function iio_get_new_idr_val() return negative value if fails. Staging: iio: adc: fix dangling pointers Staging: iio: light: fix dangling pointers Staging: iio: test for failed allocation staging: iio: lis3l02dq - incorrect ws used in container of call.
2 parents 87156d6 + 4839737 commit be1066b

File tree

14 files changed

+25
-9
lines changed

14 files changed

+25
-9
lines changed

drivers/staging/dt3155/dt3155_drv.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -464,9 +464,9 @@ static void dt3155_init_isr(int minor)
464464
/* 50/60 Hz should be set before this point but let's make sure it is */
465465
/* right anyway */
466466

467-
ReadI2C(dt3155_lbase[ minor ], CONFIG, &i2c_csr2.reg);
467+
ReadI2C(dt3155_lbase[ minor ], CSR2, &i2c_csr2.reg);
468468
i2c_csr2.fld.HZ50 = FORMAT50HZ;
469-
WriteI2C(dt3155_lbase[ minor ], CONFIG, i2c_config.reg);
469+
WriteI2C(dt3155_lbase[ minor ], CSR2, i2c_csr2.reg);
470470

471471
/* enable busmaster chip, clear flags */
472472

drivers/staging/hv/Hv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -306,9 +306,9 @@ void HvCleanup(void)
306306
DPRINT_ENTER(VMBUS);
307307

308308
if (gHvContext.SignalEventBuffer) {
309+
kfree(gHvContext.SignalEventBuffer);
309310
gHvContext.SignalEventBuffer = NULL;
310311
gHvContext.SignalEventParam = NULL;
311-
kfree(gHvContext.SignalEventBuffer);
312312
}
313313

314314
if (gHvContext.HypercallPage) {

drivers/staging/hv/RndisFilter.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -751,6 +751,7 @@ static int RndisFilterOpenDevice(struct rndis_device *Device)
751751

752752
ret = RndisFilterSetPacketFilter(Device,
753753
NDIS_PACKET_TYPE_BROADCAST |
754+
NDIS_PACKET_TYPE_ALL_MULTICAST |
754755
NDIS_PACKET_TYPE_DIRECTED);
755756
if (ret == 0)
756757
Device->State = RNDIS_DEV_DATAINITIALIZED;

drivers/staging/hv/netvsc_drv.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -403,8 +403,7 @@ static int netvsc_probe(struct device *device)
403403
if (!net_drv_obj->Base.OnDeviceAdd)
404404
return -1;
405405

406-
net = alloc_netdev(sizeof(struct net_device_context), "seth%d",
407-
ether_setup);
406+
net = alloc_etherdev(sizeof(struct net_device_context));
408407
if (!net)
409408
return -1;
410409

drivers/staging/iio/accel/lis3l02dq_core.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -618,7 +618,7 @@ static int lis3l02dq_thresh_handler_th(struct iio_dev *dev_info,
618618
static void lis3l02dq_thresh_handler_bh_no_check(struct work_struct *work_s)
619619
{
620620
struct iio_work_cont *wc
621-
= container_of(work_s, struct iio_work_cont, ws_nocheck);
621+
= container_of(work_s, struct iio_work_cont, ws);
622622
struct lis3l02dq_state *st = wc->st;
623623
u8 t;
624624

drivers/staging/iio/accel/lis3l02dq_ring.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -493,6 +493,9 @@ int lis3l02dq_probe_trigger(struct iio_dev *indio_dev)
493493
struct lis3l02dq_state *state = indio_dev->dev_data;
494494

495495
state->trig = iio_allocate_trigger();
496+
if (!state->trig)
497+
return -ENOMEM;
498+
496499
state->trig->name = kmalloc(IIO_TRIGGER_NAME_LENGTH, GFP_KERNEL);
497500
if (!state->trig->name) {
498501
ret = -ENOMEM;

drivers/staging/iio/adc/max1363_core.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -557,6 +557,7 @@ static int __devinit max1363_probe(struct i2c_client *client,
557557
if (!IS_ERR(st->reg))
558558
regulator_put(st->reg);
559559
error_free_st:
560+
i2c_set_clientdata(client, NULL);
560561
kfree(st);
561562

562563
error_ret:
@@ -574,6 +575,7 @@ static int max1363_remove(struct i2c_client *client)
574575
regulator_disable(st->reg);
575576
regulator_put(st->reg);
576577
}
578+
i2c_set_clientdata(client, NULL);
577579
kfree(st);
578580

579581
return 0;

drivers/staging/iio/industrialio-core.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -537,6 +537,7 @@ static void iio_device_unregister_sysfs(struct iio_dev *dev_info)
537537
sysfs_remove_group(&dev_info->dev.kobj, dev_info->attrs);
538538
}
539539

540+
/* Return a negative errno on failure */
540541
int iio_get_new_idr_val(struct idr *this_idr)
541542
{
542543
int ret;
@@ -660,7 +661,7 @@ static int iio_device_register_eventset(struct iio_dev *dev_info)
660661
for (i = 0; i < dev_info->num_interrupt_lines; i++) {
661662
dev_info->event_interfaces[i].owner = dev_info->driver_module;
662663
ret = iio_get_new_idr_val(&iio_event_idr);
663-
if (ret)
664+
if (ret < 0)
664665
goto error_free_setup_ev_ints;
665666
else
666667
dev_info->event_interfaces[i].id = ret;

drivers/staging/iio/light/tsl2563.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -682,6 +682,7 @@ static int __devinit tsl2563_probe(struct i2c_client *client,
682682
fail2:
683683
iio_device_unregister(chip->indio_dev);
684684
fail1:
685+
i2c_set_clientdata(client, NULL);
685686
kfree(chip);
686687
return err;
687688
}
@@ -692,6 +693,7 @@ static int tsl2563_remove(struct i2c_client *client)
692693

693694
iio_device_unregister(chip->indio_dev);
694695

696+
i2c_set_clientdata(client, NULL);
695697
kfree(chip);
696698
return 0;
697699
}

drivers/staging/iio/ring_sw.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ int iio_read_last_from_sw_ring(struct iio_sw_ring_buffer *ring,
293293
return -EAGAIN;
294294
memcpy(data, last_written_p_copy, ring->buf.bpd);
295295

296-
if (unlikely(ring->last_written_p >= last_written_p_copy))
296+
if (unlikely(ring->last_written_p != last_written_p_copy))
297297
goto again;
298298

299299
iio_unmark_sw_rb_in_use(&ring->buf);

drivers/staging/rt2860/usb_main_dev.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ struct usb_device_id rtusb_usb_id[] = {
6363
{USB_DEVICE(0x07D1, 0x3C11)}, /* D-Link */
6464
{USB_DEVICE(0x14B2, 0x3C07)}, /* AL */
6565
{USB_DEVICE(0x050D, 0x8053)}, /* Belkin */
66+
{USB_DEVICE(0x050D, 0x825B)}, /* Belkin */
6667
{USB_DEVICE(0x14B2, 0x3C23)}, /* Airlink */
6768
{USB_DEVICE(0x14B2, 0x3C27)}, /* Airlink */
6869
{USB_DEVICE(0x07AA, 0x002F)}, /* Corega */

drivers/staging/rtl8192su/r8192U_core.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,14 +113,17 @@ u32 rt_global_debug_component = \
113113

114114
static const struct usb_device_id rtl8192_usb_id_tbl[] = {
115115
/* Realtek */
116+
{USB_DEVICE(0x0bda, 0x8171)},
116117
{USB_DEVICE(0x0bda, 0x8192)},
117118
{USB_DEVICE(0x0bda, 0x8709)},
118119
/* Corega */
119120
{USB_DEVICE(0x07aa, 0x0043)},
120121
/* Belkin */
121122
{USB_DEVICE(0x050d, 0x805E)},
123+
{USB_DEVICE(0x050d, 0x815F)}, /* Belkin F5D8053 v6 */
122124
/* Sitecom */
123125
{USB_DEVICE(0x0df6, 0x0031)},
126+
{USB_DEVICE(0x0df6, 0x004b)}, /* WL-349 */
124127
/* EnGenius */
125128
{USB_DEVICE(0x1740, 0x9201)},
126129
/* Dlink */

drivers/staging/usbip/usbip_event.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -117,6 +117,9 @@ void usbip_stop_eh(struct usbip_device *ud)
117117
{
118118
struct usbip_task *eh = &ud->eh;
119119

120+
if (eh->thread == current)
121+
return; /* do not wait for myself */
122+
120123
wait_for_completion(&eh->thread_done);
121124
usbip_dbg_eh("usbip_eh has finished\n");
122125
}

drivers/staging/vme/bridges/vme_tsi148.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2455,9 +2455,10 @@ static int tsi148_probe(struct pci_dev *pdev, const struct pci_device_id *id)
24552455
dev_info(&pdev->dev, "VME Write and flush and error check is %s\n",
24562456
err_chk ? "enabled" : "disabled");
24572457

2458-
if (tsi148_crcsr_init(tsi148_bridge, pdev))
2458+
if (tsi148_crcsr_init(tsi148_bridge, pdev)) {
24592459
dev_err(&pdev->dev, "CR/CSR configuration failed.\n");
24602460
goto err_crcsr;
2461+
}
24612462

24622463
retval = vme_register_bridge(tsi148_bridge);
24632464
if (retval != 0) {

0 commit comments

Comments
 (0)