summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorJon Loeliger <jdl@freescale.com>2008-01-10 14:28:18 -0600
committerJon Loeliger <jdl@freescale.com>2008-01-10 14:28:18 -0600
commitbb66f5613672fc80a6b38a0e1651d893bbe590a5 (patch)
tree9a8af7224b4dc2162a5cec00cf44d5afae43622f /fs
parentb830b7f1635984ba607219fcbd78597c28eeb529 (diff)
parent422b1a01602b6e2fbf8444a1192c7ba31461fd4c (diff)
downloadu-boot-imx-bb66f5613672fc80a6b38a0e1651d893bbe590a5.zip
u-boot-imx-bb66f5613672fc80a6b38a0e1651d893bbe590a5.tar.gz
u-boot-imx-bb66f5613672fc80a6b38a0e1651d893bbe590a5.tar.bz2
Merge commit 'wd/master'
Diffstat (limited to 'fs')
-rw-r--r--fs/fat/fat.c63
-rw-r--r--fs/jffs2/jffs2_1pass.c2
2 files changed, 30 insertions, 35 deletions
diff --git a/fs/fat/fat.c b/fs/fat/fat.c
index e98e50a..ee8b5fe 100644
--- a/fs/fat/fat.c
+++ b/fs/fat/fat.c
@@ -85,46 +85,41 @@ fat_register_device(block_dev_desc_t *dev_desc, int part_no)
/* no signature found */
return -1;
}
- if(!strncmp((char *)&buffer[DOS_FS_TYPE_OFFSET],"FAT",3)) {
- /* ok, we assume we are on a PBR only */
- cur_part = 1;
- part_offset=0;
- } else {
#if (defined(CONFIG_CMD_IDE) || \
defined(CONFIG_CMD_SCSI) || \
defined(CONFIG_CMD_USB) || \
- (defined(CONFIG_MMC) && defined(CONFIG_LPC2292)) || \
- defined(CONFIG_SYSTEMACE) )
- /* First we assume, there is a MBR */
- if (!get_partition_info (dev_desc, part_no, &info)) {
- part_offset = info.start;
- cur_part = part_no;
- } else if (!strncmp((char *)&buffer[DOS_FS_TYPE_OFFSET], "FAT", 3)) {
- /* ok, we assume we are on a PBR only */
- cur_part = 1;
- part_offset = 0;
- } else {
- printf ("** Partition %d not valid on device %d **\n",
+ defined(CONFIG_MMC) || \
+ defined(CONFIG_SYSTEMACE) )
+ /* First we assume, there is a MBR */
+ if (!get_partition_info (dev_desc, part_no, &info)) {
+ part_offset = info.start;
+ cur_part = part_no;
+ } else if (!strncmp((char *)&buffer[DOS_FS_TYPE_OFFSET], "FAT", 3)) {
+ /* ok, we assume we are on a PBR only */
+ cur_part = 1;
+ part_offset = 0;
+ } else {
+ printf ("** Partition %d not valid on device %d **\n",
part_no, dev_desc->dev);
- return -1;
- }
+ return -1;
+ }
+
#else
- if(!strncmp((char *)&buffer[DOS_FS_TYPE_OFFSET],"FAT",3)) {
- /* ok, we assume we are on a PBR only */
- cur_part = 1;
- part_offset = 0;
- info.start = part_offset;
- } else {
- /* FIXME we need to determine the start block of the
- * partition where the DOS FS resides. This can be done
- * by using the get_partition_info routine. For this
- * purpose the libpart must be included.
- */
- part_offset = 32;
- cur_part = 1;
- }
-#endif
+ if (!strncmp((char *)&buffer[DOS_FS_TYPE_OFFSET],"FAT",3)) {
+ /* ok, we assume we are on a PBR only */
+ cur_part = 1;
+ part_offset = 0;
+ info.start = part_offset;
+ } else {
+ /* FIXME we need to determine the start block of the
+ * partition where the DOS FS resides. This can be done
+ * by using the get_partition_info routine. For this
+ * purpose the libpart must be included.
+ */
+ part_offset = 32;
+ cur_part = 1;
}
+#endif
return 0;
}
diff --git a/fs/jffs2/jffs2_1pass.c b/fs/jffs2/jffs2_1pass.c
index 5316668..69f53ea 100644
--- a/fs/jffs2/jffs2_1pass.c
+++ b/fs/jffs2/jffs2_1pass.c
@@ -165,7 +165,7 @@ static struct part_info *current_part;
int read_jffs2_nand(size_t start, size_t len,
size_t * retlen, u_char * buf, int nanddev);
#else
-/* info for NAND chips, defined in drivers/nand/nand.c */
+/* info for NAND chips, defined in drivers/mtd/nand/nand.c */
extern nand_info_t nand_info[];
#endif