started testing. BOOTP crashes at ip_send() ?

This commit is contained in:
Markus Fröschle
2013-12-24 12:38:36 +00:00
parent c1ff9a7181
commit 4ec02ea882
13 changed files with 771 additions and 1090 deletions

View File

@@ -42,6 +42,7 @@
#include "eth.h"
#include "nbuf.h"
#include "nif.h"
#include "fec.h"
/* imported routines */
extern int mmu_init();
@@ -366,6 +367,19 @@ void BaS(void)
xprintf("BaS initialization finished, enable interrupts\r\n");
enable_coldfire_interrupts();
nbuf_init();
uint8_t mac[6] = {0x00, 0x04, 0x9f, 0x01, 0x01, 0x01}; /* this is a Freescale MAC address */
uint8_t bc[6] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; /* this is a Freescale MAC address */
fec_eth_setup(0, FEC_MODE_MII, FEC_MII_100BASE_TX, FEC_MII_FULL_DUPLEX, mac);
nif_init(&nif1);
nif1.mtu = ETH_MTU;
nif1.send = fec0_send;
memcpy(nif1.hwa, mac, 6);
memcpy(nif1.broadcast, bc, 6);
bootp_request(&nif1, 0);
xprintf("call EmuTOS\r\n");
ROM_HEADER* os_header = (ROM_HEADER*)TOS;
os_header->initial_pc();

View File

@@ -307,7 +307,7 @@ static int init_count = 0;
int driver_mem_init(void)
{
if (! init_count == 0)
if (init_count == 0)
{
#ifdef USE_RADEON_MEMORY
driver_mem_buffer = (void *) offscreen_reserved();

View File

@@ -48,6 +48,7 @@
#include "dma.h"
#include "mod_devicetable.h"
#include "pci_ids.h"
#include "driver_mem.h"
#include "usb.h"
#define UNUSED(x) (void)(x) /* Unused variable */
@@ -1126,6 +1127,7 @@ void initialize_hardware(void)
}
#endif /* MACHINE_FIREBEE */
driver_mem_init();
init_pci();
/* do not try to init USB for now on the Firebee, it hangs the machine */