• Alexandre Courbot's avatar
    serial: sh-sci: fix deadlock when resuming from S3 sleep · 36003386
    Alexandre Courbot authored
    S3 sleep invokes the shutdown callback of the sh-sci driver, which
    suspends the clocks until they are reactivated by a call to startup.
    However, before the latter is invoked, sci_set_termios may be called on
    the port by uart_resume_port. In such cases it will endlessly wait for
    the TEND bit to raise, which will never happen since the clocks are
    disabled.
    
    This patch ensures that clocks are enabled when ports registers are
    manipulated within sci_set_termios.
    Signed-off-by: default avatarAlexandre Courbot <gnurou@gmail.com>
    Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
    36003386
sh-sci.c 48.5 KB