From: Jiri Slaby Date: Tue, 11 Aug 2009 21:20:41 +0000 (+0200) Subject: tty: Power: fix suspend vt regression X-Git-Tag: v2.6.32-rc1~627^2~16 X-Git-Url: https://openfabrics.org/gitweb/?a=commitdiff_plain;h=797938b5e33991dadf4dd9228b932cc69c3e905a;p=~shefty%2Frdma-dev.git tty: Power: fix suspend vt regression vt_waitactive no longer accepts console parameter as console-1 since commit "vt: add an event interface". It expects console number directly (as viewed by userspace -- counting from 1). Fix a deadlock suspend regression by redefining adding one to vt in vt_move_to_console. Signed-off-by: Jiri Slaby Cc: Alan Cox Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/char/vt_ioctl.c b/drivers/char/vt_ioctl.c index 30b5d128037..29c651ab0d7 100644 --- a/drivers/char/vt_ioctl.c +++ b/drivers/char/vt_ioctl.c @@ -1757,7 +1757,7 @@ int vt_move_to_console(unsigned int vt, int alloc) return -EIO; } release_console_sem(); - if (vt_waitactive(vt)) { + if (vt_waitactive(vt + 1)) { pr_debug("Suspend: Can't switch VCs."); return -EINTR; }