From patchwork Sun Dec 19 18:13:00 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Charkov X-Patchwork-Id: 418891 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oBJIDK7j004885 for ; Sun, 19 Dec 2010 18:13:21 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932340Ab0LSSNE (ORCPT ); Sun, 19 Dec 2010 13:13:04 -0500 Received: from mail-ey0-f171.google.com ([209.85.215.171]:60967 "EHLO mail-ey0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932328Ab0LSSNE (ORCPT ); Sun, 19 Dec 2010 13:13:04 -0500 Received: by eyg5 with SMTP id 5so1131790eyg.2 for ; Sun, 19 Dec 2010 10:13:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:date:from:to:cc:subject :message-id:mime-version:content-type:content-disposition:user-agent; bh=kNFTIMpyfHqmwz5gC/+26l2gCU8vHzGso/TsN20jEf0=; b=iY/mzat8rdCFa75iQ8FITveNFSfZo/oPmfmRFQIJ5mLHOcDbH6BqNY+YAuyOycWsGy 5ITq7rCXupLCjsHGFIH+l/WQPNgtCcUg55gKeYD57hlMdTEGAPCst6GtHJpai4VNLKta W+/WgZGhiQqw9gU2S7keTXDQxmhVw7chRGEGA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=date:from:to:cc:subject:message-id:mime-version:content-type :content-disposition:user-agent; b=kMww24cx4tHVSy23Rb2H/RimZPYS8yVcFv58Y75jTkofCo31b/1vGEzzqHVH9nYtWq GayYLRbrWIerfRPyT0VYZ6qtTYmo23tdX6GUjDMFqG4Dd7x+rczdqVRKHRaIoKXqdwHU p/cVCTgUqkm8zMoo8UQp69345T3iqB24WSXHc= Received: by 10.213.108.208 with SMTP id g16mr3161616ebp.40.1292782381864; Sun, 19 Dec 2010 10:13:01 -0800 (PST) Received: from localhost ([109.188.43.51]) by mx.google.com with ESMTPS id u1sm2168671eeh.4.2010.12.19.10.13.00 (version=TLSv1/SSLv3 cipher=RC4-MD5); Sun, 19 Dec 2010 10:13:01 -0800 (PST) Date: Sun, 19 Dec 2010 21:13:00 +0300 From: Alexey Charkov To: Paul Mundt Cc: linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org, vt8500-wm8505-linux-kernel@googlegroups.com Subject: [PATCH] fbdev: Minor cleanup in WM8505-related code Message-ID: <20101219181300.GA32645@alchark-u3s> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Sun, 19 Dec 2010 18:13:21 +0000 (UTC) diff --git a/drivers/video/wm8505fb.c b/drivers/video/wm8505fb.c index e37251b..96e34a5 100644 --- a/drivers/video/wm8505fb.c +++ b/drivers/video/wm8505fb.c @@ -88,7 +88,7 @@ static int wm8505fb_set_timing(struct fb_info *info) int v_start = info->var.upper_margin; int v_end = v_start + info->var.yres; int v_all = v_end + info->var.lower_margin; - int v_sync = info->var.vsync_len + 1; + int v_sync = info->var.vsync_len; writel(0, fbi->regbase + WMT_GOVR_TG); @@ -291,7 +291,7 @@ static int __devinit wm8505fb_probe(struct platform_device *pdev) goto failed_fbi; } - res = request_mem_region(res->start, resource_size(res), "wm8505fb"); + res = request_mem_region(res->start, resource_size(res), DRIVER_NAME); if (res == NULL) { dev_err(&pdev->dev, "failed to request I/O memory\n"); ret = -EBUSY; diff --git a/drivers/video/wmt_ge_rops.c b/drivers/video/wmt_ge_rops.c index f31883f..45832b7 100644 --- a/drivers/video/wmt_ge_rops.c +++ b/drivers/video/wmt_ge_rops.c @@ -127,13 +127,11 @@ EXPORT_SYMBOL_GPL(wmt_ge_sync); static int __devinit wmt_ge_rops_probe(struct platform_device *pdev) { struct resource *res; - int ret; res = platform_get_resource(pdev, IORESOURCE_MEM, 0); if (res == NULL) { dev_err(&pdev->dev, "no I/O memory resource defined\n"); - ret = -ENODEV; - goto error; + return -ENODEV; } /* Only one ROP engine is presently supported. */ @@ -145,17 +143,13 @@ static int __devinit wmt_ge_rops_probe(struct platform_device *pdev) regbase = ioremap(res->start, resource_size(res)); if (regbase == NULL) { dev_err(&pdev->dev, "failed to map I/O memory\n"); - ret = -EBUSY; - goto error; + return -EBUSY; } writel(1, regbase + GE_ENABLE_OFF); printk(KERN_INFO "Enabled support for WMT GE raster acceleration\n"); return 0; - -error: - return ret; } static int __devexit wmt_ge_rops_remove(struct platform_device *pdev)