From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 53FD9C433F5 for ; Tue, 8 Feb 2022 13:42:31 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1358096AbiBHNma (ORCPT ); Tue, 8 Feb 2022 08:42:30 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39924 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S237619AbiBHNma (ORCPT ); Tue, 8 Feb 2022 08:42:30 -0500 Received: from mail-ej1-x62c.google.com (mail-ej1-x62c.google.com [IPv6:2a00:1450:4864:20::62c]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 79084C03FECE for ; Tue, 8 Feb 2022 05:42:29 -0800 (PST) Received: by mail-ej1-x62c.google.com with SMTP id st12so27525712ejc.4 for ; Tue, 08 Feb 2022 05:42:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ffwll.ch; s=google; h=date:from:to:cc:subject:message-id:mail-followup-to:references :mime-version:content-disposition:in-reply-to; bh=6maJYITlPCb5At2tK8fKqUeOaLx2xzFZeuz9bTxWtaA=; b=NXKKgezbC9q9uaMIRiYHTN4bTXXumjui8I6ooy0xz8c5Emc2s/AqQ2WgPMbFEB1JPi tt2C2CyOwM6xd/DPqgbd6nefn2Px3gvIEKg1+9NggBp29xPz1qIXxCAlvt5pzhWXmxWM zG6YqnU4MScmVN6BImvTWU9YxJONaSzMmUzyU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id :mail-followup-to:references:mime-version:content-disposition :in-reply-to; bh=6maJYITlPCb5At2tK8fKqUeOaLx2xzFZeuz9bTxWtaA=; b=Xwf7GTih3IhHBVLBo1p4gvVvbFKeyYxD8zNRXLKeq7a5ewLwXhOjxhFQieS484Ej4a yHXmziRVdV1zZAdj0S2WbqJt64egIaJKhjuIu67ChgdKeoKGx7DZieaFSUF1xQVG5LK7 lKy7ZHvPfR2BVzHdG7peX0tfom5Y9uroZgdDNns57Fnj24Crz9UMBOCLo+reIvis7Aek 6sBxiZApGA4P4j4R2FPNb7Y/2kX484DRpfRMThUWr9xjvK6/dnFtM6lol1UCKilD+g+I fNJi+jGW30BKY6Dr/OurmANQHmm2iHibaebKQmKcEmf0dzmlM4dTGdH81YPxVQyB4Gt/ 7NAA== X-Gm-Message-State: AOAM5338SbGoNzqRPTwGLzfR7850JOBtpesqPYEgQe/EFd7e9fdwJ3PX NdOKeYLcGPpurP6qFD552+RWLw== X-Google-Smtp-Source: ABdhPJyjB58jfzpksRF1ZWcvHtyXk7I9BbvVV9xbDrzhC2PMVDFWercPTHr2GmACQLgZcvydqAOBYg== X-Received: by 2002:a17:907:760a:: with SMTP id jx10mr3810310ejc.713.1644327748049; Tue, 08 Feb 2022 05:42:28 -0800 (PST) Received: from phenom.ffwll.local ([2a02:168:57f4:0:efd0:b9e5:5ae6:c2fa]) by smtp.gmail.com with ESMTPSA id i6sm4831019eja.132.2022.02.08.05.42.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 08 Feb 2022 05:42:27 -0800 (PST) Date: Tue, 8 Feb 2022 14:42:25 +0100 From: Daniel Vetter To: Sam Ravnborg Cc: Daniel Vetter , DRI Development , linux-fbdev@vger.kernel.org, Du Cheng , Tetsuo Handa , Intel Graphics Development , LKML , Claudio Suarez , Greg Kroah-Hartman , Daniel Vetter , Helge Deller Subject: Re: [PATCH 06/21] fbcon: delete delayed loading code Message-ID: Mail-Followup-To: Sam Ravnborg , DRI Development , linux-fbdev@vger.kernel.org, Du Cheng , Tetsuo Handa , Intel Graphics Development , LKML , Claudio Suarez , Greg Kroah-Hartman , Daniel Vetter , Helge Deller References: <20220131210552.482606-1-daniel.vetter@ffwll.ch> <20220131210552.482606-7-daniel.vetter@ffwll.ch> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Operating-System: Linux phenom 5.10.0-8-amd64 Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org On Thu, Feb 03, 2022 at 09:45:29PM +0100, Sam Ravnborg wrote: > Hi Daniel, > > On Mon, Jan 31, 2022 at 10:05:37PM +0100, Daniel Vetter wrote: > > Before > > > > commit 6104c37094e729f3d4ce65797002112735d49cd1 > > Author: Daniel Vetter > > Date: Tue Aug 1 17:32:07 2017 +0200 > > > > fbcon: Make fbcon a built-time depency for fbdev > > > > it was possible to load fbcon and fbdev drivers in any order, which > > means that fbcon init had to handle the case where fbdev drivers where > > already registered. > > > > This is no longer possible, hence delete that code. > > > > Note that the exit case is a bit more complex and will be done in a > > separate patch. > > > > Signed-off-by: Daniel Vetter > > Cc: Helge Deller > > Cc: Daniel Vetter > > Cc: Claudio Suarez > > Cc: Greg Kroah-Hartman > > Cc: Tetsuo Handa > > Cc: Du Cheng > > --- > > drivers/video/fbdev/core/fbcon.c | 13 +------------ > > 1 file changed, 1 insertion(+), 12 deletions(-) > > > > diff --git a/drivers/video/fbdev/core/fbcon.c b/drivers/video/fbdev/core/fbcon.c > > index 8f971de35885..814b648e8f09 100644 > > --- a/drivers/video/fbdev/core/fbcon.c > > +++ b/drivers/video/fbdev/core/fbcon.c > > @@ -942,7 +942,7 @@ static const char *fbcon_startup(void) > > return display_desc; > > /* > > * Instead of blindly using registered_fb[0], we use info_idx, set by > > - * fb_console_init(); > > + * fbcon_fb_registered(); > > */ > This comment change looks like it does not belong in this patch. > Also, the comment is wrong as info_idx is set in several places. > Like set_con2fb_map(), fbcon_remap_all(), and more. Yeah I can split this out into a separate patch, but I spotted this wrong comment as part of reviewing this code change here - essentially you have to check how fb_info for fbcon are registered and fbcon init happens to validate that deleting the below code is correct. Ok if I put this explainer into the commit message, or do you want me to split this out fully? -Daniel > > Though it is not set by fb_console_init - so partly OK. > > With the comment adjustment dropped. > Acked-by: Sam Ravnborg > > at least the code deletion looked OK, I failed to follow all the logic. > So would be good if someone else could ack it too. > > Sam > > > > > info = registered_fb[info_idx]; > > if (!info) > > @@ -3316,17 +3316,6 @@ static void fbcon_start(void) > > return; > > } > > #endif > > - > > - if (num_registered_fb) { > > - int i; > > - > > - for_each_registered_fb(i) { > > - info_idx = i; > > - break; > > - } > > - > > - do_fbcon_takeover(0); > > - } > > } > > > > static void fbcon_exit(void) > > -- > > 2.33.0 -- Daniel Vetter Software Engineer, Intel Corporation http://blog.ffwll.ch