From patchwork Mon Aug 26 18:53:32 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Eugene Surovegin X-Patchwork-Id: 269950 Return-Path: X-Original-To: patchwork-incoming@ozlabs.org Delivered-To: patchwork-incoming@ozlabs.org Received: from ozlabs.org (localhost [IPv6:::1]) by ozlabs.org (Postfix) with ESMTP id 5644F2C01B6 for ; Tue, 27 Aug 2013 05:00:41 +1000 (EST) X-Greylist: delayed 400 seconds by postgrey-1.34 at bilbo; Tue, 27 Aug 2013 05:00:15 EST Received: from gate.ebshome.net (gate.ebshome.net [173.228.107.16]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 59AA72C0084 for ; Tue, 27 Aug 2013 05:00:15 +1000 (EST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ebshome.net; s=20120831; t=1377543613; i=ebs@ebshome.net; bh=eMwNrFqQQ6ACd1IuewJ998gqJSjpTsUY+MrAQP2+CRY=; h=From:To:Cc:Subject:Date:Message-Id:X-Mailer; b=RZkDovHebcvsm5y4UdPLeEqLdwCEe6A+jFw3cEcixurJlczaSMEYvkdACMNIJxv1F r4fxn1lY71iaSXtJmMkgjrSjuFhV/EiRYIcNyoGqjDruRIbKqAC2rN+7WuJcYwgFHO lFghzHPBSWlbAtNngRgjND6TC7sfDotMEXqrRuiE= Received: (qmail 20462 invoked by uid 1000); 26 Aug 2013 11:53:32 -0700 From: Eugene Surovegin To: Benjamin Herrenschmidt Subject: [PATCH] powerpc/hvsi: increase handshake timeout from 200ms to 400ms. Date: Mon, 26 Aug 2013 11:53:32 -0700 Message-Id: <1377543212-20432-1-git-send-email-ebs@ebshome.net> X-Mailer: git-send-email 1.8.1.5 Cc: linuxppc-dev@lists.ozlabs.org X-BeenThere: linuxppc-dev@lists.ozlabs.org X-Mailman-Version: 2.1.16rc2 Precedence: list List-Id: Linux on PowerPC Developers Mail List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: linuxppc-dev-bounces+patchwork-incoming=ozlabs.org@lists.ozlabs.org Sender: "Linuxppc-dev" This solves a problem observed in kexec'ed kernel where 200ms timeout is too short and bootconsole fails to initialize. Console did eventually become workable but much later into the boot process. Observed timeout was around 260ms, but I decided to make it a little bigger for more reliability. This has been tested on Power7 machine with Petitboot as a primary bootloader and PowerNV firmware. Signed-off-by: Eugene Surovegin --- drivers/tty/hvc/hvsi_lib.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/tty/hvc/hvsi_lib.c b/drivers/tty/hvc/hvsi_lib.c index 3396eb9..ac27671 100644 --- a/drivers/tty/hvc/hvsi_lib.c +++ b/drivers/tty/hvc/hvsi_lib.c @@ -341,8 +341,8 @@ void hvsilib_establish(struct hvsi_priv *pv) pr_devel("HVSI@%x: ... waiting handshake\n", pv->termno); - /* Try for up to 200s */ - for (timeout = 0; timeout < 20; timeout++) { + /* Try for up to 400ms */ + for (timeout = 0; timeout < 40; timeout++) { if (pv->established) goto established; if (!hvsi_get_packet(pv))