staging: comedi: ni_labpc: remove unnecessary private data validation

The labpc_free_dma_chan() function validates the private data. Remove the
unnecessary validation in labpc_datach().

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
H Hartley Sweeten 2015-01-21 15:11:46 -07:00 committed by Greg Kroah-Hartman
parent 67a0149ee6
commit aae59483bc

View File

@ -104,11 +104,7 @@ static int labpc_attach(struct comedi_device *dev, struct comedi_devconfig *it)
static void labpc_detach(struct comedi_device *dev)
{
struct labpc_private *devpriv = dev->private;
if (devpriv)
labpc_free_dma_chan(dev);
labpc_free_dma_chan(dev);
comedi_legacy_detach(dev);
}