Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 353925
b: refs/heads/master
c: 85104e9
h: refs/heads/master
i:
  353923: 8d4da8a
v: v3
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Jan 7, 2013
1 parent 4e4f160 commit 01c373b
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 43bd33f22444868cbc9d4cbec7a3efb0a7c2cb25
refs/heads/master: 85104e9b409013c78624b367dec02e6ccc996635
10 changes: 10 additions & 0 deletions trunk/drivers/staging/comedi/comedi_fops.c
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,16 @@ static DEFINE_SPINLOCK(comedi_file_info_table_lock);
static struct comedi_device_file_info
*comedi_file_info_table[COMEDI_NUM_MINORS];

struct comedi_device *comedi_dev_from_minor(unsigned minor)
{
struct comedi_device_file_info *info;

info = comedi_get_device_file_info(minor);

return info ? info->device : NULL;
}
EXPORT_SYMBOL_GPL(comedi_dev_from_minor);

static struct comedi_subdevice *
comedi_get_read_subdevice(const struct comedi_device_file_info *info)
{
Expand Down
2 changes: 2 additions & 0 deletions trunk/drivers/staging/comedi/comedidev.h
Original file line number Diff line number Diff line change
Expand Up @@ -282,6 +282,8 @@ static const unsigned COMEDI_SUBDEVICE_MINOR_OFFSET = 1;

struct comedi_device_file_info *comedi_get_device_file_info(unsigned minor);

struct comedi_device *comedi_dev_from_minor(unsigned minor);

int comedi_alloc_subdevices(struct comedi_device *, int);

void comedi_device_detach(struct comedi_device *dev);
Expand Down

0 comments on commit 01c373b

Please sign in to comment.