libspl/mnttab: remove struct extmnttab

The two additional fields are never used by calling code, and we can
replace their sole internal use with an extra stack param.

Sponsored-by: TrueNAS
Reviewed-by: Ameer Hamza <ahamza@ixsystems.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Rob Norris <rob.norris@truenas.com>
Closes #18296
This commit is contained in:
Rob Norris
2026-03-09 12:08:14 +11:00
committed by Brian Behlendorf
parent f64f12079c
commit a59e712d25
7 changed files with 15 additions and 54 deletions
+1 -16
View File
@@ -54,25 +54,10 @@ struct mnttab {
char *mnt_mntopts;
};
/*
* NOTE: fields in extmnttab should match struct mnttab till new fields
* are encountered, this allows hasmntopt to work properly when its arg is
* a pointer to an extmnttab struct cast to a mnttab struct pointer.
*/
struct extmnttab {
char *mnt_special;
char *mnt_mountp;
char *mnt_fstype;
char *mnt_mntopts;
uint_t mnt_major;
uint_t mnt_minor;
};
struct statfs;
extern int _sol_getmntent(FILE *fp, struct mnttab *mp);
extern int getextmntent(const char *path, struct extmnttab *mp,
extern int getextmntent(const char *path, struct mnttab *mp,
struct stat64 *statbuf);
static inline char *_sol_hasmntopt(struct mnttab *mnt, const char *opt)
{