mirror of
https://github.com/ericonr/util-linux.git
synced 2024-04-21 09:12:35 -05:00
The ambivalent probing result should be properly reported and user should be informed that the problem is possible to bypass by "-t <type>" or resolved by wipefs(8). The mount(8) command uses a brute force stage (calls mount(2) for all /{proc,etc}/fylesystems) if there is not any other way how to detect the filesystem type. The brute force stage should not be restricted by libblkid. It's possible that libblkid is not able to detect slightly corrupted filesystem, but kernel is able to mount such filesystem. Note that the brute force stage should not be used if libblkid returns ambivalent probing result. In this case user's intervention is required (e.g. mount -t <type>). Reported-by: Mike Frysinger <vapier@gentoo.org> Signed-off-by: Karel Zak <kzak@redhat.com>
26 lines
872 B
C
26 lines
872 B
C
#ifndef FSPROBE_H
|
|
#define FSPROBE_H
|
|
/*
|
|
* This is the generic interface for filesystem guessing libraries.
|
|
* Implementations are provided by
|
|
*/
|
|
extern void fsprobe_init(void);
|
|
extern void fsprobe_exit(void);
|
|
|
|
extern int fsprobe_parse_spec(const char *spec, char **name, char **value);
|
|
|
|
/* all routines return newly allocated string */
|
|
extern char *fsprobe_get_devname_by_uuid(const char *uuid);
|
|
extern char *fsprobe_get_devname_by_label(const char *label);
|
|
extern char *fsprobe_get_devname_by_spec(const char *spec);
|
|
|
|
extern char *fsprobe_get_label_by_devname(const char *devname);
|
|
extern char *fsprobe_get_uuid_by_devname(const char *devname);
|
|
extern char *fsprobe_get_fstype_by_devname(const char *devname);
|
|
extern char *fsprobe_get_fstype_by_devname_ambi(const char *devname, int *ambi);
|
|
|
|
|
|
extern int fsprobe_known_fstype(const char *fstype);
|
|
|
|
#endif /* FSPROBE_H */
|