From patchwork Mon May 9 15:08:06 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Jarod Wilson X-Patchwork-Id: 769572 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.3) with ESMTP id p49F6cM9004783 for ; Mon, 9 May 2011 15:08:50 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751185Ab1EIPIt (ORCPT ); Mon, 9 May 2011 11:08:49 -0400 Received: from mx1.redhat.com ([209.132.183.28]:14836 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750915Ab1EIPIt (ORCPT ); Mon, 9 May 2011 11:08:49 -0400 Received: from int-mx01.intmail.prod.int.phx2.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p49F8lXP027649 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Mon, 9 May 2011 11:08:47 -0400 Received: from xavier.bos.redhat.com (xavier.bos.redhat.com [10.16.16.50]) by int-mx01.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p49F8kFR014898; Mon, 9 May 2011 11:08:47 -0400 From: Jarod Wilson To: linux-media@vger.kernel.org Cc: Jarod Wilson , =?UTF-8?q?Juan=20Jes=C3=BAs=20Garc=C3=ADa=20de=20Soria?= Subject: [PATCH] [media] ite-cir: make IR receive work after resume Date: Mon, 9 May 2011 11:08:06 -0400 Message-Id: <1304953686-21805-1-git-send-email-jarod@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.67 on 10.5.11.11 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Mon, 09 May 2011 15:08:50 +0000 (UTC) Just recently acquired an Asus Eee Box PC with an onboard IR receiver driven by ite-cir (ITE8713 sub-variant). Works out of the box with the ite-cir driver in 2.6.39, but stops working after a suspend/resume cycle. Its fixed by simply reinitializing registers after resume, similar to what's done in the nuvoton-cir driver. I've not tested with any other ITE variant, but code inspection suggests this should be safe on all variants. Reported-by: Stephan Raue CC: Juan Jesús García de Soria Signed-off-by: Jarod Wilson --- drivers/media/rc/ite-cir.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/drivers/media/rc/ite-cir.c b/drivers/media/rc/ite-cir.c index 43908a7..8488e53 100644 --- a/drivers/media/rc/ite-cir.c +++ b/drivers/media/rc/ite-cir.c @@ -1684,6 +1684,8 @@ static int ite_resume(struct pnp_dev *pdev) /* wake up the transmitter */ wake_up_interruptible(&dev->tx_queue); } else { + /* reinitialize hardware config registers */ + itdev->params.init_hardware(itdev); /* enable the receiver */ dev->params.enable_rx(dev); }