26 Feb, 2014

1 commit


22 Feb, 2014

1 commit

  • In an ext4 filesystem, the inode corresponding to a file has a 60-byte
    area which contains an extent header structure and up to 4 extent
    structures (5 x 12 bytes).

    For files that need more than 4 extents to be represented (either files
    larger than 4 x 128MB = 512MB or smaller files but very fragmented),
    ext4 creates extent index structures. Each extent index points to a 4KB
    physical block where one extent header and additional 340 extents could
    be stored.

    The current u-boot ext4 code is very inefficient when it tries to load a
    file which has extent indexes. For each logical file block the code will
    read over and over again the same blocks of 4096 bytes from the disk.

    Since the extent tree in a file is always the same, we can cache the
    extent structures in memory before actually starting to read the file.

    This patch creates a simple linked list of structures holding information
    about all the extents used to represent a file. The list is sorted by
    the logical block number (ee_block) so that we can easily find the
    proper extent information for any file block.

    Without this patch, a 69MB file which had just one extent index pointing
    to a block with another 6 extents was read in approximately 3 minutes.
    With this patch applied the same file can be read in almost 20 seconds.

    Signed-off-by: Ionut Nicu

    Ionut Nicu
     

19 Feb, 2014

1 commit


24 Jul, 2013

1 commit


16 Jul, 2013

1 commit

  • With CONFIG_SYS_64BIT_LBA, lbaint_t gets defined as a 64-bit type,
    which is required to represent block numbers for storage devices that
    exceed 2TiB (the block size usually is 512B), e.g. recent hard drives

    We now use lbaint_t for partition offset to reflect the lbaint_t change,
    and access partitions beyond or crossing the 2.1TiB limit.
    This required changes to signature of ext4fs_devread(), and type of all
    variables relatives to block sector.

    ext2/ext4 fs uses logical block represented by a 32 bit value. Logical
    block is a multiple of device block sector. To avoid overflow problem
    when calling ext4fs_devread(), we need to cast the sector parameter.

    Signed-off-by: Frédéric Leroy

    Frederic Leroy
     

10 May, 2013

1 commit


05 Mar, 2013

2 commits


07 Dec, 2012

3 commits

  • The filename buffer is allocated dynamically. It must be cache aligned.
    Moreover, it is necessary to erase its content before we use it for
    file name operations.

    This prevents from corruption of written file names.

    Signed-off-by: Lukasz Majewski
    Signed-off-by: Kyungmin Park

    Łukasz Majewski
     
  • Several fixes to suppress compiler's (eldk-5.[12].x gcc 4.6)
    warning [-Wunused-but-set-variable]

    Signed-off-by: Lukasz Majewski
    Signed-off-by: Kyungmin Park

    Łukasz Majewski
     
  • The ext4write code has been using direct calls to 64-32 division
    (/ and %).

    Officially supported u-boot toolchains (eldk-5.[12].x) generate calls
    to __aeabi_uldivmod(), which is niether defined in the toolchain libs
    nor u-boot source tree.

    Due to that, when the ext4write command has been executed, "undefined
    instruction" execption was generated (since the __aeabi_uldivmod()
    is not provided).

    To fix this error, lldiv() for division and do_div() for modulo have
    been used.

    Those two functions are recommended for performing 64-32 bit number
    division in u-boot.

    Signed-off-by: Lukasz Majewski
    Signed-off-by: Kyungmin Park

    Łukasz Majewski
     

30 Oct, 2012

1 commit

  • This makes the FAT and ext4 filesystem implementations build if
    CONFIG_FS_{FAT,EXT4} are defined, rather than basing the build on
    whether CONFIG_CMD_{FAT,EXT*} are defined. This will allow the
    filesystems to be built separately from the filesystem-specific commands
    that use them. This paves the way for the creation of filesystem-generic
    commands that used the filesystems, without requiring the filesystem-
    specific commands.

    Minor documentation changes are made for this change.

    The new config options are automatically selected by the old config
    options to retain backwards-compatibility.

    Signed-off-by: Stephen Warren
    Reviewed-by: Benoît Thébaudeau

    Stephen Warren
     

04 Oct, 2012

1 commit


26 Sep, 2012

2 commits


10 Aug, 2012

2 commits