linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] staging: lustre: ldlm: use designated initializers
@ 2016-12-17  1:00 Kees Cook
  2016-12-19 16:22 ` James Simmons
  2016-12-20 17:29 ` Designated initializers, struct randomization and addressing? Joe Perches
  0 siblings, 2 replies; 21+ messages in thread
From: Kees Cook @ 2016-12-17  1:00 UTC (permalink / raw)
  To: linux-kernel
  Cc: Oleg Drokin, Andreas Dilger, James Simmons, Greg Kroah-Hartman,
	John L. Hammond, Emoly Liu, Vitaly Fertman, Bruno Faccini,
	Bruce Korb, lustre-devel, devel

Prepare to mark sensitive kernel structures for randomization by making
sure they're using designated initializers. These were identified during
allyesconfig builds of x86, arm, and arm64, with most initializer fixes
extracted from grsecurity.

Signed-off-by: Kees Cook <keescook@chromium.org>
---
 drivers/staging/lustre/lustre/ldlm/ldlm_flock.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c b/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c
index 722160784f83..f815827532dc 100644
--- a/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c
+++ b/drivers/staging/lustre/lustre/ldlm/ldlm_flock.c
@@ -143,7 +143,7 @@ static int ldlm_process_flock_lock(struct ldlm_lock *req, __u64 *flags,
 	int added = (mode == LCK_NL);
 	int overlaps = 0;
 	int splitted = 0;
-	const struct ldlm_callback_suite null_cbs = { NULL };
+	const struct ldlm_callback_suite null_cbs = { };
 
 	CDEBUG(D_DLMTRACE,
 	       "flags %#llx owner %llu pid %u mode %u start %llu end %llu\n",
-- 
2.7.4


-- 
Kees Cook
Nexus Security

^ permalink raw reply related	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2017-01-04 22:31 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-12-17  1:00 [PATCH] staging: lustre: ldlm: use designated initializers Kees Cook
2016-12-19 16:22 ` James Simmons
2016-12-19 16:47   ` Bruce Korb
2016-12-19 17:12     ` James Simmons
2016-12-20  7:10     ` Dan Carpenter
2016-12-20 14:57       ` Hammond, John
2016-12-20 16:47         ` Bruce Korb
2016-12-20 18:52           ` Dan Carpenter
2016-12-20 19:07         ` Dan Carpenter
2016-12-20 19:46           ` Kees Cook
     [not found]   ` <CY4PR11MB175166F4D71AC6994081356BCB910@CY4PR11MB1751.namprd11.prod.outlook.com>
2016-12-19 17:11     ` [lustre-devel] " James Simmons
2016-12-20 10:40   ` Dan Carpenter
2016-12-20 17:29 ` Designated initializers, struct randomization and addressing? Joe Perches
2017-01-03 23:47   ` Kees Cook
2017-01-03 23:55     ` Bruce Korb
2017-01-04  0:13       ` Kees Cook
2017-01-04  6:27     ` Julia Lawall
2017-01-04  6:35       ` Kees Cook
2017-01-04 16:55         ` Stephen Hemminger
2017-01-04 17:37           ` Julia Lawall
2017-01-04 22:30           ` Kees Cook

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).