Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755341AbdLTNOi (ORCPT ); Wed, 20 Dec 2017 08:14:38 -0500 Received: from mx2.suse.de ([195.135.220.15]:51525 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755215AbdLTNOe (ORCPT ); Wed, 20 Dec 2017 08:14:34 -0500 Subject: Re: [RFC PATCH v2 03/13] bootsplash: Flush framebuffer after drawing To: Ray Strode Cc: b.zolnierkie@samsung.com, linux-fbdev@vger.kernel.org, michal@markovi.net, sndirsch@suse.com, oneukum@suse.com, tiwai@suse.com, dri-devel@lists.freedesktop.org, "Linux-Kernel@Vger. Kernel. Org" , bernhard.rosenkranzer@linaro.org, philm@manjaro.org References: <20171213194755.3409-1-mstaudt@suse.de> <20171213194755.3409-4-mstaudt@suse.de> <20171213213506.GD26573@phenom.ffwll.local> <20171219122313.GE26573@phenom.ffwll.local> <8bbb0497-4a10-2f81-0040-6e7cd4e7353c@suse.de> <20171219135715.GG26573@phenom.ffwll.local> <8036b6a6-6ed5-2f34-e854-1c397a9f34d4@suse.de> From: Max Staudt Message-ID: Date: Wed, 20 Dec 2017 14:14:31 +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 Content-Length: 2644 Lines: 39 On 12/19/2017 10:01 PM, Ray Strode wrote: > Hi, > > On Tue, Dec 19, 2017 at 10:41 AM, Max Staudt wrote: >> I'm hooking into the in-kernel terminal emulator, because the bootsplash is a >> functional extension of that. It just happens that fbcon sits on top of FB, so I >> work with what I get. >> >> And the console in turn happens to work on all FB and KMS drivers, so it >> makes users of all kinds of drivers happy. In fact, that's why the FB emulation >> in KMS drivers came to be in the first place, if I remember right - to ensure >> fbcon continues to work. > > But what about multi-monitor? what about hidpi screens? Ideally you want > each monitor to show the splash in a way that best fits that monitor. Actually, I don't want that :) This was a design decision that I've made to keep the code small and simple to audit. As it is, the simple bootsplash code will make 99% of people happy. It includes positioning of objects in corners and in the center, and a background color, and thus can render something that doesn't look funny in all but the most extreme cases. I've made this decision from the point of view of someone who wants to ship a general purpose distribution. If you have a look around and compare this to e.g. the Windows or Mac OS X bootsplashes, the possibilities that my kernel code provides already surpasses them. If you really want such sophisticated features, supplanting the initial bootsplash with Plymouth (or not using it at all) is a better solution. In my opinion, it is overengineering, at least for kernel code. So... I'll just take what the fbdev emulation gives me. In most cases (single screen systems), this looks good. In most remaining cases, you have two identical monitors that show exactly the same thing. And whatever remains can live with whatever mode the DRM driver decides to set for the fbdev emulation. As for HiDPI, if you're working on an embedded device with a fixed screen size - say a phone - you can easily include a huge picture the size of the screen in the bootsplash. Again, it's feature creep now. Apple just centers a, well, an apple in the middle of the screen. Windows may even boot in 640x480 and then do a mode switch when showing the desktop (not sure whether this is still true with the latest version). Neither of them scales for HiDPI, and neither cares about multiple monitors. People are happy. So in the end, it's a matter of taste. I agree that in user space, exploring these features is fun. But in kernel space, it's definitely important to keep the code short and simple. I'm convinced that I've found a good balance :) Max