/* Returns 0 on success or error code from kernel_thread()  */
int zfcp_erp_thread_setup(struct zfcp_adapter *adapter)
/* Returns 0 on success or error code from kernel_thread()  */
int zfcp_erp_thread_setup(struct zfcp_adapter *adapter)
{
	struct task_struct *thread;
	thread = kthread_run(zfcp_erp_thread, adapter, "zfcperp%s",
			     dev_name(&adapter->ccw_device->dev));
	if (IS_ERR(thread)) {
		dev_err(&adapter->ccw_device->dev,
			"Creating an ERP thread for the FCP device failed.\n");
		return PTR_ERR(thread);
	}
	adapter->erp_thread = thread;
	return 0;
}