summaryrefslogtreecommitdiffstats
path: root/kernel/user-return-notifier.c
diff options
context:
space:
mode:
authorMichal Simek <michal.simek@xilinx.com>2021-06-22 12:15:11 +0200
committerStephen Boyd <sboyd@kernel.org>2021-06-25 16:04:54 -0700
commit6c9feabc2c6bd49abbd2130341e7cb91f42d3fa5 (patch)
tree259c670a71032f8a5c4778aeaea8eb92a46df7a2 /kernel/user-return-notifier.c
parent6efb943b8616ec53a5e444193dccf1af9ad627b5 (diff)
downloadlinux-stable-6c9feabc2c6bd49abbd2130341e7cb91f42d3fa5.tar.gz
linux-stable-6c9feabc2c6bd49abbd2130341e7cb91f42d3fa5.tar.bz2
linux-stable-6c9feabc2c6bd49abbd2130341e7cb91f42d3fa5.zip
clk: zynqmp: fix compile testing without ZYNQMP_FIRMWARE
When the firmware code is disabled, the incomplete error handling in the clk driver causes compile-time warnings: drivers/clk/zynqmp/pll.c: In function 'zynqmp_pll_recalc_rate': drivers/clk/zynqmp/pll.c:147:29: error: 'fbdiv' is used uninitialized [-Werror=uninitialized] 147 | rate = parent_rate * fbdiv; | ~~~~~~~~~~~~^~~~~~~ In function 'zynqmp_pll_get_mode', inlined from 'zynqmp_pll_recalc_rate' at drivers/clk/zynqmp/pll.c:148:6: drivers/clk/zynqmp/pll.c:61:27: error: 'ret_payload' is used uninitialized [-Werror=uninitialized] 61 | return ret_payload[1]; | ~~~~~~~~~~~^~~ drivers/clk/zynqmp/pll.c: In function 'zynqmp_pll_recalc_rate': drivers/clk/zynqmp/pll.c:53:13: note: 'ret_payload' declared here 53 | u32 ret_payload[PAYLOAD_ARG_CNT]; | ^~~~~~~~~~~ drivers/clk/zynqmp/clk-mux-zynqmp.c: In function 'zynqmp_clk_mux_get_parent': drivers/clk/zynqmp/clk-mux-zynqmp.c:57:16: error: 'val' is used uninitialized [-Werror=uninitialized] 57 | return val; | ^~~ As it was apparently intentional to support this for compile testing purposes, change the code to have just enough error handling for the compiler to not notice the remaining bugs. Fixes: 21f237534661 ("clk: zynqmp: Drop dependency on ARCH_ZYNQMP") Co-developed-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Michal Simek <michal.simek@xilinx.com> Link: https://lore.kernel.org/r/f1c4e8c903fe2d5df5413421920a56890a46387a.1624356908.git.michal.simek@xilinx.com Signed-off-by: Stephen Boyd <sboyd@kernel.org>
Diffstat (limited to 'kernel/user-return-notifier.c')
0 files changed, 0 insertions, 0 deletions