Skip to content

Commit

Permalink
serial: pch_uart: fix build error with !CONFIG_DEBUG_FS
Browse files Browse the repository at this point in the history
Fix the build error with CONFIG_DEBUG_FS is not set:

drivers/tty/serial/pch_uart.c: In function 'pch_uart_init_port':
drivers/tty/serial/pch_uart.c:1815:9: error: 'port_regs_ops' undeclared (first use in this function)
 1815 |        &port_regs_ops);
      |         ^~~~~~~~~~~~~

This commit get rid of the CONFIG_PM_SLEEP ifdefery to
fix the build error.

Fixes: 1f8a51e ("tty: serial: pch_uart.c: remove debugfs dentry pointer")
Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Link: https://lore.kernel.org/r/20210322122601.2980258-1-weiyongjun1@huawei.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Wei Yongjun authored and Greg Kroah-Hartman committed Mar 23, 2021
1 parent 1657ca6 commit df5d151
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions drivers/tty/serial/pch_uart.c
Original file line number Diff line number Diff line change
Expand Up @@ -291,8 +291,6 @@ static const int trigger_level_64[4] = { 1, 16, 32, 56 };
static const int trigger_level_16[4] = { 1, 4, 8, 14 };
static const int trigger_level_1[4] = { 1, 1, 1, 1 };

#ifdef CONFIG_DEBUG_FS

#define PCH_REGS_BUFSIZE 1024


Expand Down Expand Up @@ -352,7 +350,6 @@ static const struct file_operations port_regs_ops = {
.read = port_show_regs,
.llseek = default_llseek,
};
#endif /* CONFIG_DEBUG_FS */

static const struct dmi_system_id pch_uart_dmi_table[] = {
{
Expand Down

0 comments on commit df5d151

Please sign in to comment.