Add support for AXFS filesystem type
v3 cover Add support for AXFS filesystem type
This patch series adds support for using the AXFS filesystem type.
The Advanced XIP File System is a Linux kernel filesystem driver that enables files to be executed directly from flash or ROM memory rather than being copied into RAM. It has the ability to store individual *pages* in a file uncompressed/XIP or compressed/Demand Paged.
At the moment, the FS is not supported in Linux mainline (v4.3-rc5), so the kernel has to be built with the axfs patches to be able to read it. Patches can be found here: https://github.com/jaredeh/axfs
NOTE: adding this as a kernel extension is planned.
The mkfs.axfs utility is used to create an AXFS file system image. It can receive an additional argument using the -i flag which points to a CSV file that indicates which pages the user desires to have marked for XIP within the file system image.
This patch only adds support for 'XIP all' mode, so all the files that have the execute attribute set will be XIP'ed. Support for more options (including AXFS profiling tool) will be submitted in following patches.
More info can be found here:
* http://elinux.org/AXFS
* http://www.academypublisher.com/ojs/index.php/jcp/article/viewFile/03017989/370
* http://docslide.us/documents/application-execute-in-place-xip-with-linux-and-axfs.html
Changes from v2:
* Added host-zlib as a dependency.
* Fixed LICENSE_FILES path.
* Expanded explanation in config help.
Changes from v1:
* Removed unnecessary call to $(generic-package) in axfsutils.mk.
Thanks,
Ariel D'Alessandro (2):
axfsutils: add new package
axfs: add new filesystem type
fs/Config.in | 1 + fs/axfs/Config.in | 16 ++++++++++++++++ fs/axfs/axfs.mk | 13 +++++++++++++ package/axfsutils/axfsutils.mk | 23 +++++++++++++++++++++++ 4 files changed, 53 insertions(+) create mode 100644 fs/axfs/Config.in create mode 100644 fs/axfs/axfs.mk create mode 100644 package/axfsutils/axfsutils.mk
Signature · 1 line
2.6.1
PATCH v3 1/2 axfsutils: add new package
Tools for building AXFS Filesystem.
The Advanced XIP File System is a Linux kernel filesystem driver that enables files to be executed directly from flash or ROM memory rather than being copied into RAM. It has the ability to store individual *pages* in a file uncompressed/XIP or compressed/Demand Paged.
Source:
https://github.com/jaredeh/axfs
--- package/axfsutils/axfsutils.mk | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 package/axfsutils/axfsutils.mk
package/axfsutils/axfsutils.mk new file +23 -0
@@ -0,0 +1,23 @@ +################################################################################ +# +# axfsutils +# +################################################################################ + +AXFSUTILS_VERSION = f26ae785e33df76f658b71ef2cfbc7f511ff875d +AXFSUTILS_SITE = $(call github,jaredeh,axfs,$(AXFSUTILS_VERSION)) +AXFSUTILS_LICENSE = GPLv2 +AXFSUTILS_LICENSE_FILES = mkfs.axfs-legacy/COPYING +AXFSUTILS_DEPENDENCIES = host-zlib + +# The 'new' mkfs.axfs version requires GNUstep which is not a buildroot +# prerequisite. The 'legacy' one works just as well without that requirement. +define HOST_AXFSUTILS_BUILD_CMDS + $(HOST_MAKE_ENV) $(MAKE) -C $(@D)/mkfs.axfs-legacy +endef + +define HOST_AXFSUTILS_INSTALL_CMDS + cp $(@D)/mkfs.axfs-legacy/mkfs.axfs $(HOST_DIR)/usr/bin/ +endef + +$(eval $(host-generic-package))
Signature · 1 line
2.6.1
PATCH v3 1/2 axfsutils: add new package
Dear Ariel D'Alessandro,
Quoted 7 lines · Ariel D'Alessandro
Tools for building AXFS Filesystem.
The Advanced XIP File System is a Linux kernel filesystem driver that enables files to be executed directly from flash or ROM memory rather than being copied into RAM. It has the ability to store individual *pages* in a file uncompressed/XIP or compressed/Demand Paged.
Quoted 8 lines
Source:
https://github.com/jaredeh/axfsSigned-off-by Ariel D'Alessandro <[email protected]>--- package/axfsutils/axfsutils.mk | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 package/axfsutils/axfsutils.mk
Applied with some minor tweaks:
[Thomas:
- add hash file.
- use $(INSTALL) -D -m 0755 instead of cp for installing mkfs.axfs.]
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH v3 2/2 axfs: add new filesystem type
In reply to Ariel D'AlessandroThe Advanced XIP File System is a Linux kernel filesystem driver that enables files to be executed directly from flash or ROM memory rather than being copied into RAM. It has the ability to store individual *pages* in a file uncompressed/XIP or compressed/Demand Paged.
This commit only adds support for 'XIP all' mode, so all the files that have the execute attribute set will be XIP'ed.
At the moment, the FS is not supported in Linux mainline (v4.3-rc5), so the kernel has to be built with the axfs patches to be able to read it. Patches can be found here: https://github.com/jaredeh/axfs
--- fs/Config.in | 1 + fs/axfs/Config.in | 16 ++++++++++++++++ fs/axfs/axfs.mk | 13 +++++++++++++ 3 files changed, 30 insertions(+) create mode 100644 fs/axfs/Config.in create mode 100644 fs/axfs/axfs.mk
fs/Config.in +1 -0
@@ -1,5 +1,6 @@ menu "Filesystem images" +source "fs/axfs/Config.in" source "fs/cloop/Config.in" source "fs/cpio/Config.in" source "fs/cramfs/Config.in"
fs/axfs/Config.in new file +16 -0
@@ -0,0 +1,16 @@ +config BR2_TARGET_ROOTFS_AXFS + bool "axfs root filesystem" + help + The Advanced XIP File System is a Linux kernel filesystem driver + that enables files to be executed directly from flash or ROM + memory rather than being copied into RAM. It has the ability to + store individual *pages* in a file uncompressed/XIP or + compressed/Demand Paged. + + So far, the only supported mode is 'XIP all', so all the files + that have the execute attribute set will be XIP'ed. + + At the moment, the FS is not supported in Linux mainline + (v4.3-rc5), so the kernel has to be built with the axfs patches + to be able to read it. Patches can be found here: + https://github.com/jaredeh/axfs
fs/axfs/axfs.mk new file +13 -0
@@ -0,0 +1,13 @@ +################################################################################ +# +# Build the axfs root filesystem image +# +################################################################################ + +ROOTFS_AXFS_DEPENDENCIES = host-axfsutils + +define ROOTFS_AXFS_CMD + $(HOST_DIR)/usr/bin/mkfs.axfs -s -a $(TARGET_DIR) $@ +endef + +$(eval $(call ROOTFS_TARGET,axfs))
Signature · 1 line
2.6.1
PATCH v3 2/2 axfs: add new filesystem type
Dear Ariel D'Alessandro,
Quoted 12 lines · Ariel D'Alessandro
The Advanced XIP File System is a Linux kernel filesystem driver that enables files to be executed directly from flash or ROM memory rather than being copied into RAM. It has the ability to store individual *pages* in a file uncompressed/XIP or compressed/Demand Paged.
This commit only adds support for 'XIP all' mode, so all the files that have the execute attribute set will be XIP'ed.
At the moment, the FS is not supported in Linux mainline (v4.3-rc5), so the kernel has to be built with the axfs patches to be able to read it. Patches can be found here: https://github.com/jaredeh/axfs
Quoted 8 lines
Signed-off-by Ariel D'Alessandro <[email protected]>--- fs/Config.in | 1 + fs/axfs/Config.in | 16 ++++++++++++++++ fs/axfs/axfs.mk | 13 +++++++++++++ 3 files changed, 30 insertions(+) create mode 100644 fs/axfs/Config.in create mode 100644 fs/axfs/axfs.mk
Applied with some minor tweaks:
[Thomas: rewrap Config.in help text.]
Thanks!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com