md: raid10: avoid VLAIS
authorArnd Bergmann <arnd@arndb.de>
Tue, 5 Jan 2016 09:02:52 +0000 (10:02 +0100)
committerStefan Agner <stefan@agner.ch>
Mon, 7 Aug 2017 06:21:11 +0000 (23:21 -0700)
commitbf67dc9cb3a8c302e2cb4769313508f2c706807a
treede0bcf2e87915bee62a05faa2991c868edaba774
parent4892c8abc8e115ed8448f2bdc6bda827109c672a
md: raid10: avoid VLAIS

clang fails to build the raid10 code because of a variable-length
array in a structure (VLAIS):

../drivers/md/raid10.c:4488:17: error: fields must have a constant size: 'variable length array in structure' extension will never be supported

Those constructs are usually a bad idea, and this patch replaces it
with an alloca() call that is not much better either but at least builds
with clang.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
drivers/md/raid10.c