* [U-Boot-Users] [PATCH] mpc5200 without fec
@ 2008-03-13 12:50 André Schwarz
2008-03-13 16:54 ` Grant Likely
2008-03-25 22:59 ` Wolfgang Denk
0 siblings, 2 replies; 6+ messages in thread
From: André Schwarz @ 2008-03-13 12:50 UTC (permalink / raw)
To: u-boot
include fec specific nodes in ft_cpu_setup only if CONFIG_MPC5xxx_FEC is
defined. Systems without FEC, i.e. no fec node in dtb, should be possible.
Signed-off-by: Andre Schwarz <andre.schwarz@matrix-vision.de>
---
MATRIX VISION GmbH, Talstra?e 16, DE-71570 Oppenweiler - Registergericht: Amtsgericht Stuttgart, HRB 271090
Gesch?ftsf?hrer: Gerhard Thullner, Werner Armingeon, Uwe Furtner
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: diff_fec
Url: http://lists.denx.de/pipermail/u-boot/attachments/20080313/c2b3e8cd/attachment.txt
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot-Users] [PATCH] mpc5200 without fec
2008-03-13 12:50 [U-Boot-Users] [PATCH] mpc5200 without fec André Schwarz
@ 2008-03-13 16:54 ` Grant Likely
2008-03-13 17:05 ` Andre Schwarz
2008-03-25 22:59 ` Wolfgang Denk
1 sibling, 1 reply; 6+ messages in thread
From: Grant Likely @ 2008-03-13 16:54 UTC (permalink / raw)
To: u-boot
On Thu, Mar 13, 2008 at 6:50 AM, Andr? Schwarz
<andre.schwarz@matrix-vision.de> wrote:
> include fec specific nodes in ft_cpu_setup only if CONFIG_MPC5xxx_FEC is
> defined. Systems without FEC, i.e. no fec node in dtb, should be possible.
>
> Signed-off-by: Andre Schwarz <andre.schwarz@matrix-vision.de>
Hmm; if there is no fec node; then won't this just fail silently? In
which case; I'd rather avoid adding more inline #ifdefs to the code.
(correct me if I'm wrong)
Cheers,
g.
> ---
>
>
> MATRIX VISION GmbH, Talstra?e 16, DE-71570 Oppenweiler - Registergericht: Amtsgericht Stuttgart, HRB 271090
> Gesch?ftsf?hrer: Gerhard Thullner, Werner Armingeon, Uwe Furtner
>
> diff --git a/cpu/mpc5xxx/cpu.c b/cpu/mpc5xxx/cpu.c
> index e4d6168..dbfdd97 100644
> --- a/cpu/mpc5xxx/cpu.c
> +++ b/cpu/mpc5xxx/cpu.c
> @@ -119,7 +119,9 @@ void ft_cpu_setup(void *blob, bd_t *bd)
> {
> int div = in_8((void*)CFG_MBAR + 0x204) & 0x0020 ? 8 : 4;
> char * cpu_path = "/cpus/" OF_CPU;
> +#ifdef CONFIG_MPC5xxx_FEC
> char * eth_path = "/" OF_SOC "/ethernet at 3000";
> +#endif
>
> do_fixup_by_path_u32(blob, cpu_path, "timebase-frequency", OF_TBCLK, 1);
> do_fixup_by_path_u32(blob, cpu_path, "bus-frequency", bd->bi_busfreq, 1);
> @@ -127,7 +129,9 @@ void ft_cpu_setup(void *blob, bd_t *bd)
> do_fixup_by_path_u32(blob, "/" OF_SOC, "bus-frequency", bd->bi_ipbfreq, 1);
> do_fixup_by_path_u32(blob, "/" OF_SOC, "system-frequency",
> bd->bi_busfreq*div, 1);
> +#ifdef CONFIG_MPC5xxx_FEC
> do_fixup_by_path(blob, eth_path, "mac-address", bd->bi_enetaddr, 6, 0);
> do_fixup_by_path(blob, eth_path, "local-mac-address", bd->bi_enetaddr, 6, 0);
> +#endif
> }
> #endif
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> U-Boot-Users mailing list
> U-Boot-Users at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/u-boot-users
>
>
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot-Users] [PATCH] mpc5200 without fec
2008-03-13 16:54 ` Grant Likely
@ 2008-03-13 17:05 ` Andre Schwarz
2008-03-13 18:03 ` Grant Likely
0 siblings, 1 reply; 6+ messages in thread
From: Andre Schwarz @ 2008-03-13 17:05 UTC (permalink / raw)
To: u-boot
Grant Likely schrieb:
> On Thu, Mar 13, 2008 at 6:50 AM, Andr? Schwarz
> <andre.schwarz@matrix-vision.de> wrote:
>
>> include fec specific nodes in ft_cpu_setup only if CONFIG_MPC5xxx_FEC is
>> defined. Systems without FEC, i.e. no fec node in dtb, should be possible.
>>
>> Signed-off-by: Andre Schwarz <andre.schwarz@matrix-vision.de>
>>
>
> Hmm; if there is no fec node; then won't this just fail silently? In
> which case; I'd rather avoid adding more inline #ifdefs to the code.
> (correct me if I'm wrong)
>
> Cheers,
> g.
>
>
it fails - but not silently. If you don't care for the error messages on
the console you don't need it.
I don't like _any_ error message :-)
After all it's not a board specific #ifdef ...
>> ---
>>
>>
>> MATRIX VISION GmbH, Talstra?e 16, DE-71570 Oppenweiler - Registergericht: Amtsgericht Stuttgart, HRB 271090
>> Gesch?ftsf?hrer: Gerhard Thullner, Werner Armingeon, Uwe Furtner
>>
>> diff --git a/cpu/mpc5xxx/cpu.c b/cpu/mpc5xxx/cpu.c
>> index e4d6168..dbfdd97 100644
>> --- a/cpu/mpc5xxx/cpu.c
>> +++ b/cpu/mpc5xxx/cpu.c
>> @@ -119,7 +119,9 @@ void ft_cpu_setup(void *blob, bd_t *bd)
>> {
>> int div = in_8((void*)CFG_MBAR + 0x204) & 0x0020 ? 8 : 4;
>> char * cpu_path = "/cpus/" OF_CPU;
>> +#ifdef CONFIG_MPC5xxx_FEC
>> char * eth_path = "/" OF_SOC "/ethernet at 3000";
>> +#endif
>>
>> do_fixup_by_path_u32(blob, cpu_path, "timebase-frequency", OF_TBCLK, 1);
>> do_fixup_by_path_u32(blob, cpu_path, "bus-frequency", bd->bi_busfreq, 1);
>> @@ -127,7 +129,9 @@ void ft_cpu_setup(void *blob, bd_t *bd)
>> do_fixup_by_path_u32(blob, "/" OF_SOC, "bus-frequency", bd->bi_ipbfreq, 1);
>> do_fixup_by_path_u32(blob, "/" OF_SOC, "system-frequency",
>> bd->bi_busfreq*div, 1);
>> +#ifdef CONFIG_MPC5xxx_FEC
>> do_fixup_by_path(blob, eth_path, "mac-address", bd->bi_enetaddr, 6, 0);
>> do_fixup_by_path(blob, eth_path, "local-mac-address", bd->bi_enetaddr, 6, 0);
>> +#endif
>> }
>> #endif
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by: Microsoft
>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>> _______________________________________________
>> U-Boot-Users mailing list
>> U-Boot-Users at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/u-boot-users
>>
>>
>>
>
>
>
>
MATRIX VISION GmbH, Talstra?e 16, DE-71570 Oppenweiler - Registergericht: Amtsgericht Stuttgart, HRB 271090
Gesch?ftsf?hrer: Gerhard Thullner, Werner Armingeon, Uwe Furtner
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.denx.de/pipermail/u-boot/attachments/20080313/c2ec8934/attachment.htm
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot-Users] [PATCH] mpc5200 without fec
2008-03-13 17:05 ` Andre Schwarz
@ 2008-03-13 18:03 ` Grant Likely
2008-03-25 23:00 ` Wolfgang Denk
0 siblings, 1 reply; 6+ messages in thread
From: Grant Likely @ 2008-03-13 18:03 UTC (permalink / raw)
To: u-boot
On Thu, Mar 13, 2008 at 11:05 AM, Andre Schwarz
<andre.schwarz@matrix-vision.de> wrote:
>
> it fails - but not silently. If you don't care for the error messages on
> the console you don't need it.
> I don't like _any_ error message :-)
>
> After all it's not a board specific #ifdef ...
Okay then.
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Wolfgang, can you please pick this one up?
Thanks,
g.
--
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot-Users] [PATCH] mpc5200 without fec
2008-03-13 12:50 [U-Boot-Users] [PATCH] mpc5200 without fec André Schwarz
2008-03-13 16:54 ` Grant Likely
@ 2008-03-25 22:59 ` Wolfgang Denk
1 sibling, 0 replies; 6+ messages in thread
From: Wolfgang Denk @ 2008-03-25 22:59 UTC (permalink / raw)
To: u-boot
In message <47D9232C.5020208@matrix-vision.de> you wrote:
> This is a multi-part message in MIME format.
> --------------090008080204070507060201
> Content-Type: text/plain; charset=ISO-8859-15; format=flowed
> Content-Transfer-Encoding: 7bit
>
> include fec specific nodes in ft_cpu_setup only if CONFIG_MPC5xxx_FEC is
> defined. Systems without FEC, i.e. no fec node in dtb, should be possible.
>
> Signed-off-by: Andre Schwarz <andre.schwarz@matrix-vision.de>
Applied, thanks.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Things are not as simple as they seem at first. - Edward Thorp
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot-Users] [PATCH] mpc5200 without fec
2008-03-13 18:03 ` Grant Likely
@ 2008-03-25 23:00 ` Wolfgang Denk
0 siblings, 0 replies; 6+ messages in thread
From: Wolfgang Denk @ 2008-03-25 23:00 UTC (permalink / raw)
To: u-boot
In message <fa686aa40803131103r4a1c3fa7qec63655b20fdc014@mail.gmail.com> you wrote:
>
> Okay then.
>
> Acked-by: Grant Likely <grant.likely@secretlab.ca>
>
> Wolfgang, can you please pick this one up?
Sure - done.
Best regards,
Wolfgang Denk
--
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de
Every time history repeats itself the price goes up.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2008-03-25 23:00 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-13 12:50 [U-Boot-Users] [PATCH] mpc5200 without fec André Schwarz
2008-03-13 16:54 ` Grant Likely
2008-03-13 17:05 ` Andre Schwarz
2008-03-13 18:03 ` Grant Likely
2008-03-25 23:00 ` Wolfgang Denk
2008-03-25 22:59 ` Wolfgang Denk
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox