Linux-Clk Archive on lore.kernel.org
 help / color / Atom feed
* [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c
@ 2019-09-25 11:23 Ben Dooks
  2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Ben Dooks @ 2019-09-25 11:23 UTC (permalink / raw)
  To: linux-clk; +Cc: Michael Turquette, Stephen Boyd, Ben Dooks

Fix the following warnings from sparse by removing the 0 initialiser
that is actually a pointer.

drivers/clk/hisilicon/clk-hi3670.c:298:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:300:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:302:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:304:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:306:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:308:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:310:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:312:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:314:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:316:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:318:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:320:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:322:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:324:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:326:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:328:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:330:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:332:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:334:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:336:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:338:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:340:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:342:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:344:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:346:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:348:65: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:350:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:352:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:488:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:490:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:492:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:494:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:496:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:498:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:500:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:502:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:504:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:506:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:508:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:510:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:512:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:514:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:516:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:518:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:520:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:522:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:524:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:526:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:528:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:530:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:532:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:534:71: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:536:71: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:538:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:611:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:614:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:616:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:653:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:655:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:657:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:659:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:661:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:663:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:665:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:735:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:737:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:739:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:741:63: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:743:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:745:64: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:802:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:804:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:806:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:808:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:810:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3670.c:812:69: warning: Using plain integer as NULL pointer

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
---
 drivers/clk/hisilicon/clk-hi3670.c | 152 ++++++++++++++---------------
 1 file changed, 76 insertions(+), 76 deletions(-)

diff --git a/drivers/clk/hisilicon/clk-hi3670.c b/drivers/clk/hisilicon/clk-hi3670.c
index fd8c837a6ea3..4d05a71683a5 100644
--- a/drivers/clk/hisilicon/clk-hi3670.c
+++ b/drivers/clk/hisilicon/clk-hi3670.c
@@ -295,61 +295,61 @@ static const struct hisi_gate_clock hi3670_crgctrl_gate_sep_clks[] = {
 
 static const struct hisi_gate_clock hi3670_crgctrl_gate_clks[] = {
 	{ HI3670_AUTODIV_SYSBUS, "autodiv_sysbus", "clk_div_sysbus",
-	  CLK_SET_RATE_PARENT, 0x404, 5, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x404, 5, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_AUTODIV_EMMC0BUS, "autodiv_emmc0bus", "autodiv_sysbus",
-	  CLK_SET_RATE_PARENT, 0x404, 1, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x404, 1, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_PCLK_ANDGT_MMC1_PCIE, "pclk_andgt_mmc1_pcie", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xf8, 13, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xf8, 13, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_GATE_VCODECBUS_GT, "clk_gate_vcodecbus_gt", "clk_mux_vcodecbus",
-	  CLK_SET_RATE_PARENT, 0x0F0, 8, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0F0, 8, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_SD, "clk_andgt_sd", "clk_mux_sd_pll",
-	  CLK_SET_RATE_PARENT, 0xF4, 3, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 3, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_SD_SYS_GT, "clk_sd_sys_gt", "clkin_sys",
-	  CLK_SET_RATE_PARENT, 0xF4, 5, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 5, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_SDIO, "clk_andgt_sdio", "clk_mux_sdio_pll",
-	  CLK_SET_RATE_PARENT, 0xF4, 8, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 8, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_SDIO_SYS_GT, "clk_sdio_sys_gt", "clkin_sys",
-	  CLK_SET_RATE_PARENT, 0xF4, 6, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 6, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_A53HPM_ANDGT, "clk_a53hpm_andgt", "clk_mux_a53hpm",
-	  CLK_SET_RATE_PARENT, 0x0F4, 7, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0F4, 7, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_320M_PLL_GT, "clk_320m_pll_gt", "clk_mux_320m",
-	  CLK_SET_RATE_PARENT, 0xF8, 10, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF8, 10, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_UARTH, "clk_andgt_uarth", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xF4, 11, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 11, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_UARTL, "clk_andgt_uartl", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xF4, 10, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 10, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_UART0, "clk_andgt_uart0", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xF4, 9, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 9, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_SPI, "clk_andgt_spi", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xF4, 13, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 13, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_PCIEAXI, "clk_andgt_pcieaxi", "clk_mux_pcieaxi",
-	  CLK_SET_RATE_PARENT, 0xfc, 15, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xfc, 15, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_AO_ASP_GT, "clk_div_ao_asp_gt", "clk_mux_ao_asp",
-	  CLK_SET_RATE_PARENT, 0xF4, 4, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 4, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_GATE_CSI_TRANS, "clk_gate_csi_trans", "clk_ppll2",
-	  CLK_SET_RATE_PARENT, 0xF4, 14, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 14, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_GATE_DSI_TRANS, "clk_gate_dsi_trans", "clk_ppll2",
-	  CLK_SET_RATE_PARENT, 0xF4, 1, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF4, 1, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_PTP, "clk_andgt_ptp", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xF8, 5, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF8, 5, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_OUT0, "clk_andgt_out0", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0xF0, 10, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF0, 10, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_OUT1, "clk_andgt_out1", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0xF0, 11, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF0, 11, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLKGT_DP_AUDIO_PLL_AO, "clkgt_dp_audio_pll_ao", "clk_ppll6",
-	  CLK_SET_RATE_PARENT, 0xF8, 15, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF8, 15, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_VDEC, "clk_andgt_vdec", "clk_mux_vdec",
-	  CLK_SET_RATE_PARENT, 0xF0, 13, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF0, 13, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_VENC, "clk_andgt_venc", "clk_mux_venc",
-	  CLK_SET_RATE_PARENT, 0xF0, 9, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xF0, 9, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ISP_SNCLK_ANGT, "clk_isp_snclk_angt", "clk_div_a53hpm",
-	  CLK_SET_RATE_PARENT, 0x108, 2, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x108, 2, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_RXDPHY, "clk_andgt_rxdphy", "clk_div_a53hpm",
-	  CLK_SET_RATE_PARENT, 0x0F0, 12, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0F0, 12, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_ICS, "clk_andgt_ics", "clk_mux_ics",
-	  CLK_SET_RATE_PARENT, 0xf0, 14, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xf0, 14, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_AUTODIV_DMABUS, "autodiv_dmabus", "autodiv_sysbus",
-	  CLK_SET_RATE_PARENT, 0x404, 3, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x404, 3, CLK_GATE_HIWORD_MASK, },
 };
 
 static const char *const
@@ -485,57 +485,57 @@ static const struct hisi_mux_clock hi3670_crgctrl_mux_clks[] = {
 
 static const struct hisi_divider_clock hi3670_crgctrl_divider_clks[] = {
 	{ HI3670_CLK_DIV_CFGBUS, "clk_div_cfgbus", "clk_div_sysbus",
-	  CLK_SET_RATE_PARENT, 0xEC, 0, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xEC, 0, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_MMC0BUS, "clk_div_mmc0bus", "autodiv_emmc0bus",
-	  CLK_SET_RATE_PARENT, 0x0EC, 2, 1, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0EC, 2, 1, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_MMC1BUS, "clk_div_mmc1bus", "clk_div_sysbus",
-	  CLK_SET_RATE_PARENT, 0x0EC, 3, 1, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0EC, 3, 1, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_PCLK_DIV_MMC1_PCIE, "pclk_div_mmc1_pcie", "pclk_andgt_mmc1_pcie",
-	  CLK_SET_RATE_PARENT, 0xb4, 6, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb4, 6, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_VCODECBUS, "clk_div_vcodecbus", "clk_gate_vcodecbus_gt",
-	  CLK_SET_RATE_PARENT, 0x0BC, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x0BC, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_SD, "clk_div_sd", "clk_andgt_sd",
-	  CLK_SET_RATE_PARENT, 0xB8, 0, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xB8, 0, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_SDIO, "clk_div_sdio", "clk_andgt_sdio",
-	  CLK_SET_RATE_PARENT, 0xC0, 0, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xC0, 0, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_UARTH, "clk_div_uarth", "clk_andgt_uarth",
-	  CLK_SET_RATE_PARENT, 0xB0, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xB0, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_UARTL, "clk_div_uartl", "clk_andgt_uartl",
-	  CLK_SET_RATE_PARENT, 0xB0, 8, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xB0, 8, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_UART0, "clk_div_uart0", "clk_andgt_uart0",
-	  CLK_SET_RATE_PARENT, 0xB0, 4, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xB0, 4, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_I2C, "clk_div_i2c", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xE8, 4, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xE8, 4, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_SPI, "clk_div_spi", "clk_andgt_spi",
-	  CLK_SET_RATE_PARENT, 0xC4, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xC4, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_PCIEAXI, "clk_div_pcieaxi", "clk_andgt_pcieaxi",
-	  CLK_SET_RATE_PARENT, 0xb4, 0, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb4, 0, 5, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_AO_ASP, "clk_div_ao_asp", "clk_div_ao_asp_gt",
-	  CLK_SET_RATE_PARENT, 0x108, 6, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x108, 6, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_CSI_TRANS, "clk_div_csi_trans", "clk_gate_csi_trans",
-	  CLK_SET_RATE_PARENT, 0xD4, 0, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xD4, 0, 5, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_DSI_TRANS, "clk_div_dsi_trans", "clk_gate_dsi_trans",
-	  CLK_SET_RATE_PARENT, 0xD4, 10, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xD4, 10, 5, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_PTP, "clk_div_ptp", "clk_andgt_ptp",
-	  CLK_SET_RATE_PARENT, 0xD8, 0, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xD8, 0, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_CLKOUT0_PLL, "clk_div_clkout0_pll", "clk_andgt_out0",
-	  CLK_SET_RATE_PARENT, 0xe0, 4, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xe0, 4, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_CLKOUT1_PLL, "clk_div_clkout1_pll", "clk_andgt_out1",
-	  CLK_SET_RATE_PARENT, 0xe0, 10, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xe0, 10, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLKDIV_DP_AUDIO_PLL_AO, "clkdiv_dp_audio_pll_ao", "clkgt_dp_audio_pll_ao",
-	  CLK_SET_RATE_PARENT, 0xBC, 11, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xBC, 11, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_VDEC, "clk_div_vdec", "clk_andgt_vdec",
-	  CLK_SET_RATE_PARENT, 0xC4, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xC4, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_VENC, "clk_div_venc", "clk_andgt_venc",
-	  CLK_SET_RATE_PARENT, 0xC0, 8, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xC0, 8, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_ISP_SNCLK_DIV0, "clk_isp_snclk_div0", "clk_isp_snclk_fac",
-	  CLK_SET_RATE_PARENT, 0x108, 0, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x108, 0, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_ISP_SNCLK_DIV1, "clk_isp_snclk_div1", "clk_isp_snclk_fac",
-	  CLK_SET_RATE_PARENT, 0x10C, 14, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x10C, 14, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_ISP_SNCLK_DIV2, "clk_isp_snclk_div2", "clk_isp_snclk_fac",
-	  CLK_SET_RATE_PARENT, 0x10C, 11, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x10C, 11, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_ICS, "clk_div_ics", "clk_andgt_ics",
-	  CLK_SET_RATE_PARENT, 0xE4, 9, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xE4, 9, 6, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 /* clk_pmuctrl */
@@ -608,12 +608,12 @@ static const struct hisi_gate_clock hi3670_sctrl_gate_sep_clks[] = {
 
 static const struct hisi_gate_clock hi3670_sctrl_gate_clks[] = {
 	{ HI3670_CLK_ANDGT_IOPERI, "clk_andgt_ioperi", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x270, 6, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x270, 6, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLKANDGT_ASP_SUBSYS_PERI, "clkandgt_asp_subsys_peri",
 	  "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x268, 3, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x268, 3, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANGT_ASP_SUBSYS, "clk_angt_asp_subsys", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x258, 0, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x258, 0, CLK_GATE_HIWORD_MASK, },
 };
 
 static const char *const
@@ -650,19 +650,19 @@ static const struct hisi_mux_clock hi3670_sctrl_mux_clks[] = {
 
 static const struct hisi_divider_clock hi3670_sctrl_divider_clks[] = {
 	{ HI3670_CLK_DIV_AOBUS, "clk_div_aobus", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x254, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x254, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_UFS_SUBSYS, "clk_div_ufs_subsys", "clk_mux_ufs_subsys",
-	  CLK_SET_RATE_PARENT, 0x274, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x274, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_IOPERI, "clk_div_ioperi", "clk_andgt_ioperi",
-	  CLK_SET_RATE_PARENT, 0x270, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x270, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_CLKOUT0_TCXO, "clk_div_clkout0_tcxo", "clkin_sys",
-	  CLK_SET_RATE_PARENT, 0x254, 6, 3, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x254, 6, 3, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_CLKOUT1_TCXO, "clk_div_clkout1_tcxo", "clkin_sys",
-	  CLK_SET_RATE_PARENT, 0x254, 9, 3, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x254, 9, 3, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_ASP_SUBSYS_PERI_DIV, "clk_asp_subsys_peri_div", "clkandgt_asp_subsys_peri",
-	  CLK_SET_RATE_PARENT, 0x268, 0, 3, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x268, 0, 3, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_ASP_SUBSYS, "clk_div_asp_subsys", "clk_angt_asp_subsys",
-	  CLK_SET_RATE_PARENT, 0x250, 0, 3, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x250, 0, 3, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 /* clk_iomcu */
@@ -732,17 +732,17 @@ static const struct hisi_gate_clock hi3670_media1_gate_sep_clks[] = {
 
 static const struct hisi_gate_clock hi3670_media1_gate_clks[] = {
 	{ HI3670_CLK_GATE_VIVOBUS_ANDGT, "clk_gate_vivobus_andgt", "clk_mux_vivobus",
-	  CLK_SET_RATE_PARENT, 0x84, 3, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 3, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_EDC0, "clk_andgt_edc0", "clk_mux_edc0",
-	  CLK_SET_RATE_PARENT, 0x84, 7, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 7, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_LDI0, "clk_andgt_ldi0", "clk_mux_ldi0",
-	  CLK_SET_RATE_PARENT, 0x84, 9, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 9, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_ANDGT_LDI1, "clk_andgt_ldi1", "clk_mux_ldi1",
-	  CLK_SET_RATE_PARENT, 0x84, 8, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 8, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_CLK_MMBUF_PLL_ANDGT, "clk_mmbuf_pll_andgt", "clk_sw_mmbuf",
-	  CLK_SET_RATE_PARENT, 0x84, 14, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 14, CLK_GATE_HIWORD_MASK, },
 	{ HI3670_PCLK_MMBUF_ANDGT, "pclk_mmbuf_andgt", "aclk_div_mmbuf",
-	  CLK_SET_RATE_PARENT, 0x84, 15, CLK_GATE_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x84, 15, CLK_GATE_HIWORD_MASK, },
 };
 
 static const char *const
@@ -799,17 +799,17 @@ static const struct hisi_mux_clock hi3670_media1_mux_clks[] = {
 
 static const struct hisi_divider_clock hi3670_media1_divider_clks[] = {
 	{ HI3670_CLK_DIV_VIVOBUS, "clk_div_vivobus", "clk_gate_vivobus_andgt",
-	  CLK_SET_RATE_PARENT, 0x74, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x74, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_EDC0, "clk_div_edc0", "clk_andgt_edc0",
-	  CLK_SET_RATE_PARENT, 0x68, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x68, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_LDI0, "clk_div_ldi0", "clk_andgt_ldi0",
-	  CLK_SET_RATE_PARENT, 0x60, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x60, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_CLK_DIV_LDI1, "clk_div_ldi1", "clk_andgt_ldi1",
-	  CLK_SET_RATE_PARENT, 0x64, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x64, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_ACLK_DIV_MMBUF, "aclk_div_mmbuf", "clk_mmbuf_pll_andgt",
-	  CLK_SET_RATE_PARENT, 0x7C, 10, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x7C, 10, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3670_PCLK_DIV_MMBUF, "pclk_div_mmbuf", "pclk_mmbuf_andgt",
-	  CLK_SET_RATE_PARENT, 0x78, 0, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x78, 0, 2, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 /* clk_media2 */
-- 
2.23.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c
  2019-09-25 11:23 [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Ben Dooks
@ 2019-09-25 11:23 ` Ben Dooks
  2019-09-25 13:42   ` Ben Dooks
  2019-10-03 20:58   ` Stephen Boyd
  2019-09-25 13:14 ` [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Stephen Boyd
  2019-10-03 20:58 ` Stephen Boyd
  2 siblings, 2 replies; 8+ messages in thread
From: Ben Dooks @ 2019-09-25 11:23 UTC (permalink / raw)
  To: linux-clk; +Cc: Michael Turquette, Stephen Boyd, Ben Dooks

Fix sparse warnings of a 0 being used for a pointer by removing it from
the initialiser.

drivers/clk/hisilicon/clk-hi3660.c:336:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:338:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:340:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:342:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:344:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:346:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:348:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:350:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:352:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:354:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:356:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:358:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:360:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:362:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:364:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:366:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:368:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:370:69: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:372:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:374:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:376:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:378:71: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:423:68: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:425:68: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:427:68: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:429:68: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:449:70: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:451:71: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:453:71: warning: Using plain integer as NULL pointer
drivers/clk/hisilicon/clk-hi3660.c:455:71: warning: Using plain integer as NULL pointer

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
---
 drivers/clk/hisilicon/clk-hi3660.c | 60 +++++++++++++++---------------
 1 file changed, 30 insertions(+), 30 deletions(-)

diff --git a/drivers/clk/hisilicon/clk-hi3660.c b/drivers/clk/hisilicon/clk-hi3660.c
index 5b3ad26dcc77..41f61726ab19 100644
--- a/drivers/clk/hisilicon/clk-hi3660.c
+++ b/drivers/clk/hisilicon/clk-hi3660.c
@@ -333,49 +333,49 @@ static const struct hisi_mux_clock hi3660_crgctrl_mux_clks[] = {
 
 static const struct hisi_divider_clock hi3660_crgctrl_divider_clks[] = {
 	{ HI3660_CLK_DIV_UART0, "clk_div_uart0", "clk_andgt_uart0",
-	  CLK_SET_RATE_PARENT, 0xb0, 4, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb0, 4, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_UART1, "clk_div_uart1", "clk_andgt_uart1",
-	  CLK_SET_RATE_PARENT, 0xb0, 8, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb0, 8, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_UARTH, "clk_div_uarth", "clk_andgt_uarth",
-	  CLK_SET_RATE_PARENT, 0xb0, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb0, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_MMC, "clk_div_mmc", "clk_andgt_mmc",
-	  CLK_SET_RATE_PARENT, 0xb4, 3, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb4, 3, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_SD, "clk_div_sd", "clk_andgt_sd",
-	  CLK_SET_RATE_PARENT, 0xb8, 0, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xb8, 0, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_EDC0, "clk_div_edc0", "clk_andgt_edc0",
-	  CLK_SET_RATE_PARENT, 0xbc, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xbc, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_LDI0, "clk_div_ldi0", "clk_andgt_ldi0",
-	  CLK_SET_RATE_PARENT, 0xbc, 10, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xbc, 10, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_SDIO, "clk_div_sdio", "clk_andgt_sdio",
-	  CLK_SET_RATE_PARENT, 0xc0, 0, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xc0, 0, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_LDI1, "clk_div_ldi1", "clk_andgt_ldi1",
-	  CLK_SET_RATE_PARENT, 0xc0, 8, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xc0, 8, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_SPI, "clk_div_spi", "clk_andgt_spi",
-	  CLK_SET_RATE_PARENT, 0xc4, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xc4, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_VENC, "clk_div_venc", "clk_andgt_venc",
-	  CLK_SET_RATE_PARENT, 0xc8, 6, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xc8, 6, 5, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_VDEC, "clk_div_vdec", "clk_andgt_vdec",
-	  CLK_SET_RATE_PARENT, 0xcc, 0, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xcc, 0, 5, CLK_DIVIDER_HIWORD_MASK,  },
 	{ HI3660_CLK_DIV_VIVOBUS, "clk_div_vivobus", "clk_vivobus_andgt",
-	  CLK_SET_RATE_PARENT, 0xd0, 7, 5, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xd0, 7, 5, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_I2C, "clk_div_i2c", "clk_div_320m",
-	  CLK_SET_RATE_PARENT, 0xe8, 4, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xe8, 4, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_UFSPHY, "clk_div_ufsphy_cfg", "clk_gate_ufsphy_gt",
-	  CLK_SET_RATE_PARENT, 0xe8, 9, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xe8, 9, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_CFGBUS, "clk_div_cfgbus", "clk_div_sysbus",
-	  CLK_SET_RATE_PARENT, 0xec, 0, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xec, 0, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_MMC0BUS, "clk_div_mmc0bus", "autodiv_emmc0bus",
-	  CLK_SET_RATE_PARENT, 0xec, 2, 1, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xec, 2, 1, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_MMC1BUS, "clk_div_mmc1bus", "clk_div_sysbus",
-	  CLK_SET_RATE_PARENT, 0xec, 3, 1, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xec, 3, 1, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_UFSPERI, "clk_div_ufsperi", "clk_gate_ufs_subsys",
-	  CLK_SET_RATE_PARENT, 0xec, 14, 1, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0xec, 14, 1, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_AOMM, "clk_div_aomm", "clk_aomm_andgt",
-	  CLK_SET_RATE_PARENT, 0x100, 7, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x100, 7, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_ISP_SNCLK, "clk_isp_snclk_div", "clk_isp_snclk_fac",
-	  CLK_SET_RATE_PARENT, 0x108, 0, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x108, 0, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_IOPERI, "clk_div_ioperi", "clk_mux_ioperi",
-	  CLK_SET_RATE_PARENT, 0x108, 11, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x108, 11, 4, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 /* clk_pmuctrl */
@@ -420,13 +420,13 @@ static const struct hisi_gate_clock hi3660_sctrl_gate_clks[] = {
 	{ HI3660_PCLK_MMBUF_ANDGT, "pclk_mmbuf_andgt", "clk_sw_mmbuf",
 	  CLK_SET_RATE_PARENT, 0x258, 7, CLK_GATE_HIWORD_MASK, },
 	{ HI3660_CLK_MMBUF_PLL_ANDGT, "clk_mmbuf_pll_andgt", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x260, 11, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x260, 11, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_FLL_MMBUF_ANDGT, "clk_fll_mmbuf_andgt", "clk_fll_src",
-	  CLK_SET_RATE_PARENT, 0x260, 12, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x260, 12, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_SYS_MMBUF_ANDGT, "clk_sys_mmbuf_andgt", "clkin_sys",
-	  CLK_SET_RATE_PARENT, 0x260, 13, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x260, 13, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_GATE_PCIEPHY_GT, "clk_gate_pciephy_gt", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x268, 11, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x268, 11, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 static const char *const
@@ -446,13 +446,13 @@ static const struct hisi_mux_clock hi3660_sctrl_mux_clks[] = {
 
 static const struct hisi_divider_clock hi3660_sctrl_divider_clks[] = {
 	{ HI3660_CLK_DIV_AOBUS, "clk_div_aobus", "clk_ppll0",
-	  CLK_SET_RATE_PARENT, 0x254, 0, 6, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x254, 0, 6, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_PCLK_DIV_MMBUF, "pclk_div_mmbuf", "pclk_mmbuf_andgt",
-	  CLK_SET_RATE_PARENT, 0x258, 10, 2, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x258, 10, 2, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_ACLK_DIV_MMBUF, "aclk_div_mmbuf", "clk_mmbuf_pll_andgt",
-	  CLK_SET_RATE_PARENT, 0x258, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x258, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 	{ HI3660_CLK_DIV_PCIEPHY, "clk_div_pciephy", "clk_gate_pciephy_gt",
-	  CLK_SET_RATE_PARENT, 0x268, 12, 4, CLK_DIVIDER_HIWORD_MASK, 0, },
+	  CLK_SET_RATE_PARENT, 0x268, 12, 4, CLK_DIVIDER_HIWORD_MASK, },
 };
 
 /* clk_iomcu */
-- 
2.23.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c
  2019-09-25 11:23 [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Ben Dooks
  2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
@ 2019-09-25 13:14 ` Stephen Boyd
  2019-09-25 13:39   ` Ben Dooks
  2019-09-25 13:44   ` Ben Dooks
  2019-10-03 20:58 ` Stephen Boyd
  2 siblings, 2 replies; 8+ messages in thread
From: Stephen Boyd @ 2019-09-25 13:14 UTC (permalink / raw)
  To: Ben Dooks, linux-clk; +Cc: Michael Turquette, Ben Dooks

Quoting Ben Dooks (2019-09-25 04:23:46)
> Fix the following warnings from sparse by removing the 0 initialiser
> that is actually a pointer.
> 
> drivers/clk/hisilicon/clk-hi3670.c:298:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:300:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:302:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:304:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:306:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:308:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:310:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:312:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:314:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:316:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:318:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:320:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:322:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:324:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:326:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:328:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:330:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:332:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:334:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:336:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:338:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:340:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:342:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:344:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:346:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:348:65: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:350:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:352:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:488:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:490:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:492:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:494:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:496:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:498:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:500:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:502:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:504:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:506:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:508:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:510:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:512:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:514:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:516:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:518:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:520:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:522:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:524:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:526:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:528:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:530:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:532:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:534:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:536:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:538:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:611:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:614:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:616:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:653:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:655:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:657:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:659:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:661:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:663:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:665:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:735:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:737:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:739:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:741:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:743:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:745:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:802:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:804:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:806:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:808:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:810:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:812:69: warning: Using plain integer as NULL pointer
> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>

Did you compile and confirm that the binary is the same before and
after? It would give me more confidence if that was stated in the commit
text, otherwise I'll have to build the code before and after to make
sure myself.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c
  2019-09-25 13:14 ` [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Stephen Boyd
@ 2019-09-25 13:39   ` Ben Dooks
  2019-09-25 13:44   ` Ben Dooks
  1 sibling, 0 replies; 8+ messages in thread
From: Ben Dooks @ 2019-09-25 13:39 UTC (permalink / raw)
  To: Stephen Boyd; +Cc: linux-clk, Michael Turquette



On 2019-09-25 14:14, Stephen Boyd wrote:
> Quoting Ben Dooks (2019-09-25 04:23:46)
>> Fix the following warnings from sparse by removing the 0 initialiser
>> that is actually a pointer.
>> 
>> drivers/clk/hisilicon/clk-hi3670.c:298:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:300:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:302:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:304:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:306:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:308:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:310:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:312:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:314:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:316:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:318:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:320:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:322:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:324:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:326:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:328:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:330:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:332:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:334:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:336:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:338:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:340:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:342:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:344:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:346:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:348:65: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:350:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:352:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:488:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:490:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:492:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:494:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:496:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:498:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:500:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:502:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:504:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:506:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:508:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:510:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:512:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:514:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:516:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:518:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:520:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:522:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:524:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:526:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:528:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:530:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:532:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:534:71: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:536:71: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:538:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:611:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:614:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:616:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:653:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:655:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:657:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:659:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:661:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:663:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:665:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:735:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:737:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:739:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:741:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:743:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:745:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:802:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:804:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:806:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:808:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:810:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:812:69: warning: Using plain 
>> integer as NULL pointer
>> 
>> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> 
> Did you compile and confirm that the binary is the same before and
> after? It would give me more confidence if that was stated in the 
> commit
> text, otherwise I'll have to build the code before and after to make
> sure myself.

I'll go and check.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c
  2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
@ 2019-09-25 13:42   ` Ben Dooks
  2019-10-03 20:58   ` Stephen Boyd
  1 sibling, 0 replies; 8+ messages in thread
From: Ben Dooks @ 2019-09-25 13:42 UTC (permalink / raw)
  To: linux-clk; +Cc: Michael Turquette, Stephen Boyd



On 2019-09-25 12:23, Ben Dooks wrote:
> Fix sparse warnings of a 0 being used for a pointer by removing it from
> the initialiser.
> 
> drivers/clk/hisilicon/clk-hi3660.c:336:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:338:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:340:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:342:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:344:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:346:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:348:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:350:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:352:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:354:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:356:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:358:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:360:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:362:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:364:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:366:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:368:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:370:69: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:372:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:374:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:376:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:378:71: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:423:68: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:425:68: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:427:68: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:429:68: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:449:70: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:451:71: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:453:71: warning: Using plain
> integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:455:71: warning: Using plain
> integer as NULL pointer


Compile testing show same object from both pre and post patch.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c
  2019-09-25 13:14 ` [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Stephen Boyd
  2019-09-25 13:39   ` Ben Dooks
@ 2019-09-25 13:44   ` Ben Dooks
  1 sibling, 0 replies; 8+ messages in thread
From: Ben Dooks @ 2019-09-25 13:44 UTC (permalink / raw)
  To: Stephen Boyd; +Cc: linux-clk, Michael Turquette



On 2019-09-25 14:14, Stephen Boyd wrote:
> Quoting Ben Dooks (2019-09-25 04:23:46)
>> Fix the following warnings from sparse by removing the 0 initialiser
>> that is actually a pointer.
>> 
>> drivers/clk/hisilicon/clk-hi3670.c:298:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:300:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:302:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:304:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:306:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:308:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:310:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:312:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:314:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:316:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:318:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:320:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:322:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:324:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:326:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:328:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:330:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:332:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:334:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:336:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:338:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:340:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:342:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:344:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:346:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:348:65: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:350:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:352:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:488:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:490:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:492:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:494:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:496:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:498:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:500:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:502:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:504:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:506:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:508:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:510:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:512:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:514:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:516:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:518:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:520:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:522:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:524:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:526:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:528:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:530:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:532:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:534:71: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:536:71: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:538:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:611:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:614:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:616:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:653:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:655:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:657:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:659:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:661:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:663:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:665:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:735:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:737:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:739:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:741:63: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:743:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:745:64: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:802:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:804:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:806:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:808:69: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:810:70: warning: Using plain 
>> integer as NULL pointer
>> drivers/clk/hisilicon/clk-hi3670.c:812:69: warning: Using plain 
>> integer as NULL pointer
>> 
>> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> 
> Did you compile and confirm that the binary is the same before and
> after? It would give me more confidence if that was stated in the 
> commit
> text, otherwise I'll have to build the code before and after to make
> sure myself.

yes, get the same binary output pre and post patching.

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c
  2019-09-25 11:23 [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Ben Dooks
  2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
  2019-09-25 13:14 ` [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Stephen Boyd
@ 2019-10-03 20:58 ` Stephen Boyd
  2 siblings, 0 replies; 8+ messages in thread
From: Stephen Boyd @ 2019-10-03 20:58 UTC (permalink / raw)
  To: Ben Dooks, linux-clk; +Cc: Michael Turquette, Ben Dooks

Quoting Ben Dooks (2019-09-25 04:23:46)
> Fix the following warnings from sparse by removing the 0 initialiser
> that is actually a pointer.
> 
> drivers/clk/hisilicon/clk-hi3670.c:298:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:300:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:302:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:304:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:306:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:308:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:310:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:312:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:314:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:316:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:318:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:320:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:322:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:324:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:326:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:328:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:330:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:332:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:334:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:336:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:338:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:340:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:342:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:344:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:346:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:348:65: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:350:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:352:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:488:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:490:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:492:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:494:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:496:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:498:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:500:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:502:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:504:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:506:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:508:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:510:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:512:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:514:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:516:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:518:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:520:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:522:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:524:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:526:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:528:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:530:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:532:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:534:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:536:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:538:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:611:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:614:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:616:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:653:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:655:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:657:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:659:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:661:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:663:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:665:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:735:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:737:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:739:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:741:63: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:743:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:745:64: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:802:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:804:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:806:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:808:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:810:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3670.c:812:69: warning: Using plain integer as NULL pointer
> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> ---

Applied to clk-next


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c
  2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
  2019-09-25 13:42   ` Ben Dooks
@ 2019-10-03 20:58   ` Stephen Boyd
  1 sibling, 0 replies; 8+ messages in thread
From: Stephen Boyd @ 2019-10-03 20:58 UTC (permalink / raw)
  To: Ben Dooks, linux-clk; +Cc: Michael Turquette, Ben Dooks

Quoting Ben Dooks (2019-09-25 04:23:47)
> Fix sparse warnings of a 0 being used for a pointer by removing it from
> the initialiser.
> 
> drivers/clk/hisilicon/clk-hi3660.c:336:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:338:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:340:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:342:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:344:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:346:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:348:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:350:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:352:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:354:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:356:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:358:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:360:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:362:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:364:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:366:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:368:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:370:69: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:372:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:374:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:376:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:378:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:423:68: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:425:68: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:427:68: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:429:68: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:449:70: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:451:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:453:71: warning: Using plain integer as NULL pointer
> drivers/clk/hisilicon/clk-hi3660.c:455:71: warning: Using plain integer as NULL pointer
> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> ---

Applied to clk-next


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, back to index

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-09-25 11:23 [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Ben Dooks
2019-09-25 11:23 ` [PATCH 2/2] clk: hisilicon: fix sparse warnings in clk-hi3660.c Ben Dooks
2019-09-25 13:42   ` Ben Dooks
2019-10-03 20:58   ` Stephen Boyd
2019-09-25 13:14 ` [PATCH 1/2] clk: hisilicon: fix sparse warnings in clk-hi3670.c Stephen Boyd
2019-09-25 13:39   ` Ben Dooks
2019-09-25 13:44   ` Ben Dooks
2019-10-03 20:58 ` Stephen Boyd

Linux-Clk Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/linux-clk/0 linux-clk/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 linux-clk linux-clk/ https://lore.kernel.org/linux-clk \
		linux-clk@vger.kernel.org linux-clk@archiver.kernel.org
	public-inbox-index linux-clk

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.linux-clk


AGPL code for this site: git clone https://public-inbox.org/ public-inbox