Commit Graph

19 Commits

Author SHA1 Message Date
Mike Frysinger c87f6457bb ext2: constify file/dir names
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
2010-11-28 21:58:51 +01:00
Sebastien Carlier 6d8962e814 Switch from archive libraries to partial linking
Before this commit, weak symbols were not overridden by non-weak symbols
found in archive libraries when linking with recent versions of
binutils.  As stated in the System V ABI, "the link editor does not
extract archive members to resolve undefined weak symbols".

This commit changes all Makefiles to use partial linking (ld -r) instead
of creating library archives, which forces all symbols to participate in
linking, allowing non-weak symbols to override weak symbols as intended.
This approach is also used by Linux, from which the gmake function
cmd_link_o_target (defined in config.mk and used in all Makefiles) is
inspired.

The name of each former library archive is preserved except for
extensions which change from ".a" to ".o".  This commit updates
references accordingly where needed, in particular in some linker
scripts.

This commit reveals board configurations that exclude some features but
include source files that depend these disabled features in the build,
resulting in undefined symbols.  Known such cases include:
- disabling CMD_NET but not CMD_NFS;
- enabling CONFIG_OF_LIBFDT but not CONFIG_QE.

Signed-off-by: Sebastien Carlier <sebastien.carlier@gmail.com>
2010-11-17 21:02:18 +01:00
Aaron Pace a2740dd00d ext2fs: Fix optimization bug for doubly-indirect block pointers
Doubly-indirect block numbers are compared against the first-level
indirect block when checking for a cached copy.  This is causing the
doubly-indirect block to be re-read each time it is accessed.
Repairing this reduces load time for a 70M file from 72 seconds
to 38 seconds.

Signed-off-by: Aaron Pace <Aaron.Pace@alcatel-lucent.com>
2010-08-07 22:44:08 +02:00
Michael Brandt 270737acca EXT2FS: fix inode size for ext2fs rev#0
extfs.c assumes that there is always a valid inode_size field in the
superblock. But this is not true for ext2fs rev 0. Such ext2fs images
are for instance generated by genext2fs. Symptoms on ARM machines are
messages like: "raise: Signal # 8 caught"; on PowerPC "ext2ls" will
print nothing.
This fix checks for rev 0 and uses then 128 bytes as inode size.

Signed-off-by: Michael Brandt <Michael.Brandt@emsyso.de>
Tested on: TQM5200S
Tested-by: Wolfgang Denk <wd@denx.de>
Signed-off-by: Wolfgang Denk <wd@denx.de>
2009-12-05 00:46:10 +01:00
Weirich, Bernhard 56fdaadc12 ext2: fix inode size and calculations
Signed-off-by: unsik Kim <donari75@gmail.com>
Signed-off-by: Bernhard Weirich <bernhard.weirich@riedel.net>
Signed-off-by: Wolfgang Denk <wd@denx.de>
Tested-by: Wolfgang Denk <wd@denx.de>
2009-07-28 22:38:17 +02:00
Jean-Christophe PLAGNIOL-VILLARD 08ab4e1780 fs: Move conditional compilation to Makefile
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2008-08-31 04:24:56 +02:00
Dave Liu ce1120dd70 fs: Fix ext2 read issue
The ext2 aligned process will corrupt the key
data struct, the patch fix this.

Signed-off-by: Dave Liu <daveliu@freescale.com>
2008-03-02 22:47:35 +01:00
Wolfgang Denk 0ddb89601a Fix memset bug in ext2fs_read_file()
ext2fs_read_file() had the function arguments swapped.

Pointed out by Mike Montour, 19 Dec 2007 22:34:25 -0800

Signed-off-by: Wolfgang Denk <wd@denx.de>
2008-01-09 10:16:33 +01:00
Jon Loeliger f40a7f3e38 fs/: Remove lingering references to CFG_CMD_* symbols.
Fixed some broken instances of "#ifdef CMD_CFG_IDE" too.
Those always evaluated TRUE, and thus were always compiled
even when IDE really wasn't defined/wanted.

Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-07-10 11:07:56 -05:00
Jon Loeliger dd60d1223b fs/: Remove obsolete references to CONFIG_COMMANDS
Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-07-09 17:56:50 -05:00
Jon Loeliger 4e109ae982 fs/: Augment CONFIG_COMMANDS tests with defined(CONFIG_CMD_*).
This is a compatibility step that allows both the older form
and the new form to co-exist for a while until the older can
be removed entirely.

All transformations are of the form:
Before:
    #if (CONFIG_COMMANDS & CFG_CMD_AUTOSCRIPT)
After:
    #if (CONFIG_COMMANDS & CFG_CMD_AUTOSCRIPT) || defined(CONFIG_CMD_AUTOSCRIPT)

Signed-off-by: Jon Loeliger <jdl@freescale.com>
2007-07-04 00:23:12 +02:00
Wolfgang Denk 2b208f5308 Move "ar" flags to config.mk to allow for silent "make -s"
Based on patch by Mike Frysinger, 20 Jun 2006
2006-10-09 01:02:05 +02:00
Marian Balakowicz f93286397e Add support for a saving build objects in a separate directory.
Modifications are based on the linux kernel approach and
support two use cases:

  1) Add O= to the make command line
  'make O=/tmp/build all'

  2) Set environement variable BUILD_DIR to point to the desired location
  'export BUILD_DIR=/tmp/build'
  'make'

The second approach can also be used with a MAKEALL script
'export BUILD_DIR=/tmp/build'
'./MAKEALL'

Command line 'O=' setting overrides BUILD_DIR environent variable.

When none of the above methods is used the local build is performed and
the object files are placed in the source directory.
2006-09-01 19:49:50 +02:00
Stefan Roese a7b9fb9110 Add VGA support (CT69000) to CPCI750 board.
Insert missing __le32_to_cpu() for filesize in ext2fs_read_file().

Patch by Reinhard Arlt, 30 Dec 2005
2006-01-18 20:05:34 +01:00
wdenk b05dcb58fe * Fix get_partition_info() parameter error in all other calls
(common/cmd_ide.c, common/cmd_reiser.c, common/cmd_scsi.c).

* Enable USB and IDE support for INKA4x0 board

* Patch by Andrew Dyer, 28 February 2005:
  fix ext2load passing an incorrect pointer to get_partition_info()
  resulting in load failure for devices other than 0
2005-03-04 11:27:31 +00:00
wdenk 20a80418f9 * Patch by Cajus Hahn, 04 Feb 2005:
- don't insist on leading '/' for filename in ext2load
  - set default partition to useful value (1) in ext2load

* Patch by Andrew Dyer, 08 Jan 2005:
  fix wrong return codes in ext2 code
2005-02-04 15:02:06 +00:00
wdenk ec0aee7b68 Cleanup: avoid trigraph warning in fs/ext2/ext2fs.c; rename UC100 -> uc100 2004-12-19 09:58:11 +00:00
wdenk efe2a4d5cf Code cleanup. 2004-12-16 21:44:03 +00:00
stroese 2b9187127f ext2fs support added 2004-12-16 17:26:24 +00:00