From patchwork Fri Apr 26 08:52:57 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sachin Kamat X-Patchwork-Id: 16417 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f200.google.com (mail-vc0-f200.google.com [209.85.220.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 27F162397A for ; Fri, 26 Apr 2013 09:06:36 +0000 (UTC) Received: by mail-vc0-f200.google.com with SMTP id gf12sf2089409vcb.3 for ; Fri, 26 Apr 2013 02:05:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:x-beenthere:x-received:received-spf :x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :x-gm-message-state:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe; bh=Q+sai+kk1RHdzZQwIDSNUdelIzEhAC0FoJWyifvxFQ0=; b=PI7NZvfdX6aq4fUPuHAYRkxi3bjMh8umdZb3wcJcKDlcNOScTLvOtJy9I9Rknc1r7+ 2p0rGK9tUEbnEqpl7UnZVd5cGR6Ml/q9CU17ronQQKQp6HMSNXNF/A+hSlaOuLGolyfu OTddGHUQ7LkfTPQ5e/T8JlpuZSYMb33XvetKXo1ODZwa7svesTidU/XeY6STBS+yM895 QVY2D11O29sN6Pwzujf30Pm4qAveXIBZuvWalIsrsw6kb5y4Kpma3R4+ZplOU+9ht5qd Frp46dVkp/bT7Eg0+SmOO5iX2j2eeJcFslJe4gmKr6JqFVyTB7c4O6MAmOTPIg8S+xpv xznQ== X-Received: by 10.236.81.115 with SMTP id l79mr5435918yhe.20.1366967140291; Fri, 26 Apr 2013 02:05:40 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.107.201 with SMTP id he9ls1829855qeb.2.gmail; Fri, 26 Apr 2013 02:05:40 -0700 (PDT) X-Received: by 10.52.73.42 with SMTP id i10mr7914827vdv.50.1366967140085; Fri, 26 Apr 2013 02:05:40 -0700 (PDT) Received: from mail-ve0-x22a.google.com (mail-ve0-x22a.google.com [2607:f8b0:400c:c01::22a]) by mx.google.com with ESMTPS id d10si4990783vdv.145.2013.04.26.02.05.40 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 26 Apr 2013 02:05:40 -0700 (PDT) Received-SPF: neutral (google.com: 2607:f8b0:400c:c01::22a is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=2607:f8b0:400c:c01::22a; Received: by mail-ve0-f170.google.com with SMTP id 15so1733403vea.15 for ; Fri, 26 Apr 2013 02:05:40 -0700 (PDT) X-Received: by 10.220.39.69 with SMTP id f5mr29059277vce.45.1366967139946; Fri, 26 Apr 2013 02:05:39 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.58.127.98 with SMTP id nf2csp59096veb; Fri, 26 Apr 2013 02:05:39 -0700 (PDT) X-Received: by 10.68.112.196 with SMTP id is4mr58714427pbb.117.1366967138869; Fri, 26 Apr 2013 02:05:38 -0700 (PDT) Received: from mail-da0-x22b.google.com (mail-da0-x22b.google.com [2607:f8b0:400e:c00::22b]) by mx.google.com with ESMTPS id nb4si9822518pbc.204.2013.04.26.02.05.38 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 26 Apr 2013 02:05:38 -0700 (PDT) Received-SPF: neutral (google.com: 2607:f8b0:400e:c00::22b is neither permitted nor denied by best guess record for domain of sachin.kamat@linaro.org) client-ip=2607:f8b0:400e:c00::22b; Received: by mail-da0-f43.google.com with SMTP id u36so1862114dak.16 for ; Fri, 26 Apr 2013 02:05:38 -0700 (PDT) X-Received: by 10.68.94.227 with SMTP id df3mr56869758pbb.182.1366967138323; Fri, 26 Apr 2013 02:05:38 -0700 (PDT) Received: from linaro.sisodomain.com ([115.113.119.130]) by mx.google.com with ESMTPSA id qi1sm11898513pac.21.2013.04.26.02.05.34 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 26 Apr 2013 02:05:37 -0700 (PDT) From: Sachin Kamat To: linux-media@vger.kernel.org Cc: s.nawrocki@samsung.com, sachin.kamat@linaro.org, patches@linaro.org Subject: [PATCH v2] [media] exynos4-is: Fix potential null pointer dereference in mipi-csis.c Date: Fri, 26 Apr 2013 14:22:57 +0530 Message-Id: <1366966377-15808-1-git-send-email-sachin.kamat@linaro.org> X-Mailer: git-send-email 1.7.9.5 X-Gm-Message-State: ALoCoQkR6OczRkkXzL3qsrPPq2UWKg/Y2DQCJRCH9YAgWfzSWMq2h1D8zHb7Lyl9ye0W08t7E20S X-Original-Sender: sachin.kamat@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 2607:f8b0:400c:c01::22a is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , When 'node' is NULL, the print statement tries to dereference it. Hence replace the variable with the one that is accessible. Signed-off-by: Sachin Kamat --- Changes since v1: Used pdev->dev.of_node->full_name for node name. --- drivers/media/platform/exynos4-is/mipi-csis.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/exynos4-is/mipi-csis.c b/drivers/media/platform/exynos4-is/mipi-csis.c index a2eda9d..254d70f 100644 --- a/drivers/media/platform/exynos4-is/mipi-csis.c +++ b/drivers/media/platform/exynos4-is/mipi-csis.c @@ -746,7 +746,7 @@ static int s5pcsis_parse_dt(struct platform_device *pdev, node = v4l2_of_get_next_endpoint(node, NULL); if (!node) { dev_err(&pdev->dev, "No port node at %s\n", - node->full_name); + pdev->dev.of_node->full_name); return -EINVAL; } /* Get port node and validate MIPI-CSI channel id. */