9
0
Fork 0
Commit Graph

320 Commits

Author SHA1 Message Date
Sascha Hauer 14273e7be2 ramfs: increase chunk size to 8192 bytes
dlmalloc seems to work more efficient with this chunk size.
Copying a bigger file (3MB) takes 271ms vs. 125ms on a i.MX27
board. Even bigger chunk sizes do not further improve performance.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-05 17:53:36 +01:00
Sascha Hauer 35869a211f fix cramfs support broken since zlib update
cramfs does not compile since we updated zlib to the kernel
version. Fix this by using the kernel version of uncompress.c

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-12-05 15:19:26 +01:00
Sascha Hauer e0f4fb2c98 Merge branch 'master' into next
Conflicts:
	drivers/ata/disk_drive.c

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-29 20:45:23 +01:00
Juergen Beisert 3ca9f1812f Create a unique cdev number for on demand devices
For disk like devices attached to MCI, ATA or USB it depends on the order they
will be recognized. So an unique number for all disk like devices is required.

Signed-off-by: Juergen Beisert <jbe@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-28 09:23:24 +01:00
Franck Jullien 186d926c23 fs/fat: Initialize local variable finfo
fat_stat in fs/fat.c declares finfo but doesn't initialize it.
When get_fileinfo is called, fno->lfname and fno->lfsize are
tested but haven't been zeroed...This can lead to a wrong
behavior.

Signed-off-by: Franck Jullien <franck.jullien@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-17 16:59:29 +01:00
Franck Jullien 84b222987e mount: Fix the printing of device name
Mount without argument always print a "none" as device name mounted
because entry->parent_device is always NULL.

The problem is the mount function in fs/fs.c. parent_device is
initialized to NULL and never updated. With this patch,
parent_device is set with the mounted device name.

Moreover, the mount function has been modified to print the device
name plus device id using the dev_name function.

Signed-off-by: Franck Jullien <franck.jullien@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-11 12:13:34 +01:00
Sascha Hauer 6756cd2cb2 fs: read: do not call read op when count is 0
Some ops do not handle read with count = 0 correctly. They do
not have to if this is catched in the upper layer.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-11-09 11:23:16 +01:00
Sascha Hauer dac6e90115 fix bug introduced with fixing path_check_prereq()
This fixes a bug introduced with:

commit 74c36329c3
Author: Antony Pavlov <antonynpavlov@gmail.com>
Date:   Tue Oct 18 13:48:44 2011 +0400

    fs: fix path_check_prereq()

    This patch makes impossible the situations than path_check_prereq() can make
    'return 0' without changing errno.

    Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
    Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>

path_check_prereq is supposed to return 0 when a file does
not exist and S_UB_DOES_NOT_EXIST is given. stat() changes
errno, so we have to set errno back to 0 before returning.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-10-19 11:53:22 +02:00
Antony Pavlov a76e310abf fs: fix chdir()
chdir() allocates memory using mormalise_path(). But if path_check_prereq()
returns error than memory isn't freed.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-10-18 12:12:43 +02:00
Antony Pavlov 74c36329c3 fs: fix path_check_prereq()
This patch makes impossible the situations than path_check_prereq() can make
'return 0' without changing errno.

Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-10-18 12:12:43 +02:00
Sascha Hauer db879ec1a9 Merge branch 'next' 2011-08-04 14:49:33 +02:00
Antony Pavlov cce6520927 fs/fat/ff.c: fix 'no previous prototype' warnings
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-08-03 17:55:42 +02:00
Jean-Christophe PLAGNIOL-VILLARD 12ed40bb17 fs: switch to resource
Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
2011-07-30 02:05:27 +08:00
Sascha Hauer 4128911f43 mem_read/write: use resources
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-07-19 00:12:49 +08:00
Sascha Hauer 17e91068b1 fs: add fat filesystem support
This code is based on:

http://elm-chan.org/fsw/ff/00index_e.html

FatFs Generic FAT File System Module

This patch offers a read/write implementation for barebox. The code
does not exaclty match barebox coding style, but works nicely and
should be ready to give it a try.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-12 09:54:56 +02:00
Sascha Hauer 77e8307b32 fs mount: fix error handling
If we register a device we have to unregister it later when
the driver did not accept the device. Also, do not forget to
free the backingstore string.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:26 +02:00
Sascha Hauer 092ec16fdf fs: use safe_strncpy instead of sprintf
This is safe against string overflows.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:08 +02:00
Sascha Hauer 30be97aff2 devfs: factor out core devfs functionality
This makes it possible to compile without devfs. devfs_create/devfs_remove
is used by drivers and thus must still be present even without devfs support.
Also, this patch adds cdev_open/cdev_close/cdev_flush/cdev_ioctl calls to
work with devices without using the file api.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:07 +02:00
Sascha Hauer f1bb89fd9e fs: implement flush function
Once we have caching in file functions we need a way to sync
the the underlying devices.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:07 +02:00
Sascha Hauer 3efa8f7bed devfs: remove unused struct filep* argument from open/close
the cdev layer is under the file layer, so it should not use
struct filep*.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:07 +02:00
Sascha Hauer 5c44e3af24 fs: remove unused field 'type' from struct fs_driver_d
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-11 12:36:07 +02:00
Sascha Hauer 019e12210d fs: errno should be set correctly before the end of functions
Otherwise we end up with errno not being set correctly
if a filesystem driver uses the standard open/close/read/write
functions to access its backing store.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-04-04 15:02:40 +02:00
Sascha Hauer c28810e08f ramfs: increase chunk size to 4 kbyte
This greatly increases speed on ramfs.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-03-10 14:48:35 +01:00
Sascha Hauer a5734b08bd fs: fix multiple mount of the same fstype
We need to assign a new device id if we want to register
a fs with the same type of an already registered fstype.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2011-01-08 13:09:53 +01:00
Marek Belisko a894660cf1 fs: Fix bug found by sparse.
Patch fix following sparse warning:
fs/fs.c:757:28: warning: dubious: !x & y

Signed-off-by: Marek Belisko <marek.belisko@open-nandra.com>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-11-19 09:31:57 +01:00
Sascha Hauer 47ca335deb ramfs: sparse fixes
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-10-21 22:21:24 +02:00
Baruch Siach edf1301d82 fs: add basic sanity check before accessing the files array
This patch adds some basic file descriptor sanity checks to the file access
routines. Check whether the given file descriptor is in the files array range,
and whether the file entry is valid.

Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-07-28 08:21:46 +02:00
Sascha Hauer 9ae9ef472e devfs: only check for ioctl function when needed
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-07-05 15:07:13 +02:00
Sascha Hauer acc46ca4f0 add partition mtd support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2010-07-05 13:00:02 +02:00
Peter Korsgaard d2f785374f cramfs: probe(): fix cdev lookup
Strip /dev/ part of backing store before passing cdev_by_name, as
cramfs_probe() will otherwise always fail.

Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-12-16 08:38:42 +01:00
Sascha Hauer a3ffa97f40 rename U-Boot-v2 project to barebox
This has been done with the following script:

find -path ./.git -prune -o -type f -print0 | xargs -0 -r sed -i \
	-e 's/u2boot/barebox/g' \
	-e 's/U2Boot/barebox/g' \
	-e 's/U-boot V2/barebox/g' \
	-e 's/u-boot v2/barebox/g' \
	-e 's/U-Boot V2/barebox/g' \
	-e 's/U-Boot-v2/barebox/g' \
	-e 's/U_BOOT/BAREBOX/g' \
	-e 's/UBOOT/BAREBOX/g' \
	-e 's/uboot/barebox/g' \
	-e 's/u-boot/barebox/g' \
	-e 's/u_boot/barebox/g' \
	-e 's/U-Boot/barebox/g' \
	-e 's/U-boot/barebox/g' \
	-e 's/U-BOOT/barebox/g'

find -path ./.git -prune -o \( -name "*u-boot*" -o -name "*uboot*" -o -name "*u_boot*" \) -print0 | \
	xargs -0 -r rename 's/u[-_]?boot/barebox/'

It needs some manual fixup following in the next patch

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-12-15 10:18:30 +01:00
Sascha Hauer 2baeaf38f3 fs: replace broken dev_protect with protect_file function
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-10-02 15:23:22 +02:00
Sascha Hauer 2e976df267 devfs: fix return value for lseek in partitions
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-09-25 13:34:01 +02:00
Sascha Hauer f46010a1ab devfs: add open counter
Add an open counter for device files so that we cannot accidently
remove an opened device. This happened with bb devices.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-09-11 09:13:33 +02:00
Sascha Hauer 915aa03c77 fs: write: fix writing on devices
We can't truncate device files. Make sure that if we want to
write beyond the device that the bytes that still fit into the
device get written.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-30 16:10:20 +02:00
Sascha Hauer b42f481fa4 reactivate cramfs
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:47 +02:00
Sascha Hauer 02ba8a0542 get rid of device ids
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:47 +02:00
Sascha Hauer ec318139f6 make sure ramfs/devfs are initialised when needed
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:46 +02:00
Sascha Hauer 6459b135d9 Get rid of DEVICE_TYPE_FS usage
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:46 +02:00
Sascha Hauer 8fe9c1fa46 devfs: add missing remove function
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:45 +02:00
Sascha Hauer 4adfb9cf54 ramfs: add missing remove function
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:45 +02:00
Sascha Hauer a2b7cd183b introduce cdev
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2009-07-21 16:41:44 +02:00
fredo c3dbf6e1d6 remove warning
Signed-off-by: Frederic RODO <fred.rodo@gmail.com>
2008-12-18 14:20:08 +01:00
Sascha Hauer 8a45275a01 fs: fix compiler warning
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-08-26 11:40:51 +02:00
Sascha Hauer e133ccdda8 implement memmap for mem driver
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-08-14 10:25:56 +02:00
Sascha Hauer f295acb556 lseek: return -1 for errors and check for that return value
We cannot check for < 0 in lseek, otherwise we get problems with files > 0x7fffffff

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
2008-08-01 08:59:27 +02:00
Sascha Hauer b403f8d6f3 [fs]: set errno correctly for ioctl() 2008-06-25 10:23:15 +02:00
Sascha Hauer ee6d36a540 - introduce ioctl call
- pass open/close/lseek through to drivers
2008-06-06 09:30:48 +02:00
Menon, Nishanth b9655280e2 This is Kconfig cleanup patch (not all configurations will use CFI, SPI, RAMFS and DEVFS).
* Enable CFI and SPI drivers menuconfig option to be able to disable them in menuconfig.
* Introduce capability to disable ramfs and devfs.
2008-05-12 15:59:48 +02:00
Sascha Hauer e77ed305e6 add missing null pointer check in unlink() 2008-03-01 21:05:23 +01:00
Carsten Schlote c1bba7e226 [general] Fixed crash in fs.h, when called with fsdrv.create == NULL
When a nor0 devices has no partitions assigned, then a call to
open() to create a file will jump with a NULL fct ptr.

Much more cheching code is missing and pointers to function are
jumped without any NULL ptr check. This must be fixed as well later.

Signed-off-by: Carsten Schlote <c.schlote@konzeptpark.de>
2008-02-19 09:28:17 +01:00
Marc Kleine-Budde cefc190b1b [sparse] declare functions static, use NULL as NULL pointer
this fixes:
fs/fs.c:210:6: warning: symbol 'files' was not declared. Should it be static?
fs/fs.c:212:6: warning: symbol 'get_file' was not declared. Should it be static?
fs/fs.c:227:6: warning: symbol 'put_file' was not declared. Should it be static?
fs/fs.c:248:5: warning: symbol 'dir_is_empty' was not declared. Should it be static?
fs/fs.c:613:41: warning: Using plain integer as NULL pointer

Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
2007-11-29 10:22:47 +01:00
sascha 3b6d6a45e7 - Implement tree structure for devices
- Use device tree structure to implement partitions
- Let devinfo print a nice tree
- Introduce 'fixed' partitions which are not removable
- Fix mount: It was not possible to mount on a relative path.
2007-10-19 08:45:57 +02:00
sascha 6b8e56295f use S_ISDIR macro in open() 2007-10-16 16:41:05 +02:00
Sascha Hauer eadf71abc7 Use Linux kernel list for drivers and devices instead of handmade
list.
2007-10-11 20:20:36 +02:00
Sascha Hauer 2443c7a6f1 export symbols 2007-10-07 14:27:24 +02:00
Sascha Hauer faf5efa138 change files and dirs to rwxrwxrwx 2007-10-04 13:15:09 +02:00
Sascha Hauer 0b19fcf491 export functions 2007-10-04 12:30:32 +02:00
Sascha Hauer e5e965b7f4 change files and directories to 0777 2007-10-03 19:57:46 +02:00
Sascha Hauer 0fb965de2c remove debug printf, replace with debug 2007-10-03 19:37:11 +02:00
Sascha Hauer b3dc734018 declare lots of functions static 2007-09-28 10:07:26 +02:00
Sascha Hauer 79ed00ba92 pass file size from read_file 2007-09-27 16:33:35 +02:00
Sascha Hauer 2d02f7c0f0 fix bug in ramfs when creating files whose parents do not exist 2007-09-27 11:58:22 +02:00
Sascha Hauer 6ed4c53c21 handle NULL Pointers in readdir/closedir properly 2007-09-25 14:36:55 +02:00
Sascha Hauer f132b2e073 - change function declarations for better standard conformity:
int open(const char *pathname, int flags);
-> int open(const char *pathname, int flags, ...);
   int mkdir(const char *pathname);
-> int mkdir(const char *pathname, mode_t mode);
2007-09-24 17:03:20 +02:00
Sascha Hauer 4d17340dc1 remove unused includes 2007-09-21 21:30:25 +02:00
Sascha Hauer 9a365ade16 remove uncompilable filesystems 2007-09-21 14:02:08 +02:00
Sascha Hauer 056a695c15 implement flash protection 2007-07-16 10:29:28 +02:00
Sascha Hauer 665291e693 implement memmap().
With this function we can get a pointer to directly memory mapped
devices like nor flash or RAM. Useful for bootm where we save one
memcopy when the image is mappable
2007-07-15 13:50:04 +02:00
Sascha Hauer 11534fdfa2 implement truncate for devfs 2007-07-05 21:46:42 +02:00
Sascha Hauer 75a10b942c svn_rev_706
add file headers
2007-07-05 18:02:19 +02:00
Sascha Hauer b2c5310d4d svn_rev_653
restructure tree, add reginfo command
2007-07-05 18:02:14 +02:00
Sascha Hauer 3fd64b7c45 svn_rev_633
add some comments, minor cleanups
2007-07-05 18:02:12 +02:00
Sascha Hauer e2f1a28306 svn_rev_605
make read_file global
2007-07-05 18:02:09 +02:00
Sascha Hauer edc878b37e svn_rev_566
fs support is not optional
2007-07-05 18:02:05 +02:00
Sascha Hauer e390c672eb svn_rev_544
make fs menuconfig
2007-07-05 18:02:03 +02:00
Sascha Hauer a4b07792b9 svn_rev_465
make fs support mandatory
2007-07-05 18:01:56 +02:00
Sascha Hauer 44635dd22e svn_rev_452
add erase function
2007-07-05 18:01:55 +02:00
Sascha Hauer 0dc645fba6 svn_rev_448
add erase
2007-07-05 18:01:54 +02:00
Sascha Hauer 0eaabc8439 svn_rev_438 2007-07-05 18:01:54 +02:00
Sascha Hauer 0396fe8021 svn_rev_437
use dev_read/dev_write
2007-07-05 18:01:53 +02:00
Sascha Hauer e694adc6a4 svn_rev_420
- do more POSIX:
  - use DIR instead of struct dirent
  - use (struct dirent)->d_name instead of (struct dirent)->name
- switch to a new layout for U_BOOT_CMD:
  - use C99 initializers to be able to add more fields to the
    command struct
  - add aliases for commands (needed mainly for help -> ? and test -> [
  - This is not done for all commands yet, but the compiler will tell you ;)
2007-07-05 18:01:52 +02:00
Sascha Hauer 014678f7a0 svn_rev_406
let normalise path allocate the string instead of changing the original one
2007-07-05 18:01:51 +02:00
Sascha Hauer 5b4110a39c svn_rev_396
fix truncate (again). This still looks ugly
2007-07-05 18:01:50 +02:00
Sascha Hauer 31fc4bbff6 svn_rev_379 2007-07-05 18:01:48 +02:00
Sascha Hauer d7e3f8d227 svn_rev_378
fix truncate
2007-07-05 18:01:48 +02:00
Sascha Hauer 8ab8512461 svn_rev_372 2007-07-05 18:01:48 +02:00
Sascha Hauer 8287d7f588 svn_rev_371
fix mem hole
2007-07-05 18:01:48 +02:00
Sascha Hauer 46743ea28f svn_rev_369
include asm-generic in errno.h instead of all other files
2007-07-05 18:01:47 +02:00
Sascha Hauer 46d7dcc9ad svn_rev_364
- fix free corruption in open
- simplify mount()
- fix mem hole
2007-07-05 18:01:47 +02:00
Sascha Hauer e0cf91dbc4 svn_rev_339 2007-07-05 18:01:44 +02:00
Sascha Hauer 9df483a88f svn_rev_338
add rmdir and unlink, make creat more like posix, add common function for prerequites checking
2007-07-05 18:01:44 +02:00
Sascha Hauer 96b3a92454 svn_rev_337 2007-07-05 18:01:44 +02:00
Sascha Hauer 132c9b968d svn_rev_325
implement . and .. entries
2007-07-05 18:01:43 +02:00
Sascha Hauer 57013a9864 svn_rev_324
use xzalloc instead of malloc/memset
2007-07-05 18:01:43 +02:00
Sascha Hauer 5a82f54e59 svn_rev_301 2007-07-05 18:01:41 +02:00
Sascha Hauer d5f7b1f985 svn_rev_288
remove handling of / in stat function. We will never be called with / here
2007-07-05 18:01:40 +02:00
Sascha Hauer 700983e486 svn_rev_287
add lseek implementation, remove special handling of /dev/ (is now implemented as devfs)
2007-07-05 18:01:40 +02:00
Sascha Hauer 17fda95040 svn_rev_286 2007-07-05 18:01:40 +02:00
Sascha Hauer 877e92f7f1 svn_rev_284
add devfs
2007-07-05 18:01:39 +02:00
Sascha Hauer eaff0679f3 svn_rev_281
read support for ramfs
2007-07-05 18:01:39 +02:00
Sascha Hauer 9b4dfd7995 svn_rev_272
more FS work
2007-07-05 18:01:38 +02:00
Sascha Hauer 112ada667b svn_rev_270
WIP FS support
2007-07-05 18:01:38 +02:00
Sascha Hauer cf7a56fc78 svn_rev_268
WIP
2007-07-05 18:01:38 +02:00
Sascha Hauer afeec6a99b svn_rev_264 2007-07-05 18:01:38 +02:00
Sascha Hauer 06ed886f8b svn_rev_263 2007-07-05 18:01:38 +02:00
Sascha Hauer 9db8ed3312 svn_rev_261
WIP Filesystem support
2007-07-05 18:01:37 +02:00
Sascha Hauer 3f55f3e108 svn_rev_252
WIP
2007-07-05 18:01:37 +02:00
Sascha Hauer 8bf868e450 svn_rev_238
moved mkmodestr() to fs/fs.c
2007-07-05 18:01:35 +02:00
Sascha Hauer 0ed157cd19 svn_rev_234
beginning filesystem support
2007-07-05 18:01:35 +02:00
Sascha Hauer 162484b83c svn_rev_003
remove all #if 0 and #if 1
2007-07-05 18:01:13 +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
Marian Balakowicz 6db3970811 Fix JFFS2 support for legacy NAND driver.
Some more NAND cleanup and small fixes.
2006-04-08 19:08:06 +02:00
Wolfgang Denk 09e4b0c5d3 Add support for Lite5200B board.
Patch by  Patch by Jose Maria (Txema) Lopez, 16 Jan 2006
2006-03-17 11:42:53 +01:00
Wolfgang Denk 74f92e6a3f Add crc of data to jffs2 (in jffs2_1pass_build_lists()).
Patch by Rick Bronson, 15 Jun 2005
2006-03-12 16:05:05 +01:00
Bartlomiej Sieka addb2e1650 Re-factoring the legacy NAND code (legacy NAND now only in board-specific
code and in SoC code). Boards using the old way have CFG_NAND_LEGACY and
BOARDLIBS = drivers/nand_legacy/libnand_legacy.a added. Build breakage for
NETTA.ERR and NETTA_ISDN - will go away when the new NAND support is
implemented for these boards.
2006-03-05 18:57:33 +01:00
Bartlomiej Sieka 038ccac511 Merge with /home/wd/git/u-boot/testing-NAND/ to add new NAND handling. 2006-02-24 09:37:22 +01: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
Wolfgang Denk 84bd92bdda Merge with /home/m8/git/u-boot 2005-10-15 18:23:43 +02:00
Wolfgang Denk 77ddac9480 Cleanup for GCC-4.x 2005-10-13 16:45:02 +02:00
Marian Balakowicz e6f2e90233 Added support for TQM834x boards. 2005-10-11 19:09:42 +02:00
Wolfgang Denk ac7eb8a315 Update of new NAND code
Patch by Ladislav Michl, 13 Sep 2005
2005-09-14 23:53:32 +02:00
Wolfgang Denk 05b47540aa Merge with testing-NAND (Rewrite of NAND code) 2005-08-17 12:57:49 +02:00
Wolfgang Denk 932394ac43 Rewrite of NAND code based on what is in 2.6.12 Linux kernel
Patch by Ladislav Michl, 29 Jun 2005
2005-08-17 12:55:25 +02:00
Wolfgang Denk 87b8bd5aed Fix return values of the jffs2 commands ls/fsload/fsinfo,
so we can use them to, e.g., check the existence of a file with
"if ls foo; then this; else that; fi" in the hush shell
Patch by Andreas Engel, 16 August 2005
2005-08-16 09:32:45 +02:00
Wolfgang Denk 8f79e4c2da Add configuration for IFM AEV FIFO board.
Minor coding style cleanup.
2005-08-10 15:14:32 +02:00
Wolfgang Denk 700a0c648d Add common (with Linux) MTD partition scheme and "mtdparts" command
Old, obsolete and duplicated code was cleaned up and replace by the
new partitioning method. There are two possible approaches now:
* define a single, static partition
* use mtdparts command line option and dynamic partitioning
Default is static partitioning.
2005-08-08 01:03:24 +02:00
Wolfgang Denk d06a5f7ebf Add support for Altera NIOS DK1C20 board
Patch by Shlomo Kut, 13 Dec 2004
2005-08-06 01:56:59 +02:00
wdenk 412babe304 It's better to handle LZO and LZARI compression mdoes for JFFS2 with
a single #define.
2005-05-05 09:51:44 +00:00
wdenk 07cc099941 Major upate of JFFS2 code; now in sync with snapshot of MTD CVS of
March 13, 2005); new configuration options CONFIG_JFFS2_LZO and
CONFIG_JFFS2_LZARI are added. Both are undefined by default.
2005-05-05 00:04:14 +00:00
wdenk cf8bc5773c Fix problem with symbolic links in JFFS2 code. 2005-05-04 23:50:54 +00: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 20cc00ddac "static" from "do_fat_read" removed 2004-12-16 17:57:26 +00:00
stroese 2b9187127f ext2fs support added 2004-12-16 17:26:24 +00:00
wdenk a5bbcc3c53 * Patches by Sean Chang, 09 Aug 2004:
- Added support for both 8 and 16 bit mode access to System ACE CF
    through MPU.
  - Fixed missing System ACE CF device during get FAT partition info
    in fat_register_device function.
  - Enabled System ACE CF support on ML300.

* Patch by Sean Chang, 09 Aug 2004:
  Synch defines for saveenv and do_saveenv functions so they get
  compiled under the same statement.
2004-09-29 22:55:14 +00:00
wdenk 02b11f8e09 Patch by Klaus Heydeck, 12 May 2004:
Using external watchdog for KUP4 boards in mpc8xx/cpu.c;
load_sernum_ethaddr() for KUP4 boards in lib_ppc/board.c;
various changes to KUP4 board specific files
2004-05-12 22:54:36 +00:00
wdenk 32877d66aa * Fix memory leak in the NAND-specific JFFS2 code
* Fix SL811 USB controller when attached to a USB hub
2004-05-05 19:44:41 +00:00
wdenk 2729af9d54 * Fix minor NAND JFFS2 related issue
* Fixes for SL811 USB controller:
  - implement workaround for broken memory stick
  - improve error handling

* Increase packet send timeout to 10 ms in cpu/mpc8xx/scc.c to better
  cope with congested networks.
2004-05-03 20:45:30 +00:00
wdenk fc1cfcdb12 * Back out Patch by Christian Hohnstaedt, 23 Apr 2004:
(JFFS2 speed enhancements) because of using non-public
  data (PHYS_FLASH_SECT_SIZE)

* Patch by Travis Sawyer, 23 Apr 2004:
  Fix VSC/CIS 8201 phy descrambler interoperability timing due to
  errata from Vitesse Semiconductor.
2004-04-25 15:41:35 +00:00
wdenk 0b8fa03b6d * Patch by Christian Hohnstaedt, 23 Apr 2004:
JFFS2 speed enhancements:
  - repair header CRC calculation in jffs2_1pass.c
  - add eraseblock size to the partition information to skip empty
    eraseblocks if we find more then 4k of free space.
  - The JFFS2 scanner is now fast enough to remove the spinning wheel
    so #ifdef-ed out.
  - add watchdog calls in long running loops

* Patch by Philippe Robin, 22 Apr 2004:
  Fix ethernet configuration for "versatile" board

* Patch by Kshitij Gupta, 21 Apr 2004:
  Remove busy loop and use MPU timer fr usleep() on OMAP1510/1610 boards

* Patch by Steven Scholz, 24 Feb 2004:
  Fix a bug in AT91RM9200 ethernet driver:
  The MII interface is now initialized before accessing the PHY.

* Cleanup PCI ID's
2004-04-25 14:37:29 +00:00
wdenk 507bbe3e80 * Patch by Yasushi Shoji, 07 Apr 2004:
- add support for microblaze processors
  - add support for AtmarkTechno "suzaku" board
2004-04-18 21:13:41 +00:00
wdenk 998eaaecd4 * Configure PPChameleon board to use redundand environment in flash
* Configure PPChameleon board to use JFFS2 NAND support.

* Added support for JFFS2 filesystem (read-only) on top of NAND flash
2004-04-18 19:43:36 +00:00
wdenk 04a85b3b36 * Patches by Pantelis Antoniou, 30 Mar 2004:
- add auto-complete support to the U-Boot CLI
  - add support for NETTA and NETPHONE boards; fix NETVIA board

* Patch by Yuli Barcohen, 28 Mar 2004:
  - Add support for MPC8272 family including MPC8247/8248/8271/8272
  - Add support for MPC8272ADS evaluation board (another flavour of MPC8260ADS)
  - Change configuration method for MPC8260ADS family
2004-04-15 18:22:41 +00:00
wdenk b79a11cc2b Code cleanup 2004-03-25 15:14:43 +00:00
wdenk 518e2e1ae3 * Patch by Pavel Bartusek, 21 Mar 2004
Add Reiserfs support

* Patch by Hinko Kocevar, 20 Mar 2004
  - Add auto-release for SMSC LAN91c111 driver
  - Add save/restore of PTR and PNR regs as suggested in datasheet
2004-03-25 14:59:05 +00:00
wdenk 4b9206ed51 * Patches by Thomas Viehweger, 16 Mar 2004:
- show PCI clock frequency on MPC8260 systems
  - add FCC_PSMR_RMII flag for HiP7 processors
  - in do_jffs2_fsload(), take load address from load_addr if not set
    explicit, update load_addr otherwise
  - replaced printf by putc/puts when no formatting is needed
    (smaller code size, faster execution)
2004-03-23 22:14:11 +00:00
wdenk 855a496fe9 * Patches by Travis Sawyer, 12 Mar 2004:
- Fix Gigabit Ethernet support for 440GX
  - Add Gigabit Ethernet Support to MII PHY utilities

* Patch by Brad Kemp, 12 Mar 2004:
  Fixes for drivers/cfi_flash.c:
  - Better support for x8/x16 implementations
  - Added failure for AMD chips attempting to use CFG_FLASH_USE_BUFFER_WRITE
  - Added defines for AMD command and address constants

* Patch by Leon Kukovec, 12 Mar 2004:
  Fix get_dentfromdir() to correctly handle deleted dentries

* Patch by George G. Davis, 11 Mar 2004:
  Remove hard coded network settings in TI OMAP1610 H2
  default board config

* Patch by George G. Davis, 11 Mar 2004:
  add support for ADS GraphicsClient+ board.
2004-03-14 18:23:55 +00:00
wdenk 80885a9d52 * Patch by Markus Pietrek, 24 Feb 2004:
NS9750 DevBoard added

* Patch by Pierre AUBERT, 24 Feb 2004
  add USB support for MPC5200

* Patch by Steven Scholz, 24 Feb 2004:
  - fix MII commands to use values from last command

* Patch by Torsten Demke, 24 Feb 2004:
  Add support for the eXalion platform (SPSW-8240, F-30, F-300)
2004-02-26 23:46:20 +00:00
wdenk 2d1a537d87 * Patch by Thomas Elste, 10 Feb 2004:
Add support for NET+50 CPU and ModNET50 board

* Patch by Sam Song, 10 Feb 2004:
  Fix typos in cfi_flash.c

* Patch by Leon Kukovec, 10 Feb 2004
  Fixed long dir entry slot id calculation in get_vfatname

* Patch by Robin Gilks, 10 Feb 2004:
  add "itest" command (operators: -eq, -ne, -lt, -gt, -le, -ge, ==,
  !=, <>, <, >, <=, >=)
2004-02-23 19:30:57 +00:00
wdenk 180d3f74e4 * Fix problems caused by Robert Schwebel's cramfs patch
* Patch by Scott McNutt, 02 Jan 2004:
  Add support for the Nios Active Serial Memory Interface (ASMI)
  on Cyclone devices

* Patch by Andrea Marson, 16 Dec 2003:
  Add support for the PPChameleon ME and HI modules

* Patch by Yuli Barcohen, 22 Dec 2003:
  Add support for Motorola DUET ADS board (MPC87x/88x)
2004-01-04 16:28:35 +00:00
wdenk dd875c767e * Patch by Robert Schwebel, 15 Dec 2003:
add support for cramfs (uses JFFS2 command interface)
2004-01-03 21:24:46 +00:00
wdenk a2663ea4fc * Patches by David Müller, 14 Nov 2003:
- board/mpl/common/common_util.c
    * implement support for BZIP2 compressed images
    * various cleanups (printf -> puts, ...)
  - board/mpl/common/flash.c
    * report correct errors to upper layers
    * check the erase fail and VPP low bits in status reg
  - board/mpl/vcma9/cmd_vcma9.c
  - board/mpl/vcma9/flash.c
    * various cleanups (printf -> puts, ...)
  - common/cmd_usb.c
    * fix typo in comment
  - cpu/arm920t/usb_ohci.c
    * support for S3C2410 is missing in #if line
  - drivers/cs8900.c
    * reinit some registers in case of error (cable missing, ...)
  - fs/fat/fat.c
    * support for USB/MMC devices is missing in #if line
  - include/configs/MIP405.h
  - include/configs/PIP405.h
    * enable BZIP2 support
    * enlarge malloc space to 1MiB because of BZIP2 support
  - include/configs/VCMA9.h
    * enable BZIP2 support
    * enlarge malloc space to 1MiB because of BZIP2 support
    * enable USB support
  - lib_arm/armlinux.c
    * change calling convention of ARM Linux kernel as
      described on http://www.arm.linux.org.uk/developer/booting.php

* Patch by Thomas Lange, 14 Nov 2003:
  Split dbau1x00 into dbau1000, dbau1100 and dbau1500 configs to
  support all these AMD boards.

* Patch by Thomas Lange, 14 Nov 2003:
  Workaround for mips au1x00 physical memory accesses (the au1x00
  uses a 36 bit bus internally and cannot access physical memory
  directly. Use the uncached SDRAM address instead of the physical
  one.)
2003-12-07 18:32:37 +00:00
wdenk 5fa66df63a * Prepare for release
* Fix problems in memory test on some boards (which was not
  non-destructive as intended)

* Patch by Gary Jennejohn, 28 Oct 2003:
  Change fs/fat/fat.c to put I/O buffers in BSS instead on the stack
  to prevent stack overflow on ARM systems
2003-10-29 23:18:55 +00:00
wdenk 42d1f0394b * Patches by Xianghua Xiao, 15 Oct 2003:
- Added Motorola CPU 8540/8560 support (cpu/85xx)
  - Added Motorola MPC8540ADS board support (board/mpc8540ads)
  - Added Motorola MPC8560ADS board support (board/mpc8560ads)

* Minor code cleanup
2003-10-15 23:53:47 +00:00
wdenk a0ff7f2eda * Patch by Martin Krause, 09 Oct 2003:
Fixes for TRAB board
  - /board/trab/rs485.c: correct baudrate
  - /board/trab/cmd_trab.c: bug fix for problem with timer overflow in
    udelay(); fix some timing problems with adc controller
  - /board/trab/trab_fkt.c: add new commands: gain, eeprom and power;
    modify commands: touch and buzzer

* Disable CONFIG_SUPPORT_VFAT when used with CONFIG_AUTO_UPDATE
  (quick & dirty workaround for rogue pointer problem in get_vfatname());
  Use direct function calls for auto_update instead of hush commands
2003-10-09 13:16:55 +00:00
wdenk a43278a43d * Patch by Gary Jennejohn, 11 Sep 2003:
- allow for longer timeouts for USB mass storage devices

* Patch by Denis Peter, 11 Sep 2003:
  - fix USB data pointer assignment for bulk only transfer.
  - prevent to display erased directories in FAT filesystem.

* Change output format for NAND flash - make it look like for other
  memory, too
2003-09-11 19:48:06 +00:00
wdenk 7205e4075d * Patches by Denis Peter, 9 Sep 2003:
add FAT support for IDE, SCSI and USB

* Patches by Gleb Natapov, 2 Sep 2003:
  - cleanup of POST code for unsupported architectures
  - MPC824x locks way0 of data cache for use as initial RAM;
    this patch unlocks it after relocation to RAM and invalidates
    the locked entries.

* Patch by Gleb Natapov, 30 Aug 2003:
  new I2C driver for mpc107 bridge. Now works from flash.

* Patch by Dave Ellis, 11 Aug 2003:
  - JFFS2: fix typo in common/cmd_jffs2.c
  - JFFS2: fix CFG_JFFS2_SORT_FRAGMENTS option
  - JFFS2: remove node version 0 warning
  - JFFS2: accept JFFS2 PADDING nodes
  - SXNI855T: add AM29LV800 support
  - SXNI855T: move environment from EEPROM to flash
  - SXNI855T: boot from JFFS2 in NOR or NAND flash

* Patch by Bill Hargen, 11 Aug 2003:
  fixes for I2C on MPC8240
  - fix i2c_write routine
  - fix iprobe command
  - eliminates use of global variables, plus dead code, cleanup.
2003-09-10 22:30:53 +00:00
wdenk 8bde7f776c * Code cleanup:
- remove trailing white space, trailing empty lines, C++ comments, etc.
  - split cmd_boot.c (separate cmd_bdinfo.c and cmd_load.c)

* Patches by Kenneth Johansson, 25 Jun 2003:
  - major rework of command structure
    (work done mostly by Michal Cendrowski and Joakim Kristiansen)
2003-06-27 21:31:46 +00:00
wdenk 71f9511803 * Fix CONFIG_NET_MULTI support in include/net.h
* Patches by Kyle Harris, 13 Mar 2003:
  - Add FAT partition support
  - Add command support for FAT
  - Add command support for MMC
  ----
  - Add Intel PXA support for video
  - Add Intel PXA support for MMC
  ----
  - Enable MMC and FAT for lubbock board
  - Other misc changes for lubbock board
2003-06-15 22:40:42 +00:00
wdenk 06d01dbe00 * Avoid flicker on the TRAB's VFD by synchronizing the enable with
the HSYNC/VSYNC. Requires new CPLD code (Version 101 for Rev. 100
  boards, version 153 for Rev. 200 boards).

* Patch by Vladimir Gurevich, 12 Mar 2003:
  Fix relocation problem of statically initialized string pointers
  in common/cmd_pci.c

* Patch by Kai-Uwe Blöm, 12 Mar 2003:
  Cleanup & bug fixes for JFFS2 code:
  - the memory mangement was broken. It caused havoc on malloc by
    writing beyond the block boundaries.
  - the length calculation for files was wrong, sometimes resulting
    in short file reads.
  - data copying now optionally takes fragment version numbers into
    account, to avoid copying from older data.
  See doc/README.JFFS2 for details.
2003-03-14 20:47:52 +00:00
wdenk 47cd00fa70 * Patches by Robert Schwebel, 06 Mar 2003:
- fix bug in BOOTP code (must use NetCopyIP)
  - update of CSB226 port
  - clear BSS segment on XScale
  - added support for i2c_init_board() function
  - update to the Innokom plattform

* Extend support for redundand environments for configurations where
  environment size < sector size
2003-03-06 13:39:27 +00:00
wdenk 2262cfeef9 * Patch by Daniel Engström, 13 Nov 2002:
Add support for i386 architecture and AMD SC520 board

* Patch by Pierre Aubert, 12 Nov 2002:
  Add support for DOS filesystem and booting from DOS floppy disk
2002-11-18 00:14:45 +00:00
wdenk fe8c2806cd Initial revision 2002-11-03 00:38:21 +00:00
wdenk ae6448002a Initial revision 2002-03-08 23:11:41 +00:00
wdenk 012771d88a Initial revision 2002-03-08 21:31:05 +00:00
wdenk 5a2543c93b Initial revision 2002-02-17 23:36:36 +00:00