Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 76e744c3 authored by Jeyaprakash Soundrapandian's avatar Jeyaprakash Soundrapandian Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: camera: sensor: Assign power settings pointer to null" into dev/msm-4.9-camx

parents 699626fe 663eb951
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -53,6 +53,7 @@ int32_t cam_actuator_construct_default_power_setting(

free_power_settings:
	kfree(power_info->power_setting);
	power_info->power_setting = NULL;
	return rc;
}

+5 −1
Original line number Diff line number Diff line
/* Copyright (c) 2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -252,6 +252,8 @@ static int32_t cam_actuator_platform_remove(struct platform_device *pdev)
	a_ctrl->io_master_info.cci_client = NULL;
	kfree(power_info->power_setting);
	kfree(power_info->power_down_setting);
	power_info->power_setting = NULL;
	power_info->power_down_setting = NULL;
	kfree(a_ctrl->soc_info.soc_private);
	kfree(a_ctrl->i2c_data.per_frame);
	a_ctrl->i2c_data.per_frame = NULL;
@@ -284,6 +286,8 @@ static int32_t cam_actuator_driver_i2c_remove(struct i2c_client *client)
	kfree(power_info->power_setting);
	kfree(power_info->power_down_setting);
	kfree(a_ctrl->soc_info.soc_private);
	power_info->power_setting = NULL;
	power_info->power_down_setting = NULL;
	a_ctrl->soc_info.soc_private = NULL;
	kfree(a_ctrl);
	return rc;
+1 −0
Original line number Diff line number Diff line
@@ -55,6 +55,7 @@ int32_t cam_ois_construct_default_power_setting(

free_power_settings:
	kfree(power_info->power_setting);
	power_info->power_setting = NULL;
	return rc;
}

+5 −1
Original line number Diff line number Diff line
/* Copyright (c) 2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2017-2018, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -240,6 +240,8 @@ static int cam_ois_i2c_driver_remove(struct i2c_client *client)

	kfree(power_info->power_setting);
	kfree(power_info->power_down_setting);
	power_info->power_setting = NULL;
	power_info->power_down_setting = NULL;
	kfree(o_ctrl->soc_info.soc_private);
	kfree(o_ctrl);

@@ -341,6 +343,8 @@ static int cam_ois_platform_driver_remove(struct platform_device *pdev)

	kfree(power_info->power_setting);
	kfree(power_info->power_down_setting);
	power_info->power_setting = NULL;
	power_info->power_down_setting = NULL;
	kfree(o_ctrl->soc_info.soc_private);
	kfree(o_ctrl->io_master_info.cci_client);
	kfree(o_ctrl);