From: Doug Ledford <dledford@redhat.com>
To: Igor Stoppa <igor.stoppa@gmail.com>, linux-kernel@vger.kernel.org
Cc: Igor Stoppa <igor.stoppa@huawei.com>,
Chien Tung <chien.tin.tung@intel.com>,
Roland Dreier <rolandd@cisco.com>,
Faisal Latif <faisal.latif@intel.com>,
Jason Gunthorpe <jgg@ziepe.ca>
Subject: Re: [PATCH 01/23] infiniband: nes: add unlikely() to assert()
Date: Fri, 31 Aug 2018 10:06:59 -0400 [thread overview]
Message-ID: <ffe6f38e96c0d84326e2d853e2aa8e9b87b8b9f1.camel@redhat.com> (raw)
In-Reply-To: <20180830223429.30051-2-igor.stoppa@huawei.com>
[-- Attachment #1: Type: text/plain, Size: 1140 bytes --]
On Fri, 2018-08-31 at 01:34 +0300, Igor Stoppa wrote:
> Typically the assert is expected to not fail.
>
> Signed-off-by: Igor Stoppa <igor.stoppa@huawei.com>
> Cc: Chien Tung <chien.tin.tung@intel.com>
> Cc: Roland Dreier <rolandd@cisco.com>
> Cc: Faisal Latif <faisal.latif@intel.com>
> Cc: Doug Ledford <dledford@redhat.com>
> Cc: Jason Gunthorpe <jgg@ziepe.ca>
Acked-by: Doug Ledford <dledford@redhat.com>
> ---
> drivers/infiniband/hw/nes/nes.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/infiniband/hw/nes/nes.h b/drivers/infiniband/hw/nes/nes.h
> index bedaa02749fb..d2d0098f38e0 100644
> --- a/drivers/infiniband/hw/nes/nes.h
> +++ b/drivers/infiniband/hw/nes/nes.h
> @@ -151,7 +151,7 @@ do { \
>
> #define assert(expr) \
> do { \
> - if (!(expr)) { \
> + if (unlikely(!(expr))) { \
> printk(KERN_ERR PFX "Assertion failed! %s, %s, %s, line %d\n", \
> #expr, __FILE__, __func__, __LINE__); \
> } \
--
Doug Ledford <dledford@redhat.com>
GPG KeyID: B826A3330E572FDD
Key fingerprint = AE6B 1BDA 122B 23B4 265B 1274 B826 A333 0E57 2FDD
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 833 bytes --]
next prev parent reply other threads:[~2018-08-31 14:07 UTC|newest]
Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <20180830223429.30051-1-igor.stoppa@huawei.com>
2018-08-30 22:34 ` Igor Stoppa
2018-08-31 14:06 ` Doug Ledford [this message]
2018-08-30 22:34 ` [PATCH 02/23] ethernet: hnae: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 03/23] asm-generic: bug: add unlikely() to BUG_ON() Igor Stoppa
2018-08-30 22:34 ` [PATCH 04/23] mips: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 05/23] selftest: vm: " Igor Stoppa
2018-08-30 22:57 ` Dmitry Safonov
2018-08-30 23:04 ` Dmitry Safonov
2018-08-31 21:25 ` Igor Stoppa
2018-08-30 22:34 ` [PATCH 06/23] virtio: add unlikely() to WARN_ON_ONCE() Igor Stoppa
2018-08-30 22:34 ` [PATCH 07/23] seccomp: remove unnecessary unlikely() Igor Stoppa
2018-09-02 21:26 ` Kees Cook
2018-08-30 22:34 ` [PATCH 08/23] drm: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 09/23] cpufreq: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 10/23] wireless: " Igor Stoppa
2018-08-31 9:52 ` Kalle Valo
2018-08-31 13:44 ` Igor Stoppa
2018-08-30 22:34 ` [PATCH 11/23] " Igor Stoppa
2018-08-30 22:34 ` [PATCH 12/23] " Igor Stoppa
2018-08-30 22:34 ` [PATCH 13/23] freescale: ethernet: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 14/23] wimax: i2400m: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 15/23] lvm: device mapper: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 16/23] " Igor Stoppa
2018-08-30 22:34 ` [PATCH 17/23] usb: octeon-hcd: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 18/23] infiniband: scsi: " Igor Stoppa
2018-08-30 22:53 ` Bart Van Assche
2018-08-30 22:34 ` [PATCH 19/23] pinctrl: " Igor Stoppa
2018-08-31 9:29 ` Linus Walleij
2018-08-30 22:34 ` [PATCH 20/23] mm: percpu: " Igor Stoppa
2018-08-31 1:58 ` Dennis Zhou
2018-08-30 22:34 ` [PATCH 21/23] filesystems: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 22/23] powerpc: " Igor Stoppa
2018-08-30 22:34 ` [PATCH 23/23] scsi: " Igor Stoppa
2018-08-31 14:09 ` [PATCH 00/23] Make use of unlikely() more consistently Arnd Bergmann
2018-08-31 20:35 ` Igor Stoppa
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=ffe6f38e96c0d84326e2d853e2aa8e9b87b8b9f1.camel@redhat.com \
--to=dledford@redhat.com \
--cc=chien.tin.tung@intel.com \
--cc=faisal.latif@intel.com \
--cc=igor.stoppa@gmail.com \
--cc=igor.stoppa@huawei.com \
--cc=jgg@ziepe.ca \
--cc=linux-kernel@vger.kernel.org \
--cc=rolandd@cisco.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®