示例#1
0
static void __exit mmc_exit(void)
{
	sdio_unregister_bus();
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
}
示例#2
0
static int __init mmc_init(void)
{
	int ret;

	workqueue = create_singlethread_workqueue("kmmcd");
	if (!workqueue)
		return -ENOMEM;

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;

	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);

	return ret;
}
示例#3
0
static int __init mmc_init(void)
{
	int ret;

	wake_lock_init(&mmc_delayed_work_wake_lock, WAKE_LOCK_SUSPEND, "mmc_delayed_work");

	workqueue = create_freezeable_workqueue("kmmcd");
	if (!workqueue)
		return -ENOMEM;

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;

	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);

	return ret;
}
示例#4
0
static void __exit mmc_exit(void)
{
	sdio_unregister_bus();
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
	wake_lock_destroy(&mmc_delayed_work_wake_lock);
}
示例#5
0
static void __exit mmc_exit(void)
{
#ifdef UCONFIG_DDE_MMC_HAVE_SDIO
	sdio_unregister_bus();
#endif
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
	wake_lock_destroy(&mmc_delayed_work_wake_lock);
}
示例#6
0
static void __exit mmc_exit(void)
{
	DBG("[%s] s\n",__func__);
	sdio_unregister_bus();
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
	wake_lock_destroy(&mmc_delayed_work_wake_lock);
	DBG("[%s] e\n",__func__);
}
示例#7
0
static void __exit mmc_exit(void)
{
	sdio_unregister_bus();
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
	#if 0 //Robert, 20101006, KB62_CR766 : Fix unexpectedly remove SD card issue
	wake_lock_destroy(&mmc_delayed_work_wake_lock);
	#endif
}
示例#8
0
static void __exit mmc_exit(void)
{
	sdio_unregister_bus();
	mmc_unregister_host_class();
	mmc_unregister_bus();
	destroy_workqueue(workqueue);
	wake_lock_destroy(&mmc_delayed_work_wake_lock);

	/* FIH, BillHJChang, 2009/11/20 { */
	/* [FXX_CR], issue of card detect fail in suspend mode */
	#ifdef CONFIG_FIH_FXX
	wake_lock_destroy(&sdcard_idle_wake_lock); 
	#endif
	/* } FIH, BillHJChang, 2009/11/20 */	
}
示例#9
0
static int __init mmc_init(void)
{
	int ret;

	wake_lock_init(&mmc_delayed_work_wake_lock, WAKE_LOCK_SUSPEND, "mmc_delayed_work");

    /* FIH, BillHJChang, 2009/11/20 { */
	/* [FXX_CR], issue of card detect fail in suspend mode */
	#ifdef CONFIG_FIH_FXX
	wake_lock_init(&sdcard_idle_wake_lock, WAKE_LOCK_IDLE, "sd_suspend_work");	
	#endif
	/* } FIH, BillHJChang, 2009/11/20 */

    /* FIH, SimonSSChang, 2010/08/25 { */
    /* avoid WIFI firmware reload fail when to do kernel resume */
    #ifdef CONFIG_FIH_FXX
	workqueue = create_singlethread_workqueue("kmmcd");
    #else
	workqueue = create_freezeable_workqueue("kmmcd");    
    #endif
    /* } FIH, SimonSSChang, 2010/08/25 */
	if (!workqueue)
		return -ENOMEM;

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;

	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);

	return ret;
}
示例#10
0
static int __init mmc_init(void)
{
	int ret;
	DBG("[%s] s\n",__func__);
	wake_lock_init(&mmc_delayed_work_wake_lock, WAKE_LOCK_SUSPEND, "mmc_delayed_work");

	workqueue = create_singlethread_workqueue("kmmcd");
	if (!workqueue) {
		DBG("[%s] e1\n",__func__);
		return -ENOMEM;
	}

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;

	DBG("[%s] e2\n",__func__);
	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);
	
	DBG("[%s] e3\n",__func__);
	return ret;
}
示例#11
0
static int __init mmc_init(void)
{
	int ret;
  pr_debug("mmc_init() start...\n");

	wake_lock_init(&mmc_delayed_work_wake_lock, WAKE_LOCK_SUSPEND, "mmc_delayed_work");

	workqueue = create_singlethread_workqueue("kmmcd");
	if (!workqueue)
		return -ENOMEM;

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

#ifdef UCONFIG_DDE_MMC_HAVE_SDIO
	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;
#endif

	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);

	return ret;
}
示例#12
0
static int __init mmc_init(void)
{
	int ret;
	//B: Robert, 20101006, KB62_CR766 : Fix unexpectedly remove SD card issue
	#if 0
	wake_lock_init(&mmc_delayed_work_wake_lock, WAKE_LOCK_SUSPEND, "mmc_delayed_work");
	#endif
	workqueue = create_singlethread_workqueue("kmmcd");
	//E: Robert, 20101006, KB62_CR766

	if (!workqueue)
		return -ENOMEM;

	ret = mmc_register_bus();
	if (ret)
		goto destroy_workqueue;

	ret = mmc_register_host_class();
	if (ret)
		goto unregister_bus;

	ret = sdio_register_bus();
	if (ret)
		goto unregister_host_class;

	return 0;

unregister_host_class:
	mmc_unregister_host_class();
unregister_bus:
	mmc_unregister_bus();
destroy_workqueue:
	destroy_workqueue(workqueue);

	return ret;
}