Skip to contentSkip to conversation

Titan ethernet and little endian

PATCH Rojhalat Ibrahim 2 participants 6 messages Feb 3, 2005 – Feb 10, 2005 MIPS

lore
Share & tools
lore
#0 lore raw

Hi,
a while ago I posted the attached patch, which makes the titan_ge driver work in little-endian mode. I got no reaction whatsoever. What did I do wrong? Rojhalat Ibrahim

Index: titan_ge.h
===================================================================
RCS file: /home/cvs/linux/drivers/net/titan_ge.h,v retrieving revision 1.17

titan_ge.h +4 -2
diff -u -r1.17 titan_ge.h
@@ -153,8 +153,10 @@
 
 /* Define the Rx descriptor */
 typedef struct eth_rx_desc {
-	u32	buffer_addr;	/* Buffer address inclusive of checksum */
-	u32     cmd_sts;	/* Command and Status info */
+	u32     buffer_addr;	/* CPU buffer address 	*/
+	u32     reserved;	/* Unused 		*/
+	u32	buffer;		/* XDMA buffer address	*/
+	u32	cmd_sts;	/* Command and Status	*/
 } titan_ge_rx_desc;
 
 /* Define the Tx descriptor */
#1 lore raw
Quoted 21 lines · Rojhalat Ibrahim

Hi,
a while ago I posted the attached patch, which makes the titan_ge driver work in little-endian mode. I got no reaction whatsoever. What did I do wrong? Rojhalat Ibrahim

------------------------------------------------------------------------

Index: titan_ge.h
===================================================================
RCS file: /home/cvs/linux/drivers/net/titan_ge.h,v retrieving revision 1.17
diff -u -r1.17 titan_ge.h

titan_ge.h +0 -0
@@ -153,8 +153,10 @@
 
 /* Define the Rx descriptor */

titan_ge.h line 162

Quoted 10 lines
titan_ge.h +4 -2
 typedef struct eth_rx_desc {
-	u32	buffer_addr;	/* Buffer address inclusive of checksum */
-	u32     cmd_sts;	/* Command and Status info */
+	u32     buffer_addr;	/* CPU buffer address 	*/
+	u32     reserved;	/* Unused 		*/
+	u32	buffer;		/* XDMA buffer address	*/
+	u32	cmd_sts;	/* Command and Status	*/
 } titan_ge_rx_desc;
 
 /* Define the Tx descriptor */

Hi !

So, have you got the titan to work in the LE mode? Are you using the Yosemite board? Does this patch break BE?

Please do let us know.

Thanks
Manish Lachwani

#2 lore raw
Quoted 10 lines · Manish Lachwani

Hi !

So, have you got the titan to work in the LE mode? Are you using the Yosemite board? Does this patch break BE?

Please do let us know.

Thanks
Manish Lachwani

Hi!

Yes I have got the titan work in LE mode. And yes I am using the Yosemite board. And no this patch does not break BE. I haven't actually tested that but all the changes I made are between #ifdef LITTLE_ENDIAN and #endif.

Thanks
Rojhalat Ibrahim

#3 lore raw
Quoted 15 lines · Rojhalat Ibrahim
Quoted 10 lines · Manish Lachwani

Hi !

So, have you got the titan to work in the LE mode? Are you using the Yosemite board? Does this patch break BE?

Please do let us know.

Thanks
Manish Lachwani

Hi!

Quoted 9 lines

Yes I have got the titan work in LE mode. And yes I am using the Yosemite board. And no this patch does not break BE. I haven't actually tested that but all the changes I made are between #ifdef LITTLE_ENDIAN and #endif.

Thanks
Rojhalat Ibrahim

Ok, as long as the changes are in #ifdef. Although, your patch did not indicate the "#ifdef LITTLE_ENDIAN"

Thanks
Manish Lachwani

#4 lore raw
Quoted 22 lines · Manish Lachwani
Quoted 20 lines · Rojhalat Ibrahim
Quoted 10 lines · Manish Lachwani

Hi !

So, have you got the titan to work in the LE mode? Are you using the Yosemite board? Does this patch break BE?

Please do let us know.

Thanks
Manish Lachwani

Hi!

Yes I have got the titan work in LE mode. And yes I am using the Yosemite board. And no this patch does not break BE. I haven't actually tested that but all the changes I made are between #ifdef LITTLE_ENDIAN and #endif.

Quoted 11 lines
Quoted 4 lines

Thanks
Rojhalat Ibrahim

Ok, as long as the changes are in #ifdef. Although, your patch did not indicate the "#ifdef LITTLE_ENDIAN"

Thanks
Manish Lachwani

That's because the #ifdef was already there. The code inbetween was just not entirely correct.

Thanks
Rojhalat Ibrahim

#5 lore raw
In reply to Manish Lachwani
Quoted 22 lines · Manish Lachwani
Quoted 20 lines · Rojhalat Ibrahim
Quoted 10 lines · Manish Lachwani

Hi !

So, have you got the titan to work in the LE mode? Are you using the Yosemite board? Does this patch break BE?

Please do let us know.

Thanks
Manish Lachwani

Hi!

Yes I have got the titan work in LE mode. And yes I am using the Yosemite board. And no this patch does not break BE. I haven't actually tested that but all the changes I made are between #ifdef LITTLE_ENDIAN and #endif.

Quoted 11 lines
Quoted 4 lines

Thanks
Rojhalat Ibrahim

Ok, as long as the changes are in #ifdef. Although, your patch did not indicate the "#ifdef LITTLE_ENDIAN"

Thanks
Manish Lachwani

I have actually tested it also in BE mode now. Is there any remaining reason not to apply this patch?

Thanks
Rojhalat Ibrahim