From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757219AbcLQQRY (ORCPT ); Sat, 17 Dec 2016 11:17:24 -0500 Received: from mail-wj0-f193.google.com ([209.85.210.193]:36368 "EHLO mail-wj0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754279AbcLQQRX (ORCPT ); Sat, 17 Dec 2016 11:17:23 -0500 Date: Sat, 17 Dec 2016 17:17:18 +0100 From: Ingo Molnar To: Kees Cook Cc: linux-kernel@vger.kernel.org, Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , x86@kernel.org Subject: Re: [PATCH] x86/floppy: use designated initializers Message-ID: <20161217161718.GA7810@gmail.com> References: <20161217010504.GA140656@beast> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20161217010504.GA140656@beast> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org * Kees Cook wrote: > 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 > --- > arch/x86/include/asm/floppy.h | 20 ++++++++++---------- > 1 file changed, 10 insertions(+), 10 deletions(-) > > diff --git a/arch/x86/include/asm/floppy.h b/arch/x86/include/asm/floppy.h > index 1c7eefe32502..d0e4702883b9 100644 > --- a/arch/x86/include/asm/floppy.h > +++ b/arch/x86/include/asm/floppy.h > @@ -229,18 +229,18 @@ static struct fd_routine_l { > int (*_dma_setup)(char *addr, unsigned long size, int mode, int io); > } fd_routine[] = { > { > - request_dma, > - free_dma, > - get_dma_residue, > - dma_mem_alloc, > - hard_dma_setup > + ._request_dma = request_dma, > + ._free_dma = free_dma, > + ._get_dma_residue = get_dma_residue, > + ._dma_mem_alloc = dma_mem_alloc, > + ._dma_setup = hard_dma_setup > }, > { > - vdma_request_dma, > - vdma_nop, > - vdma_get_dma_residue, > - vdma_mem_alloc, > - vdma_dma_setup > + ._request_dma = vdma_request_dma, > + ._free_dma = vdma_nop, > + ._get_dma_residue = vdma_get_dma_residue, > + ._dma_mem_alloc = vdma_mem_alloc, > + ._dma_setup = vdma_dma_setup Please align the two columns vertically while at it. Thanks, Ingo