From patchwork Sat Jul 30 20:26:54 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 1022972 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p6UKQrbF031932 for ; Sat, 30 Jul 2011 20:26:55 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752631Ab1G3U0z (ORCPT ); Sat, 30 Jul 2011 16:26:55 -0400 Received: from perceval.ideasonboard.com ([95.142.166.194]:56035 "EHLO perceval.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752404Ab1G3U0w (ORCPT ); Sat, 30 Jul 2011 16:26:52 -0400 Received: from localhost.localdomain (unknown [91.178.149.42]) by perceval.ideasonboard.com (Postfix) with ESMTPSA id C65C535AA3; Sat, 30 Jul 2011 20:26:50 +0000 (UTC) From: Laurent Pinchart To: linux-fbdev@vger.kernel.org Cc: linux-sh@vger.kernel.org Subject: [PATCH 3/4] fbdev: sh_mobile_meram: Fix MExxCTL register save on runtime PM suspend Date: Sat, 30 Jul 2011 22:26:54 +0200 Message-Id: <1312057615-29123-4-git-send-email-laurent.pinchart@ideasonboard.com> X-Mailer: git-send-email 1.7.3.4 In-Reply-To: <1312057615-29123-1-git-send-email-laurent.pinchart@ideasonboard.com> References: <1312057615-29123-1-git-send-email-laurent.pinchart@ideasonboard.com> Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@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]); Sat, 30 Jul 2011 20:26:55 +0000 (UTC) To reset the ICB on resume the MExxCTL register needs to be OR'ed with MExxCTL_WBF | MExxCTL_WF | MExxCTL_RF, no set to that value. Fix this. This fixes corruption at the bottom of the display when resuming from runtime PM. Signed-off-by: Laurent Pinchart --- drivers/video/sh_mobile_meram.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/video/sh_mobile_meram.c b/drivers/video/sh_mobile_meram.c index 25a7118..7ba6dce 100644 --- a/drivers/video/sh_mobile_meram.c +++ b/drivers/video/sh_mobile_meram.c @@ -549,7 +549,7 @@ static int sh_mobile_meram_runtime_suspend(struct device *dev) meram_read_icb(priv->base, j, icb_regs[k]); /* Reset ICB on resume */ if (icb_regs[k] == MExxCTL) - priv->icb_saved_regs[j * ICB_REGS_SIZE + k] = + priv->icb_saved_regs[j * ICB_REGS_SIZE + k] |= MExxCTL_WBF | MExxCTL_WF | MExxCTL_RF; } }