Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 268150
b: refs/heads/master
c: 9019309
h: refs/heads/master
v: v3
  • Loading branch information
Jonathan Cameron authored and Greg Kroah-Hartman committed Sep 6, 2011
1 parent f9478e9 commit 6863d44
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 29 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: 47c24fdd4253a2c8d730b978a186923b1af5e879
refs/heads/master: 9019309c2f32a4479c88047532552bdeea38585a
10 changes: 0 additions & 10 deletions trunk/drivers/staging/iio/iio_core.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,6 @@
#ifndef _IIO_CORE_H_
#define _IIO_CORE_H_

/**
* iio_put() - internal module reference count reduce
**/
void iio_put(void);

/**
* iio_get() - internal module reference count increase
**/
void iio_get(void);

int __iio_add_chan_devattr(const char *postfix,
const char *group,
struct iio_chan_spec const *chan,
Expand Down
17 changes: 1 addition & 16 deletions trunk/drivers/staging/iio/industrialio-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1018,7 +1018,6 @@ static void iio_dev_release(struct device *device)
{
struct iio_dev *dev_info = container_of(device, struct iio_dev, dev);
cdev_del(&dev_info->chrdev);
iio_put();
kfree(dev_info);
}

Expand Down Expand Up @@ -1048,7 +1047,6 @@ struct iio_dev *iio_allocate_device(int sizeof_priv)
device_initialize(&dev->dev);
dev_set_drvdata(&dev->dev, (void *)dev);
mutex_init(&dev->mlock);
iio_get();
}

return dev;
Expand All @@ -1057,10 +1055,8 @@ EXPORT_SYMBOL(iio_allocate_device);

void iio_free_device(struct iio_dev *dev)
{
if (dev) {
iio_put();
if (dev)
kfree(dev);
}
}
EXPORT_SYMBOL(iio_free_device);

Expand Down Expand Up @@ -1173,17 +1169,6 @@ void iio_device_unregister(struct iio_dev *dev_info)
device_unregister(&dev_info->dev);
}
EXPORT_SYMBOL(iio_device_unregister);

void iio_put(void)
{
module_put(THIS_MODULE);
}

void iio_get(void)
{
__module_get(THIS_MODULE);
}

subsys_initcall(iio_init);
module_exit(iio_exit);

Expand Down
2 changes: 0 additions & 2 deletions trunk/drivers/staging/iio/industrialio-trigger.c
Original file line number Diff line number Diff line change
Expand Up @@ -394,7 +394,6 @@ static void iio_trig_release(struct device *device)
}
kfree(trig->name);
kfree(trig);
iio_put();
}

static struct device_type iio_trig_type = {
Expand Down Expand Up @@ -461,7 +460,6 @@ struct iio_trigger *iio_allocate_trigger(const char *fmt, ...)
IRQ_NOREQUEST | IRQ_NOAUTOEN,
IRQ_NOPROBE);
}
iio_get();
get_device(&trig->dev);
}
return trig;
Expand Down

0 comments on commit 6863d44

Please sign in to comment.