@@ -469,9 +469,6 @@ int __init z_erofs_init_zip_subsystem(void);
469469void z_erofs_exit_zip_subsystem (void );
470470int erofs_try_to_free_all_cached_pages (struct erofs_sb_info * sbi ,
471471 struct erofs_workgroup * egrp );
472- int z_erofs_load_lz4_config (struct super_block * sb ,
473- struct erofs_super_block * dsb ,
474- struct z_erofs_lz4_cfgs * lz4 , int len );
475472int z_erofs_map_blocks_iter (struct inode * inode , struct erofs_map_blocks * map ,
476473 int flags );
477474void * erofs_get_pcpubuf (unsigned int requiredpages );
@@ -480,23 +477,14 @@ int erofs_pcpubuf_growsize(unsigned int nrpages);
480477void __init erofs_pcpubuf_init (void );
481478void erofs_pcpubuf_exit (void );
482479int erofs_init_managed_cache (struct super_block * sb );
480+ int z_erofs_parse_cfgs (struct super_block * sb , struct erofs_super_block * dsb );
483481#else
484482static inline void erofs_shrinker_register (struct super_block * sb ) {}
485483static inline void erofs_shrinker_unregister (struct super_block * sb ) {}
486484static inline int erofs_init_shrinker (void ) { return 0 ; }
487485static inline void erofs_exit_shrinker (void ) {}
488486static inline int z_erofs_init_zip_subsystem (void ) { return 0 ; }
489487static inline void z_erofs_exit_zip_subsystem (void ) {}
490- static inline int z_erofs_load_lz4_config (struct super_block * sb ,
491- struct erofs_super_block * dsb ,
492- struct z_erofs_lz4_cfgs * lz4 , int len )
493- {
494- if (lz4 || dsb -> u1 .lz4_max_distance ) {
495- erofs_err (sb , "lz4 algorithm isn't enabled" );
496- return - EINVAL ;
497- }
498- return 0 ;
499- }
500488static inline void erofs_pcpubuf_init (void ) {}
501489static inline void erofs_pcpubuf_exit (void ) {}
502490static inline int erofs_init_managed_cache (struct super_block * sb ) { return 0 ; }
@@ -505,41 +493,17 @@ static inline int erofs_init_managed_cache(struct super_block *sb) { return 0; }
505493#ifdef CONFIG_EROFS_FS_ZIP_LZMA
506494int __init z_erofs_lzma_init (void );
507495void z_erofs_lzma_exit (void );
508- int z_erofs_load_lzma_config (struct super_block * sb ,
509- struct erofs_super_block * dsb ,
510- struct z_erofs_lzma_cfgs * lzma , int size );
511496#else
512497static inline int z_erofs_lzma_init (void ) { return 0 ; }
513498static inline int z_erofs_lzma_exit (void ) { return 0 ; }
514- static inline int z_erofs_load_lzma_config (struct super_block * sb ,
515- struct erofs_super_block * dsb ,
516- struct z_erofs_lzma_cfgs * lzma , int size ) {
517- if (lzma ) {
518- erofs_err (sb , "lzma algorithm isn't enabled" );
519- return - EINVAL ;
520- }
521- return 0 ;
522- }
523499#endif /* !CONFIG_EROFS_FS_ZIP_LZMA */
524500
525501#ifdef CONFIG_EROFS_FS_ZIP_DEFLATE
526502int __init z_erofs_deflate_init (void );
527503void z_erofs_deflate_exit (void );
528- int z_erofs_load_deflate_config (struct super_block * sb ,
529- struct erofs_super_block * dsb ,
530- struct z_erofs_deflate_cfgs * dfl , int size );
531504#else
532505static inline int z_erofs_deflate_init (void ) { return 0 ; }
533506static inline int z_erofs_deflate_exit (void ) { return 0 ; }
534- static inline int z_erofs_load_deflate_config (struct super_block * sb ,
535- struct erofs_super_block * dsb ,
536- struct z_erofs_deflate_cfgs * dfl , int size ) {
537- if (dfl ) {
538- erofs_err (sb , "deflate algorithm isn't enabled" );
539- return - EINVAL ;
540- }
541- return 0 ;
542- }
543507#endif /* !CONFIG_EROFS_FS_ZIP_DEFLATE */
544508
545509#ifdef CONFIG_EROFS_FS_ONDEMAND
0 commit comments