Received: by 2002:a25:5b86:0:0:0:0:0 with SMTP id p128csp897995ybb; Thu, 28 Mar 2019 14:35:14 -0700 (PDT) X-Google-Smtp-Source: APXvYqwLpAx+WiVi5+1Iwkn4ncEIivmBJx+IF5X2SWoadf2vAfSb+BulK8P/OijgWT41XSyMTD/Z X-Received: by 2002:a17:902:59c5:: with SMTP id d5mr11703676plj.104.1553808914247; Thu, 28 Mar 2019 14:35:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553808914; cv=none; d=google.com; s=arc-20160816; b=widk8Ra8YHM+EwXrgSP7/AOd8sPH3y9ej1G6cqvxCzqiOIjOokRda/EJOp/Va3Jn/R cyIiqwOqYwjTLROU+8hyf+1oKqifeklmdS9IP7Y0B8KG36xFs7BL8vpMYWLqxGJzjIQA L6xYLgPFv7Qgyo5xH9pDldPqHoYzYvYV3XUfDXGbuvIjTW0Uakao83Z87h24j6DDoQ3V /u/vc28VzC6TXvK8QYzN3odAFIAdEdlB/b8M20JffLLFTc6CmElckrRlz/qUkiItyclv yJMzB8d7OXcEPDiqydv+f1WO4+PAjzphqu+W4KgX4f+l5hobvgUraQGAGLUFBrwqIEQ0 xHDA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=BwJ3ahE9qKEzbgRpb2OvUo1z5D/jo/o/M5wFIL1CiC8=; b=zTnUSLsthYTuM4j+z61x9O5wtsUaCWuXlq5v3xcii+iA4uAx+jndz2U30D+b2DJSSl vBa7e/XAYCzS+MjoVbanuKw9/G22LwSDLOUEclyg0pq53h5Po+HJWXhpI5U+pe1Deylx 4XZAXg7CjzxI9+kdAPGW/gNWTCK923/NL6UjQrD0FhApFx+QZQ9OTCU1uwYufYn0a5xn ljj6EJZ7F5QD3XfzyappaCtpqHtMPW8QJAHRyFuO28yFT6HLqmM42NBOgyib3eamGhfF 4LDoJZc7ru2l8VhhOjY8vckapxXcZ3TXEN8hxz6IVwGGIEvWIAF/F9fVpk6Aqh36zlPV p8QQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="vcqB8L/6"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id r35si196512pgm.179.2019.03.28.14.34.58; Thu, 28 Mar 2019 14:35:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b="vcqB8L/6"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727766AbfC1VeK (ORCPT + 99 others); Thu, 28 Mar 2019 17:34:10 -0400 Received: from mail-it1-f196.google.com ([209.85.166.196]:54448 "EHLO mail-it1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726393AbfC1VeK (ORCPT ); Thu, 28 Mar 2019 17:34:10 -0400 Received: by mail-it1-f196.google.com with SMTP id w18so600234itj.4; Thu, 28 Mar 2019 14:34:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=BwJ3ahE9qKEzbgRpb2OvUo1z5D/jo/o/M5wFIL1CiC8=; b=vcqB8L/6O308V8thCNonQWMtwVOfoHxnu4a0MnxWmfzP/m8jOybmSO/xj42trCQIk+ O0yJkMdbThmKA/h+7Hk4i8Cftza4gVLypu+0zFcrz8j15m8CL8fTlvPzPLZDSPYlJrUS OjG4XXVdNjyuWOfs2oQtYl96Enx3xqw3qifk9aEhpYE65cBmarYVxoRx88rnWQmqEf61 +PCKTt7y5YXWg8MljOjtktzGfZcVMSC8pOZXhAFwM+cj/U5eFguxcbBd2sUdxq7bhIWl azhzx2tOsylMIws807slbs/zJS+Xh49i3xVXI1iGsXITJVi0zudz7549bqWkiF8iJwVQ QTAA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=BwJ3ahE9qKEzbgRpb2OvUo1z5D/jo/o/M5wFIL1CiC8=; b=tZuvt3QENu5KQqCXv+a039RgsvfSoLOHoiYfR/U020fQvKyy2CKKa/6X2Ubp8sRTgM OAJj4Fg6hgwtcVkyFaBpwrVi28kAjU4B9gTgztvCJu0jaBuln9Zca1lXWHBdatvq7ir0 7k3bDzaJqWJs95AGmWU0exYmPeP2g2CO1LOPTxECsIfpLUGD8wPm4/29VU5QajuS0wsh ZqF4I/Wyg8Hk4SgMLTnal2Vv5c2xoJtTh7LFz56PnE2WbTJssontzd1OybcBy8qJADkf 0E7BbTDoJ8/9Kpa5wDoiucFHYesZ6nQj48ktr7xQ4tV7zth4RVrTYjGarW1cmgyD4G6k uy9g== X-Gm-Message-State: APjAAAXYVcSp71/kYnnNTfsF5NJj06ud7HvoaBelciFOIwoGrxJEe7Yb WFcSZcHvdnpNdj+5vVEA1qRIePC3+1MboHx3hzg= X-Received: by 2002:a02:5541:: with SMTP id e62mr10689867jab.88.1553808848380; Thu, 28 Mar 2019 14:34:08 -0700 (PDT) MIME-Version: 1.0 References: <20190315101013.GN8455@Legion-PC.fortress> <20190326172411.GA15936@Legion-PC.fortress> <20190327154025.GB23293@linux-8ccs> <20190328184546.GB23800@kroah.com> In-Reply-To: <20190328184546.GB23800@kroah.com> From: Dmitry Torokhov Date: Thu, 28 Mar 2019 14:33:56 -0700 Message-ID: Subject: Re: [RESEND PATCH v1] moduleparam: Save information about built-in modules in separate file To: Greg KH Cc: Lucas De Marchi , Jessica Yu , Alexey Gladkov , Masahiro Yamada , Michal Marek , Linux Kernel Mailing List , Linux Kbuild mailing list , "open list:ABI/API" , "Kirill A . Shutemov" , Gleb Fotengauer-Malinovskiy , "Dmitry V. Levin" , Rusty Russell , linux-modules Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Mar 28, 2019 at 11:45 AM Greg KH wrote: > > On Thu, Mar 28, 2019 at 10:41:59AM -0700, Lucas De Marchi wrote: > > On Wed, Mar 27, 2019 at 8:40 AM Jessica Yu wrote: > > > >No. There are definitely not all modules. I have a builtin sha256_generic, > > > >but I can't find him in the /sys/module. > > > > > > Yeah, you'll only find builtin modules under /sys/module/ if it has any module > > > parameters, otherwise you won't find it there. As Masahiro already mentioned, > > > if a builtin module has any parameters, they would be accessible under /sys/module/. > > > > Could we please change that and add the sysfs entry regardless of > > what's being discussed here? Not having the entry there simply because > > we don't have parameters for that module always annoyed me. What is the benefit compared to wasting some memory for the directory? > > What is the sysfs directory going to show? Will it just be empty? > > Feel free to send a patch for this, but from what I remember, it wasn't > the easiest thing to do for some reason. But given that the code was > implemented before git was, I can't quite remember. I am pretty sure we allow empty attribute groups, so it is probbaly as simple as removing "If (!params) return 0;" form module_param_sysfs_setup() and making sure we always create "parameters" group instead of doing it on first visible parameter in add_sysfs_param(). I suppose we no longer want to skip over parameters that are not readable nor writable either? Thanks. -- Dmitry