Skip to content

Commit de5b2c9

Browse files
jhovoldgregkh
authored andcommitted
serial: pmac_zilog: add sparse context annotation
Add sparse context annotation to the receive handler, which releases and reacquires the port lock, to silence a sparse warning: drivers/tty/serial/pmac_zilog.c:255:36: sparse: sparse: context imbalance in 'pmz_receive_chars' - unexpected unlock Reported-by: kernel test robot <[email protected]> Signed-off-by: Johan Hovold <[email protected]> Reviewed-by: Andy Shevchenko <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 118499e commit de5b2c9

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/tty/serial/pmac_zilog.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,7 @@ static void pmz_interrupt_control(struct uart_pmac_port *uap, int enable)
213213
}
214214

215215
static bool pmz_receive_chars(struct uart_pmac_port *uap)
216+
__must_hold(&uap->port.lock)
216217
{
217218
struct tty_port *port;
218219
unsigned char ch, r1, drop, flag;

0 commit comments

Comments
 (0)