public inbox for isar-users@googlegroups.com
 help / color / mirror / Atom feed
* [PATCH v1] linux-module: remove double quotes around AUTOLOAD
@ 2022-03-03 11:47 Daniel Machon
  2022-03-03 14:15 ` Henning Schild
  2022-03-17 13:47 ` Anton Mikanovich
  0 siblings, 2 replies; 3+ messages in thread
From: Daniel Machon @ 2022-03-03 11:47 UTC (permalink / raw)
  To: isar-users; +Cc: Daniel Machon, Daniel Machon, Torsten Bonde Christensen

If the AUTOLOAD variable has more than 1 entry the for-loop in
do_prepare_build() doesn't expand and therefor result in a
one-line entry into the postinst file. This in turn gives the
wrong format for the /etc/modules (all module names are on the
same line) and therefor fails to load at startup.

Signed-off-by: Daniel Machon <dama@universal-robots.com>
Signed-off-by: Torsten Bonde Christensen <tbch@universal-robots.com>
---
 meta/recipes-kernel/linux-module/module.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/meta/recipes-kernel/linux-module/module.inc b/meta/recipes-kernel/linux-module/module.inc
index 968ac4c..fa13e41 100644
--- a/meta/recipes-kernel/linux-module/module.inc
+++ b/meta/recipes-kernel/linux-module/module.inc
@@ -30,7 +30,7 @@ TEMPLATE_VARS += "KERNEL_IMAGE_PKG KERNEL_HEADERS_PKG"
 do_prepare_build() {
     cp -r ${WORKDIR}/debian ${S}/
 
-    for module in "${AUTOLOAD}"; do
+    for module in ${AUTOLOAD}; do
         echo "echo $module >> /etc/modules" >> ${S}/debian/postinst
     done
 }
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] linux-module: remove double quotes around AUTOLOAD
  2022-03-03 11:47 [PATCH v1] linux-module: remove double quotes around AUTOLOAD Daniel Machon
@ 2022-03-03 14:15 ` Henning Schild
  2022-03-17 13:47 ` Anton Mikanovich
  1 sibling, 0 replies; 3+ messages in thread
From: Henning Schild @ 2022-03-03 14:15 UTC (permalink / raw)
  To: Daniel Machon; +Cc: isar-users, Daniel Machon, Torsten Bonde Christensen

Good catch!

Well written modules will know when to load and how to depend on each
other. MODULE_ALIAS MODULES_SOFTDEP and some more, but yes if your
modules do not do that and one package has multiple your patch is valid.

Thanks!
Henning

Am Thu,  3 Mar 2022 12:47:24 +0100
schrieb Daniel Machon <dmachon.dev@gmail.com>:

> If the AUTOLOAD variable has more than 1 entry the for-loop in
> do_prepare_build() doesn't expand and therefor result in a
> one-line entry into the postinst file. This in turn gives the
> wrong format for the /etc/modules (all module names are on the
> same line) and therefor fails to load at startup.
> 
> Signed-off-by: Daniel Machon <dama@universal-robots.com>
> Signed-off-by: Torsten Bonde Christensen <tbch@universal-robots.com>
> ---
>  meta/recipes-kernel/linux-module/module.inc | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/meta/recipes-kernel/linux-module/module.inc
> b/meta/recipes-kernel/linux-module/module.inc index 968ac4c..fa13e41
> 100644 --- a/meta/recipes-kernel/linux-module/module.inc
> +++ b/meta/recipes-kernel/linux-module/module.inc
> @@ -30,7 +30,7 @@ TEMPLATE_VARS += "KERNEL_IMAGE_PKG
> KERNEL_HEADERS_PKG" do_prepare_build() {
>      cp -r ${WORKDIR}/debian ${S}/
>  
> -    for module in "${AUTOLOAD}"; do
> +    for module in ${AUTOLOAD}; do
>          echo "echo $module >> /etc/modules" >> ${S}/debian/postinst
>      done
>  }


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v1] linux-module: remove double quotes around AUTOLOAD
  2022-03-03 11:47 [PATCH v1] linux-module: remove double quotes around AUTOLOAD Daniel Machon
  2022-03-03 14:15 ` Henning Schild
@ 2022-03-17 13:47 ` Anton Mikanovich
  1 sibling, 0 replies; 3+ messages in thread
From: Anton Mikanovich @ 2022-03-17 13:47 UTC (permalink / raw)
  To: Daniel Machon, isar-users; +Cc: Daniel Machon, Torsten Bonde Christensen

03.03.2022 14:47, Daniel Machon wrote:
> If the AUTOLOAD variable has more than 1 entry the for-loop in
> do_prepare_build() doesn't expand and therefor result in a
> one-line entry into the postinst file. This in turn gives the
> wrong format for the /etc/modules (all module names are on the
> same line) and therefor fails to load at startup.
>
> Signed-off-by: Daniel Machon <dama@universal-robots.com>
> Signed-off-by: Torsten Bonde Christensen <tbch@universal-robots.com>

Applied to next, thanks.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-03-17 13:47 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-03 11:47 [PATCH v1] linux-module: remove double quotes around AUTOLOAD Daniel Machon
2022-03-03 14:15 ` Henning Schild
2022-03-17 13:47 ` Anton Mikanovich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox