From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 25234 invoked by alias); 30 Aug 2007 21:25:53 -0000 Received: (qmail 25220 invoked by uid 22791); 30 Aug 2007 21:25:52 -0000 X-Spam-Check-By: sourceware.org Received: from out2.smtp.messagingengine.com (HELO out2.smtp.messagingengine.com) (66.111.4.26) by sourceware.org (qpsmtpd/0.31) with ESMTP; Thu, 30 Aug 2007 21:25:47 +0000 Received: from compute1.internal (compute1.internal [10.202.2.41]) by out1.messagingengine.com (Postfix) with ESMTP id 218F92703D for ; Thu, 30 Aug 2007 17:25:46 -0400 (EDT) Received: from heartbeat1.messagingengine.com ([10.202.2.160]) by compute1.internal (MEProxy); Thu, 30 Aug 2007 17:25:46 -0400 Received: from [192.168.0.159] (TOROON12-1177741232.sdsl.bell.ca [70.50.231.176]) by mail.messagingengine.com (Postfix) with ESMTP id D3BCB1D29 for ; Thu, 30 Aug 2007 17:25:45 -0400 (EDT) Message-ID: <46D735D8.8010409@Malcolmson.com> Date: Thu, 30 Aug 2007 21:25:00 -0000 From: Tom Malcolmson User-Agent: Thunderbird 2.0.0.6 (Windows/20070728) MIME-Version: 1.0 To: ecos-discuss@ecos.sourceware.org Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Mailing-List: contact ecos-discuss-help@ecos.sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: ecos-discuss-owner@ecos.sourceware.org Subject: [ECOS] ethernet driver - receiving packets doesn't work X-SW-Source: 2007-08/txt/msg00173.txt.bz2 Hi. I'm new to eCos - we are trying to move away from a proprietary OS, and I'm having basic problems with my Ethernet driver. I'm using an eCos 2.0 snapshot from September 2006 on an ARM platform with the standard FreeBSD stack. Sending packets from an eCos app, thru my driver works fine, but eCos doesn't seem to do anything with the packets that I deliver up to it: they never back up to the application. For DHCP for instance, I see the DHCP request come out of my system, and I see a DHCP offer from the server go back into my system. I can see from debug prints in the generic ethernet driver that it has correctly received the DHCP offer, but the offer never gets back to the app. I have tried apps other then DHCP. Now, I should expain that there is no actual ethernet hardware, so no ethernet interrupts, etc. My guide for writing the driver has been the eCos reference manual, chapter 46: http://ecos.sourceware.org/docs-2.0/ref/io-eth-drv-generic1.html But I skip some steps since I don`t have a DSR. When I have a packet for the net stack, I just call (sc->funs->eth_drv->recv)() with the number of bytes needed. eCos calls my receive function which puts the packet into the sg list. From debug output I can see that the generic driver code (eth_drv.c) has corrrectly received my packet and presumably calls ether_input. A couple other thing. Loopback tests work. I don`t have any debugging capability. I believe that the next step for me would be to insert print statements in if_ethersubr.c. Thanks for any suggestions. Tom. -- Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss