[U-Boot-Users] u-boot-1.1.6-DOC is not recognised in Uboot?

Binay Kumar binay.kumar14 at gmail.com
Fri Oct 19 07:03:30 CEST 2007


Hi,

I cross-compiled u-boot-1.1.6 with patch for BMW board(MPC-8245) as
well as Montavista Kernel(linux 2.6.10_mv1401).Both running fine on
board.But DOC is not recognised in Uboot.

----------------Message-------------------

U-Boot 1.1.6 (Oct  4 2007 - 17:24:54)

CPU:   MPC8245 Revision 1.4 at 198.002 MHz: 16 kB I-Cache 16 kB D-Cache
Board: BMW MPC8245/KAHLUA2 - CHRP (MAP B)
HELLO BINAY........
Built: Oct  4 2007 at 17:24:57
Local Bus at 99.001 MHz
DRAM:  256 MB
FLASH: 512 kB
In:    serial
Out:   serial
Err:   serial
DOC:   No DiskOnChip found
----------------------------------------------
Even I checked in source code.....details are below.

1.u-boot-1.1.6\u-boot-1.1.6\board\bmw.c

* Map onboard TSOP-16MB DOC FLASH chip.

Line No:320
void doc_int(void)
{
  doc_probe(DOC_BASE_ADDR);
}

2.u-boot-1.1.6\u-boot-1.1.6\board\bmw.h
/* Extended ROM space devices */

Line No:42
#define DOC_BASE_ADDR 0xff000000
/*Onboard DOC TSOP 16 MB */

3.u-boot-1.1.6\u-boot-1.1.6\include\configs\BMW.h
Line No:75
#define CFG_MAX_DOC_DEVICE 1
/*Only use onboard TSOP 16 MB device */

4.u-boot-1.1.6\u-boot-1.1.6\common\cmd_doc.c
Line No:1577 to 1611
Line No.:1607 puts ("No DiskOnChip found\n");

void doc_probe(unsigned long physadr)
{
	struct DiskOnChip *this = NULL;
	int i=0, ChipID;

	if ((ChipID = doccheck(physadr, physadr))) {

		for (i=0; i<CFG_MAX_DOC_DEVICE; i++) {
			if (doc_dev_desc[i].ChipID == DOC_ChipID_UNKNOWN) {
				this = doc_dev_desc + i;
				break;
			}
		}

		if (!this) {
			puts ("Cannot allocate memory for data structures.\n");
			return;
		}

		if (curr_device == -1)
			curr_device = i;

		memset((char *)this, 0, sizeof(struct DiskOnChip));

		this->virtadr = physadr;
		this->physadr = physadr;
		this->ChipID = ChipID;

		DoC2k_init(this);
	} else {
		puts ("No DiskOnChip found\n");
	}
}

#endif /* (CONFIG_COMMANDS & CFG_CMD_DOC) */

So according to my understanding doc_prob function not able to check
below condition

if ((ChipID = doccheck(physadr, physadr)))
,so kindly give me some hint to short out this problem.

Thanks in advance
Binay




More information about the U-Boot mailing list