From: Paul Sokolovsky <pmiscml@gmail.com>
To: Borislav Petkov <bbpetkov@yahoo.de>
Cc: bzolnier@gmail.com, linux-ide@vger.kernel.org,
lkml <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] ide.c: microscopic size and readability optimization
Date: Thu, 17 May 2007 14:33:54 +0300 [thread overview]
Message-ID: <1726326841.20070517143354@gmail.com> (raw)
In-Reply-To: <20070517112554.GA32183@zmei.tnic>
Hello Borislav,
Thursday, May 17, 2007, 2:25:54 PM, you wrote:
> -----
> From: bbpetkov@yahoo.de
> A very small size (object file 432 bytes smaller) and readability optimization of ide.c
And how these "optimizations" fit with BUG_ON() purpose - to
be able to easily identify cause and place of the failure? You
could just remove them altogether and claim that you did even "better"
"optimization".
> Signed-off-by: Borislav Petkov <bbpetkov@yahoo.de>
> --
> Index: 22-rc1/drivers/ide/ide.c
> ===================================================================
> --- 22-rc1/drivers/ide/ide.c.orig
> +++ 22-rc1/drivers/ide/ide.c
> @@ -568,10 +568,8 @@ void ide_unregister(unsigned int index)
> ide_hwgroup_t *hwgroup;
> int irq_count = 0, unit;
> - BUG_ON(index >= MAX_HWIFS);
> + BUG_ON(index >= MAX_HWIFS || in_interrupt() || irqs_disabled());
> - BUG_ON(in_interrupt());
> - BUG_ON(irqs_disabled());
> down(&ide_cfg_sem);
--
Best regards,
Paul mailto:pmiscml@gmail.com
next prev parent reply other threads:[~2007-05-17 11:33 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-05-17 11:25 [PATCH] ide.c: microscopic size and readability optimization Borislav Petkov
2007-05-17 11:33 ` Paul Sokolovsky [this message]
2007-05-17 12:06 ` Alan Cox
2007-05-18 8:28 ` Borislav Petkov
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=1726326841.20070517143354@gmail.com \
--to=pmiscml@gmail.com \
--cc=bbpetkov@yahoo.de \
--cc=bzolnier@gmail.com \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/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;
as well as URLs for NNTP newsgroup(s).