From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mediacenter.hi.pengutronix.de ([2001:6f8:1178:2::65]) by metis.ext.pengutronix.de with esmtp (Exim 4.72) (envelope-from ) id 1SCpUN-0002Th-Su for ptxdist@pengutronix.de; Wed, 28 Mar 2012 11:48:23 +0200 Received: from mol by mediacenter.hi.pengutronix.de with local (Exim 4.72) (envelope-from ) id 1SCpUN-0001CL-R8 for ptxdist@pengutronix.de; Wed, 28 Mar 2012 11:48:23 +0200 Date: Wed, 28 Mar 2012 11:48:23 +0200 From: Michael Olbrich Message-ID: <20120328094823.GB27119@pengutronix.de> References: <1332766310-1764-1-git-send-email-post@lespocky.de> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1332766310-1764-1-git-send-email-post@lespocky.de> Subject: Re: [ptxdist] [PATCH] add config and install symlink to let systemd load modules from /etc/modules Reply-To: ptxdist@pengutronix.de List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: ptxdist-bounces@pengutronix.de Errors-To: ptxdist-bounces@pengutronix.de To: ptxdist@pengutronix.de On Mon, Mar 26, 2012 at 02:51:50PM +0200, Alexander Dahl wrote: > systemd can statically load kernel modules at boot. This is done by > placing appropriate files *.conf in /etc/modules-load.d. To be > compatible with initmethod-busybox (e.g. if you switch between both) > just a symlink to /etc/modules is created like Debian does, too. PTXdist doesn't really support switching the initmethod at runtime. I'd prefer to just install /etc/modules-load.d/modules.conf. If you need both you can add the symlink in projectroot. Michael > Signed-off-by: Alexander Dahl > --- > rules/initmethod-systemd.in | 10 ++++++++-- > rules/initmethod-systemd.make | 7 +++++++ > 2 files changed, 15 insertions(+), 2 deletions(-) > > diff --git a/rules/initmethod-systemd.in b/rules/initmethod-systemd.in > index 07010b4..20a2f43 100644 > --- a/rules/initmethod-systemd.in > +++ b/rules/initmethod-systemd.in > @@ -11,6 +11,12 @@ config INITMETHOD_SYSTEMD_IFUPDOWN > help > Enable this to install services to handle networks with ifup/ifdown > > -endif > - > +config INITMETHOD_SYSTEMD_MODULES_LOAD > + bool > + prompt "load kernel modules at boot time" > + help > + Installs /etc/modules and links /etc/modules-load.d/modules.conf > + to it for statically loading kernel modules at boot time. This is > + the hacked systemd equivalent of /etc/init.d/modules ... > > +endif > diff --git a/rules/initmethod-systemd.make b/rules/initmethod-systemd.make > index 4a0667f..c3abee8 100644 > --- a/rules/initmethod-systemd.make > +++ b/rules/initmethod-systemd.make > @@ -53,6 +53,13 @@ ifdef PTXCONF_INITMETHOD_SYSTEMD_IFUPDOWN > @$(call install_copy, initmethod-systemd, 0, 0, 0755, /etc/network/if-pre-up.d) > endif > > +ifdef PTXCONF_INITMETHOD_SYSTEMD_MODULES_LOAD > + @$(call install_alternative, initmethod-systemd, 0, 0, 0644, \ > + /etc/modules) > + @$(call install_link, initmethod-systemd, ../modules, \ > + /etc/modules-load.d/modules.conf) > +endif > + > @$(call install_finish,initmethod-systemd) > > @$(call touch) > -- > 1.7.2.5 > > > -- > ptxdist mailing list > ptxdist@pengutronix.de > -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | -- ptxdist mailing list ptxdist@pengutronix.de