From: david.vanhoose@comcast.net (David van Hoose)
To: lm-sensors@vger.kernel.org
Subject: [lm-sensors] [PATCH 2.6] I2C: Rewrite i2c_probe
Date: Tue, 09 Aug 2005 22:59:38 +0000 [thread overview]
Message-ID: <42F9190E.20405@comcast.net> (raw)
In-Reply-To: <20050809201755.15962b81.khali@linux-fr.org>
Hi Jean,
From places like below (a snippet from your patch). You use 0 instead
of preprocessor tokens. It is also this way in various other places in
the i2c core code.
// Snippet of i2c_probe_addresses
+ /* Make sure there is something at this address, unless forced */
+ if (kind < 0
+ && i2c_smbus_xfer(adapter, addr, 0, 0, 0, I2C_SMBUS_QUICK, NULL) < 0)
+ return 0;
+
+ /* Finally call the custom detection function */
+ err = found_proc(adapter, addr, kind);
// Snippet end
IMHO it would make the code a bit less obfuscated.
I can get a patch done by tonight against 2.6.12.4 unless you have
another source I should try.
Thanks,
David van Hoose
Jean Delvare wrote:
> Hi David,
>
>
>>Would it be appreciated if I went through the code and changed the
>>hardcoded integer constants to actual preprocessor tokens?
>
>
> What hardcoded integer constants are you talking about?
>
next prev parent reply other threads:[~2005-08-09 22:59 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-09 20:18 [lm-sensors] [PATCH 2.6] I2C: Rewrite i2c_probe Jean Delvare
2005-08-09 20:36 ` David van Hoose
2005-08-09 21:29 ` Jean Delvare
2005-08-09 22:25 ` Jean Delvare
2005-08-09 22:59 ` David van Hoose [this message]
2005-08-09 23:31 ` Jean Delvare
2005-08-10 0:03 ` David van Hoose
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=42F9190E.20405@comcast.net \
--to=david.vanhoose@comcast.net \
--cc=lm-sensors@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 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.