![]() |
|
Network Configuration of uClinux 2.4.x for 44B0X
by Tong Lai Yu and Felix Lo, July 2005
Network
It took us about four days to bring the network up. It took such a long time mainly because at first we could not find the appropriate network driver. Worse, the schematics that came with the CD did not show the correct DMA mode used by the network card; it indicated that 16-bit mode was used but upon calling the Beijing head quarter of Brightek, we learned that actually 8-bit mode is used in the board that we purchased.
At first we modified the file drivers/net/ne.c. To use this driver we need to select [] Other ISA card under Ethernet (10 or 100Mbit)--> of Network device support ---> . We added the following:
//added by Tong
#elif defined(CONFIG_ARCH_S3C44B0)
static int once = 0;
if (once)
return -ENXIO;
// if (base_addr == 0) { //Felix hardcode
dev->base_addr = base_addr = 0x06000000;//ARM_NE2000_BASE;
dev->irq = 22;//ARM_NE2000_IRQ;
once++;
// }
#endif
//Felix
static struct devprobe arm_probes[] __initdata = {
#ifdef CONFIG_ARM
{ne_probe, 0},
#endif
{NULL, 0},
};
if [ "$CONFIG_ARCH_S3C44B0" = "y" ]; then define_bool CONFIG_NO_PGT_CACHE y define_bool CONFIG_CPU_32 y define_bool CONFIG_CPU_32v4 y define_bool CONFIG_CPU_26 n define_bool CONFIG_CPU_ARM710 y define_bool CONFIG_CPU_WITH_CACHE y define_bool CONFIG_CPU_WITH_MCR_INSTRUCTION n define_hex DRAM_BASE 0x0c000000 define_hex DRAM_SIZE 0x00800000 define_hex FLASH_MEM_BASE 0x00000000 define_hex FLASH_SIZE 0x00200000 define_hex ARM_NE2000_BASE 0x06000000 define_hex ARM_NE2000_IRQ 24 fi
Later, we copied the files rtl8019.c and rtl8019.h to the directory arch/armnommu/mach-s3c44b0 from a 2.6.x distribution. But even after long struggling and juggling with various parameters and modifications, we could not bring up the network.
Finally, we called Brightek at Beijing; the technical support, Mr.Zhang promised to send the correct network driver but he never did. Nevertheless from what he hinted, Felix found that the network driver actually was hidden somewhere in a tar-zipped package and the files were also named 'rtl8019.h' and 'rtl8019.c' and all irqs are defined in irq.h. Besides using 8-bit DMA mode, the crucial changes made in these files are that they cast all 16-bit data to char. After adopting this driver, we could ping from two sites successfully. But still the receiving packets showed some errors.
To ping to the outside world, execute the command:
LCD Driver
The driver is at drivers/video/s3c44b0fb.c. 'fb' here means framebuffer, which is a hardware device that can save a graphics image.:q