int
    imx278_carrera_power_down(
    hwsensor_intf_t* si)
{
    int ret = 0;
    sensor_t* sensor = NULL;
    sensor = I2S(si);
    ret = hw_sensor_power_down(sensor);
    return ret;
}
int
ov8865_rear_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	sensor_t* sensor = NULL;
	sensor = I2S(si);
	ret = hw_sensor_power_down(sensor);
	return ret;
}
int
imx179_front_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	sensor_t* sensor = NULL;
	sensor = I2S(si);
	ret = hw_sensor_power_down(sensor);
	return ret;
}
int
imx214_sunny_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	sensor_t* sensor = NULL;
	sensor = I2S(si);
	ret = hw_sensor_power_down(sensor);
	return ret;
}
int
imx328_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	sensor_t* sensor = NULL;
	cam_info("%s enter. called by %pF", __func__, __builtin_return_address(0));

	sensor = I2S(si);
	ret = hw_sensor_power_down(sensor);
	return ret;
}
int
    ov8865_carrera_power_down(
    hwsensor_intf_t* si)
{
    int ret = 0;
    sensor_t* sensor = NULL;
    sensor = I2S(si);
    if(is_poweron) {
        ret = hw_sensor_power_down(sensor);
        cam_notice("---ov8865_carrera power off!---");
        is_poweron = false;
    } else {
        cam_notice("---not power off---");
    }
    return ret;
}
int
ar1335_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	int i, num_consumers;
	sensor_t* sensor = NULL;
	struct regulator_bulk_data *consumers;

	sensor = I2S(si);
	ret = hw_sensor_power_down(sensor);

	consumers = sensor->board_info->ldo;
	num_consumers = sensor->board_info->ldo_num;
	for (i = 0; i < num_consumers && consumers[i].consumer; i++)
	{
		devm_regulator_put(consumers[i].consumer);
		consumers[i].consumer = NULL;
	}
	return ret;
}
int
imx278_power_down(
        hwsensor_intf_t* si)
{
	int ret = 0;
	sensor_t* sensor = NULL;
	sensor = I2S(si);
	cam_info("enter %s. index = %d name = %s", __func__, sensor->board_info->sensor_index, sensor->board_info->name);
	if (hw_is_fpga_board()) {
		ret = do_sensor_power_off(sensor->board_info->sensor_index, sensor->board_info->name);
	} else {
		ret = hw_sensor_power_down(sensor);
	}
    if (0 == ret )
    {
        cam_info("%s. power down sensor success.", __func__);
    }
    else
    {
        cam_err("%s. power down sensor fail.", __func__);
    }
	return ret;
}