提交 f0426b4e 编写于 作者: W Wan Jiabing 提交者: Greg Kroah-Hartman

tty/hvc_opal: simplify if-if to if-else

Use if and else instead of if(A) and if (!A).
Reviewed-by: NJiri Slaby <jirislaby@kernel.org>
Signed-off-by: NWan Jiabing <wanjiabing@vivo.com>
Link: https://lore.kernel.org/r/20220426071041.168282-1-wanjiabing@vivo.comSigned-off-by: NGreg Kroah-Hartman <gregkh@linuxfoundation.org>
上级 8043b16f
...@@ -342,9 +342,9 @@ void __init hvc_opal_init_early(void) ...@@ -342,9 +342,9 @@ void __init hvc_opal_init_early(void)
* path, so we hard wire it * path, so we hard wire it
*/ */
opal = of_find_node_by_path("/ibm,opal/consoles"); opal = of_find_node_by_path("/ibm,opal/consoles");
if (opal) if (opal) {
pr_devel("hvc_opal: Found consoles in new location\n"); pr_devel("hvc_opal: Found consoles in new location\n");
if (!opal) { } else {
opal = of_find_node_by_path("/ibm,opal"); opal = of_find_node_by_path("/ibm,opal");
if (opal) if (opal)
pr_devel("hvc_opal: " pr_devel("hvc_opal: "
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册