Re: [PATCH v1 05/10] staging: atomisp: Remove non-ACPI leftovers

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Dec 19, 2017 at 10:59:52PM +0200, Andy Shevchenko wrote:
> @@ -1147,10 +1145,8 @@ static int gc2235_probe(struct i2c_client *client)
>  	if (ret)
>  		gc2235_remove(client);

This error handling is probably wrong...

>  
> -	if (ACPI_HANDLE(&client->dev))
> -		ret = atomisp_register_i2c_module(&dev->sd, gcpdev, RAW_CAMERA);
> +	return atomisp_register_i2c_module(&dev->sd, gcpdev, RAW_CAMERA);

In the end this should look something like:

	ret = atomisp_register_i2c_module(&dev->sd, gcpdev, RAW_CAMERA);
	if (ret)
		goto err_free_something;

	return 0;

>  
> -	return ret;
>  out_free:
>  	v4l2_device_unregister_subdev(&dev->sd);
>  	kfree(dev);

regards,
dan carpenter




[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux