提交 16f5df8b 编写于 作者: S Shawn Lin 提交者: Ulf Hansson

mmc: dw_mmc: fix the wrong condition check of getting num-slots from DT

Change to print the information about when the deprecated "num-slots" DT
binding is being used, as to avoid confusion when browsing the log:

dwmmc_rockchip fe320000.dwmmc: 'num-slots' was deprecated.
Signed-off-by: NShawn Lin <shawn.lin@rock-chips.com>
Fixes: d30a8f7b ("mmc: dw_mmc: deprecated the "num-slots" property")
Signed-off-by: NUlf Hansson <ulf.hansson@linaro.org>
上级 36acbd9e
...@@ -2957,7 +2957,7 @@ static struct dw_mci_board *dw_mci_parse_dt(struct dw_mci *host) ...@@ -2957,7 +2957,7 @@ static struct dw_mci_board *dw_mci_parse_dt(struct dw_mci *host)
} }
/* find out number of slots supported */ /* find out number of slots supported */
if (device_property_read_u32(dev, "num-slots", &pdata->num_slots)) if (!device_property_read_u32(dev, "num-slots", &pdata->num_slots))
dev_info(dev, "'num-slots' was deprecated.\n"); dev_info(dev, "'num-slots' was deprecated.\n");
if (device_property_read_u32(dev, "fifo-depth", &pdata->fifo_depth)) if (device_property_read_u32(dev, "fifo-depth", &pdata->fifo_depth))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册