static int __init mtk_cooler_shutdown_init(void)
{
	int err = 0;
	int i;

	for (i = MAX_NUM_INSTANCE_MTK_COOLER_SHUTDOWN; i-- > 0;) {
		cl_shutdown_dev[i] = NULL;
		cl_sd_state[i].state = 0;
		cl_sd_state[i].sd_cnt = 0;
	}

	mtk_cooler_shutdown_dprintk("init\n");

#if defined(MTK_COOLER_SHUTDOWN_SIGNAL)
	{
		struct proc_dir_entry *entry = NULL;
		struct proc_dir_entry *dir_entry = mtk_thermal_get_proc_drv_therm_dir_entry();

		if (!dir_entry) {
			mtk_cooler_shutdown_dprintk("%s mkdir /proc/driver/thermal failed\n",
						    __func__);
			return 0;
		}

		entry =
		    proc_create("clsd_pid", S_IRUGO | S_IWUSR | S_IWGRP, dir_entry,
				&_cl_sd_pid_fops);
		if (!entry)
			mtk_cooler_shutdown_dprintk("%s clsd_pid creation failed\n", __func__);
		else
			proc_set_user(entry, uid, gid);

		entry =
		    proc_create("clsd_rst", S_IRUGO | S_IWUSR | S_IWGRP, dir_entry,
				&_cl_sd_rst_fops);
		if (!entry)
			mtk_cooler_shutdown_dprintk("%s clsd_rst creation failed\n", __func__);
		else
			proc_set_user(entry, uid, gid);

		entry =
		    proc_create("clsd_dbt", S_IRUGO | S_IWUSR | S_IWGRP, dir_entry,
				&_cl_sd_debouncet_fops);
		if (!entry)
			mtk_cooler_shutdown_dprintk("%s clsd_dbt creation failed\n", __func__);
		else
			proc_set_user(entry, uid, gid);
	}
#endif

	err = mtk_cooler_shutdown_register_ltf();
	if (err)
		goto err_unreg;

	return 0;

err_unreg:
	mtk_cooler_shutdown_unregister_ltf();
	return err;
}
static int __init mtk_cooler_shutdown_init(void)
{
  int err = 0;
  int i;

  for (i = MAX_NUM_INSTANCE_MTK_COOLER_SHUTDOWN; i-- > 0; )
  {
    cl_shutdown_dev[i] = NULL;
    cl_shutdown_state[i] = 0;
  }

  //cl_shutdown_dev = NULL;

  mtk_cooler_shutdown_dprintk("init\n");

  err = mtk_cooler_shutdown_register_ltf();
  if (err)
    goto err_unreg;

  return 0;

err_unreg:
  mtk_cooler_shutdown_unregister_ltf();
  return err;
}
static void __exit mtk_cooler_shutdown_exit(void)
{
	mtk_cooler_shutdown_dprintk("exit\n");
	mtk_cooler_shutdown_unregister_ltf();
}
static int __init mtk_cooler_shutdown_init(void)
{
    int err = 0;
    int i;
    
    for (i = MAX_NUM_INSTANCE_MTK_COOLER_SHUTDOWN; i-- > 0; )
    {
        cl_shutdown_dev[i] = NULL;
        cl_shutdown_state[i] = 0;
    }

    mtk_cooler_shutdown_dprintk("init\n");
  
#if defined(MTK_COOLER_SHUTDOWN_SIGNAL)
    {
        struct proc_dir_entry *entry;

#if 0
        entry = create_proc_entry("driver/mtk_cl_sd_pid", S_IRUGO | S_IWUSR, NULL);
        if (NULL != entry)
        {
            entry->read_proc = _mtk_cl_sd_pid_read;
            entry->write_proc = _mtk_cl_sd_pid_write;
        }
#endif

        entry = proc_create("driver/mtk_cl_sd_pid", S_IRUGO | S_IWUSR | S_IWGRP, NULL, &_cl_sd_pid_fops);
        if (!entry)
        {
            xlog_printk(ANDROID_LOG_DEBUG, "thermal/cooler/shutdown", "mtk_cooler_shutdown_init driver/mtk_cl_sd_pid creation failed\n");
        }
        else
        {
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
            proc_set_user(entry, 0, 1000);
#else
            entry->gid = 1000;
#endif
        }
    }
    
    {
        struct proc_dir_entry *entry;

#if 0
        entry = create_proc_entry("driver/mtk_cl_sd_rst", S_IRUGO | S_IWUSR | S_IWGRP, NULL);
        if (NULL != entry)
        {
            entry->write_proc = _mtk_cl_sd_rst_write;
            entry->gid = 1000;
        }
#endif
        entry = proc_create("driver/mtk_cl_sd_rst", S_IRUGO | S_IWUSR | S_IWGRP, NULL, &_cl_sd_rst_fops);
        if (!entry)
        {
            xlog_printk(ANDROID_LOG_DEBUG, "thermal/cooler/shutdown", "mtk_cooler_shutdown_init driver/mtk_cl_sd_rst creation failed\n");
        }
        else
        {
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
            proc_set_user(entry, 0, 1000);
#else
            entry->gid = 1000;
#endif
        }
    }

    {
        struct proc_dir_entry *entry;

        entry = proc_create("driver/mtk_cl_sd_dbt", S_IRUGO | S_IWUSR | S_IWGRP, NULL, &_cl_sd_debouncet_fops);
        if (!entry)
        {
            xlog_printk(ANDROID_LOG_DEBUG, "thermal/cooler/shutdown", "mtk_cooler_shutdown_init driver/mtk_cl_sd_dbt creation failed\n");
        }
        else
        {
#if LINUX_VERSION_CODE >= KERNEL_VERSION(3, 10, 0)
            proc_set_user(entry, 0, 1000);
#else
            entry->gid = 1000;
#endif
        }
    }
#endif

    err = mtk_cooler_shutdown_register_ltf();
    if (err)
        goto err_unreg;

    return 0;

err_unreg:
    mtk_cooler_shutdown_unregister_ltf();
    return err;
}