[openwrt/openwrt] generic: enable RELR relocations

LEDE Commits lede-commits at lists.infradead.org
Mon Sep 16 13:47:48 PDT 2024


robimarko pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/7e1d0925526a104364630b7af5355b799ef884d9

commit 7e1d0925526a104364630b7af5355b799ef884d9
Author: Robert Marko <robimarko at gmail.com>
AuthorDate: Mon Sep 16 11:51:45 2024 +0200

    generic: enable RELR relocations
    
    RELR is a relocation packing format for relative relocations.
    
    Linux has supported using it for ARM64 since 5.4, and more recently
    for LoongArch as well.
    
    It requires compatible tooling as well, so only with binutils 2.43
    TOOLS_SUPPORT_RELR is set and thus RELR available.
    
    RELR should always decrease the binary size and while testing this
    the default build for Dynalink WRX-36 (qualcommax/ipq807x) reduced
    the compressed kernel size by 38k and uncompressed one by 640k.
    
    So, lets enable it in the default config.
    
    Link: https://github.com/openwrt/openwrt/pull/16403
    Signed-off-by: Robert Marko <robimarko at gmail.com>
---
 target/linux/generic/config-5.15 | 1 +
 target/linux/generic/config-6.1  | 1 +
 target/linux/generic/config-6.6  | 1 +
 3 files changed, 3 insertions(+)

diff --git a/target/linux/generic/config-5.15 b/target/linux/generic/config-5.15
index a34ba551be..4c5b808799 100644
--- a/target/linux/generic/config-5.15
+++ b/target/linux/generic/config-5.15
@@ -5074,6 +5074,7 @@ CONFIG_REISERFS_FS_XATTR=y
 # CONFIG_REISERFS_PROC_INFO is not set
 # CONFIG_RELAY is not set
 # CONFIG_RELOCATABLE is not set
+CONFIG_RELR=y
 # CONFIG_REMOTEPROC is not set
 # CONFIG_RENESAS_PHY is not set
 # CONFIG_RESET_ATH79 is not set
diff --git a/target/linux/generic/config-6.1 b/target/linux/generic/config-6.1
index ef61717d78..f6163e3294 100644
--- a/target/linux/generic/config-6.1
+++ b/target/linux/generic/config-6.1
@@ -5280,6 +5280,7 @@ CONFIG_REISERFS_FS_XATTR=y
 # CONFIG_REISERFS_PROC_INFO is not set
 # CONFIG_RELAY is not set
 # CONFIG_RELOCATABLE is not set
+CONFIG_RELR=y
 # CONFIG_REMOTEPROC is not set
 # CONFIG_RENESAS_PHY is not set
 # CONFIG_RESET_ATH79 is not set
diff --git a/target/linux/generic/config-6.6 b/target/linux/generic/config-6.6
index 71fdf59d33..eb8011d3f7 100644
--- a/target/linux/generic/config-6.6
+++ b/target/linux/generic/config-6.6
@@ -4977,6 +4977,7 @@ CONFIG_REISERFS_FS_XATTR=y
 # CONFIG_REISERFS_PROC_INFO is not set
 # CONFIG_RELAY is not set
 # CONFIG_RELOCATABLE is not set
+CONFIG_RELR=y
 # CONFIG_REMOTEPROC is not set
 # CONFIG_RENESAS_PHY is not set
 # CONFIG_RESET_ATH79 is not set




More information about the lede-commits mailing list