File tree Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Expand file tree Collapse file tree 1 file changed +4
-6
lines changed Original file line number Diff line number Diff line change @@ -1151,9 +1151,6 @@ struct io_wq *io_wq_create(unsigned bounded, struct io_wq_data *data)
1151
1151
wq = kzalloc (sizeof (struct io_wq ), GFP_KERNEL );
1152
1152
if (!wq )
1153
1153
return ERR_PTR (- ENOMEM );
1154
- ret = cpuhp_state_add_instance_nocalls (io_wq_online , & wq -> cpuhp_node );
1155
- if (ret )
1156
- goto err_wq ;
1157
1154
1158
1155
refcount_inc (& data -> hash -> refs );
1159
1156
wq -> hash = data -> hash ;
@@ -1186,13 +1183,14 @@ struct io_wq *io_wq_create(unsigned bounded, struct io_wq_data *data)
1186
1183
wq -> task = get_task_struct (data -> task );
1187
1184
atomic_set (& wq -> worker_refs , 1 );
1188
1185
init_completion (& wq -> worker_done );
1186
+ ret = cpuhp_state_add_instance_nocalls (io_wq_online , & wq -> cpuhp_node );
1187
+ if (ret )
1188
+ goto err ;
1189
+
1189
1190
return wq ;
1190
1191
err :
1191
1192
io_wq_put_hash (data -> hash );
1192
- cpuhp_state_remove_instance_nocalls (io_wq_online , & wq -> cpuhp_node );
1193
-
1194
1193
free_cpumask_var (wq -> cpu_mask );
1195
- err_wq :
1196
1194
kfree (wq );
1197
1195
return ERR_PTR (ret );
1198
1196
}
You can’t perform that action at this time.
0 commit comments