m68k/atari: Avoid VLA use in atari_switches_setup()
authorGeert Uytterhoeven <geert@linux-m68k.org>
Sun, 6 Jan 2019 20:09:58 +0000 (21:09 +0100)
committerGeert Uytterhoeven <geert@linux-m68k.org>
Mon, 21 Jan 2019 09:36:53 +0000 (10:36 +0100)
commitc097a39ce1f39b0ff2357ff1e787145e8c47da4c
treefd0bde09560dc537e39715545fc77fa4ccce20fd
parent35f61d7b3ba36f85dacc20c62e5d0dca0807bc77
m68k/atari: Avoid VLA use in atari_switches_setup()

With gcc 7.3.0:

    arch/m68k/atari/config.c: In function ‘atari_switches_setup’:
    arch/m68k/atari/config.c:151:2: warning: ISO C90 forbids variable length array ‘switches’ [-Wvla]
      char switches[strlen(str) + 1];
      ^~~~

Replace the variable size by the maximum kernel command line size (256
bytes), which is an upper limit for all suboptions.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
arch/m68k/atari/config.c