This is the mail archive of the ecos-discuss@sources.redhat.com mailing list for the eCos project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: raw sockets in bsd stack. . ..


On Mon, Aug 30, 2004 at 02:07:45PM -0700, dries wrote:
> Jörn Seger wrote :
> 
> >  Maybe somebody can correct me, but I remember something like the io/eth/
> >  directory, where you can "read" the packets directly from the network
> > driver via some abstract functions like eth_drv_read()!?
> >
> >  But I haven't found any documentation on that up until now.
> >
> >  - Jörn
> 
> the eth_drv_read function is a internal driver function, i don't think your 
> allowed to call it directly . . . 

When I needed to do raw Ethernet, I ended up writing an
interface between my Ethernet driver and the normal
cyg_io_read()/cyg_io_write() API.  It existed in parallel with
the network driver API so that I could do both IP stuff and raw
stuff at the same time.  The main restriction was that it could
only be configured to send one Ethernet protocol type to the
cyg_io_read() API, the rest went to the network stack.

It wasn't particularly hard to do, but it did require a bit of
work.

-- 
Grant Edwards
grante@visi.com

-- 
Before posting, please read the FAQ: http://ecos.sourceware.org/fom/ecos
and search the list archive: http://ecos.sourceware.org/ml/ecos-discuss


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]