summaryrefslogtreecommitdiffstats
path: root/fs/Kconfig
Commit message (Collapse)AuthorAgeFilesLines
* efi: payload: rename CONFIG_EFI_BOOTUP to CONFIG_EFI_PAYLOADAhmad Fatoum2024-03-051-2/+2
| | | | | | | | | | The symbol is internal, so we don't break anything by renaming it. CONFIG_EFI_PAYLOAD is clearer in intent, as BOOTUP doesn't clearly indificate whether barebox would act as EFI payload or as EFI loader. Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20240304190038.3486881-9-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* tftp: implement UDP reorder cache using listsSascha Hauer2022-09-221-22/+0
| | | | | | | | The UDP reorder cache can be much easier implemented using lists. As a bonus the cache grows and shrinks on demand and no fixed size has to be configured at compile time. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* tftp: reorder tftp packetsEnrico Scholz2022-09-121-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With the tftp "windowsize" option, reordering of udp datagrams becomes an issue. Depending on the network topology, this reordering occurs several times with large tftp transfers and will heavily reduce the transfer speed. This patch adds a packet cache so that datagrams can be reassembled in the correct order. Because it increases memory usage and barebox binary size, it is an Kconfig option. bloat-o-meter reports with a non-zero FS_TFTP_REORDER_CACHE_SIZE | add/remove: 3/0 grow/shrink: 4/0 up/down: 916/0 (916) | Function old new delta | tftp_handler 920 1244 +324 | tftp_put_data - 184 +184 | tftp_window_cache_remove - 124 +124 | tftp_window_cache_get_pos - 120 +120 | tftp_allocate_transfer 104 188 +84 | tftp_do_close 260 312 +52 | tftp_send 384 412 +28 | Total: Before=630104, After=631020, chg +0.15% After setting FS_TFTP_REORDER_CACHE_SIZE Kconfig option to 0, numbers are going down to | add/remove: 0/0 grow/shrink: 3/0 up/down: 152/0 (152) | Function old new delta | tftp_handler 920 1012 +92 | tftp_allocate_transfer 104 136 +32 | tftp_send 384 412 +28 | Total: Before=630104, After=630256, chg +0.02% Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Link: https://lore.barebox.org/20220830073816.2694734-19-enrico.scholz@sigma-chemnitz.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* tftp: implement 'windowsize' (RFC 7440) supportEnrico Scholz2022-09-121-0/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Results (with the reorder patch; numbers in bytes/s) on an iMX8MP are: | windowsize | VPN | 1 Gb/s | 100 Mb/s | |------------|-----------|------------|------------| | 128 | 3.869.284 | 98.643.085 | 11.434.852 | | 64 | 3.863.581 | 98.550.375 | 11.434.852 | | 48 | 3.431.580 | 94.211.680 | 11.275.010 | | 32 | 2.835.129 | 85.250.081 | 10.985.605 | | 24 | 2.344.858 | 77.787.537 | 10.765.667 | | 16 | 1.734.186 | 67.519.381 | 10.210.087 | | 12 | 1.403.340 | 61.972.576 | 9.915.612 | | 8 | 1.002.462 | 50.852.376 | 9.016.130 | | 6 | 775.573 | 42.781.558 | 8.422.297 | | 4 | 547.845 | 32.066.544 | 6.835.567 | | 3 | 412.987 | 26.526.081 | 6.322.435 | | 2 | 280.987 | 19.120.641 | 5.494.241 | | 1 | 141.699 | 10.431.516 | 2.967.224 | (VPN = OpenVPN on ADSL 50 Mb/s). The window size can be configured at runtime. This commit increases barebox size by | add/remove: 1/0 grow/shrink: 4/1 up/down: 148/-16 (132) | Function old new delta | tftp_send 336 384 +48 | tftp_handler 880 928 +48 | tftp_init 16 60 +44 | tftp_allocate_transfer 100 104 +4 | g_tftp_window_size - 4 +4 | tftp_poll 180 164 -16 | Total: Before=629980, After=630112, chg +0.02% Setting FS_TFTP_MAX_WINDOW_SIZE to zero reduces it to | add/remove: 1/0 grow/shrink: 3/2 up/down: 96/-52 (44) | Function old new delta | tftp_init 16 60 +44 | tftp_handler 880 924 +44 | tftp_allocate_transfer 100 104 +4 | g_tftp_window_size - 4 +4 | tftp_poll 180 164 -16 | tftp_send 336 300 -36 | Total: Before=629980, After=630024, chg +0.01% Signed-off-by: Enrico Scholz <enrico.scholz@sigma-chemnitz.de> Link: https://lore.barebox.org/20220830073816.2694734-17-enrico.scholz@sigma-chemnitz.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* treewide: add SPDX-License-Identifier for Kbuild/KconfigAhmad Fatoum2022-01-051-0/+1
| | | | | | | | | | | | | | | To verify only Kconfig/Makefile is touched: git show --numstat --format=oneline HEAD | grep -v 'Kconfig\|Makefile' will print only arch/powerpc/Kbuild. To verify nothing unexpected is added: git show -U0 | grep '^-[^-]\|^+[^+]' | sort -u Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de> Link: https://lore.barebox.org/20220103120539.1730644-3-a.fatoum@pengutronix.de Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: jffs2: add initial support for reading jffs2Steffen Trumtrar2020-02-101-0/+1
| | | | | | | | | | | | | | | | | | | | | Import the jffs2 filesystem code from Linux v5.5-rc1 and convert it to work with barebox. Writing is *not* supported. Testing was done with a n25q256a-compatible QuadSPI chip on a SoCFPGA-based Socrates board. Testing was done with a combination of: user@somelinuxhost: mkfs.jffs2 --eraseblock=4 -d fs/jffs2/ -o jffs2.img root@target:~ flash_erase -j /dev/mtd5 0 0 root@target:~ dd if=jffs2.img of=/dev/mtd5 barebox@EBV SOCrates:/ mount /dev/mtd0.data (...) mounted /dev/mtd0.data on /mnt/mtd0.data Signed-off-by: Steffen Trumtrar <s.trumtrar@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: Add a driver to access U-Boot environment variablesAndrey Smirnov2019-06-071-0/+8
| | | | | | | | | Add a driver working on top of ubootvar device and exposing U-Boot environment variable data as files. Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Cory Tusar <cory.tusar@zii.aero> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* treewide: surround Kconfig file paths with double quotesMasahiro Yamada2019-03-211-5/+5
| | | | | | | | | Based on Linux commit 8636a1f9677db4f883f29a072f401303acfc2edd This will be needed when you sync Kconfig with Linux 5.0 or later. Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: cramfs: Switch to dentry cache implementationSascha Hauer2018-07-131-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: tftp: Switch to dentry cache implementationSascha Hauer2018-07-131-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: nfs: Switch to dentry cache implementationSascha Hauer2018-07-131-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: devfs: Switch to dentry cache implementationSascha Hauer2018-07-111-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: ramfs: Switch to dentry cache implementationSascha Hauer2018-07-111-1/+0
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: dentry cache implementationSascha Hauer2018-07-111-0/+23
| | | | | | | | | | | | | | | | | | | | | | | This adds the Linux dentry cache implementation to barebox. Until now every filesystem driver resolves the full path to a file for itself. This leads to code duplication and is error prone since resolving paths is a complicated task. Also it can narrow down the lookup performance since barebox only knows ASCII paths and has no way of caching lookups. With this patch we get the Linux dcache implementation. The path resolving code from fs/namei.c is nearly taken as-is, minus the RCU and locking code. Dcaching is made simple as of now: We simply cache everything and never release any dentries. Although we do reference counting for inodes and dentries it is effectively not used yet. We never free anything until a fs is unmounted in which case we free everything no matter if references are taken or not. This patch also contains a wrapper in fs/legacy.c to support filesystems with the old API. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ratp: allow building without full console supportAleksander Morgado2018-03-011-1/+1
| | | | | | | | | | | | | Make CONFIG_RATP a selectable config option, so that the user can enable RATP support without explicitly needing to enable the full console support over RATP (e.g. only for RATP FS or built-in command support). The full console can still be explicitly enabled with CONFIG_CONSOLE_RATP. Signed-off-by: Aleksander Morgado <aleksander@aleksander.es> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* efi: move x86 efi boot support to x86 archJean-Christophe PLAGNIOL-VILLARD2017-02-271-2/+2
| | | | | | | prepare to drop the efi arch as efi boot up is not arch sepecific Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: add support for SquashFS 4.0Yegor Yefremov2016-03-021-0/+1
| | | | | | | | | | The driver was imported from Linux 4.4. Current implementation supports only XZ decompressor. Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com> Tested-by: Antony Pavlov <antonynpavlov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/ratp'Sascha Hauer2016-02-081-0/+8
|\
| * fs: Add RATP fs supportJan Luebbe2016-01-181-0/+8
| | | | | | | | | | | | | | | | | | | | This adds file transfer support over RATP. The host can export a directory using the bbremote tool which can then be mounted under barebox as a filesystem. Signed-off-by: Jan Luebbe <jlu@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> Tested-by: Andrey Smirnov <andrew.smirnov@gmail.com>
* | fs: Add pstore filesystemMarkus Pargmann2015-12-101-0/+2
|/ | | | | | | | | | | | | | | | pstore is a persistent storage filesystem used for RAMOOPS. It is used to store console logs, panics, ftrace and other information in case of a crash/panic/oops/reboot. pstore is implemented for barebox as a read-only filesystem at the moment. It may be extended later on. The idea is to provide a way to extract essential data from the last running kernel. Most of the code is copied from the kernel. However this is only a lightweight implementation without real write support yet. Signed-off-by: Markus Pargmann <mpa@pengutronix.de> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* ARM: Add support for semihostingAndrey Smirnov2015-10-301-0/+9
| | | | | | | | | | Add semihosting API implementation and implement a filesystem driver to access debugging host filesystem using it. Tested on Freescale SabreSD board (i.MX6Q) using OpenOCD Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/randconfig-1'Sascha Hauer2014-12-081-0/+1
|\
| * fs: bpkfs: select CRC32Sascha Hauer2014-11-281-0/+1
| | | | | | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | fs: uImagefs: select crc32Sascha Hauer2014-11-271-0/+1
|/ | | | | | It needs it. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: implement EFI variable filesystem driverSascha Hauer2014-07-161-0/+7
| | | | | | | | This implements a filesystem for accessing EFI variables. It is compatible to the Linux Kernel efivarfs filesystem. Currently the variables can only be accessed readonly. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: implement EFI filesystem driverSascha Hauer2014-07-161-0/+8
| | | | | | | This implements a filesystem driver which uses the EFI Simple File System Protocol to provide files from EFI to barebox. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* drop CONFIG_PARTITION_NEED_MTDSascha Hauer2014-05-131-3/+0
| | | | | | | | | | | | | | | | | | | | | | With CONFIG_PARTITION_NEED_MTD enabled we use mtd rather than devfs directly to create partitions on mtd devices. Since: | commit b32cd8df87b87ef744365138e145b829c02eb719 | Author: Sascha Hauer <s.hauer@pengutronix.de> | Date: Wed Apr 9 15:49:32 2014 +0200 | | mtd: nand: bb: use mtd api directly | | The devfs layer just adds an addition indirection between mtd | and the bb devices with no purpose. Drop it. | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de> The bad block aware device creation doesn't work if this option is disabled. With this we remove CONFIG_PARTITION_NEED_MTD and always use mtd partitions on mtd devices. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'for-next/fs'Sascha Hauer2013-10-071-0/+4
|\ | | | | | | | | | | Conflicts: fs/Kconfig fs/Makefile
| * fs: add uimagefsJean-Christophe PLAGNIOL-VILLARD2013-09-271-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | this will provide the image data and information via file # ls -l /tmp/ -rwxrwxrwx 3 arch -rwxrwxrwx 12 compression -rwxrwxrwx 16 name -rwxrwxrwx 5 os -rwxrwxrwx 24 time -rwxrwxrwx 12 type -rwxrwxrwx 10 load_addr -rwxrwxrwx 10 entry_point -rwxrwxrwx 2199875 data0 -rwxrwxrwx 2199875 data -rwxrwxrwx 10 data.crc if it's multi image # ls -l /tmp-multi/ -rwxrwxrwx 3 arch -rwxrwxrwx 12 compression -rwxrwxrwx 16 name -rwxrwxrwx 5 os -rwxrwxrwx 24 time -rwxrwxrwx 16 type -rwxrwxrwx 10 load_addr -rwxrwxrwx 10 entry_point -rwxrwxrwx 1292 data0 -rwxrwxrwx 983 data1 -rwxrwxrwx 2287 data -rwxrwxrwx 10 data.crc you can get the image header via an ioctl on any file UIMAGEFS_METADATA if you want to check the crc do # crc32 -f /tmp-multi/data -V /tmp-multi/data.crc CRC32 for /tmp-multi/data 0x00000000 ... 0x000008ee ==> 0x88d5a0db Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | fs: add BPKFS supportJean-Christophe PLAGNIOL-VILLARD2013-10-061-0/+15
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Simple update file format developed for Somfy, tools and library are available under LGPLv2 (https://www.gitorious.org/libbpk). This format in the v1.0 allow you to store 6 types a binary stream for a unique hardware id: - bootloader - bootloader_version - description.gz - kernel - rootfs - firmware_version and you can easly add more binary stream type. The fs will display you in a directory per hw id and if a binary stream type is unknown will be display as unknown_%08x # mount image.bpk /tmp # ls -l /tmp/hw_id_0/ -rwxrwxrwx 10 firmware_version -rwxrwxrwx 8 firmware_version.crc -rwxrwxrwx 1845968 kernel -rwxrwxrwx 8 kernel.crc -rwxrwxrwx 5062656 rootfs -rwxrwxrwx 8 rootfs.crc -rwxrwxrwx 248 bootloader -rwxrwxrwx 8 bootloader.crc -rwxrwxrwx 248925 description.gz -rwxrwxrwx 8 description.gz.crc -rwxrwxrwx 4 bootloader_version -rwxrwxrwx 8 bootloader_version.crc -rwxrwxrwx 4 unknown_1234567g -rwxrwxrwx 8 unknown_1234567g.crc Why BPK and not CPIO or uImage 1) CPIO cpio does not handle > 4GiB image and does not have any crc checksum 2) uImage uImage only provide one crc32 for the all data part and only a list of binary stream with no information about what is what (in multi-image format) 3) BPK BPK provide a crc32 for the header part and one crc32 per binary stream so if you does not care of some data you are not force to check them And you known exactly the binary stream type and for which hw to use it. Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Fargier Sylvain <sylvain.fargier@somfy.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: Add ubifs supportSascha Hauer2013-08-071-0/+1
| | | | | | | | This adds ubifs support from u-boot-2013.07. This is taken mostly as-is, only the necessary adjustments to attach to the barebox fs layer have been made. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'kconfig'Sascha Hauer2012-12-081-1/+1
|\
| * Cleanup Kconfig filesAlexander Shiyan2012-12-081-1/+1
| | | | | | | | | | | | | | | | | | This patch provides a global cleanup barebox Kconfig files. This includes replacing spaces to tabs, formatting in accordance format, removing extraneous lines and spaces. No functional changes. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | fs: implement initial ext4 support from U-BootSascha Hauer2012-12-031-0/+2
|/ | | | | | | | | | | | | | The ext4 implementation has been taken from U-Boot with some changes: - No global variables to allow for multiple filesystems to be mounted and multiple files to be open. - remove fs internal link following and use the barebox link implementation. - remove write support. This is incomplete in U-Boot, so I decided to skip this for now. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* omap4: add filesystem support over usb bootVicente2012-11-161-0/+5
| | | | | Signed-off-by: Vicente <vicencb@gmail.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs/mount: add autodetection type supportJean-Christophe PLAGNIOL-VILLARD2012-09-041-0/+5
| | | | | | if NULL is pass as type mount will try to autodetect the filesystem type Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com>
* fs nfs: depend on netSascha Hauer2012-07-251-0/+1
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Merge branch 'next'Sascha Hauer2012-06-061-0/+4
|\
| * fs: Add NFS supportSascha Hauer2012-05-141-0/+4
| | | | | | | | | | | | | | | | This patch adds readonly NFS support. Currently no links are supported. This is based on the previous U-Boot/NetBSD based code and some Kernel bits. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | fs tftp: depend on NET, not on NET_TFTPSascha Hauer2012-05-311-1/+1
| | | | | | | | | | | | | | The tftp filesystem support is by no means dependent on the old tftp support, it depends on NET though. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* | fs/tftp: depend on NET_TFTPEric Bénard2012-05-171-0/+1
|/ | | | | | | else the option remains selected when network gets disabled Signed-off-by: Eric Bénard <eric@eukrea.com> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Add automount supportSascha Hauer2012-03-181-0/+3
| | | | | | | | | | | | | | This patch adds an automount command which makes it possible to execute a script when a certain directory is first accessed. It's the commands responsibility to make this directory available (bringing devices up and mounting it). This results in automount support which makes sure that from the shell every file can be accessed without having to care for device bringup. Bringing up devices may be expensive (USB, dhcp). The automount support makes it easy for the environment to bringup devices when they are actually needed. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* Add suport for tftp as a filesystemSascha Hauer2012-02-191-0/+4
| | | | | | | | | | | | | | | | | | This adds tftp filesystem support. It currently duplicates significant amounts of the tftp (command) support. This is ok since we can eventually drop the original tftp command later. tftp is not really suitable to be handled as a filesystem. It lacks support for stat, reading directories and other things. Handling it as a filesystem has one big advantage though: tftp is no special case for boot scripts and/or commands anymore which makes them simpler. This implementation has some improvements to the original tftp command. It supports blocksize negotiation which speeds up transfers if the tftp server supports it. Also we can determine the filesize to transfer if the remote end supports it. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* fs: add fat filesystem supportSascha Hauer2011-04-121-0/+2
| | | | | | | | | | | | | | 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>
* add partition mtd supportSascha Hauer2010-07-051-0/+3
| | | | Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
* This is Kconfig cleanup patch (not all configurations will use CFI, SPI, ↵Menon, Nishanth2008-05-121-0/+10
| | | | | | | 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.
* svn_rev_566Sascha Hauer2007-07-051-2/+2
| | | | fs support is not optional
* svn_rev_544Sascha Hauer2007-07-051-2/+2
| | | | make fs menuconfig
* svn_rev_465Sascha Hauer2007-07-051-5/+2
| | | | make fs support mandatory
* svn_rev_234Sascha Hauer2007-07-051-0/+12
beginning filesystem support