提交 bcad87bd 编写于 作者: D Dmitry Torokhov

Input: cma3000-d0x - remove unneeded checks

data->mode is unsigned and can not be less than 0.
Reported-by: NWerner <w.landgraf@ru.ru>
Signed-off-by: NDmitry Torokhov <dtor@mail.ru>
上级 b83643eb
......@@ -318,7 +318,7 @@ struct cma3000_accl_data *cma3000_init(struct device *dev, int irq,
mutex_init(&data->mutex);
data->mode = pdata->mode;
if (data->mode < CMAMODE_DEFAULT || data->mode > CMAMODE_POFF) {
if (data->mode > CMAMODE_POFF) {
data->mode = CMAMODE_MOTDET;
dev_warn(dev,
"Invalid mode specified, assuming Motion Detect\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册