From mboxrd@z Thu Jan 1 00:00:00 1970 X-GM-THRID: 6576101197771440128 X-Received: by 2002:a1c:7003:: with SMTP id l3-v6mr3128420wmc.28.1534673880625; Sun, 19 Aug 2018 03:18:00 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a1c:3f44:: with SMTP id m65-v6ls2733250wma.6.gmail; Sun, 19 Aug 2018 03:18:00 -0700 (PDT) X-Google-Smtp-Source: AA+uWPxQ44Ymch3wLdWX3xYZR7KpYwWqp4lpmQc5lCqF0T/Dd3gFrveCLIY5Qxr7aFNMpWRP2hS+ X-Received: by 2002:a1c:99cf:: with SMTP id b198-v6mr3262428wme.14.1534673880250; Sun, 19 Aug 2018 03:18:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1534673880; cv=none; d=google.com; s=arc-20160816; b=n0NdG1p92mTs9gH9xPhE8jmaeJkUG4PnyF7bv/46QyMn20gYF9J3I6PXBau6gN2KhJ NRjgRvt2PGYdgrrx059OJMT0NOhQhtP/CQUryOP9BXkJbcQj7MC9UWGiuIM/x+FA3BgL SVmKyfzSZ8Iy0gMWZ/4qASukOKJtUBg6SZoQ2JCIrsI0t4ebfi2eIeYv1O/0Zc7fX0Kg P9ECqfTo3SEfg5NS5WuKkorBuROWSYanS6I/bNiweCJuqEc+49PwMU3aUpvaHS1NNEHT rGaefYkuaSDHH8OA5yOABg43Rby1hK6G57EnTHuOMyxUBjJZ/8wjshJvrSaGlnl06Q4e ZQAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:content-language:in-reply-to:mime-version :user-agent:date:message-id:references:to:from:subject :arc-authentication-results; bh=jc+fw07bcgtKx1Cp+sZ4cA60KpogdowRpAdmtTjm2UY=; b=smlvnZ7pSfLolsn5ZO1EpbsfgKc4TXuUp2dBRAYK4KlarAwyvDVEWlOQ3nTT/1v91+ k/v5PJHvgSHDeQrEKm3dVxX00THCl1sLiP5HgompEbu5+QlB4Rfaq0HDSvjwHB8wX+q2 r5kkO0KMc/hzcvCFeu3N0g5CfLQCF4HUqVx4f2dpZc25TGgUdo2QMuBwWxDRsR0weerl ERsg0xG9FEtTb/QGS919vn4l1L2ECw2GatZIp/hRd/uPK3UB/NvKsOj2AJ1wcbJXug96 zJmYHGRYYmQfGhWMVKT4eQh5yEj3LbH6Vn1uYMj1Ae0IS/49t+rL2CviQrN6bUppnGSM wFJw== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of jan.kiszka@web.de designates 212.227.17.11 as permitted sender) smtp.mailfrom=jan.kiszka@web.de Return-Path: Received: from mout.web.de (mout.web.de. [212.227.17.11]) by gmr-mx.google.com with ESMTPS id y13-v6si83337wrd.3.2018.08.19.03.18.00 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Sun, 19 Aug 2018 03:18:00 -0700 (PDT) Received-SPF: pass (google.com: domain of jan.kiszka@web.de designates 212.227.17.11 as permitted sender) client-ip=212.227.17.11; Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of jan.kiszka@web.de designates 212.227.17.11 as permitted sender) smtp.mailfrom=jan.kiszka@web.de Received: from [192.168.1.10] ([95.157.57.47]) by smtp.web.de (mrweb103 [213.165.67.124]) with ESMTPSA (Nemesis) id 0MOzoR-1foKMy344d-006S21; Sun, 19 Aug 2018 12:17:59 +0200 Subject: Re: [PATCH v3] meta: Run depmod after kernel module installation From: Jan Kiszka To: isar-users , Maksim Osipov References: <9eb9c94c-e048-68f1-5662-fcb233ef7ff5@siemens.com> Message-ID: <818c50bb-6998-96a2-dc8f-7082631fd10c@web.de> Date: Sun, 19 Aug 2018 12:17:58 +0200 User-Agent: Mozilla/5.0 (X11; U; Linux i686 (x86_64); de; rv:1.8.1.12) Gecko/20080226 SUSE/2.0.0.12-1.1 Thunderbird/2.0.0.12 Mnenhy/0.7.5.666 MIME-Version: 1.0 In-Reply-To: <9eb9c94c-e048-68f1-5662-fcb233ef7ff5@siemens.com> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K1:lUaB+yDfh5m+BXGxeebcCjk8jF8tFkCcWlb0l8dCFkQBMh2+pU9 wf5nySE0mpBZCCxajZ54LhA/z060iqV1Ed6ACC/9xv5/lc0L7AKopW4ykZfAwTT2WzIeSEH iiegt1nwjs71hb+XMzssJWyNd65b7285J5A5t3hbrAR00fBcdmO4kn2oWRgH64fXYyr5PeJ kj/bq/eszAZuieigwP+tw== X-UI-Out-Filterresults: notjunk:1;V01:K0:C22n7Hwx0Ws=:kshd9fvjvzDBttkedEeCM4 GoZ3t6C3YkyAo+PEGKUClohtny1iVX5pkOdRs2DBC8gISLEqj72VpnsubO58Yd8bc/THuA3v5 Iq2mTEMKl16llSLqrj37aNhmyRiVtoeLTyVgeDsn10vG1JnYOXneEAoasl4no4Y1F22uy/Sw4 dTSm9d8TE4jTUMYwdeUZSzWa1Hu9KzefTwQ4JrQ1HObrZtwARY9W5DuZLF3qm3ifEjzBB80nf pYm6LKRtkJM7Uzvza2E6p90Cvk+UjwTni8HxfOZcv9MkaV7ktwE5ihJD7Dyanjz8MvA+V4Oqd bwTEHQ6tT1ndk1ZuUkyGYXwDlgHiKkImQ8CSfb/GhaQ2UxOUA67duSrNjbvQlUmgP4tJY9K5D RML6zDeggfEFh0XUphXThG2lK4xNEAwiqypUQBZ5DfVq82pYNKcjYdPzqDPdSBRJjQyRiloVb smXpHyLOvV/jSCNlHcRa4IH+wB447SIGcC0FdL7Nlli2e1k+dm4zPC5AfFhIRyypqwwnBkaEX m/uOczK3MajKr2Gd6RaKh/FidxBv/ZKuAXa+tdrZuKzW17aF1vMjfLEjAuWsLcI2LT48qVz9M 6sopzMM8CdJVQpSKYpWNDj5vDpG/UGCYml0+T8tUu6lLdtMO6RW7iDd6CEpztV/NyJE3FCQp2 4KuWn0RfXfZlNfR8fk8s/XuqDdqwcqXCSWW6/YeulZ7u78ZvG18uL2SI/tIOoMq7MAvFNbUnQ Q5sRmTsfgrFuwA/CliaaGO7wjHbUhyldURQmZuI8Atb2UX5F/S9/cuwMsE+FzWj4nncO5Kjge vZvNxHU X-TUID: y9hZ80yxLJAx On 2018-08-19 09:23, [ext] Jan Kiszka wrote: > On 2018-07-09 11:50, [ext] Jan Kiszka wrote: >> Otherwise the module may not be found if the module package is installed >> on its own, i.e. without the kernel package performing the depmod run. >> >> As we now install a postinst baseline with the right mode, the chmod on >> AUTOLOAD becomes obsolete. >> >> Signed-off-by: Jan Kiszka >> --- >> >> Changes in v3: >>   - remove now obsolete chmod on AUTOLOAD >> >>   meta/recipes-kernel/linux-module/files/debian/postinst | 4 ++++ >>   meta/recipes-kernel/linux-module/module.inc            | 1 - >>   2 files changed, 4 insertions(+), 1 deletion(-) >>   create mode 100755 >> meta/recipes-kernel/linux-module/files/debian/postinst >> >> diff --git a/meta/recipes-kernel/linux-module/files/debian/postinst >> b/meta/recipes-kernel/linux-module/files/debian/postinst >> new file mode 100755 >> index 0000000..baabf5d >> --- /dev/null >> +++ b/meta/recipes-kernel/linux-module/files/debian/postinst >> @@ -0,0 +1,4 @@ >> +#!/bin/sh >> +set -e >> + >> +depmod -a >> diff --git a/meta/recipes-kernel/linux-module/module.inc >> b/meta/recipes-kernel/linux-module/module.inc >> index 3075f44..76a49f3 100644 >> --- a/meta/recipes-kernel/linux-module/module.inc >> +++ b/meta/recipes-kernel/linux-module/module.inc >> @@ -26,6 +26,5 @@ dpkg_runbuild_prepend() { >>       if [ ${AUTOLOAD} = "1" ]; then >>           echo "echo ${PN} >> /etc/modules" >> ${S}/debian/postinst >> -        chmod +x ${S}/debian/postinst >>       fi >>   } >> > > Ping. Seems this fell through the cracks. > > Jan > OK, this does not yet work, at least when run during image generation: depmod will pick of the host kernel version, not that of the target, and will fail if the differ (quite likely). That "set -e" needs to go, just like in [1]. Will send v4. Jan [1] https://github.com/siemens/jailhouse-images/commit/2a66ef8e7f86496ae919ed84cd95370a2ddb7b91#diff-61a459fb1abcb39646b0e3661640ecbf