Lines Matching refs:devs

285 	if (sbi->devs->extra_devices &&  in erofs_scan_devices()
286 ondisk_extradevs != sbi->devs->extra_devices) { in erofs_scan_devices()
288 ondisk_extradevs, sbi->devs->extra_devices); in erofs_scan_devices()
296 down_read(&sbi->devs->rwsem); in erofs_scan_devices()
297 if (sbi->devs->extra_devices) { in erofs_scan_devices()
298 idr_for_each_entry(&sbi->devs->tree, dif, id) { in erofs_scan_devices()
311 err = idr_alloc(&sbi->devs->tree, dif, 0, 0, GFP_KERNEL); in erofs_scan_devices()
316 ++sbi->devs->extra_devices; in erofs_scan_devices()
323 up_read(&sbi->devs->rwsem); in erofs_scan_devices()
570 down_write(&ctx->devs->rwsem); in erofs_fc_parse_param()
571 ret = idr_alloc(&ctx->devs->tree, dif, 0, 0, GFP_KERNEL); in erofs_fc_parse_param()
572 up_write(&ctx->devs->rwsem); in erofs_fc_parse_param()
578 ++ctx->devs->extra_devices; in erofs_fc_parse_param()
731 sbi->devs = ctx->devs; in erofs_fc_fill_super()
732 ctx->devs = NULL; in erofs_fc_fill_super()
867 static void erofs_free_dev_context(struct erofs_dev_context *devs) in erofs_free_dev_context() argument
869 if (!devs) in erofs_free_dev_context()
871 idr_for_each(&devs->tree, &erofs_release_device_info, NULL); in erofs_free_dev_context()
872 idr_destroy(&devs->tree); in erofs_free_dev_context()
873 kfree(devs); in erofs_free_dev_context()
880 erofs_free_dev_context(ctx->devs); in erofs_fc_free()
910 ctx->devs = kzalloc(sizeof(struct erofs_dev_context), GFP_KERNEL); in erofs_init_fs_context()
911 if (!ctx->devs) { in erofs_init_fs_context()
917 idr_init(&ctx->devs->tree); in erofs_init_fs_context()
918 init_rwsem(&ctx->devs->rwsem); in erofs_init_fs_context()
949 erofs_free_dev_context(sbi->devs); in erofs_kill_sb()