linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Hannes Reinecke <hare@suse.de>
To: Stephen Kitt <steve@sk2.org>,
	hare@suse.com, axboe@kernel.dk, jejb@linux.vnet.ibm.com,
	martin.petersen@oracle.com
Cc: linux-scsi@vger.kernel.org, kernel-hardening@lists.openwall.com,
	linux-kernel@vger.kernel.org, linux-block@vger.kernel.org
Subject: Re: [PATCH] device_handler: remove VLAs
Date: Mon, 12 Mar 2018 07:25:08 +0100	[thread overview]
Message-ID: <7cd80595-ca17-0474-5870-6d7c0429db7a@suse.de> (raw)
In-Reply-To: <20180309223211.20473-1-steve@sk2.org>

On 03/09/2018 11:32 PM, Stephen Kitt wrote:
> In preparation to enabling -Wvla, remove VLAs and replace them with
> fixed-length arrays instead.
> 
> scsi_dh_{alua,emc,rdac} use variable-length array declarations to
> store command blocks, with the appropriate size as determined by
> COMMAND_SIZE. This patch replaces these with fixed-sized arrays using
> MAX_COMMAND_SIZE, so that the array size can be determined at compile
> time.
> 
> This was prompted by https://lkml.org/lkml/2018/3/7/621
> 
> Signed-off-by: Stephen Kitt <steve@sk2.org>
> ---
>  drivers/scsi/device_handler/scsi_dh_alua.c | 8 ++++----
>  drivers/scsi/device_handler/scsi_dh_emc.c  | 2 +-
>  drivers/scsi/device_handler/scsi_dh_rdac.c | 2 +-
>  3 files changed, 6 insertions(+), 6 deletions(-)
> 
Reviewed-by: Hannes Reinecke <hare@suse.com>

Cheers,

Hannes
-- 
Dr. Hannes Reinecke		   Teamlead Storage & Networking
hare@suse.de			               +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nürnberg
GF: F. Imendörffer, J. Smithard, J. Guild, D. Upmanyu, G. Norton
HRB 21284 (AG Nürnberg)

  parent reply	other threads:[~2018-03-12  6:25 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-03-09 22:29 VLA removal, device_handler and COMMAND_SIZE Stephen Kitt
2018-03-09 22:32 ` [PATCH] device_handler: remove VLAs Stephen Kitt
2018-03-09 22:48   ` Bart Van Assche
2018-03-10 13:14     ` Stephen Kitt
2018-03-12 15:41       ` Bart Van Assche
2018-03-12 19:26         ` Stephen Kitt
2018-03-12  6:25   ` Hannes Reinecke [this message]
2018-03-13  2:37   ` Martin K. Petersen
2018-03-09 22:33 ` [PATCH] scsi: resolve COMMAND_SIZE at compile time Stephen Kitt
2018-03-09 22:47   ` Bart Van Assche
2018-03-10 13:29     ` Stephen Kitt
2018-03-10 20:49       ` James Bottomley
2018-03-10 21:16         ` Douglas Gilbert
2018-03-13 11:34   ` David Laight

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7cd80595-ca17-0474-5870-6d7c0429db7a@suse.de \
    --to=hare@suse.de \
    --cc=axboe@kernel.dk \
    --cc=hare@suse.com \
    --cc=jejb@linux.vnet.ibm.com \
    --cc=kernel-hardening@lists.openwall.com \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=steve@sk2.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).