mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-09 13:43:21 -04:00
staging: comedi: ni_mio_common: ni_gpct_device_destroy() can handle a NULL pointer
Remove the unnecessary NULL pointer check. 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:
committed by
Greg Kroah-Hartman
parent
bed05b6c34
commit
99307a69bf
@@ -5675,8 +5675,6 @@ static void mio_common_detach(struct comedi_device *dev)
|
||||
{
|
||||
struct ni_private *devpriv = dev->private;
|
||||
|
||||
if (devpriv) {
|
||||
if (devpriv->counter_dev)
|
||||
ni_gpct_device_destroy(devpriv->counter_dev);
|
||||
}
|
||||
if (devpriv)
|
||||
ni_gpct_device_destroy(devpriv->counter_dev);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user