Skip to contentSkip to conversation

modules: Allow to use depmod from a non default install

PATCH In review Carmelo Amoroso 3 participants 6 messages Nov 8, 2009 – Dec 24, 2010 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 modules: Allow to use depmod from a non default install

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

---
 Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
Makefile +2 -1
index b4c04f7..f5286c4 100644
@@ -316,7 +316,8 @@ OBJDUMP             = $(CROSS_COMPILE)objdump
 AWK            = awk
 GENKSYMS       = scripts/genksyms/genksyms
 INSTALLKERNEL  := installkernel
-DEPMOD         = /sbin/depmod
+DEPMOD_PATH    ?= /sbin
+DEPMOD         = $(DEPMOD_PATH)/depmod
 KALLSYMS       = scripts/kallsyms
 PERL           = perl
 CHECK          = sparse

-- 1.6.3.3

#1 lore raw
Quoted 23 lines · Carmelo Amoroso

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

---
 Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
Makefile +0 -0
index b4c04f7..f5286c4 100644

Makefile OBJDUMP = $(CROSS_COMPILE)objdump

Quoted 10 lines
Makefile +2 -2
@@ -316,7 +316,8 @@ OBJDUMP             = $(CROSS_COMPILE)objdump
 AWK            = awk
 GENKSYMS       = scripts/genksyms/genksyms
 INSTALLKERNEL  := installkernel
-DEPMOD         = /sbin/depmod
+DEPMOD_PATH    ?= /sbin
+DEPMOD         = $(DEPMOD_PATH)/depmod
 KALLSYMS       = scripts/kallsyms
 PERL           = perl
 CHECK          = sparse
-- 1.6.3.3

Apologies for duplicated emails.
Please discard this last one.

Regards,
Carmelo

Acked-by on v1 1/1
#2 lore raw
In reply to Carmelo Amoroso
Quoted 12 lines · Carmelo Amoroso

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

Quoted 1 line
Quoted 24 lines

---
Makefile | 3 ++-

1 files changed, 2 insertions(+), 1 deletions(-)
Makefile +0 -0
index b4c04f7..f5286c4 100644
@@ -316,7 +316,8 @@ OBJDUMP             = $(CROSS_COMPILE)objdump
AWK            = awk
GENKSYMS       = scripts/genksyms/genksyms
INSTALLKERNEL  := installkernel
Makefile +2 -1
-DEPMOD         = /sbin/depmod
+DEPMOD_PATH    ?= /sbin
+DEPMOD         = $(DEPMOD_PATH)/depmod
KALLSYMS       = scripts/kallsyms
PERL           = perl
CHECK          = sparse

-- 1.6.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

Signature · 1 line
Live like a child, think like the god.
#3 lore raw
Quoted 13 lines · Américo Wang
Quoted 12 lines · Carmelo Amoroso

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

Quoted 5 lines
Quoted 1 line

Hi,
any plan to get it included ?

cheers,
carmelo

Quoted 25 lines
Quoted 24 lines

---
Makefile | 3 ++-

1 files changed, 2 insertions(+), 1 deletions(-)
Makefile +0 -0
index b4c04f7..f5286c4 100644
@@ -316,7 +316,8 @@ OBJDUMP             = $(CROSS_COMPILE)objdump
AWK            = awk
GENKSYMS       = scripts/genksyms/genksyms
INSTALLKERNEL  := installkernel
Makefile +2 -1
-DEPMOD         = /sbin/depmod
+DEPMOD_PATH    ?= /sbin
+DEPMOD         = $(DEPMOD_PATH)/depmod
KALLSYMS       = scripts/kallsyms
PERL           = perl
CHECK          = sparse

-- 1.6.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

#4 lore raw
Quoted 14 lines · Carmelo Amoroso
Quoted 13 lines · Américo Wang
Quoted 12 lines · Carmelo Amoroso

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

Quoted 9 lines
Quoted 5 lines
Quoted 1 line

Hi,
any plan to get it included ?

Hi,

I am not the maintainer, Sam was supposed to take this, but yesterday, he just gave his position out. So I expect Andrew or someone can take this.

Thanks.

Signature · 1 line
Live like a child, think like the god.
#5 lore raw
In reply to Carmelo Amoroso

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Quoted 20 lines · Carmelo Amoroso
Quoted 13 lines · Américo Wang
Quoted 12 lines · Carmelo Amoroso

This patch allow to specify the directory where to find the depmod tool other than being forced to use the module-init-tools installed on the host. The reason for this is explained below. When doing cross-compilation, it not guaranteed that the module-init-tools installed on the host (and used during kernel build) are exactly the same and compatible with those used on the target at runtime. For example, recent changes in how depmod writes modules.dep using root-less path, make older modprobe unusable on the target.
User in ths case could install in a different path the module-init-tools compatible with the version used on the target and specify the path on the command line.

Quoted 5 lines
Quoted 1 line
Quoted 33 lines

Hi,
any plan to get it included ?

cheers,
carmelo

Quoted 25 lines
Quoted 24 lines

---
Makefile | 3 ++-

1 files changed, 2 insertions(+), 1 deletions(-)
Makefile +0 -0
index b4c04f7..f5286c4 100644
@@ -316,7 +316,8 @@ OBJDUMP = $(CROSS_COMPILE)objdump

AWK = awk
GENKSYMS = scripts/genksyms/genksyms
INSTALLKERNEL := installkernel

Makefile +2 -1
-DEPMOD = /sbin/depmod
+DEPMOD_PATH ?= /sbin
+DEPMOD = $(DEPMOD_PATH)/depmod

KALLSYMS = scripts/kallsyms
PERL = perl
CHECK = sparse
-- 1.6.3.3
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

ping... one year later.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.10 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAk0UTj8ACgkQoRq/3BrK1s99/wCglIZ37nvDw8g0/nKAt5KRsI6W M9AAnRVGSbEiod4jFCFhwRRxxofakEQa
=ZSKN
-----END PGP SIGNATURE-----