Skip to content

Commit

Permalink
USB: serial: mos7720: fix parallel-port state restore
Browse files Browse the repository at this point in the history
The parallel-port restore operations is called when a driver claims the
port and is supposed to restore the provided state (e.g. saved when
releasing the port).

Fixes: b69578d ("USB: usbserial: mos7720: add support for parallel port on moschip 7715")
Cc: stable <stable@vger.kernel.org>     # 2.6.35
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Johan Hovold <johan@kernel.org>
  • Loading branch information
jhovold committed Nov 5, 2020
1 parent 179dfb9 commit 975323a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/usb/serial/mos7720.c
Original file line number Diff line number Diff line change
Expand Up @@ -639,6 +639,8 @@ static void parport_mos7715_restore_state(struct parport *pp,
spin_unlock(&release_lock);
return;
}
mos_parport->shadowDCR = s->u.pc.ctr;
mos_parport->shadowECR = s->u.pc.ecr;
write_parport_reg_nonblock(mos_parport, MOS7720_DCR,
mos_parport->shadowDCR);
write_parport_reg_nonblock(mos_parport, MOS7720_ECR,
Expand Down

0 comments on commit 975323a

Please sign in to comment.