summaryrefslogtreecommitdiff
path: root/include/linux/root_dev.h
diff options
context:
space:
mode:
authorIan Abbott <abbotti@mev.co.uk>2013-11-08 15:03:33 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-11-11 16:16:44 -0800
commitb449c1cad7e3acf80834d4bdb1b6241d5d8dd249 (patch)
treeb02f278cb85f0b6f98b998b448c3e5ae97a8cde7 /include/linux/root_dev.h
parent5b13ed94a7d24fdc8abbac81e7e4d30ab22c6540 (diff)
staging: comedi: add comedi_dev_get_from_minor()
Add function `struct comedi_device *comedi_dev_get_from_minor(unsigned minor)`. This behaves like the existing `comedi_dev_from_minor()` except that it also increments the `struct kref refcount` member (via new helper function `comedi_dev_get()`) to prevent it being freed. If it returns a valid pointer, the caller is responsible for calling `comedi_dev_put()` to decrement the reference count. Export `comedi_dev_get_from_minor()` and `comedi_dev_put()` as they will be used by the "kcomedilib" module in addition to the "comedi" module itself. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/root_dev.h')
0 files changed, 0 insertions, 0 deletions