Re: [PATCH RESEND v2] i2c-eg20t: support new device OKI SEMICONDUCTOR ML7213 IOH

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

 



On Mon, Feb 28, 2011 at 03:54:32PM +0900, Tomoya MORINAGA wrote:
> -	ret = i2c_add_adapter(&(adap_info->pch_data.pch_adapter));
> +		pch_adap->dev.parent = &pdev->dev;
>  
> -	if (ret) {
> -		pch_pci_err(pdev, "i2c_add_adapter FAILED\n");
> -		goto err_i2c_add_adapter;
> -	}
> +		ret = i2c_add_adapter(pch_adap);
> +		if (ret) {
> +			pch_pci_err(pdev, "i2c_add_adapter[ch:%d] FAILED\n", i);
> +			goto err_i2c_add_adapter;

I think goto err_request_irq was intended here.  On a side note, it's
always better to name goto destinations after the destination instead
of the starting point.  In this case, we have two gotos to one
destination and the label err_request_irq makes no sense.

regards,
dan carpenter

--
To unsubscribe from this list: send the line "unsubscribe linux-i2c" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux