From patchwork Thu Mar 26 21:09:43 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Wolfram Sang X-Patchwork-Id: 11461227 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 503AD161F for ; Thu, 26 Mar 2020 21:12:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 3AE172073E for ; Thu, 26 Mar 2020 21:12:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728237AbgCZVMj (ORCPT ); Thu, 26 Mar 2020 17:12:39 -0400 Received: from sauhun.de ([88.99.104.3]:54296 "EHLO pokefinder.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726954AbgCZVJv (ORCPT ); Thu, 26 Mar 2020 17:09:51 -0400 Received: from localhost (p54B3331F.dip0.t-ipconnect.de [84.179.51.31]) by pokefinder.org (Postfix) with ESMTPSA id 04E232C1F89; Thu, 26 Mar 2020 22:09:49 +0100 (CET) From: Wolfram Sang To: linux-i2c@vger.kernel.org Cc: Wolfram Sang , Jonathan Corbet , Mauro Carvalho Chehab , linux-media@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/6] media: marvell-ccic: convert to use i2c_new_client_device() Date: Thu, 26 Mar 2020 22:09:43 +0100 Message-Id: <20200326210947.12747-4-wsa+renesas@sang-engineering.com> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20200326210947.12747-1-wsa+renesas@sang-engineering.com> References: <20200326210947.12747-1-wsa+renesas@sang-engineering.com> MIME-Version: 1.0 Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Move away from the deprecated API and return the shiny new ERRPTR where useful. Signed-off-by: Wolfram Sang --- drivers/media/platform/marvell-ccic/cafe-driver.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/media/platform/marvell-ccic/cafe-driver.c b/drivers/media/platform/marvell-ccic/cafe-driver.c index 37fdcc53a1c4..9a09a10a3631 100644 --- a/drivers/media/platform/marvell-ccic/cafe-driver.c +++ b/drivers/media/platform/marvell-ccic/cafe-driver.c @@ -556,7 +556,7 @@ static int cafe_pci_probe(struct pci_dev *pdev, clkdev_create(mcam->mclk, "xclk", "%d-%04x", i2c_adapter_id(cam->i2c_adapter), ov7670_info.addr); - if (i2c_new_device(cam->i2c_adapter, &ov7670_info)) { + if (!IS_ERR(i2c_new_client_device(cam->i2c_adapter, &ov7670_info))) { cam->registered = 1; return 0; }