Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 364095
b: refs/heads/master
c: 7a1e1f9
h: refs/heads/master
i:
  364093: 2956166
  364091: b46b6a4
  364087: a58ea4c
  364079: 050b497
  364063: df67254
  364031: c52d921
v: v3
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Apr 11, 2013
1 parent 85d18e9 commit 707dbb3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 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: 6bb3395e4b1f497030ea14103ab110e33e1eabd8
refs/heads/master: 7a1e1f9ae5f15026126f09311b158d6673ad8200
9 changes: 5 additions & 4 deletions trunk/drivers/staging/comedi/drivers/ni_labpc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1616,8 +1616,6 @@ int labpc_common_attach(struct comedi_device *dev, unsigned long iobase,
int ret;
int i;

dev->board_name = board->name;

if (iobase == 0)
return -EINVAL;
if (board->bustype == isa_bustype) {
Expand Down Expand Up @@ -1831,6 +1829,7 @@ static int labpc_auto_attach(struct comedi_device *dev,
unsigned long context_unused)
{
struct pci_dev *pcidev = comedi_to_pci_dev(dev);
const struct labpc_boardinfo *board;
struct labpc_private *devpriv;
unsigned long iobase;
unsigned int irq;
Expand All @@ -1848,9 +1847,11 @@ static int labpc_auto_attach(struct comedi_device *dev,
return -ENOMEM;
dev->private = devpriv;

dev->board_ptr = labpc_pci_find_boardinfo(pcidev);
if (!dev->board_ptr)
board = labpc_pci_find_boardinfo(pcidev);
if (!board)
return -ENODEV;
dev->board_ptr = board;
dev->board_name = board->name;
devpriv->mite = mite_alloc(pcidev);
if (!devpriv->mite)
return -ENOMEM;
Expand Down

0 comments on commit 707dbb3

Please sign in to comment.