mirror of
https://github.com/Stichting-MINIX-Research-Foundation/u-boot.git
synced 2025-09-11 05:02:26 -04:00
Patches by himba, 21 Aug 2004:
- fix some "use of label at end of compound statement" warnings - Define type of LCD panel on lubbock board if CONFIG_LCD is used
This commit is contained in:
parent
1d9f410500
commit
63cfcbb4e2
@ -2,6 +2,10 @@
|
|||||||
Changes since U-Boot 1.1.1:
|
Changes since U-Boot 1.1.1:
|
||||||
======================================================================
|
======================================================================
|
||||||
|
|
||||||
|
* Patches by himba, 21 Aug 2004:
|
||||||
|
- fix some "use of label at end of compound statement" warnings
|
||||||
|
- Define type of LCD panel on lubbock board if CONFIG_LCD is used
|
||||||
|
|
||||||
* Patch by Steven Scholz, 16 Aug 2004:
|
* Patch by Steven Scholz, 16 Aug 2004:
|
||||||
- Introducing the concept of SoCs "./cpu/$(CPU)/$(SOC)"
|
- Introducing the concept of SoCs "./cpu/$(CPU)/$(SOC)"
|
||||||
- creating subdirs for SoCs ./cpu/arm920t/imx and ./cpu/arm920t/s3c24x0
|
- creating subdirs for SoCs ./cpu/arm920t/imx and ./cpu/arm920t/s3c24x0
|
||||||
|
@ -41,17 +41,16 @@ ulong flash_init(void)
|
|||||||
int i, j;
|
int i, j;
|
||||||
ulong size = 0;
|
ulong size = 0;
|
||||||
|
|
||||||
for (i = 0; i < CFG_MAX_FLASH_BANKS; i++)
|
for (i = 0; i < CFG_MAX_FLASH_BANKS; i++) {
|
||||||
{
|
|
||||||
ulong flashbase = 0;
|
ulong flashbase = 0;
|
||||||
|
|
||||||
flash_info[i].flash_id =
|
flash_info[i].flash_id =
|
||||||
(INTEL_MANUFACT & FLASH_VENDMASK) |
|
(INTEL_MANUFACT & FLASH_VENDMASK) |
|
||||||
(INTEL_ID_28F128J3 & FLASH_TYPEMASK);
|
(INTEL_ID_28F128J3 & FLASH_TYPEMASK);
|
||||||
flash_info[i].size = FLASH_BANK_SIZE;
|
flash_info[i].size = FLASH_BANK_SIZE;
|
||||||
flash_info[i].sector_count = CFG_MAX_FLASH_SECT;
|
flash_info[i].sector_count = CFG_MAX_FLASH_SECT;
|
||||||
memset (flash_info[i].protect, 0, CFG_MAX_FLASH_SECT);
|
memset (flash_info[i].protect, 0, CFG_MAX_FLASH_SECT);
|
||||||
switch (i)
|
switch (i) {
|
||||||
{
|
|
||||||
case 0:
|
case 0:
|
||||||
flashbase = PHYS_FLASH_1;
|
flashbase = PHYS_FLASH_1;
|
||||||
break;
|
break;
|
||||||
@ -62,9 +61,9 @@ ulong flash_init(void)
|
|||||||
panic ("configured too many flash banks!\n");
|
panic ("configured too many flash banks!\n");
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
for (j = 0; j < flash_info[i].sector_count; j++)
|
for (j = 0; j < flash_info[i].sector_count; j++) {
|
||||||
{
|
flash_info[i].start[j] =
|
||||||
flash_info[i].start[j] = flashbase + j*MAIN_SECT_SIZE;
|
flashbase + j * MAIN_SECT_SIZE;
|
||||||
}
|
}
|
||||||
size += flash_info[i].size;
|
size += flash_info[i].size;
|
||||||
}
|
}
|
||||||
@ -78,8 +77,7 @@ ulong flash_init(void)
|
|||||||
|
|
||||||
flash_protect (FLAG_PROTECT_SET,
|
flash_protect (FLAG_PROTECT_SET,
|
||||||
CFG_ENV_ADDR,
|
CFG_ENV_ADDR,
|
||||||
CFG_ENV_ADDR + CFG_ENV_SIZE - 1,
|
CFG_ENV_ADDR + CFG_ENV_SIZE - 1, &flash_info[0]);
|
||||||
&flash_info[0]);
|
|
||||||
|
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
@ -90,10 +88,8 @@ void flash_print_info (flash_info_t *info)
|
|||||||
{
|
{
|
||||||
int i, j;
|
int i, j;
|
||||||
|
|
||||||
for (j=0; j<CFG_MAX_FLASH_BANKS; j++)
|
for (j = 0; j < CFG_MAX_FLASH_BANKS; j++) {
|
||||||
{
|
switch (info->flash_id & FLASH_VENDMASK) {
|
||||||
switch (info->flash_id & FLASH_VENDMASK)
|
|
||||||
{
|
|
||||||
case (INTEL_MANUFACT & FLASH_VENDMASK):
|
case (INTEL_MANUFACT & FLASH_VENDMASK):
|
||||||
printf ("Intel: ");
|
printf ("Intel: ");
|
||||||
break;
|
break;
|
||||||
@ -102,8 +98,7 @@ void flash_print_info (flash_info_t *info)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
switch (info->flash_id & FLASH_TYPEMASK)
|
switch (info->flash_id & FLASH_TYPEMASK) {
|
||||||
{
|
|
||||||
case (INTEL_ID_28F320J3A & FLASH_TYPEMASK):
|
case (INTEL_ID_28F320J3A & FLASH_TYPEMASK):
|
||||||
printf ("28F320J3A (32Mbit)\n");
|
printf ("28F320J3A (32Mbit)\n");
|
||||||
break;
|
break;
|
||||||
@ -120,10 +115,8 @@ void flash_print_info (flash_info_t *info)
|
|||||||
info->size >> 20, info->sector_count);
|
info->size >> 20, info->sector_count);
|
||||||
|
|
||||||
printf (" Sector Start Addresses:");
|
printf (" Sector Start Addresses:");
|
||||||
for (i = 0; i < info->sector_count; i++)
|
for (i = 0; i < info->sector_count; i++) {
|
||||||
{
|
if ((i % 5) == 0) {
|
||||||
if ((i % 5) == 0)
|
|
||||||
{
|
|
||||||
printf ("\n ");
|
printf ("\n ");
|
||||||
}
|
}
|
||||||
printf (" %08lX%s", info->start[i],
|
printf (" %08lX%s", info->start[i],
|
||||||
@ -133,7 +126,7 @@ void flash_print_info (flash_info_t *info)
|
|||||||
info++;
|
info++;
|
||||||
}
|
}
|
||||||
|
|
||||||
Done:
|
Done: ;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*-----------------------------------------------------------------------
|
/*-----------------------------------------------------------------------
|
||||||
@ -189,7 +182,8 @@ int flash_erase (flash_info_t *info, int s_first, int s_last)
|
|||||||
*addr = 0xD0; /* erase confirm */
|
*addr = 0xD0; /* erase confirm */
|
||||||
|
|
||||||
while ((*addr & 0x80) != 0x80) {
|
while ((*addr & 0x80) != 0x80) {
|
||||||
if (get_timer_masked() > CFG_FLASH_ERASE_TOUT) {
|
if (get_timer_masked () >
|
||||||
|
CFG_FLASH_ERASE_TOUT) {
|
||||||
*addr = 0xB0; /* suspend erase */
|
*addr = 0xB0; /* suspend erase */
|
||||||
*addr = 0xFF; /* reset to read mode */
|
*addr = 0xFF; /* reset to read mode */
|
||||||
rc = ERR_TIMOUT;
|
rc = ERR_TIMOUT;
|
||||||
@ -255,8 +249,7 @@ static int write_word (flash_info_t *info, ulong dest, ushort data)
|
|||||||
reset_timer_masked ();
|
reset_timer_masked ();
|
||||||
|
|
||||||
/* wait while polling the status register */
|
/* wait while polling the status register */
|
||||||
while(((val = *addr) & 0x80) != 0x80)
|
while (((val = *addr) & 0x80) != 0x80) {
|
||||||
{
|
|
||||||
if (get_timer_masked () > CFG_FLASH_WRITE_TOUT) {
|
if (get_timer_masked () > CFG_FLASH_WRITE_TOUT) {
|
||||||
rc = ERR_TIMOUT;
|
rc = ERR_TIMOUT;
|
||||||
/* suspend program command */
|
/* suspend program command */
|
||||||
@ -313,8 +306,7 @@ int write_buff (flash_info_t *info, uchar *src, ulong addr, ulong cnt)
|
|||||||
/*
|
/*
|
||||||
* handle unaligned start bytes
|
* handle unaligned start bytes
|
||||||
*/
|
*/
|
||||||
if ((l = addr - wp) != 0)
|
if ((l = addr - wp) != 0) {
|
||||||
{
|
|
||||||
data = 0;
|
data = 0;
|
||||||
for (i = 0, cp = wp; i < l; ++i, ++cp) {
|
for (i = 0, cp = wp; i < l; ++i, ++cp) {
|
||||||
data = (data >> 8) | (*(uchar *) cp << 8);
|
data = (data >> 8) | (*(uchar *) cp << 8);
|
||||||
|
@ -43,6 +43,9 @@
|
|||||||
#define CONFIG_PXA250 1 /* This is an PXA250 CPU */
|
#define CONFIG_PXA250 1 /* This is an PXA250 CPU */
|
||||||
#define CONFIG_LUBBOCK 1 /* on an LUBBOCK Board */
|
#define CONFIG_LUBBOCK 1 /* on an LUBBOCK Board */
|
||||||
#define CONFIG_LCD 1
|
#define CONFIG_LCD 1
|
||||||
|
#ifdef CONFIG_LCD
|
||||||
|
#define CONFIG_SHARP_LM8V31
|
||||||
|
#endif
|
||||||
#define CONFIG_MMC 1
|
#define CONFIG_MMC 1
|
||||||
#define BOARD_LATE_INIT 1
|
#define BOARD_LATE_INIT 1
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user