From 9bacea57f445a2bc199401d1149d6f323c531028 Mon Sep 17 00:00:00 2001 From: H Hartley Sweeten Date: Wed, 4 Mar 2015 12:15:38 -0700 Subject: [PATCH] staging: comedi: ni_pcimio: (!foo) preferred over (foo == NULL) Signed-off-by: H Hartley Sweeten Reviewed-by: Ian Abbott Signed-off-by: Greg Kroah-Hartman --- drivers/staging/comedi/drivers/ni_pcimio.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/staging/comedi/drivers/ni_pcimio.c b/drivers/staging/comedi/drivers/ni_pcimio.c index 3b2bdebbca59..e78739cce175 100644 --- a/drivers/staging/comedi/drivers/ni_pcimio.c +++ b/drivers/staging/comedi/drivers/ni_pcimio.c @@ -1183,19 +1183,19 @@ static int pcimio_auto_attach(struct comedi_device *dev, return ret; devpriv->ai_mite_ring = mite_alloc_ring(devpriv->mite); - if (devpriv->ai_mite_ring == NULL) + if (!devpriv->ai_mite_ring) return -ENOMEM; devpriv->ao_mite_ring = mite_alloc_ring(devpriv->mite); - if (devpriv->ao_mite_ring == NULL) + if (!devpriv->ao_mite_ring) return -ENOMEM; devpriv->cdo_mite_ring = mite_alloc_ring(devpriv->mite); - if (devpriv->cdo_mite_ring == NULL) + if (!devpriv->cdo_mite_ring) return -ENOMEM; devpriv->gpct_mite_ring[0] = mite_alloc_ring(devpriv->mite); - if (devpriv->gpct_mite_ring[0] == NULL) + if (!devpriv->gpct_mite_ring[0]) return -ENOMEM; devpriv->gpct_mite_ring[1] = mite_alloc_ring(devpriv->mite); - if (devpriv->gpct_mite_ring[1] == NULL) + if (!devpriv->gpct_mite_ring[1]) return -ENOMEM; if (devpriv->is_m_series) -- 2.39.5