From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753758AbdLTQXd (ORCPT ); Wed, 20 Dec 2017 11:23:33 -0500 Received: from mx2.suse.de ([195.135.220.15]:39483 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751684AbdLTQX3 (ORCPT ); Wed, 20 Dec 2017 11:23:29 -0500 Subject: Re: [RFC PATCH v2 00/13] Kernel based bootsplash To: Daniel Vetter Cc: Neil Armstrong , Bartlomiej Zolnierkiewicz , Linux Fbdev development list , michal@markovi.net, sndirsch@suse.com, Oliver Neukum , Takashi Iwai , dri-devel , Linux Kernel Mailing List , =?UTF-8?Q?Bero_Rosenkr=c3=a4nzer?= , philm@manjaro.org References: <20171213194755.3409-1-mstaudt@suse.de> <20171219161630.GI26573@phenom.ffwll.local> <2f8a1a08-911d-a511-2968-4d89418ac212@suse.de> <573d4050-7607-b8e4-7552-83966f551ba3@suse.de> <20171220094355.GJ26573@phenom.ffwll.local> <20171220101421.GM26573@phenom.ffwll.local> <5dc7f218-9113-fad3-c0a8-883c4bae4e02@suse.de> From: Max Staudt Message-ID: Date: Wed, 20 Dec 2017 17:23:26 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 12/20/2017 04:19 PM, Daniel Vetter wrote: > On Wed, Dec 20, 2017 at 4:11 PM, Daniel Vetter wrote: >> On Wed, Dec 20, 2017 at 3:55 PM, Max Staudt wrote: >>> On 12/20/2017 11:14 AM, Daniel Vetter wrote: >>>> btw since I'm probably sounding a bit too grumpy here: I'd very much >>>> support this. I think bootsplash in kernel has a bunch of uses, and it >>>> shouldn't be hard to get non-suse people to cheer for it (makes merging >>>> easier if it's not just a one-off hack). >>> >>> Thank you! >>> >>> As it seems, other people and distros are already interested - for example Manjaro. >>> >>> It's also a chance to (maybe in the near future) integrate with a splash painted by EFI and/or GRUB, before userspace has even started. >> >> Maybe I've sounded too optimistic now. >> >> So fundamentally I don't think an in-kernel bootsplash is a bad idea. >> But most likely you want this on a highly embedded system, which >> probably is compiled for your exact hw, with pretty much everything >> built in. Also, no fbcon, maybe even no vt subsystem at all. >> Definitely not your general purpose distro. >> >> Your proposal to work on top of fbcon doesn't fix that niche. >> >> Now for your problem, which seems to be to have a working bootsplash >> for a general purpose distro, specifically for the bug where plymouth >> prevents the real drm driver from loading: Adding an in-kernel >> bootsplash doesn't make any sense, at least not to me. Instead I think >> the right action is to fix the problem, both in the kernel and in >> userspace. >> >> All the problems below have fairly simple solutions, but there's imo >> no point in talking technical solutions for specific problems when >> we're trying to fix the wrong problem. > > Aside: The problem you think you need the vt/console subsystem for is > simple to fix with plain kms: kms works without fbdev, fbcon and the > entire vt subsystem. Dislay ownership is controlled through the drm > master concept. That's the exact same trick that we're using already > to figure out whether fbdev (not just fbcon) is allowed to touch the > display hw. So when there is no DRM master, then the FB emulation becomes active. Sure. But I still have to multiplex between the console and the splash. It seemed cleanest to do this inside the console. If there's a good way outside, that's just as good for me, and I'm happy to implement it. But please help me and point me at how to do it best. Ideally, in both FB and KMS contexts. Without using additional video RAM wherever possible. > So yeah, there's a solution, and a modern system definitely would not > want to get encumbered with the entire vt subsystem to be able to use > a bootsplash. David Herrman had the entire pile prototyped btw, > including userspace console on top of drm, emergency log on top of > drm, and replacement for simpledrm. Adding an in-kernel boot splash > would be fairly simple for this setup. It's just that no one else > cared enough to get it merged. So... the solution for being unable to implement a good splash in userspace is... to move the console into the userspace? A ton of people will beg to differ. And I'm afraid I have to disagree as well. To be clear, I dislike the nature of the VT subsystem as well. It's a hack. But it's such an incredibly useful hack that I'm willing to turn a blind eye to its ugliness. There's a good reason why we have a terminal emulator in the kernel itself, and I'd rather keep it around for a while longer. Max From mboxrd@z Thu Jan 1 00:00:00 1970 From: Max Staudt Date: Wed, 20 Dec 2017 16:23:26 +0000 Subject: Re: [RFC PATCH v2 00/13] Kernel based bootsplash Message-Id: List-Id: References: <20171213194755.3409-1-mstaudt@suse.de> <20171219161630.GI26573@phenom.ffwll.local> <2f8a1a08-911d-a511-2968-4d89418ac212@suse.de> <573d4050-7607-b8e4-7552-83966f551ba3@suse.de> <20171220094355.GJ26573@phenom.ffwll.local> <20171220101421.GM26573@phenom.ffwll.local> <5dc7f218-9113-fad3-c0a8-883c4bae4e02@suse.de> In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: Daniel Vetter Cc: Linux Fbdev development list , michal@markovi.net, Bartlomiej Zolnierkiewicz , sndirsch@suse.com, Oliver Neukum , Takashi Iwai , dri-devel , Linux Kernel Mailing List , Neil Armstrong , philm@manjaro.org, =?UTF-8?Q?Bero_Rosenkr=c3=a4nzer?= On 12/20/2017 04:19 PM, Daniel Vetter wrote: > On Wed, Dec 20, 2017 at 4:11 PM, Daniel Vetter wrote: >> On Wed, Dec 20, 2017 at 3:55 PM, Max Staudt wrote: >>> On 12/20/2017 11:14 AM, Daniel Vetter wrote: >>>> btw since I'm probably sounding a bit too grumpy here: I'd very much >>>> support this. I think bootsplash in kernel has a bunch of uses, and it >>>> shouldn't be hard to get non-suse people to cheer for it (makes merging >>>> easier if it's not just a one-off hack). >>> >>> Thank you! >>> >>> As it seems, other people and distros are already interested - for example Manjaro. >>> >>> It's also a chance to (maybe in the near future) integrate with a splash painted by EFI and/or GRUB, before userspace has even started. >> >> Maybe I've sounded too optimistic now. >> >> So fundamentally I don't think an in-kernel bootsplash is a bad idea. >> But most likely you want this on a highly embedded system, which >> probably is compiled for your exact hw, with pretty much everything >> built in. Also, no fbcon, maybe even no vt subsystem at all. >> Definitely not your general purpose distro. >> >> Your proposal to work on top of fbcon doesn't fix that niche. >> >> Now for your problem, which seems to be to have a working bootsplash >> for a general purpose distro, specifically for the bug where plymouth >> prevents the real drm driver from loading: Adding an in-kernel >> bootsplash doesn't make any sense, at least not to me. Instead I think >> the right action is to fix the problem, both in the kernel and in >> userspace. >> >> All the problems below have fairly simple solutions, but there's imo >> no point in talking technical solutions for specific problems when >> we're trying to fix the wrong problem. > > Aside: The problem you think you need the vt/console subsystem for is > simple to fix with plain kms: kms works without fbdev, fbcon and the > entire vt subsystem. Dislay ownership is controlled through the drm > master concept. That's the exact same trick that we're using already > to figure out whether fbdev (not just fbcon) is allowed to touch the > display hw. So when there is no DRM master, then the FB emulation becomes active. Sure. But I still have to multiplex between the console and the splash. It seemed cleanest to do this inside the console. If there's a good way outside, that's just as good for me, and I'm happy to implement it. But please help me and point me at how to do it best. Ideally, in both FB and KMS contexts. Without using additional video RAM wherever possible. > So yeah, there's a solution, and a modern system definitely would not > want to get encumbered with the entire vt subsystem to be able to use > a bootsplash. David Herrman had the entire pile prototyped btw, > including userspace console on top of drm, emergency log on top of > drm, and replacement for simpledrm. Adding an in-kernel boot splash > would be fairly simple for this setup. It's just that no one else > cared enough to get it merged. So... the solution for being unable to implement a good splash in userspace is... to move the console into the userspace? A ton of people will beg to differ. And I'm afraid I have to disagree as well. To be clear, I dislike the nature of the VT subsystem as well. It's a hack. But it's such an incredibly useful hack that I'm willing to turn a blind eye to its ugliness. There's a good reason why we have a terminal emulator in the kernel itself, and I'd rather keep it around for a while longer. Max From mboxrd@z Thu Jan 1 00:00:00 1970 From: Max Staudt Subject: Re: [RFC PATCH v2 00/13] Kernel based bootsplash Date: Wed, 20 Dec 2017 17:23:26 +0100 Message-ID: References: <20171213194755.3409-1-mstaudt@suse.de> <20171219161630.GI26573@phenom.ffwll.local> <2f8a1a08-911d-a511-2968-4d89418ac212@suse.de> <573d4050-7607-b8e4-7552-83966f551ba3@suse.de> <20171220094355.GJ26573@phenom.ffwll.local> <20171220101421.GM26573@phenom.ffwll.local> <5dc7f218-9113-fad3-c0a8-883c4bae4e02@suse.de> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Return-path: Received: from mx2.suse.de (mx2.suse.de [195.135.220.15]) by gabe.freedesktop.org (Postfix) with ESMTPS id 6BAC56E0DF for ; Wed, 20 Dec 2017 16:23:29 +0000 (UTC) In-Reply-To: Content-Language: en-US List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" To: Daniel Vetter Cc: Linux Fbdev development list , michal@markovi.net, Bartlomiej Zolnierkiewicz , sndirsch@suse.com, Oliver Neukum , Takashi Iwai , dri-devel , Linux Kernel Mailing List , Neil Armstrong , philm@manjaro.org, =?UTF-8?Q?Bero_Rosenkr=c3=a4nzer?= List-Id: dri-devel@lists.freedesktop.org T24gMTIvMjAvMjAxNyAwNDoxOSBQTSwgRGFuaWVsIFZldHRlciB3cm90ZToKPiBPbiBXZWQsIERl YyAyMCwgMjAxNyBhdCA0OjExIFBNLCBEYW5pZWwgVmV0dGVyIDxkYW5pZWxAZmZ3bGwuY2g+IHdy b3RlOgo+PiBPbiBXZWQsIERlYyAyMCwgMjAxNyBhdCAzOjU1IFBNLCBNYXggU3RhdWR0IDxtc3Rh dWR0QHN1c2UuZGU+IHdyb3RlOgo+Pj4gT24gMTIvMjAvMjAxNyAxMToxNCBBTSwgRGFuaWVsIFZl dHRlciB3cm90ZToKPj4+PiBidHcgc2luY2UgSSdtIHByb2JhYmx5IHNvdW5kaW5nIGEgYml0IHRv byBncnVtcHkgaGVyZTogSSdkIHZlcnkgbXVjaAo+Pj4+IHN1cHBvcnQgdGhpcy4gSSB0aGluayBi b290c3BsYXNoIGluIGtlcm5lbCBoYXMgYSBidW5jaCBvZiB1c2VzLCBhbmQgaXQKPj4+PiBzaG91 bGRuJ3QgYmUgaGFyZCB0byBnZXQgbm9uLXN1c2UgcGVvcGxlIHRvIGNoZWVyIGZvciBpdCAobWFr ZXMgbWVyZ2lu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