@@ -2303,29 +2303,21 @@ dsl_dir_activity_in_progress(dsl_dir_t *dd, dsl_dataset_t *ds,
2303
2303
2304
2304
switch (activity ) {
2305
2305
case ZFS_WAIT_DELETEQ : {
2306
+ #ifdef _KERNEL
2306
2307
objset_t * os ;
2307
2308
error = dmu_objset_from_ds (ds , & os );
2308
2309
if (error != 0 )
2309
2310
break ;
2310
2311
2311
- #ifdef _KERNEL
2312
2312
if (dmu_objset_type (os ) != DMU_OST_ZFS ||
2313
2313
zfs_get_vfs_flag_unmounted (os )) {
2314
2314
* in_progress = B_FALSE ;
2315
2315
return (0 );
2316
2316
}
2317
- #else
2318
- if (dmu_objset_type (os ) != DMU_OST_ZFS ) {
2319
- * in_progress = B_FALSE ;
2320
- return (0 );
2321
- }
2322
- #endif
2323
2317
2324
2318
uint64_t readonly = B_FALSE ;
2325
- dsl_pool_config_enter (dd -> dd_pool , FTAG );
2326
- error = dsl_prop_get_dd (dd , zfs_prop_to_name (ZFS_PROP_READONLY ),
2327
- sizeof (readonly ), 1 , & readonly , NULL , B_FALSE );
2328
- dsl_pool_config_exit (dd -> dd_pool , FTAG );
2319
+ error = zfs_get_temporary_prop (ds , ZFS_PROP_READONLY , & readonly ,
2320
+ NULL );
2329
2321
2330
2322
if (error != 0 )
2331
2323
break ;
@@ -2347,6 +2339,14 @@ dsl_dir_activity_in_progress(dsl_dir_t *dd, dsl_dataset_t *ds,
2347
2339
if (error == 0 )
2348
2340
* in_progress = (count != 0 );
2349
2341
break ;
2342
+ #else
2343
+ /*
2344
+ * The delete queue is ZPL specific, and libzpool doesn't have
2345
+ * it. It doesn't make sense to wait for it.
2346
+ */
2347
+ * in_progress = B_FALSE ;
2348
+ break ;
2349
+ #endif
2350
2350
}
2351
2351
default :
2352
2352
panic ("unrecognized value for activity %d" , activity );
0 commit comments