提交 761a38a4 编写于 作者: H H Hartley Sweeten 提交者: Greg Kroah-Hartman

staging: comedi: serial2002: cleanup serial_read()

Remove the unnecessary '{ }' around the code and the extra indents
in the switch().
Signed-off-by: NH Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 071e0866
...@@ -273,15 +273,13 @@ static struct serial_data serial_read(struct file *f, int timeout) ...@@ -273,15 +273,13 @@ static struct serial_data serial_read(struct file *f, int timeout)
} else { } else {
if (length == 1) { if (length == 1) {
switch ((data >> 5) & 0x03) { switch ((data >> 5) & 0x03) {
case 0:{ case 0:
result.value = 0; result.value = 0;
result.kind = is_digital; result.kind = is_digital;
}
break; break;
case 1:{ case 1:
result.value = 1; result.value = 1;
result.kind = is_digital; result.kind = is_digital;
}
break; break;
} }
} else { } else {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册