From patchwork Mon Dec 24 08:33:47 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 1908361 Return-Path: X-Original-To: patchwork-dri-devel@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) by patchwork1.kernel.org (Postfix) with ESMTP id 6A48C40061 for ; Mon, 24 Dec 2012 09:43:15 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A6DF9E5F3A for ; Mon, 24 Dec 2012 01:43:14 -0800 (PST) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-pb0-f50.google.com (mail-pb0-f50.google.com [209.85.160.50]) by gabe.freedesktop.org (Postfix) with ESMTP id A0F71E5C30 for ; Mon, 24 Dec 2012 00:42:21 -0800 (PST) Received: by mail-pb0-f50.google.com with SMTP id wz7so3858408pbc.37 for ; Mon, 24 Dec 2012 00:42:21 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=ytPD0h3b0uG31itOoqH+l7AUbyfaXCABHPZkJWULMCU=; b=PYCQ4EIdYG9Pr1VJSpHUUv5zssgnIroykOpOcrC5jHBrh6htdaO7pLFfsbUK5lz8Hs sKbJmNSoC090xYyEPZrzS7P9mbfHutxUqfu4W3deuJMQo/ixgX0yeqZNLbE4etNAtFO9 6O2awchq6X5hzPk/nePWi/6UstpJreNqbvKbjPri/j0xCYfrDmaMleAmr9j+CNW6NoW8 RqXBmTU4Mg69qz+SOZe8rcsgxJU9I0yDd6ilHHU0SrtWyiVrXAfTQZzfgL8wxhL/vc4m tXxTm5w0uogGw4KlxXxLZScz6QdjKGAFujtL5aDo8+m+m/1wdenU1hpFnVJ349M8zWmz ZGuA== X-Received: by 10.66.89.199 with SMTP id bq7mr61324524pab.26.1356338541444; Mon, 24 Dec 2012 00:42:21 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id pv8sm11959096pbc.26.2012.12.24.00.42.18 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 24 Dec 2012 00:42:20 -0800 (PST) From: Sachin Kamat To: dri-devel@lists.freedesktop.org Subject: [PATCH 06/10] drm/exynos: Remove redundant NULL check in exynos_drm_rotator.c Date: Mon, 24 Dec 2012 14:03:47 +0530 Message-Id: <1356338031-23674-7-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1356338031-23674-1-git-send-email-sachin.kamat@linaro.org> References: <1356338031-23674-1-git-send-email-sachin.kamat@linaro.org> X-Gm-Message-State: ALoCoQlrpH4L/uO7QUMEp5bMJWkpVYq3ZW+XImXc7Mx+EAeAn3ol/fd3uVdXwx8V8kcTzIqwroD4 X-Mailman-Approved-At: Mon, 24 Dec 2012 01:36:57 -0800 Cc: sachin.kamat@linaro.org, patches@linaro.org X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.13 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org Errors-To: dri-devel-bounces+patchwork-dri-devel=patchwork.kernel.org@lists.freedesktop.org devm_request_and_ioremap API checks for NULL. Hence explicit NULL check is not necessary. Saves some code. Cc: Eunchul Kim Signed-off-by: Sachin Kamat --- drivers/gpu/drm/exynos/exynos_drm_rotator.c | 5 ----- 1 files changed, 0 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/exynos/exynos_drm_rotator.c b/drivers/gpu/drm/exynos/exynos_drm_rotator.c index 0f168449..4505163 100644 --- a/drivers/gpu/drm/exynos/exynos_drm_rotator.c +++ b/drivers/gpu/drm/exynos/exynos_drm_rotator.c @@ -655,11 +655,6 @@ static int __devinit rotator_probe(struct platform_device *pdev) platform_get_device_id(pdev)->driver_data; rot->regs_res = platform_get_resource(pdev, IORESOURCE_MEM, 0); - if (!rot->regs_res) { - dev_err(dev, "failed to find registers\n"); - return -ENOENT; - } - rot->regs = devm_request_and_ioremap(dev, rot->regs_res); if (!rot->regs) { dev_err(dev, "failed to map register\n");