pmt: initial 2.9.1 update

This commit is contained in:
2024-10-02 21:37:57 +03:00
parent 82bd2939cd
commit 7259d451c4
459 changed files with 86355 additions and 2404 deletions

View File

@@ -0,0 +1,57 @@
#ifndef _CREATE_INODE_H
#define _CREATE_INODE_H
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include "et/com_err.h"
#include "e2p/e2p.h"
#include "ext2fs/ext2fs.h"
struct hdlink_s
{
dev_t src_dev;
ino_t src_ino;
ext2_ino_t dst_ino;
};
struct hdlinks_s
{
int count;
int size;
struct hdlink_s *hdl;
};
#define HDLINK_CNT (4)
struct fs_ops_callbacks {
errcode_t (* create_new_inode)(ext2_filsys fs, const char *target_path,
const char *name, ext2_ino_t parent_ino, ext2_ino_t root,
mode_t mode);
errcode_t (* end_create_new_inode)(ext2_filsys fs,
const char *target_path, const char *name,
ext2_ino_t parent_ino, ext2_ino_t root, mode_t mode);
};
extern int no_copy_xattrs; /* this should eventually be a flag
passed to populate_fs3() */
/* For populating the filesystem */
extern errcode_t populate_fs(ext2_filsys fs, ext2_ino_t parent_ino,
const char *source_dir, ext2_ino_t root);
extern errcode_t populate_fs2(ext2_filsys fs, ext2_ino_t parent_ino,
const char *source_dir, ext2_ino_t root,
struct fs_ops_callbacks *fs_callbacks);
extern errcode_t do_mknod_internal(ext2_filsys fs, ext2_ino_t cwd,
const char *name, unsigned int st_mode,
unsigned int st_rdev);
extern errcode_t do_symlink_internal(ext2_filsys fs, ext2_ino_t cwd,
const char *name, char *target,
ext2_ino_t root);
extern errcode_t do_mkdir_internal(ext2_filsys fs, ext2_ino_t cwd,
const char *name, ext2_ino_t root);
extern errcode_t do_write_internal(ext2_filsys fs, ext2_ino_t cwd,
const char *src, const char *dest,
ext2_ino_t root);
#endif /* _CREATE_INODE_H */

30
include/e2fsprogs/misc/mke2fs.h Executable file
View File

@@ -0,0 +1,30 @@
/*
* mke2fs.h
*
* Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
* 2003, 2004, 2005 by Theodore Ts'o.
*
* %Begin-Header%
* This file may be redistributed under the terms of the GNU Public
* License.
* %End-Header%
*/
/* mke2fs.c */
extern const char * program_name;
extern int quiet;
extern int verbose;
extern int zero_hugefile;
extern char **fs_types;
extern char *get_string_from_profile(char **types, const char *opt,
const char *def_val);
extern int get_int_from_profile(char **types, const char *opt, int def_val);
extern int get_bool_from_profile(char **types, const char *opt, int def_val);
extern int int_log10(unsigned long long arg);
/* mk_hugefiles.c */
extern errcode_t mk_hugefiles(ext2_filsys fs, const char *device_name);

29
include/e2fsprogs/misc/util.h Executable file
View File

@@ -0,0 +1,29 @@
/*
* util.h --- header file defining prototypes for helper functions
* used by tune2fs and mke2fs
*
* Copyright 2000 by Theodore Ts'o.
*
* %Begin-Header%
* This file may be redistributed under the terms of the GNU Public
* License.
* %End-Header%
*/
extern int journal_size;
extern int journal_fc_size;
extern int journal_flags;
extern char *journal_device;
extern char *journal_location_string;
#ifndef HAVE_STRCASECMP
extern int strcasecmp (char *s1, char *s2);
#endif
extern char *get_progname(char *argv_zero);
extern void proceed_question(int delay);
extern void parse_journal_opts(const char *opts);
extern void check_mount(const char *device, int force, const char *type);
extern void figure_journal_size(struct ext2fs_journal_params *jparams,
int requested_j_size, int requested_fc_size, ext2_filsys fs);
extern void print_check_message(int, unsigned int);
extern void dump_mmp_msg(struct mmp_struct *mmp, const char *msg);