From patchwork Fri Apr 16 22:52:50 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Peter M. Petrakis" X-Patchwork-Id: 93249 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o3GMqsO1019835 for ; Fri, 16 Apr 2010 22:52:54 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932716Ab0DPWwx (ORCPT ); Fri, 16 Apr 2010 18:52:53 -0400 Received: from adelie.canonical.com ([91.189.90.139]:34075 "EHLO adelie.canonical.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932692Ab0DPWww (ORCPT ); Fri, 16 Apr 2010 18:52:52 -0400 Received: from hutte.canonical.com ([91.189.90.181]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1O2uP5-0002VV-N4; Fri, 16 Apr 2010 23:52:51 +0100 Received: from [91.189.91.3] (helo=[10.0.1.106]) by hutte.canonical.com with esmtpsa (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1O2uP5-0001mc-Ij; Fri, 16 Apr 2010 23:52:51 +0100 Message-ID: <4BC8EA42.6030507@canonical.com> Date: Fri, 16 Apr 2010 18:52:50 -0400 From: "Peter M. Petrakis" Organization: Canonical USA Inc. User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.9) Gecko/20100404 Thunderbird/3.0.4 MIME-Version: 1.0 To: linux-input@vger.kernel.org CC: rubini@cvml.unipv.it Subject: [PATCH] Reset ps/2 port should psmouse_probe fail before retrying Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Fri, 16 Apr 2010 22:52:55 +0000 (UTC) diff --git a/drivers/input/mouse/psmouse-base.c b/drivers/input/mouse/psmouse-base.c index d8c0c8d..a51b9a7 100644 --- a/drivers/input/mouse/psmouse-base.c +++ b/drivers/input/mouse/psmouse-base.c @@ -905,12 +905,12 @@ static const struct psmouse_protocol *psmouse_protocol_by_name(const char *name, return NULL; } - /* - * psmouse_probe() probes for a PS/2 mouse. + * __psmouse_probe() probes for a PS/2 mouse. + * Wrapped by psmouse_probe() for clean reset code. */ -static int psmouse_probe(struct psmouse *psmouse) +static int __psmouse_probe(struct psmouse *psmouse) { struct ps2dev *ps2dev = &psmouse->ps2dev;