Skip to content

Commit

Permalink
Staging: comedi: adv_pci1724: Remove redundant return statements
Browse files Browse the repository at this point in the history
Replace unnecessary conditional checks for variable 'ret' and replace
by single return statement.

Signed-off-by: Abhishek Sharma <asharm14@visteon.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Abhishek Sharma authored and Greg Kroah-Hartman committed Jun 8, 2015
1 parent 51bb618 commit e1f9ae3
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions drivers/staging/comedi/drivers/adv_pci1724.c
Original file line number Diff line number Diff line change
Expand Up @@ -180,11 +180,7 @@ static int adv_pci1724_auto_attach(struct comedi_device *dev,
s->insn_write = adv_pci1724_insn_write;
s->private = (void *)PCI1724_DAC_CTRL_MODE_GAIN;

ret = comedi_alloc_subdev_readback(s);
if (ret)
return ret;

return 0;
return comedi_alloc_subdev_readback(s);
}

static struct comedi_driver adv_pci1724_driver = {
Expand Down

0 comments on commit e1f9ae3

Please sign in to comment.