From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754169AbcICSKI (ORCPT ); Sat, 3 Sep 2016 14:10:08 -0400 Received: from mail-vk0-f66.google.com ([209.85.213.66]:34193 "EHLO mail-vk0-f66.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753716AbcICSKE (ORCPT ); Sat, 3 Sep 2016 14:10:04 -0400 MIME-Version: 1.0 In-Reply-To: References: <1466117661-22075-3-git-send-email-mcgrof@kernel.org> <20160824203901.GT3296@wotan.suse.de> <20160825194133.GC3296@wotan.suse.de> <20160902235916.GO3296@wotan.suse.de> <20160903002014.GP3296@wotan.suse.de> <20160903174939.GB32345@dtor-ws> From: Dmitry Torokhov Date: Sat, 3 Sep 2016 11:10:02 -0700 Message-ID: Subject: Re: [RFC] fs: add userspace critical mounts event support To: Linus Torvalds Cc: "open list:DOCUMENTATION" , cocci@systeme.lip6.fr, Jacek Anaszewski , David Woodhouse , Christian Lamparter , Julia Lawall , Andrew Morton , linuxppc-dev , Mimi Zohar , Andy Lutomirski , Richard Purdie , Wu Fengguang , Johannes Berg , "Luis R. Rodriguez" , Michal Marek , Hauke Mehrtens , Mark Brown , Jiri Slaby , Ming Lei , Daniel Vetter , Kevin Cernekee , Jeff Mahoney , Greg KH , Bjorn Andersson , Jonathan Corbet , Felix Fietkau , David Howells , Vikram Mulukutla , Alessandro Rubini , Tom Gundersen , Kees Cook , Takashi Iwai , Gilles.Muller@lip6.fr, linux-serial , Roman Pen , Kay Sievers , Stephen Boyd , nicolas.palix@imag.fr, "Abhay_Salunke@dell.com" , Linux Kernel Mailing List , Thierry Martinez , Josh Boyer Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, Sep 3, 2016 at 11:01 AM, Linus Torvalds wrote: > On Sat, Sep 3, 2016 at 10:49 AM, Dmitry Torokhov > wrote: >> >> Unfortunately module loading and availability of firmware is very >> loosely coupled. > > The whole "let's add a new magical proc entry to say that all > filesystems are mounted" is all about the user space coupling them. I will be first to say that the proposed *implementation* is nowhere near what should be accepted. I was thinking if we kernel could post "conditions" (maybe simple stings) that it waits for, and userspace could unlock these "conditions". One of them might be "firmware available". > > I'm just saying that if user space must know about when firmware is > ready to be loaded anyway, just do it rigth. Not with some hacky "you > can now do random things" flag. But by having user space actually say > "put this module together with this firmware". > > If you just put the two pieces together, then the module "will just work". > > And quite frankly, that sounds like a much better maintenance practice > anyway. If some module doesn't work without the firmware, then dammit, > the two *should* go together. Putting them in two different places > would be *INSANE*. Quite often it does until it does not. Most of the touch controllers work just fine until some event (abrupt cutting of power for example) where nvram gets corrupted and they come up in bootloader mode. It is just an example. Thanks. -- Dmitry