Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1239039

[PATCH 1/3] scsi: drop unlikely behind BUG_ON()

From Geliang Tang <geliangtang@163.com>
Newsgroups linux.kernel
Subject [PATCH 1/3] scsi: drop unlikely behind BUG_ON()
Date 2015-10-04 08:20 +0200
Message-ID <qfKOl-uJ-3@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


BUG_ON() already contain an unlikely compiler flag. Drop it.

Signed-off-by: Geliang Tang <geliangtang@163.com>
---
 drivers/scsi/scsi_lib.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/scsi_lib.c b/drivers/scsi/scsi_lib.c
index f570b48..3b5faab 100644
--- a/drivers/scsi/scsi_lib.c
+++ b/drivers/scsi/scsi_lib.c
@@ -1164,8 +1164,8 @@ int scsi_init_io(struct scsi_cmnd *cmd)
 
 		count = blk_rq_map_integrity_sg(rq->q, rq->bio,
 						prot_sdb->table.sgl);
-		BUG_ON(unlikely(count > ivecs));
-		BUG_ON(unlikely(count > queue_max_integrity_segments(rq->q)));
+		BUG_ON(count > ivecs);
+		BUG_ON(count > queue_max_integrity_segments(rq->q));
 
 		cmd->prot_sdb = prot_sdb;
 		cmd->prot_sdb->table.nents = count;
-- 
2.5.0


--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextNext in thread | Find similar | Unroll thread


Thread

[PATCH 1/3] scsi: drop unlikely behind BUG_ON() Geliang Tang <geliangtang@163.com> - 2015-10-04 08:20 +0200
  [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Geliang Tang <geliangtang@163.com> - 2015-10-04 08:20 +0200
    Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Leon Romanovsky <leon@leon.nu> - 2015-10-04 13:10 +0200
      Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-05 04:10 +0200
        Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Leon Romanovsky <leon@leon.nu> - 2015-10-05 10:00 +0200
    Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-05 04:00 +0200
      Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Geliang Tang <geliangtang@163.com> - 2015-10-05 04:40 +0200
        Re: [PATCH 3/3] mm/nommu: drop unlikely behind BUG_ON() Davidlohr Bueso <dave@stgolabs.net> - 2015-10-05 05:40 +0200

csiph-web