Received: by 2002:a05:6a11:4021:0:0:0:0 with SMTP id ky33csp84302pxb; Tue, 21 Sep 2021 19:31:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw50whu5W8RujOywDJ1+0bAWEaF++3cPva+8dcboU3MPX1bNHP49D3bLYaa1BCRgVyUVztf X-Received: by 2002:a5e:c741:: with SMTP id g1mr2489562iop.67.1632277864622; Tue, 21 Sep 2021 19:31:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1632277864; cv=none; d=google.com; s=arc-20160816; b=K4vCqz39LijO3DMDFCHDbCW3bIovAJCpBTRbkI1f9s6SZLHOdgzrWM5SeGRJ6Yd3oJ Cu3US94ezmELL2SBxOpKwHEwNnO8ePy5rxT87JFGYum3v1/pXc7l4P0OHkZigCjTFNRq ep2PF2lAtDNucuz7BQXi28rjzK5s07xa/+g6MKslQSz+QlxYezROntU/REvel27IqHz3 r9VKKDOJsrXJ3RudmrRjk9IuBxCru5Gv1OTkw2Kb7ItPdwV8WXi0oxTiw59vhMaiSbN9 2yVW1v632FoxJ2JE5GLmi/QMwOBQXP2VmQt9f7YC0oYMpTGtIan/rAP/luahvvzZ9vcb /tFQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:date:message-id:from:references:cc:to :dkim-signature:subject; bh=qSuSnPieUDaOVO6CRq2eMJxdMYKzQp0LFeT47UvdBaA=; b=p7u/7dY3b9V5o6F6Te3VatYfsqaFApp77yNFtxVlkjLTV77sUAHyh4AJwvIIggnxs2 HM+12bzFe2jxiN71k/WiNPPi3mpyPpjy8KH02KNoDiVCvjHALc/GvtLN5o8Pp4O9Hy8C 5p3rL2ycZ1BcfpOaP75JDLH5uV8iIKRbQH3Mg0TA/q50Gg1lhYv0gJrsnSr/am3bZi99 AEKjInpdwx37wyEcgUYwz/EVqmCOeuN35LFX/WqdHRajjvYAZcYdgWDCZi2Y9gftcxR6 AQNiOc8+cEoxg4Y9Hee0XEdBAEoVp2FldpVYJmGeM+03XVOGBp7BMKMnd+7BCnw++oCz cssw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=bHOv9kgY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id x13si1030341ilg.76.2021.09.21.19.30.52; Tue, 21 Sep 2021 19:31:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linux.dev header.s=key1 header.b=bHOv9kgY; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linux.dev Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229807AbhIVCbc (ORCPT + 99 others); Tue, 21 Sep 2021 22:31:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60446 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229537AbhIVCba (ORCPT ); Tue, 21 Sep 2021 22:31:30 -0400 Received: from out1.migadu.com (out1.migadu.com [IPv6:2001:41d0:2:863f::]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B1BA2C061574 for ; Tue, 21 Sep 2021 19:30:01 -0700 (PDT) Subject: Re: [PATCH v3] mdacon: fix redefinition of 'scr_memsetw' DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1632277798; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qSuSnPieUDaOVO6CRq2eMJxdMYKzQp0LFeT47UvdBaA=; b=bHOv9kgYfeLnP/9rouj9kS6ktFMQL8roXXTHoqAVWT8PlGlga2p4uA2PV796StdYlsPOR7 D39DF/4vYaox2QojALbrTzzmrnAC2aO5c4rSZamixdfSpx6eRfLcLhhtNbhDVg1ap1eoV/ WkQNE0CxswZ8qv34f5nkyPsXNTTDoNk= To: dri-devel@lists.freedesktop.org Cc: gregkh@linuxfoundation.org, linux-kernel@vger.kernel.org References: <20210915011354.2669416-1-liu.yun@linux.dev> X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Jackie Liu Message-ID: <73758b4e-50ba-05d1-aa30-1384ee6d1421@linux.dev> Date: Wed, 22 Sep 2021 10:29:52 +0800 MIME-Version: 1.0 In-Reply-To: <20210915011354.2669416-1-liu.yun@linux.dev> Content-Type: text/plain; charset=gbk; format=flowed Content-Language: en-US Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: liu.yun@linux.dev Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org ping, would anyone take this patch? ?? 2021/9/15 ????9:13, Jackie Liu ะด??: > From: Jackie Liu > > CONFIG_VGA_CONSOLE=n and CONFIG_MDA_CONSOLE=n will cause vt_buffer.h not > include . > > But if we set CONFIG_MDA_CONSOLE=m, mdacon.c include > is in front of include . VT_BUF_HAVE_MEMSETW is not defined, > so vt_buffer.h will define a scr_memsetw, after that, vga.h also define > a scr_memsetw, so the repeated definition of scr_memsetw appears, builds > error. > > We only need to make vt_buffer.h also contain vga.h when > CONFIG_MDA_CONSOLE=m. This problem can be fixed. > > BTW, mdacon.c no need to include vga.h forcibly, let vt_buffer.h do it. > > Cc: linux-fbdev@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > Cc: dri-devel@lists.freedesktop.org > Fixes: ac036f9570a2 ("vga: optimise console scrolling") > Reviewed-by: Greg Kroah-Hartman > Signed-off-by: Jackie Liu > --- > drivers/video/console/mdacon.c | 1 - > include/linux/vt_buffer.h | 2 +- > 2 files changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/video/console/mdacon.c b/drivers/video/console/mdacon.c > index ef29b321967f..5898d01bc492 100644 > --- a/drivers/video/console/mdacon.c > +++ b/drivers/video/console/mdacon.c > @@ -42,7 +42,6 @@ > #include > > #include > -#include > > static DEFINE_SPINLOCK(mda_lock); > > diff --git a/include/linux/vt_buffer.h b/include/linux/vt_buffer.h > index 848db1b1569f..3a79cc27a33b 100644 > --- a/include/linux/vt_buffer.h > +++ b/include/linux/vt_buffer.h > @@ -16,7 +16,7 @@ > > #include > > -#if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_MDA_CONSOLE) > +#if defined(CONFIG_VGA_CONSOLE) || IS_ENABLED(CONFIG_MDA_CONSOLE) > #include > #endif > >