Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 259998
b: refs/heads/master
c: 0435f93
h: refs/heads/master
v: v3
  • Loading branch information
Pavel Roskin authored and Greg Kroah-Hartman committed Jul 6, 2011
1 parent f20eaf8 commit 5254ff4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 11 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: 7104b5df5b2e53ef864e94556c1b3f63f6a56b70
refs/heads/master: 0435f9337f051db77b4eaf02eee83e7a29f3474a
12 changes: 5 additions & 7 deletions trunk/drivers/staging/comedi/comedi_fops.c
Original file line number Diff line number Diff line change
Expand Up @@ -2175,9 +2175,8 @@ int comedi_alloc_board_minor(struct device *hardware_device)
return -EBUSY;
}
info->device->minor = i;
csdev = COMEDI_DEVICE_CREATE(comedi_class, NULL,
MKDEV(COMEDI_MAJOR, i), NULL,
hardware_device, "comedi%i", i);
csdev = device_create(comedi_class, hardware_device,
MKDEV(COMEDI_MAJOR, i), NULL, "comedi%i", i);
if (!IS_ERR(csdev))
info->device->class_dev = csdev;
dev_set_drvdata(csdev, info);
Expand Down Expand Up @@ -2276,10 +2275,9 @@ int comedi_alloc_subdevice_minor(struct comedi_device *dev,
return -EBUSY;
}
s->minor = i;
csdev = COMEDI_DEVICE_CREATE(comedi_class, dev->class_dev,
MKDEV(COMEDI_MAJOR, i), NULL, NULL,
"comedi%i_subd%i", dev->minor,
(int)(s - dev->subdevices));
csdev = device_create(comedi_class, dev->class_dev,
MKDEV(COMEDI_MAJOR, i), NULL, "comedi%i_subd%i",
dev->minor, (int)(s - dev->subdevices));
if (!IS_ERR(csdev))
s->class_dev = csdev;
dev_set_drvdata(csdev, info);
Expand Down
3 changes: 0 additions & 3 deletions trunk/drivers/staging/comedi/comedidev.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,6 @@
#define COMEDI_NUM_BOARD_MINORS 0x30
#define COMEDI_FIRST_SUBDEVICE_MINOR COMEDI_NUM_BOARD_MINORS

#define COMEDI_DEVICE_CREATE(cs, parent, devt, drvdata, device, fmt...) \
device_create(cs, ((parent) ? (parent) : (device)), devt, drvdata, fmt)

struct comedi_subdevice {
struct comedi_device *device;
int type;
Expand Down

0 comments on commit 5254ff4

Please sign in to comment.