From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8B2537C for ; Mon, 23 Jan 2023 18:36:18 +0000 (UTC) X-IronPort-AV: E=McAfee;i="6500,9779,10599"; a="305777600" X-IronPort-AV: E=Sophos;i="5.97,240,1669104000"; d="scan'208";a="305777600" Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga106.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 Jan 2023 10:36:17 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10599"; a="990569441" X-IronPort-AV: E=Sophos;i="5.97,240,1669104000"; d="scan'208";a="990569441" Received: from smile.fi.intel.com ([10.237.72.54]) by fmsmga005.fm.intel.com with ESMTP; 23 Jan 2023 10:36:15 -0800 Received: from andy by smile.fi.intel.com with local (Exim 4.96) (envelope-from ) id 1pK1fx-00DsLb-1Y; Mon, 23 Jan 2023 20:36:13 +0200 Date: Mon, 23 Jan 2023 20:36:13 +0200 From: Andy Shevchenko To: Hans de Goede Cc: Mauro Carvalho Chehab , Sakari Ailus , Tsuchiya Yuto , Yury Luneff , Nable , andrey.i.trufanov@gmail.com, Fabio Aiuto , linux-media@vger.kernel.org, linux-staging@lists.linux.dev Subject: Re: [PATCH 51/57] media: atomisp: ov2722: Call atomisp_gmin_remove_subdev() on probe failure Message-ID: References: <20230123125205.622152-1-hdegoede@redhat.com> <20230123125205.622152-52-hdegoede@redhat.com> Precedence: bulk X-Mailing-List: linux-staging@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20230123125205.622152-52-hdegoede@redhat.com> Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo On Mon, Jan 23, 2023 at 01:51:59PM +0100, Hans de Goede wrote: > Call atomisp_gmin_remove_subdev() on probe failure to properly free > the GPIOs and other resources acquired by the gmin_camera_platform_data() > call earlier. Fixes? Reviewed-by: Andy Shevchenko > Signed-off-by: Hans de Goede > --- > drivers/staging/media/atomisp/i2c/atomisp-ov2722.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c > index d819ab5de28a..d874e12da8cc 100644 > --- a/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c > +++ b/drivers/staging/media/atomisp/i2c/atomisp-ov2722.c > @@ -994,6 +994,7 @@ static int ov2722_probe(struct i2c_client *client) > v4l2_ctrl_handler_free(&dev->ctrl_handler); > > out_free: > + atomisp_gmin_remove_subdev(&dev->sd); > v4l2_device_unregister_subdev(&dev->sd); > kfree(dev); > return ret; > -- > 2.39.0 > -- With Best Regards, Andy Shevchenko