예제 #1
0
void __init evt_peripherals_init(void)
{
//&*&*&*SJ1_20110419, Add /proc file to display software and hardware version.
#if defined (CONFIG_PROCFS_DISPLAY_SW_HW_VERSION)
	get_share_region();	
#endif
//&*&*&*SJ2_20110419, Add /proc file to display software and hardware version.

//&*&*&*BC1_110615: fix the issue that system can not enter off mode
	twl4030_get_scripts(&evt_t2scripts_data);
//&*&*&*BC2_110615: fix the issue that system can not enter off mode

    
#ifdef CONFIG_ANDROID_RAM_CONSOLE
    platform_device_register(&ram_console_device);
#endif
    
    omap_i2c_init();
    platform_add_devices( evt_board_devices, ARRAY_SIZE(evt_board_devices) );
    platform_add_devices( evt_board_devices_2, ARRAY_SIZE(evt_board_devices_2) );
    
#ifdef CONFIG_ENCORE_MODEM_MGR
    if (is_encore_3g()) {
        platform_device_register(&encore_modem_mgr_device);
    }
#endif 

#ifdef CONFIG_SND_SOC_TLV320DAC3100
    audio_dac_3100_dev_init();
#endif
/***++++20110115, jimmySu add backlight driver for PWM***/
#ifdef CONFIG_LEDS_OMAP_DISPLAY
	gptimer8 = (unsigned long)ioremap(0x4903E000, 16);
//&*&*&*HC1_20110826, modify pwm init sequence
	//zoom_pwm_init();
	omap_set_primary_brightness(100);
//&*&*&*HC2_20110826, modify pwm init sequence
#endif // CONFIG_LEDS_OMAP_DISPLAY
/***-----20110115, jimmySu add backlight driver for PWM***/


    /* NOTE: Please deselect CONFIG_MACH_OMAP_USE_UART3 in order to init 
    *  only UART1 and UART2, all in the name of saving some power.
    */
    omap_serial_init(omap_serial_platform_data);
    evt_lcd_panel_init();
//    kxtf9_dev_init();

#ifdef CONFIG_BATTERY_MAX17042
    max17042_dev_init();
#endif

    usb_musb_init(&musb_board_data);

//&*&*&*SJ1_20110607
#if defined (CONFIG_ANDROID_FACTORY_DEFAULT_REBOOT)
	android_factory_default_init();
#endif
//&*&*&*SJ2_20110607
}
static int __init omap_i2c_init(void)
{
        twl4030_get_scripts(&hub_t2scripts_data);
	omap_register_i2c_bus(1, 400, NULL, hub_i2c_boardinfo,
			ARRAY_SIZE(hub_i2c_boardinfo));
	omap_register_i2c_bus(2, 400, NULL,hub_i2c_bus2_info,
			ARRAY_SIZE(hub_i2c_bus2_info));
	omap_register_i2c_bus(3, 400, NULL,hub_i2c_bus3_info, 
			ARRAY_SIZE(hub_i2c_bus3_info));// 20100624 [email protected], add the i2c3 platform device
	return 0;
}
void __init zoom_peripherals_init(void)
{
	twl4030_get_scripts(&zoom_t2scripts_data);
	omap_i2c_init();
	platform_add_devices(zoom_board_devices,
			ARRAY_SIZE(zoom_board_devices));
	synaptics_dev_init();
	omap_serial_init();
#if defined(CONFIG_MACH_OMAP_ZOOM3) || defined(CONFIG_MACH_OMAP_ZOOM2)
	zoom_lcd_tv_panel_init();
#endif
	usb_musb_init(&musb_board_data);
	enable_board_wakeup_source();
	zoom2_cam_init();
#ifdef CONFIG_PANEL_SIL9022
	config_hdmi_gpio();
	zoom_hdmi_reset_enable(1);
#endif
}
void __init omap_board_peripherals_init(void)
{
	printk("*******board_peripherals_init*****\n");
	twl4030_get_scripts(&latona_t2scripts_data);

	omap_i2c_init();

    platform_add_devices(board_devices, ARRAY_SIZE(board_devices));
       omap_board_usb_data.sensor_dev = &samsung_pl_sensor_power_device.dev;    // Add for regulator
       
	spi_register_board_info( board_spi_board_info, ARRAY_SIZE( board_spi_board_info ) );
       
	atmel_dev_init();
	omap_serial_init(omap_serial_platform_data);
	usb_musb_init(&musb_board_data);
	board_init_power_key();
	enable_board_wakeup_source();
	board_init_battery();
#ifdef CONFIG_INPUT_ZEUS_EAR_KEY
	board_init_ear_key();
#endif
}