Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1472836

Re: [PATCH] drm/nouveau: silence warnings reported during builds with W=1

From Arnd Bergmann <arnd@arndb.de>
Newsgroups linux.kernel
Subject Re: [PATCH] drm/nouveau: silence warnings reported during builds with W=1
Date 2016-08-30 22:20 +0200
Message-ID <sbXFM-1b9-13@gated-at.bofh.it> (permalink)
References <sbTVw-7a6-23@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Tuesday 30 August 2016, Baoyou Xie wrote:
> We get some warnings when building kernel with W=1:
> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgf117.c:222:1: warning: no previous prototype for 'gf117_grctx_generate_main' [-Wmissing-prototypes]
> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c:255:1: warning: no previous prototype for 'nv50_grctx_fill' [-Wmissing-prototypes]
> drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxnv50.c:265:1: warning: no previous prototype for 'nv50_grctx_init' [-Wmissing-prototypes]
> ....
> 
> In fact, some functions are only used in the file in which they
> are declared and don't need a declaration, but can be made static.
> and others are declared in the header files, but need to add
> missing header dependencies.
> 
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>

The patch looks very good, and this is better than one patch per file. I would personally
do this as two patches, as you are touching a number of files and are doing two separate
things here. As a rule of thumb, when the changelog text mentions two or more things
that the patch does, the patch should be split up so that each part does one thing.
After you do that, it also becomes easier to write a good subject line like "mark
function as static" and "add missing includes", which tells you more about the patch
than "silence warnings".

It's quite likely that the nouveau maintainers are less picky than I am though, so
if they want to apply the patch as-is

Acked-by: Arnd Bergmann <arnd@arndb.de>

Otherwise please split and resend in a few days, in case there are other comments
that need to be addressed.

	Arnd

Back to linux.kernel | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

[PATCH] drm/nouveau: silence warnings reported during builds with W=1 Baoyou Xie <baoyou.xie@linaro.org> - 2016-08-30 18:20 +0200
  Re: [PATCH] drm/nouveau: silence warnings reported during builds with W=1 Arnd Bergmann <arnd@arndb.de> - 2016-08-30 22:20 +0200

csiph-web