DORMANTno replies

[PATCH] LLTEMAC resource end address

From: Hugo Villeneuve <hidden>
Date: 2008-04-15 14:37:48

Hi,
We have a design with LLTEMAC0 using channels 0 & 1, and LLTEMAC1 using =
channel 0. When the Linux kernel boots, we had the following error =
message:

---
Registering device xilinx_lltemac:0
Registering device xilinx_lltemac:1
xilinx_lltemac.1: failed to claim resource 0
cannot register dev xilinx_lltemac:1
Registering device xilinx_lltemac:2
---

We found out that the two channels of a LLTEMAC interface are each using =
0x40 bytes in length, and are contiguous. The following patch took care =
of the problem for us (against the linux-2.6-xlnx-git tree):

---
diff --git a/arch/ppc/syslib/virtex_devices.c =
b/arch/ppc/syslib/virtex_devices.c
index 457e1bd..7f731e4 100644
--- a/arch/ppc/syslib/virtex_devices.c
+++ b/arch/ppc/syslib/virtex_devices.c
@@ -202,7 +202,7 @@
        .resource =3D (struct resource[]) { \
                { \
                        .start =3D XPAR_LLTEMAC_##num##_BASEADDR, \
-                       .end =3D XPAR_LLTEMAC_##num##_BASEADDR + 0x1000, =
\
+                       .end =3D XPAR_LLTEMAC_##num##_BASEADDR + 0x003F, =
\
                        .flags =3D IORESOURCE_MEM \
                }, \
                { \
---

Hugo V.


Hugo Villeneuve
Hardware developer | Concepteur mat=E9riel
Lyrtech
Phone/T=E9l. : (1) (418) 877-4644 #2395
Toll-free/Sans frais - Canada & USA : (1) (888) 922-4644 #2395
Fax/T=E9l=E9c. : (1) (418) 877-7710
www.lyrtech.com
Infinite possibilities...TM

THIS MESSAGE AND ALL ATTACHED DOCUMENTS ARE EXCLUSIVELY INTENDED
TO THE INDICATED RECIPIENTS AND ITS CONTENTS MAY BE CONFIDENTIAL.
IT IS STRICTLY FORBIDDEN TO ANYONE TO TAKE COGNIZANCE, USE, OR
DIVULGE THE INFORMATION CONTAINED HEREIN. IF YOU MISTAKENLY
RECEIVE THIS MESSAGE, IMMEDIATELY INFORM LYRTECH AND DESTROY THE
MESSAGE AND ATTACHMENTS FORTHWITH.THANK YOU.

LE PRESENT MESSAGE ET LES DOCUMENTS QUI Y SONT JOINTS S'ADRESSENT
EXCLUSIVEMENT AU(X)DESTINATAIRE(S) INDIQUE(S) ET LEUR TENEUR PEUT
ETRE CONFIDENTIELLE. IL EST STRICTEMENT INTERDIT A QUICONQUE D'EN
PRENDRE CONNAISSANCE, DE LES UTILISER OU DE LES DIVULGUER. SI
VOUS RECEVEZ LE PRESENT MESSAGE PAR ERREUR, VEUILLEZ EN AVISER
LYRTECH IMMEDIATEMENT ET DETRUIRE LE MESSAGE SEANCE TENANTE,
AINSI QUE LES DOCUMENTS QUI Y SONT JOINTS.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help