[Aesop-embedded-devel] u-boot-aesop/disk part.c part_dos.c
Status: Beta
Brought to you by:
linuxpark
|
From: linux4go <lin...@li...> - 2005-07-07 15:48:26
|
linux4go 2005/07/07 08:48:20
Modified: disk part.c part_dos.c
Log:
Revision Changes Path
1.2 +8 -1 u-boot-aesop/disk/part.c
Index: part.c
===================================================================
RCS file: /cvsroot/aesop-embedded/u-boot-aesop/disk/part.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- part.c 27 Jun 2005 17:03:51 -0000 1.1
+++ part.c 7 Jul 2005 15:48:19 -0000 1.2
@@ -25,7 +25,7 @@
#include <command.h>
#include <ide.h>
-#define CONFIG_DOS_PARTITION
+#define CONFIG_DOS_PARTITION 1
#undef PART_DEBUG
@@ -38,6 +38,7 @@
#if ((CONFIG_COMMANDS & CFG_CMD_IDE) || \
(CONFIG_COMMANDS & CFG_CMD_SCSI) || \
(CONFIG_COMMANDS & CFG_CMD_USB) || \
+ (CONFIG_COMMANDS & CFG_CMD_MMC) || \
(CONFIG_MMC) || (CONFIG_SYSTEMACE) )
/* ------------------------------------------------------------------------- */
@@ -127,6 +128,7 @@
#if ((CONFIG_COMMANDS & CFG_CMD_IDE) || \
(CONFIG_COMMANDS & CFG_CMD_SCSI) || \
(CONFIG_COMMANDS & CFG_CMD_USB) || \
+ (CONFIG_COMMANDS & CFG_CMD_MMC) || \
defined(CONFIG_SYSTEMACE) )
#if defined(CONFIG_MAC_PARTITION) || \
@@ -136,6 +138,7 @@
void init_part (block_dev_desc_t * dev_desc)
{
+ printf("Init Part!!\n");
#ifdef CONFIG_ISO_PARTITION
if (test_part_iso(dev_desc) == 0) {
dev_desc->part_type = PART_TYPE_ISO;
@@ -152,6 +155,7 @@
#ifdef CONFIG_DOS_PARTITION
if (test_part_dos(dev_desc) == 0) {
+ printf("I need DOS partition!");
dev_desc->part_type = PART_TYPE_DOS;
return;
}
@@ -180,6 +184,7 @@
#ifdef CONFIG_DOS_PARTITION
case PART_TYPE_DOS:
+ //printf("Part Type is DOS?\n");
if (get_partition_info_dos(dev_desc,part,info) == 0) {
PRINTF ("## Valid DOS partition found ##\n");
return (0);
@@ -225,6 +230,8 @@
break;
case IF_TYPE_DOC: puts ("DOC");
break;
+ case IF_TYPE_MMC: puts ("MMC");
+ break;
default: puts ("UNKNOWN");
break;
}
1.2 +2 -1 u-boot-aesop/disk/part_dos.c
Index: part_dos.c
===================================================================
RCS file: /cvsroot/aesop-embedded/u-boot-aesop/disk/part_dos.c,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- part_dos.c 27 Jun 2005 17:03:50 -0000 1.1
+++ part_dos.c 7 Jul 2005 15:48:20 -0000 1.2
@@ -38,6 +38,7 @@
#if ((CONFIG_COMMANDS & CFG_CMD_IDE) || \
(CONFIG_COMMANDS & CFG_CMD_SCSI) || \
(CONFIG_COMMANDS & CFG_CMD_USB) || \
+ (CONFIG_COMMANDS & CFG_CMD_MMC) || \
(CONFIG_SYSTEMACE)) && defined(CONFIG_DOS_PARTITION)
/* Convert char[4] in little endian format to the host format integer
@@ -83,7 +84,7 @@
int test_part_dos (block_dev_desc_t *dev_desc)
{
unsigned char buffer[DEFAULT_SECTOR_SIZE];
-
+// printf("I must be hrer!!\n");
if ((dev_desc->block_read(dev_desc->dev, 0, 1, (ulong *) buffer) != 1) ||
(buffer[DOS_PART_MAGIC_OFFSET + 0] != 0x55) ||
(buffer[DOS_PART_MAGIC_OFFSET + 1] != 0xaa) ) {
|