Forum Discussion
Altera_Forum
Honored Contributor
20 years agoHi Will,
> 1. copy dm9000x.c dm9000x.h from original u-boot 1.3.1 Yes, there was lots of driver code that was removed from the u-boot sources at psyent.com, mostly to keep the tarball size reasonable. But you should always be able to grab the latest driver code from the main u-boot source tree and just copy it into your local sources. > dm9000 not found at 0x00200920 id: 0xffffffff Perhaps, you might also want to define the CONFIG_DM9000_BASE macro using cache bypass (if you are using data cache). E.g. # define CONFIG_DM9000_BASE 0x80200920 Also, you must correctly define CONFIG_DM9000_USE_xxBIT (for the bus width). E.g.: # define CONFIG_DM9000_USE_32BIT If your bus width is not 32-bit, make sure you are using native alignment rather than the memory/dynamic alignment. I have never used this driver in u-boot ... you may need to define CONFIG_DM9000_DEBUG to track down any issues. > I using MTD patitions over Flash. How can I access patitions in u-boot ? and How in uClinux? This has recently changed in u-boot ... but I believe the following should still work: - CFG_CMD_JFFS2 to CONFIG_COMMANDS - define CFG_JFFS_CUSTOM_PART - the in one of your board-specific modules, something like this:#if (CONFIG_COMMANDS & CFG_CMD_JFFS2) && defined(CFG_JFFS_CUSTOM_PART)
static struct part_info parts = {
{ /* system partition */
.size = 0x00600000,
.offset = (char *)(CFG_FLASH_BASE + 0x00200000),
},
{ /* /usr/local partition */
.size = 0x00040000,
.offset = (char *)(CFG_FLASH_BASE + 0x00800000),
}
};
static int numparts = sizeof(parts)/sizeof(struct part_info);
struct part_info *jffs2_part_info (int part_num)
{
struct part_info *info = NULL;
if (part_num < numparts)
info = &parts;
return (info);
}
# endif /* (CONFIG_COMMANDS & CFG_CMD_JFFS2) */ Then you should be able to use the u-boot ls, fsload, etc. commands. To switch between the active partition, use the chpart command. BTW: in u-boot you can define a partition in ram/sdram to test your images prior to performing any flash programming. For linux, you will have to write your own mapping driver. Regards, --Scott