Skip to contentSkip to conversation

compiling BCM5700 driver

DISCUSSION Roman Mashak 3 participants 5 messages May 30, 2006 – May 31, 2006 MIPS

lore
Share & tools
lore
#0 lore raw

Hello,

I try to compile BCM5700 driver of gigabit ethernet card for MIPS target. I used both toolchains (from PMC-sierra and self-made following http://www.kegel.com/crosstool recommendations). Get same errors:

In file included from mm.h:151,

                from b57um.c:19:

tigon3.h:2225: unnamed fields of type other than struct or union are not allowed tigon3.h:2225: warning: no semicolon at end of struct or union tigon3.h:2225: syntax error before numeric constant
tigon3.h:2225: warning: no semicolon at end of struct or union tigon3.h:2239: syntax error before '}' token
tigon3.h:2239: warning: type defaults to int' in declaration of reg' tigon3.h:2239: warning: data definition has no type or storage class tigon3.h:2240: syntax error before '}' token

Here is abstract from tigon3.h where compiler complains:

typedef unsigned int LM_UINT32, *PLM_UINT32;
...
typedef volatile LM_UINT32 T3_32BIT_REGISTER, *PT3_32BIT_REGISTER;
...

typedef union T3_CPU
{
struct
{
T3_32BIT_REGISTER mode;
#define CPU_MODE_HALT BIT_10
#define CPU_MODE_RESET BIT_0
T3_32BIT_REGISTER state;
T3_32BIT_REGISTER EventMask;
T3_32BIT_REGISTER reserved1[4];
T3_32BIT_REGISTER PC; /* ERROR! */
T3_32BIT_REGISTER Instruction;
T3_32BIT_REGISTER SpadUnderflow;
T3_32BIT_REGISTER WatchdogClear;
T3_32BIT_REGISTER WatchdogVector;
T3_32BIT_REGISTER WatchdogSavedPC;
T3_32BIT_REGISTER HardwareBp;
T3_32BIT_REGISTER reserved2[3];
T3_32BIT_REGISTER WatchdogSavedState;
T3_32BIT_REGISTER LastBrchAddr;
T3_32BIT_REGISTER SpadUnderflowSet;
T3_32BIT_REGISTER reserved3[(0x200-0x50)/4];
T3_32BIT_REGISTER Regs[32];
T3_32BIT_REGISTER reserved4[(0x400-0x280)/4];
}reg;
}T3_CPU, *PT3_CPU;

I used the following compiler flags:

CFLAGS=-DMODULE -D__KERNEL__ -DDBG=0 -DT3_JUMBO_RCV_RCB_ENTRY_COUNT=256 -DNICE_SUPPORT -DPCIX_TARGET_WORKAROUND=1 -DINCLUDE_TBI_SUPPORT -DINCLUDE_5701_AX_FIX=1 -Wall -Wstrict-prototypes -mabi=32 -pipe -mips4 -mlong-calls -fno-common -fomit-frame-pointer -fno-pic -mno-abicalls -G0 -I$(LINUX)/include

What may be the reason?

Thanks in advance for hints!

With best regards, Roman Mashak. E-mail: [email protected]

#1 lore raw
Quoted 3 lines · Roman Mashak

I try to compile BCM5700 driver of gigabit ethernet card for MIPS target. I used both toolchains (from PMC-sierra and self-made following
http://www.kegel.com/crosstool recommendations). Get same errors:

I really can't help you w/ the bcm5700 driver. But, I am wondering why are you not using tg3 instead?

John

Signature · 2 lines
John W. Linville
[email protected]
#2 lore raw
In reply to Roman Mashak
Quoted 8 lines · Roman Mashak

I try to compile BCM5700 driver of gigabit ethernet card for MIPS target. I used both toolchains (from PMC-sierra and self-made following
http://www.kegel.com/crosstool recommendations). Get same errors:

In file included from mm.h:151,

                from b57um.c:19:

tigon3.h:2225: unnamed fields of type other than struct or union are not allowed

Broadcom's old and infamous Tigon 3 driver. Dump it, use tg3, be happy.

Ralf

#3 lore raw

Hello, Ralf!
You wrote to "Roman Mashak" <[email protected]> on Tue, 30 May 2006 15:06:16 +0100:

??>> I try to compile BCM5700 driver of gigabit ethernet card for MIPS ??>> target. I used both toolchains (from PMC-sierra and self-made ??>> following http://www.kegel.com/crosstool recommendations). Get same
??>> errors: In file included from mm.h:151, from
??>> b57um.c:19: tigon3.h:2225: unnamed fields of type other than struct or ??>> union are not allowed

RB> Broadcom's old and infamous Tigon 3 driver. Dump it, use tg3, be
RB> happy.
I ran across problems with Trigon3 driver working in bridge mode. Upon replacement it with bcm5700 - all problems have gone. Anyway, I managed to compile driver and now I'm testing it.

I'm more concerned with Titan GE driver on "Sequoia" board (by PMC-sierra). What's the status of this driver in 2.4.26? If I understand correct - it's maintained now only in 2.6.x? Upon compilation of 2.4.26 for Sequoia" board and installation on to target, we observed a lot of CRC errors on gigabit ethernet (we used SmartBit for testing). Is the driver in this version broken?

With best regards, Roman Mashak. E-mail: [email protected]

#4 lore raw
Quoted 6 lines · Roman Mashak

I'm more concerned with Titan GE driver on "Sequoia" board (by PMC-sierra). What's the status of this driver in 2.4.26? If I understand correct - it's maintained now only in 2.6.x? Upon compilation of 2.4.26 for Sequoia" board and installation on to target, we observed a lot of CRC errors on gigabit ethernet (we used SmartBit for testing). Is the driver in this version broken?

Likely. There is a new Titan driver written from scratch which permitting time hope to integrate soon but nothing like that will happen for 2.4. 2.4 has a shrinking userbase and all focus is on 2.6, and hardly a distribution or platform still needs 2.4 so there is very little happening wrt. to Linux 2.4 these days.

Ralf