From owner-freebsd-current@freebsd.org Fri Aug 24 08:05:34 2018 Return-Path: Delivered-To: freebsd-current@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 1EF141082EF7 for ; Fri, 24 Aug 2018 08:05:34 +0000 (UTC) (envelope-from johalun0@gmail.com) Received: from mail-wm0-x232.google.com (mail-wm0-x232.google.com [IPv6:2a00:1450:400c:c09::232]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority G3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 8C4357C48F for ; Fri, 24 Aug 2018 08:05:33 +0000 (UTC) (envelope-from johalun0@gmail.com) Received: by mail-wm0-x232.google.com with SMTP id t25-v6so745020wmi.3 for ; Fri, 24 Aug 2018 01:05:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=+gzhCQTJn4Y6Xdac27QLPnIQIHsYM7X2ldpiPuT0pQc=; b=fEFs4BoLXQmAyy4ZWEl+upA+d7VZvMRwtegdZcy7mgTiGU5WrZmRURDx1gQQlTHMu4 ivC3U4pKPoTtGAJSsU43f7ZpdBu0Zk2KXVR94ns2kI1LbrxOnVF8AOMRpOiS+c/JcCWg bdOKUgNBEBVwiYBtagQH9zcFGpzXobizUZ+n0X8k8NKR0ZUeL76VENmfSFJOL+5DCBk7 dYapiSD1E2hWc/L6aw4Op887LrtTv0+7i54AMv1RZIWmafmLrNJnjqwBoEaW/Lp9b5lO Tcd+r+vwa4p0jzyHYKE+r9LKasJUq1dT1NHWVoTHQLwux3TAI4RoRXzIhx3QgawHTNKb SVEw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=+gzhCQTJn4Y6Xdac27QLPnIQIHsYM7X2ldpiPuT0pQc=; b=VcVQfXbZkQg3HMNhadn4TKXPcbck67+XUFMTqAphdO+EvxR/sxk7XtnpTZ3s+V5Mg5 bXnZ1NoPyHBBDkGEaZ1mHeGljyCgmkWUUoZNXamK2wk+m9zzRryQctWePfXn95TbDrpg aeVqqgh7YIfuUbMx2LQOCw84+OzWowh8pLNpg0f0iItrm8jrdxMqi6x+TSkIqlKZbRRK HXV2M+PUSGbT6jRhgcI7uhNZneUkAeVZ9vx2AxvE8fzB9pNew8ptOsAsVHYD7Cx6UErd /vYLEdJO2Mw2NQtpYmYHOf4V0m3fF0XYqHU1/DvkVDdZSbN9ew4AgoC0H7w5/8bT5mOO kRvQ== X-Gm-Message-State: APzg51CBaWolHKvZ2k/HbaMPlQnPHAWW11c0hUplzPxuiXPuX/25DhX2 UY/yhFbMun+axeV+zBi0g3DLIke7SySTc//kR8g6rZTj X-Google-Smtp-Source: ANB0VdbXnuqQ0x2wYYCIzJL/FlRqLKWLtOHCCpYPLPCvnkd/zKjRSl9cXWfQzX85dN+ozrjOrgZ+Ynf/FJsWamxmKDw= X-Received: by 2002:a1c:af53:: with SMTP id y80-v6mr637545wme.55.1535097930911; Fri, 24 Aug 2018 01:05:30 -0700 (PDT) MIME-Version: 1.0 From: Johannes Lundberg Date: Fri, 24 Aug 2018 10:04:54 +0200 Message-ID: Subject: priority of paths to kernel modules? To: freebsd-current Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.27 X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.27 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 24 Aug 2018 08:05:34 -0000 Hi Since we now stuck with drm2 in base for a few more years I have an idea would make things much smoother for many of us, hugely reduce the amount of bug reports we get and I think would be beneficial in other ways too. Current I run with something like this in /boot/loader.conf module_path="/boot/modules.drm-v4.16;/boot/modules;/boot/dtb;/boot/overlays" So I expect modules to be loaded in that order, with /boot/ LAST. However, if you look at this sysctl kern.module_path kern.module_path: /boot/kernel;/boot/modules.drm-v4.16;/boot/modules;/boot/dtb;/boot/overlays /boot/kernel is inserted first and probably modules in /boot/kernel have the highest priority. This is also proven by everyone wanting to use drm*kmods that get drm.ko from base loaded instead of the installed in /boot/modules. Please correct me if I'm wrong but if my understanding is correct this is a flaw and /boot/ should be inserted last so that any overlays or custom modules have higher priority than the default ones. I can imagine this is also useful when building custom modules and you don't want to overwrite or delete the default one in /boot/kernel... Cheers