Browse Source

dmaengine: bcm-scm-raid: remove redundant null check on req

Req is never null on at the point of the null check, so
remove this redundant check and just return &req->tx.

Detected by CoverityScan, CID#1436147 ("Logically dead code")

Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Colin Ian King 8 years ago
parent
commit
1fc63cb4f1
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/dma/bcm-sba-raid.c

+ 1 - 1
drivers/dma/bcm-sba-raid.c

@@ -582,7 +582,7 @@ sba_prep_dma_interrupt(struct dma_chan *dchan, unsigned long flags)
 	req->tx.flags = flags;
 	req->tx.flags = flags;
 	req->tx.cookie = -EBUSY;
 	req->tx.cookie = -EBUSY;
 
 
-	return (req) ? &req->tx : NULL;
+	return &req->tx;
 }
 }
 
 
 static void sba_fillup_memcpy_msg(struct sba_request *req,
 static void sba_fillup_memcpy_msg(struct sba_request *req,