From: Andi Kleen <ak@muc.de>
To: Luben Tuikov <luben_tuikov@adaptec.com>
Cc: linux-scsi@vger.kernel.org
Subject: Re: [ANNOUNCE] Adaptec SAS/SATA device driver [17/27]
Date: Thu, 17 Feb 2005 22:08:27 +0100 [thread overview]
Message-ID: <m14qgadhdg.fsf@muc.de> (raw)
In-Reply-To: <4214D645.60709@adaptec.com> (Luben Tuikov's message of "Thu, 17 Feb 2005 12:37:09 -0500")
Luben Tuikov <luben_tuikov@adaptec.com> writes:
> +/********************************** Misc Macros *******************************/
[... lots of code...]
What are they all good for? As far as I can see every one of them
duplicates or wraps something Linux already has.
How about you just use the native Linux functions directly?
+
> +#if KDB_ENABLE
> +#define ASSERT(expression) \
> + if (!(expression)) { \
> + printk("assertion failed: %s, file: %s, line: %d\n", \
> + #expression, __FILE__, __LINE__); \
> + KDB_ENTER(); \
> + }
> +#else
> +#define ASSERT(expression) \
> + if (!(expression)) { \
> + panic("assertion failed: %s, file: %s, line: %d\n", \
> + #expression, __FILE__, __LINE__); \
> + }
> +#endif
That's called BUG_ON in Linux land.
> +#ifndef list_for_each_entry_safe
[...]
Such compat code does not really belong into a 2.6 driver.
> +
> +#define list_move_all(to_list, from_list) \
[...]
And this should be put into list.h
-Andi
next prev parent reply other threads:[~2005-02-17 21:08 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-17 17:37 [ANNOUNCE] Adaptec SAS/SATA device driver [17/27] Luben Tuikov
2005-02-17 21:08 ` Andi Kleen [this message]
2005-02-17 21:16 ` Luben Tuikov
2005-02-17 22:03 ` Jeff Garzik
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=m14qgadhdg.fsf@muc.de \
--to=ak@muc.de \
--cc=linux-scsi@vger.kernel.org \
--cc=luben_tuikov@adaptec.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.