From: Ben Warren <biggerbadderben@gmail.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/3 v3] Bit-banged MII driver with multi-bus support.
Date: Mon, 05 Oct 2009 13:04:14 -0700 [thread overview]
Message-ID: <4ACA513E.1010208@gmail.com> (raw)
In-Reply-To: <b73e93990910051255k748a84cbw9e9c75d7dd324962@mail.gmail.com>
Hi Luigi,
Luigi Mantellini wrote:
> Hi Ben,
>
> thank for your review. Find my inline comments.
>
> Thanks and best regards,
>
> luigi
>
> On Mon, Oct 5, 2009 at 8:27 AM, Ben Warren <biggerbadderben@gmail.com> wrote:
>
>> Hi Luigi,
>>
>> Luigi 'Comio' Mantellini wrote:
>>
>>> From: Luigi 'Comio' Mantellini <luigi.mantellini@idf-hit.com>
>>>
>>>
>>>
>> Please add some descriptive information here. This is a big patch and
>> deserves a changelong
>>
>>> +
>>> +#define BBMII_RELOATE(v,off) (v += (v?off:0))
>>>
>>>
>> s/RELOATE/RELOCATE/
>>
>> Please apply globally
>>
>
> Ok.
>
>
>>> +
>>> +struct bbmiibus bbmiibusses[] = {
>>>
>>>
>> Elsewhere, you name things 'bb_mii', but here it's 'bbmii'. I personally
>> prefer adding the underscores, but please be consistent.
>>
>
> What do you mean? change bbmiibus -> bb_mii_bus and bbmiibuses -> bb_mii_buses?
>
>
Sure, that would be fine. Consistency is the key.
>>> + {
>>> + .name = BB_MII_DEVNAME,
>>>
>
> BB_MII_DEVNAME will be "bb_mii". is it ok?
>
>
Yes.
>>> + .init = bb_mii_init_wrap,
>>> + .mdio_active = bb_mdio_active_wrap,
>>> + .mdio_tristate = bb_mdio_tristate_wrap,
>>> + .set_mdio = bb_set_mdio_wrap,
>>> + .get_mdio = bb_get_mdio_wrap,
>>> + .set_mdc = bb_set_mdc_wrap,
>>> + .delay = bb_delay_wrap,
>>> + }
>>> +};
>>>
>
>
>>> +#if !defined(CONFIG_RELOC_FIXUP_WORKS)
>>> + /* Reloate the hooks pointers*/
>>>
>>>
>> s/Reloate/Relocate/
>> s/hooks/hook/
>>
>
> ok
>
>
>
>>> */
>>> -static void miiphy_pre (char read, unsigned char addr, unsigned char reg)
>>> +static void miiphy_pre (struct bbmiibus *bus, char read, unsigned char
>>> addr, unsigned char reg)
>>>
>>>
>> This line's too long (please keep < 78 characters). Apply globally
>>
>
> ok
>
>
>>> */
>>> - MDC (0);
>>> - MDIO (0);
>>> - MIIDELAY;
>>>
> ...
>
>>> + bus->set_mdc (bus, 0);
>>> + bus->set_mdio (bus, 0);
>>> + bus->delay(bus);
>>>
>>>
>> Please be consistent with whitespace. I prefer no space before the opening
>> paren, although I think Wolfgang likes that. He's funny that way. Note
>> that this only relates to function calls. Control logic (if, for, while
>> etc.) should always have a space before the opening paren.
>>
>
> I just replaced MD{C,IO} with bus->set_md{c,io}.
> Ok.
>
>
I assumed that's what happened, but now's a good time to clean it up.
Thanks.
>>> +
>>> + bus = bb_miiphy_getbus(devname);
>>> + if (bus == NULL) {
>>> + /* Bus not found! */
>>>
>>>
>> Comment's kinda superfluous...
>>
>
> I know that the source code is always sufficiently clear regard what it does. :)
> ok
>
>
>
>> Thanks for this submission. It's a really big improvement.
>>
>> regards,
>> Ben
>>
>>
>
> I use GPL code on my devices... It obvious that my improvements will
> be shred with community.
>
> thanks again and best regards,
>
> luigi
>
>
regards,
Ben
prev parent reply other threads:[~2009-10-05 20:04 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-09-23 13:10 [U-Boot] [PATCH 0/3 v3] New MIIPHYBB implementation with multi-bus support Luigi 'Comio' Mantellini
2009-09-23 13:10 ` [U-Boot] [PATCH 1/3 v3] Bit-banged MII driver " Luigi 'Comio' Mantellini
2009-09-23 13:10 ` [U-Boot] [PATCH 2/3 v3] Add bb_miiphy_init call before any ethernet bring-up code Luigi 'Comio' Mantellini
2009-09-23 13:10 ` [U-Boot] [PATCH 3/3 v3] Update all board to support new bbmiiphy driver (with multibus support) Luigi 'Comio' Mantellini
2009-10-05 6:34 ` Ben Warren
2009-10-05 6:30 ` [U-Boot] [PATCH 2/3 v3] Add bb_miiphy_init call before any ethernet bring-up code Ben Warren
2009-10-05 20:04 ` Luigi Mantellini
2009-10-05 20:18 ` Ben Warren
2009-10-05 20:35 ` Luigi Mantellini
2009-09-24 12:52 ` [U-Boot] [PATCH 1/3 v3] Bit-banged MII driver with multi-bus support Luigi 'Comio' Mantellini
2009-09-24 13:35 ` Jerry Van Baren
2009-10-05 6:27 ` Ben Warren
2009-10-05 19:55 ` Luigi Mantellini
2009-10-05 20:04 ` Ben Warren [this message]
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=4ACA513E.1010208@gmail.com \
--to=biggerbadderben@gmail.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