提交 b85bfc44 编写于 作者: A Axel Lin 提交者: Mark Brown

spi: st-ssc4: Remove duplicate code to test unsupported mode bits

spi_setup() will test unsupported mode bits before calling spi->master->setup.
Thus remove duplicate code to test unsupported mode bits in spi_st_setup().
Signed-off-by: NAxel Lin <axel.lin@ingics.com>
Signed-off-by: NMark Brown <broonie@kernel.org>
上级 f5bac70f
无相关合并请求
......@@ -217,12 +217,6 @@ static int spi_st_setup(struct spi_device *spi)
int cs = spi->cs_gpio;
int ret;
if (spi->mode & ~MODEBITS) {
dev_err(&spi->dev, "unsupported mode bits 0x%x\n",
spi->mode & ~MODEBITS);
return -EINVAL;
}
if (!hz) {
dev_err(&spi->dev, "max_speed_hz unspecified\n");
return -EINVAL;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册
反馈
建议
客服 返回
顶部