From mboxrd@z Thu Jan 1 00:00:00 1970 From: Brice Waegeneire Subject: Re: 01/02: services: Allow modprobe to use "/etc/modprobe.d". Date: Mon, 06 Apr 2020 07:54:47 +0000 Message-ID: <00d7800adbfc1fa955ed503c1ba38e00@waegenei.re> References: <20200405110749.5469.24356@vcs0.savannah.gnu.org> <20200405110750.E368020A26@vcs0.savannah.gnu.org> <87v9mdhbxk.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([2001:470:142:3::10]:60060) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jLMar-0004wD-O9 for guix-devel@gnu.org; Mon, 06 Apr 2020 03:54:58 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1jLMaq-0002s4-6V for guix-devel@gnu.org; Mon, 06 Apr 2020 03:54:53 -0400 In-Reply-To: <87v9mdhbxk.fsf@gnu.org> List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane-mx.org@gnu.org Sender: "Guix-devel" To: =?UTF-8?Q?Ludovic_Court=C3=A8s?= Cc: guix-devel@gnu.org Hello Ludo', On 2020-04-05 21:15, Ludovic Courtès wrote: > guix-commits@gnu.org skribis: >> #~(begin >> (setenv "LINUX_MODULE_DIRECTORY" >> >> "/run/booted-system/kernel/lib/modules") >> + ;; FIXME: Remove this crutch when the patch >> #40422, >> + ;; updating to kmod 27 is merged. >> + (setenv "MODPROBE_OPTIONS" >> + "-C /etc/modprobe.d") > > [...] > >> + (services (cons* (service kernel-module-loader-service-type >> + '("ddcci" "ddcci_backlight")) >> + (simple-service 'ddcci-config etc-service-type >> + (list `("modprobe.d/ddcci.conf" >> + ,ddcci-config))) >> + %base-services)) > > Looking at this, I was wondering if it would be possible to not use > /etc/modprobe.d and instead have a way to tell the modprobe wrapper to > pass “-C /gnu/store/…-modprobe.d”, which would contain the right thing. > > Thoughts? What's the issue with using /etc/modrpobe.d? As noted in the comments I thought setting MODPROBE_OPTIONS was kinda of a hack; #40422[0] was there to fix it. But if you think it's appropriate to use this environment variable it can be done in a future “kernel-module-configuration-service-type” we discussed with Danny[1]. Instead of extending “etc-service-type” we would use “activation-service-type”, as “%modprobe-wrapper” is currently put in place by a simple activation service. [0]: https://issues.guix.info/issue/40422 [1]: https://issues.guix.info/issue/40274#29 - Brice