]> git.baikalelectronics.ru Git - kernel.git/commit
mmc: mediatek: Preinitialize delay_phase in get_best_delay()
authorGeert Uytterhoeven <geert@linux-m68k.org>
Fri, 6 Nov 2015 11:22:08 +0000 (12:22 +0100)
committerUlf Hansson <ulf.hansson@linaro.org>
Mon, 9 Nov 2015 12:16:44 +0000 (13:16 +0100)
commitd8deba104c5b91e07ffc46b9331d119a41811557
tree0922a63981635d04b8db55b09e1c8570ba39541c
parenta7e931d3eb0961c0c420635c5224936dd597f368
mmc: mediatek: Preinitialize delay_phase in get_best_delay()

drivers/mmc/host/mtk-sd.c: In function ‘get_best_delay’:
drivers/mmc/host/mtk-sd.c:1284: warning: ‘delay_phase.start’ is used uninitialized in this function
drivers/mmc/host/mtk-sd.c:1284: warning: ‘delay_phase.maxlen’ is used uninitialized in this function

If delay is zero, these fields are indeed not initialized.
Let the compiler preinitialize the whole struct to fix this.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/host/mtk-sd.c