Module Name: src
Committed By: jdolecek
Date: Wed Feb 12 20:31:46 UTC 2020
Modified Files:
src/sys/external/bsd/drm2/dist/drm/nouveau: nouveau_fbcon.c
Log Message:
remove superfluous static variable used only to zero attach args
To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 \
src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c
diff -u src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c:1.7 src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c:1.8
--- src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c:1.7 Wed Feb 12 20:25:48 2020
+++ src/sys/external/bsd/drm2/dist/drm/nouveau/nouveau_fbcon.c Wed Feb 12 20:31:46 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: nouveau_fbcon.c,v 1.7 2020/02/12 20:25:48 jdolecek Exp $ */
+/* $NetBSD: nouveau_fbcon.c,v 1.8 2020/02/12 20:31:46 jdolecek Exp $ */
/*
* Copyright © 2007 David Airlie
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nouveau_fbcon.c,v 1.7 2020/02/12 20:25:48 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nouveau_fbcon.c,v 1.8 2020/02/12 20:31:46 jdolecek Exp $");
#include <linux/module.h>
#include <linux/kernel.h>
@@ -434,10 +434,9 @@ nouveau_fbcon_create(struct drm_fb_helpe
nouveau_fbcon_zfill(dev, fbcon);
- {
- static const struct nouveaufb_attach_args zero_nfa;
- struct nouveaufb_attach_args nfa = zero_nfa;
+ struct nouveaufb_attach_args nfa;
+ memset(&nfa, 0, sizeof(nfa));
nfa.nfa_fb_helper = helper;
nfa.nfa_fb_sizes = *sizes;
nfa.nfa_fb_ptr = nvbo_kmap_obj_iovirtual(nvbo);
@@ -448,7 +447,7 @@ nouveau_fbcon_create(struct drm_fb_helpe
if (helper->fbdev == NULL) {
goto out_unlock;
}
- }
+
helper->fb = fb;
return 0;