Message ID | 20230516202257.559952-1-arnd@kernel.org |
---|---|
State | New |
Headers |
Return-Path: <linux-kernel-owner@vger.kernel.org> Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp682976vqo; Tue, 16 May 2023 13:28:51 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ54pi8wOZ7lySnX9bxOk56iUW8TeYXsDLfNz30ih+0MzDv1M3Xa37OjJInhblGbdOC+JgSi X-Received: by 2002:a17:902:a516:b0:1a6:b971:faf6 with SMTP id s22-20020a170902a51600b001a6b971faf6mr35291496plq.35.1684268930660; Tue, 16 May 2023 13:28:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684268930; cv=none; d=google.com; s=arc-20160816; b=i3JNw5u41nsumq3n/pv04PBD9S/EKMGvbrKcmn/xWi0uuXf3820Tpb++BHGv4X+sX2 dnfE4ieHXRcxrgaO/Pfjc/ax5qbBdLCJSQ68taDBvzvzfwfxzLS+lKvf2wsNB0l07xy6 1YT4AmvnkGnHAJKit0DzqVHTxdSyoprP8HflSrtZE9d6odtIihhcuTWV9OIR16Pi1pNy MD7B30JP+/evx9px1yId2h4AfgRDuR+wmj5u7OUx4XwlirEdIrQjBl2LG4u17KLzUU2m guBSc8+9V3/yd0/g5DQABKSrRqAyIM92Y0MZswGrQ7ysHjEzO+fMpNFRO95jLg9xzMQx T3eg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=/v7+zcYExfx9wm9WizrGkDyq3+ChBfphIS7aP4GYzXA=; b=bDPqlJ5MLtc3+ySIfNERH0YKgzLbjmIw1CPtw5+IYq+s8cm6W0Csy7gneXYfMAXcVH uanjsGksnifAyB8tKQaySOPOWljyOUqtyN9zsXsKzvcBD9RsmChi8RS7rppscANbtxbF G8SbkEcbTZsgu1tzCIJ2ByusEXB+sUUM7fNYtEOTYqPIesT8X7h7ekgHWwShIVG46axf TGDfFTTtOnfzG8gUHYKCh+3wsq3uMr8D7O2Cm552Gc4nQXpYo9lSS/ft2jlwXKk/CsAt 8+yt34HCcYtKVUqHEh8n2S40NtBMYHqAAbePL0pWF0AmH4XBtT0zpwWybmF/EaUXlZOT Yhww== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cwo1OJz8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id s1-20020a170902ea0100b001ac84f87b0fsi21638982plg.339.2023.05.16.13.28.35; Tue, 16 May 2023 13:28:50 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=cwo1OJz8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230397AbjEPUXG (ORCPT <rfc822;peekingduck44@gmail.com> + 99 others); Tue, 16 May 2023 16:23:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43118 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229736AbjEPUXE (ORCPT <rfc822;linux-kernel@vger.kernel.org>); Tue, 16 May 2023 16:23:04 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 675ED97; Tue, 16 May 2023 13:23:03 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 0455263F3C; Tue, 16 May 2023 20:23:03 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 6B3A0C433D2; Tue, 16 May 2023 20:23:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1684268582; bh=vu4a3gAHkMYhle534u5kDDmaO/1lqkSTmEK0D8hdHso=; h=From:To:Cc:Subject:Date:From; b=cwo1OJz8+bzgn+B6EVYFTVNxTDuaILqVkdK9VNMKQ17oBUNtzfNuoF93fXEVjbTwr QFzPXlDI47QPkfuAq6iyHfttrXJNKNpiLS5/HGlWjyRwiukjA6amzfFR/ZirO0Ng8m VNtCp9Bn6fT3O/vWjJFjCJxrQOwUPctzljgO785qtizvUqhJ7i4lpMj19Dbmfm/kXD xhr/LHlfeXcYprpMVuZhhhV4dM598ttOzZbKUzpXBbCWaFbJHOeCaqph0bNe5DlLae yduGJoReJzn8PAr1suyOBnle5RhsIXjgXuC87fGWWegVG+9cQwC9ehU9szw0eZcsQ2 hXW6SPdUPHN1A== From: Arnd Bergmann <arnd@kernel.org> To: Daniel Vetter <daniel@ffwll.ch>, Helge Deller <deller@gmx.de> Cc: Arnd Bergmann <arnd@arndb.de>, Javier Martinez Canillas <javierm@redhat.com>, Thomas Zimmermann <tzimmermann@suse.de>, Geert Uytterhoeven <geert@linux-m68k.org>, linux-fbdev@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH] fbdev: fbmem: mark get_fb_unmapped_area() static Date: Tue, 16 May 2023 22:22:48 +0200 Message-Id: <20230516202257.559952-1-arnd@kernel.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: <linux-kernel.vger.kernel.org> X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1766083978636181667?= X-GMAIL-MSGID: =?utf-8?q?1766083978636181667?= |
Series |
fbdev: fbmem: mark get_fb_unmapped_area() static
|
|
Commit Message
Arnd Bergmann
May 16, 2023, 8:22 p.m. UTC
From: Arnd Bergmann <arnd@arndb.de> There is a global function with this name on sparc, but no global declaration: drivers/video/fbdev/core/fbmem.c:1469:15: error: no previous prototype for 'get_fb_unmapped_area' Make the generic definition static to avoid this warning. On sparc, this is never seen. Signed-off-by: Arnd Bergmann <arnd@arndb.de> --- drivers/video/fbdev/core/fbmem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Comments
Hi Arnd, On Tue, May 16, 2023 at 10:23 PM Arnd Bergmann <arnd@kernel.org> wrote: > From: Arnd Bergmann <arnd@arndb.de> > > There is a global function with this name on sparc, but no > global declaration: > > drivers/video/fbdev/core/fbmem.c:1469:15: error: no previous prototype for 'get_fb_unmapped_area' > > Make the generic definition static to avoid this warning. On > sparc, this is never seen. > > Signed-off-by: Arnd Bergmann <arnd@arndb.de> Thanks for your patch! > --- a/drivers/video/fbdev/core/fbmem.c > +++ b/drivers/video/fbdev/core/fbmem.c > @@ -1468,7 +1468,7 @@ __releases(&info->lock) > } > > #if defined(CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA) && !defined(CONFIG_MMU) > -unsigned long get_fb_unmapped_area(struct file *filp, > +static unsigned long get_fb_unmapped_area(struct file *filp, > unsigned long addr, unsigned long len, > unsigned long pgoff, unsigned long flags) > { LGTM, as this is unrelated to the SPARC function, and SPARC does not support nommu (yet? ;-) drivers/video/fbdev/Kconfig:config FB_PROVIDE_GET_FB_UNMAPPED_AREA drivers/video/fbdev/Kconfig- bool drivers/video/fbdev/Kconfig- depends on FB drivers/video/fbdev/Kconfig- help drivers/video/fbdev/Kconfig- Allow generic frame-buffer to provide get_fb_unmapped_area drivers/video/fbdev/Kconfig- function. Probably you want to update this help text, too. E.g. "to provide shareable character device support on nommu"? This seems to be selected only by DRM_STM. Gr{oetje,eeting}s, Geert
diff --git a/drivers/video/fbdev/core/fbmem.c b/drivers/video/fbdev/core/fbmem.c index e808dc86001c..28739f1cb5e7 100644 --- a/drivers/video/fbdev/core/fbmem.c +++ b/drivers/video/fbdev/core/fbmem.c @@ -1468,7 +1468,7 @@ __releases(&info->lock) } #if defined(CONFIG_FB_PROVIDE_GET_FB_UNMAPPED_AREA) && !defined(CONFIG_MMU) -unsigned long get_fb_unmapped_area(struct file *filp, +static unsigned long get_fb_unmapped_area(struct file *filp, unsigned long addr, unsigned long len, unsigned long pgoff, unsigned long flags) {