From: Amit Virdi <amit.virdi@st.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 5/7] net/designware: Try configuring phy on each dw_eth_init
Date: Tue, 6 Mar 2012 09:51:48 +0530 [thread overview]
Message-ID: <4F5590DC.2040107@st.com> (raw)
In-Reply-To: <20120305190517.68366202D68@gemini.denx.de>
Dear Wonfgang,
On 3/6/2012 12:35 AM, Wolfgang Denk wrote:
> Dear Amit Virdi,
>
> In message<4F54AF08.1030003@st.com> you wrote:
>>
>> Surprisingly, I could still not find "true" and "false" defined for ARM
>> architecture or in a common file that I can include. Here's what grep
>> gives me
>
> So don't use these.
>
> In theory, any use of #define TRUE / FALSE or enum bool or plain use
> of raw 0 and 1 is fine - but only as long as you make sure to use this
> consistently within the whole project.
>
> If I am forced to use something like this, I prefer the enum as this
> can be decoded by a debugger. But in general, I try to avod it, and
> use plain C logic instead - because then I can just read and
> understand the code, in all other cases I have to look up definitions,
> especially when it comes to parameter passings.
>
> In your specific case, you use TRUE and FALSE just in one single
> place, for one single variable. Dumpt that. Use 0 and 1, and
> everybody can read the code.
>
Thanks for explaining so well. I shall be sending V2 incorporating your
suggestion.
Best Regards
Amit Virdi
next prev parent reply other threads:[~2012-03-06 4:21 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-29 10:37 [U-Boot] [PATCH 0/7] net/designware: Bug fixes Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 1/7] net/designware: Fix to restore hw mac address Amit Virdi
2012-02-29 19:09 ` Mike Frysinger
2012-03-02 11:27 ` Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 2/7] net/designware: Fix the max frame length size Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 3/7] net/designware: Phy address fix Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 4/7] net/designware: Consecutive writes must have delay Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 5/7] net/designware: Try configuring phy on each dw_eth_init Amit Virdi
2012-02-29 19:11 ` Mike Frysinger
2012-03-02 11:40 ` Amit Virdi
2012-03-02 18:38 ` Mike Frysinger
2012-03-05 12:18 ` Amit Virdi
2012-03-05 19:05 ` Wolfgang Denk
2012-03-06 4:21 ` Amit Virdi [this message]
2012-02-29 10:37 ` [U-Boot] [PATCH 6/7] net/designware: Program phy registers when auto-negotiation is ON Amit Virdi
2012-02-29 10:37 ` [U-Boot] [PATCH 7/7] net/designware: Set ANAR to 0x1e1 Amit Virdi
2012-03-07 9:49 ` [U-Boot] [PATCH 0/7] net/designware: Bug fixes Amit Virdi
2012-03-07 9:55 ` Stefan Roese
2012-03-07 10:05 ` Amit Virdi
2012-03-07 12:15 ` Amit Virdi
2012-03-07 12:36 ` Wolfgang Denk
2012-03-07 16:10 ` Joe Hershberger
2012-03-08 10:55 ` Wolfgang Denk
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=4F5590DC.2040107@st.com \
--to=amit.virdi@st.com \
--cc=u-boot@lists.denx.de \
/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