Skip to contentSkip to conversation

drivers:staging:gdm724x Fix comparison to NULL could be written like

PATCH In review Bogicevic Sasa 2 participants 3 messages Oct 30, 2015 – Oct 31, 2015 Staging

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drivers:staging:gdm724x Fix comparison to NULL could be written like

This fixes all messages from checkpatch.pl about comparison to NULL could be written according to coding style preferences

---
 drivers/staging/gdm724x/gdm_mux.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/gdm724x/gdm_mux.c +2 -2
index e416012..c70e8b8 100644
@@ -489,7 +489,7 @@ static int init_usb(struct mux_dev *mux_dev)
 
 	for (i = 0; i < MAX_ISSUE_NUM * 2; i++) {
 		r = alloc_mux_rx();
-		if (r == NULL) {
+		if (!r) {
 			ret = -ENOMEM;
 			break;
 		}
@@ -657,7 +657,7 @@ static struct usb_driver gdm_mux_driver = {
 static int __init gdm_usb_mux_init(void)
 {
 	mux_rx_wq = create_workqueue("mux_rx_wq");
-	if (mux_rx_wq == NULL) {
+	if (!mux_rx_wq) {
 		pr_err("work queue create fail\n");
 		return -1;
 	}
Signature · 1 line
2.1.4
#1 lore raw
Quoted 5 lines · Bogicevic Sasa

This fixes all messages from checkpatch.pl about comparison to NULL could be written according to coding style preferences

---

For all your next patches, either they have already deen done or they will not apply because of some other change in that part.

Are you still using the stable tree?

regards
sudip

#2 lore raw
Quoted 7 lines · Sudip Mukherjee
Quoted 5 lines · Bogicevic Sasa

This fixes all messages from checkpatch.pl about comparison to NULL could be written according to coding style preferences

---

Quoted 7 lines

For all your next patches, either they have already deen done or they will not apply because of some other change in that part.

Are you still using the stable tree?

regards
sudip

Not a lot of work but all for nothing :) I cloned staging but didn't switch to staging-testing branch :( No worries I will start again, Thanks!