/*
    NetEthernetModule.h, Copyright  (c) by Boris Lutz,
    Swiss Federal Institute of Technology,
    Computer Engineering and Networks Laboratory.
 
    TOPSY -- A Teachable Operating System.
             Implementation of a tiny and simple
             micro kernel for teaching purposes.
 
    For further information, please visit http://www.tik.ee.ethz.ch/~topsy
 
    This software is provided under the terms of the GNU General Public
    Licence. A full copy of the GNU GPL is provided in the file COPYING
    found in the development root of Topsy.
*/
/*
 
    File:                  $Source: /home/ruf/cvs_Topsy/cvs/Topsy/Net/Modules/Ethernet/NetEthernetModule.h,v $
    Affiliation:           ETH Zuerich, TIK
    Version:               $Revision: 2922 $
    Last Date of Change:   $Date: 2007-03-19 17:48:52 +0100 (Mon, 19 Mär 2007) $  by: $Author: baderma $
 
*/
#ifndef _NET_ETHERNET_MODULEUP_H_
#define _NET_ETHERNET_MODULEUP_H_

#include "NetHAL.h"
#include "NetModulesNew.h"


typedef struct NetEthernetHdr_t
{
  u8	dest[6];
  u8	src[6];
  u16	type;
}
NetEthernetHdr;

#define NETETH_TYPE_IP    0x0800
#define NETETH_TYPE_IPv6  0x86dd

#define NETETH_TYPE_ARP   0x0806

// function prototypes from EthernetUp
void netEthernetModuleUpInit (NetModule this);
int netEthernetModuleUpConfig (NetModule this, Message *msg);
void netEthernetModuleUpMain (LWPool lw, ThreadArg arg);
// function prototypes from EthernetDown
void netEthernetModuleDownInit (NetModule this);
int netEthernetModuleDownConfig (NetModule this, Message *msg);
void netEthernetModuleDownMain (LWPool lw, ThreadArg arg);


#endif
