From: "Uwe Kindler" <uwe_kindler@web.de>
To: <ecos-discuss@sources.redhat.com>
Cc: "Andrew Lunn" <andrew@lunn.ch>
Subject: Re: [ECOS] Re: EDOSK-2674 ethernet drivers -TCP problem
Date: Fri, 05 Dec 2003 14:52:00 -0000 [thread overview]
Message-ID: <002c01c3bb3f$efecc070$72d5b43e@uwepc> (raw)
In-Reply-To: <20031205085413.GG2527@lunn.ch>
Hello Andrew,
I found the problem within the driver and fixed it by myself - now the
driver works with EDOSK2674 board.
Yoshinori Satos patch does not work for me. Here is my patch for smsc91cxx
driver.
Uwe Kindler
--- if_lan91cxx.c 2003-11-18 22:05:34.000000000 +0100
+++ ../if_lan91cxx.c 2003-11-28 16:58:18.000000000 +0100
@@ -141,9 +141,8 @@
static cyg_handle_t lan91cxx_interrupt_handle;
// This ISR is called when the ethernet interrupt occurs
-static int
-lan91cxx_isr(cyg_vector_t vector, cyg_addrword_t data
- /* , HAL_SavedRegisters *regs */ )
+static int lan91cxx_isr(cyg_vector_t vector, cyg_addrword_t data)
+ /* , HAL_SavedRegisters *regs */
{
struct eth_drv_sc *sc = (struct eth_drv_sc *)data;
struct lan91cxx_priv_data *cpd =
@@ -820,7 +819,7 @@
control |= LAN91CXX_CONTROLBYTE_ODD;
}
control |= LAN91CXX_CONTROLBYTE_CRC; // Just in case...
- put_data(sc, control);
+ put_data(sc, CYG_CPU_TO_LE16(control));
// Enqueue the packet
put_reg(sc, LAN91CXX_MMU_COMMAND, LAN91CXX_MMU_enq_packet);
@@ -1071,6 +1070,7 @@
val = CYG_LE32_TO_CPU(val);
plen = (val >> 16) - 6;
#else
+ val = CYG_LE16_TO_CPU(val);
plen = get_data(sc);
plen = CYG_LE16_TO_CPU(plen) - 6;
#endif
@@ -1111,6 +1111,8 @@
val >>= 16;
mlen -= 2;
} else
+#else
+ val = CYG_LE16_TO_CPU(val);
#endif
cp = (unsigned char *)data;
> It looks to me your change causes random junk to be in the control
> word.
>
> Am i reading this wrong?
>
> Thanks
> Andrew
>
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss
prev parent reply other threads:[~2003-12-05 14:52 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-11-19 14:06 [ECOS] " Uwe Kindler
2003-11-29 13:48 ` [ECOS] " Yoshinori Sato
2003-12-05 8:54 ` Andrew Lunn
2003-12-05 10:24 ` [ECOS] Re: STL support under eCos, what does it take? Giovanni Perbellini
2003-12-05 14:52 ` Uwe Kindler [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='002c01c3bb3f$efecc070$72d5b43e@uwepc' \
--to=uwe_kindler@web.de \
--cc=andrew@lunn.ch \
--cc=ecos-discuss@sources.redhat.com \
/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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).