Re: [Nouveau] [PATCH] drm/nouveau: silence warnings reported during builds with W=1
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 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 Otherwise please split and resend in a few days, in case there are other comments that need to be addressed. Arnd ___ Nouveau mailing list Nouveau@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/nouveau
Re: [Nouveau] [PATCH v2] drm/nouveau/gr: mark gm107_grctx_generate_tpcid() static
On Tuesday 30 August 2016, Baoyou Xie wrote: > On 30 August 2016 at 00:01, Sean Paul wrote: > > > On Mon, Aug 29, 2016 at 9:02 AM, Baoyou Xie wrote: > > > We get 1 warning when build kernel with W=1: > > > drivers/gpu/drm/nouveau/nvkm/engine/gr/ctxgm107.c:937:1: warning: no > > previous prototype for 'gm107_grctx_generate_tpcid' [-Wmissing-prototypes] > > > > > > In fact, this function is only used in the file in which it is > > > declared and don't need a declaration, but can be made static. > > > so this patch marks this function with 'static'. > > > > > > > It would make things a lot easier if you either consolidated all of > > these static changes into one patch, or released them as a series. > > > > > Do you mean that I need to consolidate all of them into one patch this > time? or next time? I'd suggest consolidating the 'nouveau' changes into a single patch, as this is one (very big) driver and resend that one. Arnd ___ Nouveau mailing list Nouveau@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/nouveau
Re: [Nouveau] [PATCH] drm/nouveau/acpi: use DSM if bridge does not support D3cold
On Fri, Aug 26, 2016 at 01:00:54AM +0200, Peter Wu wrote: > Even if PR3 support is available on the bridge, it will not be used if > the PCI layer considers it unavailable (i.e. on all laptops from 2013 > and 2014). Ensure that this condition is checked to allow a fallback to > the Optimus DSM for device poweroff. > > Initially I wanted to call pci_d3cold_enable before checking bridge_d3 > (in case the user changed d3cold_allowed), but that is such an unlikely > case and likely fragile anyway. The current patch is suggested by Mika > in http://www.spinics.net/lists/linux-pci/msg52599.html > > Cc: Mika Westerberg Reviewed-by: Mika Westerberg ___ Nouveau mailing list Nouveau@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/nouveau