diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/clk/renesas/rcar-cpg-lib.c | 5 | ||||
-rw-r--r-- | drivers/mtd/spi/spi-nor-ids.c | 1 | ||||
-rw-r--r-- | drivers/net/rswitch.c | 4 |
3 files changed, 7 insertions, 3 deletions
diff --git a/drivers/clk/renesas/rcar-cpg-lib.c b/drivers/clk/renesas/rcar-cpg-lib.c index ea33bfd3239..60ab2cb379e 100644 --- a/drivers/clk/renesas/rcar-cpg-lib.c +++ b/drivers/clk/renesas/rcar-cpg-lib.c @@ -92,7 +92,8 @@ int rcar_clk_set_rate64_div_table(unsigned int parent, u64 parent_rate, ulong ra void __iomem *reg, const u32 mask, const struct clk_div_table *table, char *name) { - u32 value = 0, div = 0; + u32 div; + int value; div = DIV_ROUND_CLOSEST(parent_rate, rate); value = rcar_clk_get_table_val(table, div); @@ -101,7 +102,7 @@ int rcar_clk_set_rate64_div_table(unsigned int parent, u64 parent_rate, ulong ra clrsetbits_le32(reg, mask, field_prep(mask, value)); - debug("%s[%i] %s clk: parent=%i div=%u rate=%lu => val=%u\n", + debug("%s[%i] %s clk: parent=%i div=%u rate=%lu => val=%d\n", __func__, __LINE__, name, parent, div, rate, value); return 0; diff --git a/drivers/mtd/spi/spi-nor-ids.c b/drivers/mtd/spi/spi-nor-ids.c index e7e97780d7c..0383175beb5 100644 --- a/drivers/mtd/spi/spi-nor-ids.c +++ b/drivers/mtd/spi/spi-nor-ids.c @@ -591,6 +591,7 @@ const struct flash_info spi_nor_ids[] = { { INFO("w25m512jw", 0xef6119, 0, 64 * 1024, 1024, SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) }, { INFO("w25m512jv", 0xef7119, 0, 64 * 1024, 1024, SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) }, { INFO("w25h02jv", 0xef9022, 0, 64 * 1024, 4096, SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ) }, + { INFO("w77q51nw", 0xef8a1a, 0, 64 * 1024, 1024, SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ | SPI_NOR_4B_OPCODES) }, #endif #ifdef CONFIG_SPI_FLASH_XMC /* XMC (Wuhan Xinxin Semiconductor Manufacturing Corp.) */ diff --git a/drivers/net/rswitch.c b/drivers/net/rswitch.c index 62d3f39f071..f27587ac8bd 100644 --- a/drivers/net/rswitch.c +++ b/drivers/net/rswitch.c @@ -1110,8 +1110,10 @@ static int rswitch_probe(struct udevice *dev) return -EINVAL; priv->rsw_clk = devm_clk_get(dev, NULL); - if (ret) + if (IS_ERR(priv->rsw_clk)) { + ret = PTR_ERR(priv->rsw_clk); goto err_map; + } ret = clk_prepare_enable(priv->rsw_clk); if (ret) |