[PATCH v2 7/8] staging: bcm2835-audio: Rewrite comparison to NULL

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Fixes checkpatch check "Comparison to NULL could be written '!chip'".

Signed-off-by: Simon Sandström <simon@xxxxxxxxxx>
---
 drivers/staging/bcm2835-audio/bcm2835.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/bcm2835-audio/bcm2835.c b/drivers/staging/bcm2835-audio/bcm2835.c
index de315a1da647..5bdc590dd9c9 100644
--- a/drivers/staging/bcm2835-audio/bcm2835.c
+++ b/drivers/staging/bcm2835-audio/bcm2835.c
@@ -61,7 +61,7 @@ static int snd_bcm2835_create(struct snd_card *card,
 	*rchip = NULL;
 
 	chip = kzalloc(sizeof(*chip), GFP_KERNEL);
-	if (chip == NULL)
+	if (!chip)
 		return -ENOMEM;
 
 	chip->card = card;
-- 
2.11.0

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel




[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux