Dear [email protected],

In message <[email protected]> you 
wrote:
> From: Uma Shankar <[email protected]>
> 
> Signed-off-by: Uma Shankar <[email protected]>
> Signed-off-by: Manjunatha C Achar <[email protected]>
> Signed-off-by: Iqbal Shareef <[email protected]>
> Signed-off-by: Hakgoo Lee <[email protected]>
> ---
> Changes for v2:
>       - Code cleanup, changed comment style
>       - camel case removed, resolved code alignment issues
>       - memory allocation logic changed, removed busybox logic
>       - Modified ext4 load to remove grub dependency (GPLv3)
> 
> Changes for v1:
>       - Removed checkpatch warnings and errors
>       - Moved common API's of ext2 and ext4 to one generic header file
> 
>  Makefile              |    2 +-
>  common/Makefile       |    1 +
>  common/cmd_ext2.c     |    1 +
>  common/cmd_ext4.c     |  249 ++++++++++++++++++++++
>  fs/Makefile           |    1 +
>  fs/ext2/dev.c         |    1 +
>  fs/ext2/ext2fs.c      |  340 +++---------------------------
>  fs/ext4/Makefile      |   51 +++++
>  fs/ext4/ext4_common.c |  565 
> +++++++++++++++++++++++++++++++++++++++++++++++++
>  fs/ext4/ext4_common.h |   48 +++++
>  fs/ext4/ext4fs.c      |  219 +++++++++++++++++++
>  include/ext2fs.h      |   16 +-
>  include/ext4fs.h      |  133 ++++++++++++
>  include/ext_common.h  |  198 +++++++++++++++++
>  14 files changed, 1501 insertions(+), 324 deletions(-)
>  create mode 100644 common/cmd_ext4.c
>  create mode 100644 fs/ext4/Makefile
>  create mode 100644 fs/ext4/ext4_common.c
>  create mode 100644 fs/ext4/ext4_common.h
>  create mode 100644 fs/ext4/ext4fs.c
>  create mode 100644 include/ext4fs.h
>  create mode 100644 include/ext_common.h

Oops.  No, I cannot apply this.  When I enable  CONFIG_CMD_EXT4  in a
board config file, I get this:

+ ./MAKEALL TQM860L
Configuring for TQM860L board...
common/libcommon.o: In function `do_ext4_load':
/home/wd/git/u-boot/work/common/cmd_ext4.c:143: undefined reference to 
`ext2fs_set_blk_dev'
common/libcommon.o: In function `do_ext4_ls':
/home/wd/git/u-boot/work/common/cmd_ext4.c:220: undefined reference to 
`ext2fs_set_blk_dev'
fs/ext4/libext4fs.o: In function `ext4fs_read_file':
/home/wd/git/u-boot/work/fs/ext4/ext4fs.c:152: undefined reference to 
`ext2fs_devread'
/home/wd/git/u-boot/work/fs/ext4/ext4fs.c:178: undefined reference to 
`ext2fs_devread'
/home/wd/git/u-boot/work/fs/ext4/ext4fs.c:192: undefined reference to 
`ext2fs_devread'
fs/ext4/libext4fs.o: In function `ext4fs_ls':
/home/wd/git/u-boot/work/fs/ext4/ext4fs.c:211: undefined reference to 
`ext2fs_find_file'
/home/wd/git/u-boot/work/fs/ext4/ext4fs.c:218: undefined reference to 
`ext2fs_iterate_dir'
fs/ext4/libext4fs.o: In function `ext4fs_blockgroup':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1479: undefined reference to 
`ext2fs_devread'
fs/ext4/libext4fs.o: In function `ext4fs_read_inode':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1506: undefined reference to 
`ext2fs_devread'
fs/ext4/libext4fs.o: In function `ext4fs_get_extent_block':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1457: undefined reference to 
`ext2fs_devread'
fs/ext4/libext4fs.o: In function `read_allocated_block':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1601: undefined reference to 
`ext2fs_devread'
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1648: undefined reference to 
`ext2fs_devread'
fs/ext4/libext4fs.o:/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1686: more 
undefined references to `ext2fs_devread' follow
fs/ext4/libext4fs.o: In function `ext4fs_open':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1876: undefined reference to 
`ext2fs_find_file'
fs/ext4/libext4fs.o: In function `ext4fs_mount':
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1907: undefined reference to 
`ext2fs_devread'
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1934: undefined reference to 
`inode_size'
/home/wd/git/u-boot/work/fs/ext4/ext4_common.c:1936: undefined reference to 
`ext2fs_root'
make: *** [/work/wd/tmp-ppc/u-boot] Error 1


It seems this happens when you only enable CONFIG_CMD_EXT4, without
explicitly enabling CONFIG_CMD_EXT2 as well.  Please fix this - if the
ext4 code needs ext2, then it should automatically enable this option.

Hm... How much code duplication (for ext2 and ext4 commands) does this
cause?

Best regards,

Wolfgang Denk

-- 
DENX Software Engineering GmbH,     MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: [email protected]
The trouble with our times is that the future is not what it used  to
be.                                                     - Paul Valery
_______________________________________________
U-Boot mailing list
[email protected]
http://lists.denx.de/mailman/listinfo/u-boot

Reply via email to