int __init board_bcm59xx_init(void)
{
	int             ret = 0;
	int             irq;

	bcmpmu_reg_init();

	rgltr_init();
	adc_init();
	bcmpmu_set_pullup_reg();
	ret = gpio_request(PMU_DEVICE_INT_GPIO, "bcmpmu59xxx-irq");
	if (ret < 0) {
		printk(KERN_ERR "<%s> failed at gpio_request\n", __func__);
		goto exit;
	}
	ret = gpio_direction_input(PMU_DEVICE_INT_GPIO);
	if (ret < 0) {

		printk(KERN_ERR "%s filed at gpio_direction_input.\n",
				__func__);
		goto exit;
	}
	irq = gpio_to_irq(PMU_DEVICE_INT_GPIO);
	bcmpmu_i2c_pdata.irq = irq;
	ret  = i2c_register_board_info(PMU_DEVICE_I2C_BUSNO,
			bcmpmu_i2c_info, ARRAY_SIZE(bcmpmu_i2c_info));
	return 0;
exit:
	return ret;
}
int __init board_bcm59xx_init(void)
{
    int             ret = 0;
    int             irq;

    bcmpmu_set_pullup_reg();
    ret = gpio_request(PMU_DEVICE_INT_GPIO, "bcmpmu59xxx-irq");
    if (ret < 0) {
        pr_err("<%s> failed at gpio_request\n", __func__);
        goto exit;
    }
    ret = gpio_direction_input(PMU_DEVICE_INT_GPIO);
    if (ret < 0) {

        pr_err("%s filed at gpio_direction_input.\n",
               __func__);
        goto exit;
    }
    irq = gpio_to_irq(PMU_DEVICE_INT_GPIO);
    bcmpmu_i2c_pdata.irq = irq;
    ret  = i2c_register_board_info(PMU_DEVICE_I2C_BUSNO,
                                   bcmpmu_i2c_info, ARRAY_SIZE(bcmpmu_i2c_info));
#ifdef CONFIG_CHARGER_BCMPMU_SPA
    platform_add_devices(spa_devices, ARRAY_SIZE(spa_devices));
#endif
    return 0;
exit:
    return ret;
}
int __init board_bcm59xx_init(void)
{
	int             ret = 0;
	int             irq;

	bcmpmu_set_pullup_reg();
	ret = gpio_request(PMU_DEVICE_INT_GPIO, "bcmpmu59xxx-irq");
	if (ret < 0) {
		printk(KERN_ERR "<%s> failed at gpio_request\n", __func__);
		goto exit;
	}
	ret = gpio_direction_input(PMU_DEVICE_INT_GPIO);
	if (ret < 0) {

		printk(KERN_ERR "%s filed at gpio_direction_input.\n",
				__func__);
		goto exit;
	}
	irq = gpio_to_irq(PMU_DEVICE_INT_GPIO);
	bcmpmu_i2c_pdata.irq = irq;
	ret  = i2c_register_board_info(PMU_DEVICE_I2C_BUSNO,
			bcmpmu_i2c_info, ARRAY_SIZE(bcmpmu_i2c_info));
#if defined(CONFIG_SEC_CHARGING_FEATURE)
	platform_add_devices(spa_devices, ARRAY_SIZE(spa_devices));
#endif
/* Workaround for VDDFIX leakage during deepsleep.
   Will be fixed in Java A1 revision */
	if (is_pm_erratum(ERRATUM_VDDFIX_LEAKAGE))
		bcm59xxx_csr_data.constraints.initial_mode =
			REGULATOR_MODE_IDLE;
	return 0;
exit:
	return ret;
}