+ test_firmware-remove-some-dead-code.patch added to -mm tree

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

 



The patch titled
     Subject: lib/test_firmware.c: remove some dead code
has been added to the -mm tree.  Its filename is
     test_firmware-remove-some-dead-code.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/test_firmware-remove-some-dead-code.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/test_firmware-remove-some-dead-code.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Subject: lib/test_firmware.c: remove some dead code

The test_fw_config->reqs allocation succeeded so these addresses can't be
NULL.  Also on the second error path, we forgot to set "rc = -ENOMEM;".

Link: http://lkml.kernel.org/r/20190221183700.GA1737@kadam
Signed-off-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
Reviewed-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
Cc: "Luis R. Rodriguez" <mcgrof@xxxxxxxxxx>
Cc: Randy Dunlap <rdunlap@xxxxxxxxxxxxx>
Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---


--- a/lib/test_firmware.c~test_firmware-remove-some-dead-code
+++ a/lib/test_firmware.c
@@ -631,11 +631,6 @@ static ssize_t trigger_batched_requests_
 
 	for (i = 0; i < test_fw_config->num_requests; i++) {
 		req = &test_fw_config->reqs[i];
-		if (!req) {
-			WARN_ON(1);
-			rc = -ENOMEM;
-			goto out_bail;
-		}
 		req->fw = NULL;
 		req->idx = i;
 		req->name = test_fw_config->name;
@@ -737,10 +732,6 @@ ssize_t trigger_batched_requests_async_s
 
 	for (i = 0; i < test_fw_config->num_requests; i++) {
 		req = &test_fw_config->reqs[i];
-		if (!req) {
-			WARN_ON(1);
-			goto out_bail;
-		}
 		req->name = test_fw_config->name;
 		req->fw = NULL;
 		req->idx = i;
_

Patches currently in -mm which might be from dan.carpenter@xxxxxxxxxx are

mm-hmm-improve-driver-api-to-work-and-wait-over-a-range-fix.patch
test_firmware-remove-some-dead-code.patch
rapidio-potential-oops-in-riocm_ch_listen.patch




[Index of Archives]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux