Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

s390: remove unneeded variables

This patch remove unneeded variables used to store return values.

These issues were detected with the Coccinelle script:
scripts/coccinelle/misc/returnvar.cocci

[heiko.carstens@de.ibm.com]: make qeth_l[2/3]_stop() return void

Signed-off-by: Peter Senna Tschudin <peter.senna@gmail.com>
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>

authored by

Peter Senna Tschudin and committed by
Martin Schwidefsky
b2f4de8b 3b974874

+3 -10
+1 -2
drivers/s390/cio/eadm_sch.c
··· 336 336 { 337 337 struct eadm_private *private; 338 338 unsigned long flags; 339 - int ret = 0; 340 339 341 340 spin_lock_irqsave(sch->lock, flags); 342 341 if (!device_is_registered(&sch->dev)) ··· 355 356 out_unlock: 356 357 spin_unlock_irqrestore(sch->lock, flags); 357 358 358 - return ret; 359 + return 0; 359 360 } 360 361 361 362 static struct css_device_id eadm_subchannel_ids[] = {
+1 -4
drivers/s390/net/qeth_l2_main.c
··· 390 390 return rc; 391 391 } 392 392 393 - static int qeth_l2_stop_card(struct qeth_card *card, int recovery_mode) 393 + static void qeth_l2_stop_card(struct qeth_card *card, int recovery_mode) 394 394 { 395 - int rc = 0; 396 - 397 395 QETH_DBF_TEXT(SETUP , 2, "stopcard"); 398 396 QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); 399 397 ··· 425 427 qeth_clear_cmd_buffers(&card->read); 426 428 qeth_clear_cmd_buffers(&card->write); 427 429 } 428 - return rc; 429 430 } 430 431 431 432 static int qeth_l2_process_inbound_buffer(struct qeth_card *card,
+1 -4
drivers/s390/net/qeth_l3_main.c
··· 2158 2158 return card ; 2159 2159 } 2160 2160 2161 - static int qeth_l3_stop_card(struct qeth_card *card, int recovery_mode) 2161 + static void qeth_l3_stop_card(struct qeth_card *card, int recovery_mode) 2162 2162 { 2163 - int rc = 0; 2164 - 2165 2163 QETH_DBF_TEXT(SETUP, 2, "stopcard"); 2166 2164 QETH_DBF_HEX(SETUP, 2, &card, sizeof(void *)); 2167 2165 ··· 2194 2196 qeth_clear_cmd_buffers(&card->read); 2195 2197 qeth_clear_cmd_buffers(&card->write); 2196 2198 } 2197 - return rc; 2198 2199 } 2199 2200 2200 2201 /*