Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp2655820pxa; Mon, 17 Aug 2020 15:40:20 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwQmhP6zpSfW8N5mN78WpbsAFJNO5vBPy3z0miw+N090VLtRNfqzvUJSKTUgjE7WJ3H0siu X-Received: by 2002:a17:906:811:: with SMTP id e17mr18187990ejd.549.1597704020718; Mon, 17 Aug 2020 15:40:20 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597704020; cv=none; d=google.com; s=arc-20160816; b=0qTHWJY8LakpCEte+l7z1XC/IQOdu7O1IMaFD2YBXhenv8xXYmkfPHXtX9fST57T9h 8bgOYDBTCt393luOTjQCSM/0OK5w3jEVON1jf7yO3yGMg0Dnr0TdtS2odq+ur9z/ucaF mVQAgepauh4/9O9SaQmPYI3/A0wGWAR8LWH88lr1RJ+zyPRM0kZzJjlxOGB9B28gvy3r 0KaLloGFyQM9y5lzycXQaV8pQD9msWx08xwJjq7icgjn3CA3KA1VKH3SLVUyOj6X9kvi QupEeLJJ0L93PNCazCsWjvWl/vRxAPVmUSKUVJaMbrN6Vj3xBYsIp+2z3RXREQpJAh0D k0vA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=QbRst2ePc9HnT2YDVsN/pKImkWuILQlpUz30yJLXa2Y=; b=forMSyN/ZJbSX3jVdFWTofgOqE6TlYXQJFMNd2ARJertdKLExTcRkmrzhZBbQYt4uk Nrxz/MJCKIuOnb/LHJsrVuTcr8u6wwhaE/Tf6BAtgtIm8qD46njMjF9wjiNhYm8IY0Vz ji2unFVTKQGV1vONq4wCwayAv1izAdwqpjbR6W7F/kyMYsL4yn4El2GBbx6DWrZ3BXnB PxGJk/ekJOoOy0dw6G7MJPsTjjhqWsR7VQ+S3zZjPmN1myApFqwxbiS4DQpKBkpHWQ2I oUOSmUaOFlWzEybfNZHc6ou3M/gUm52rFZp8ucgL993VR2LbArLGB9olbp/QjF5rmbiP Goeg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=tLHI0p5x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id be10si11774551edb.574.2020.08.17.15.39.57; Mon, 17 Aug 2020 15:40:20 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=tLHI0p5x; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390466AbgHQSOq (ORCPT + 99 others); Mon, 17 Aug 2020 14:14:46 -0400 Received: from mail.kernel.org ([198.145.29.99]:54486 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388394AbgHQQG0 (ORCPT ); Mon, 17 Aug 2020 12:06:26 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4859A207FB; Mon, 17 Aug 2020 16:06:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597680384; bh=C8r8mALl/7ZEMq5jWAreO2rJacfW0xTMtM7RPgVBCDI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=tLHI0p5x24ZyiFwsZgCORw2cmfn5ai7Yk7i+KKaXQjnyTlDtgU6Hflot8pfLL5pBG x1sNmJadFq12XgbKfZWZ4phWww10RfELrzmXmYNIa5rwhkAgAf3fuwOFii/sDfZ7kX heZqTEWPr022i145jwAR/bcpkelKeWKVIEECH33U= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Chuhong Yuan , Hans Verkuil , Mauro Carvalho Chehab , Sasha Levin Subject: [PATCH 5.4 125/270] media: exynos4-is: Add missed check for pinctrl_lookup_state() Date: Mon, 17 Aug 2020 17:15:26 +0200 Message-Id: <20200817143801.999748521@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200817143755.807583758@linuxfoundation.org> References: <20200817143755.807583758@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Chuhong Yuan [ Upstream commit 18ffec750578f7447c288647d7282c7d12b1d969 ] fimc_md_get_pinctrl() misses a check for pinctrl_lookup_state(). Add the missed check to fix it. Fixes: 4163851f7b99 ("[media] s5p-fimc: Use pinctrl API for camera ports configuration]") Signed-off-by: Chuhong Yuan Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Sasha Levin --- drivers/media/platform/exynos4-is/media-dev.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/media/platform/exynos4-is/media-dev.c b/drivers/media/platform/exynos4-is/media-dev.c index 9aaf3b8060d50..9c31d950cddf7 100644 --- a/drivers/media/platform/exynos4-is/media-dev.c +++ b/drivers/media/platform/exynos4-is/media-dev.c @@ -1270,6 +1270,9 @@ static int fimc_md_get_pinctrl(struct fimc_md *fmd) pctl->state_idle = pinctrl_lookup_state(pctl->pinctrl, PINCTRL_STATE_IDLE); + if (IS_ERR(pctl->state_idle)) + return PTR_ERR(pctl->state_idle); + return 0; } -- 2.25.1