msdosfs: adjust #ifdefs to be similar to NetBSD
- Add header guards where missing - Make parts available for use in makefs Sponsored by: The FreeBSD Foundation
This commit is contained in:
parent
42c2bedf50
commit
3a25a026d3
@ -47,6 +47,8 @@
|
||||
*
|
||||
* October 1992
|
||||
*/
|
||||
#ifndef _FS_MSDOSFS_DENODE_H_
|
||||
#define _FS_MSDOSFS_DENODE_H_
|
||||
|
||||
/*
|
||||
* This is the pc filesystem specific portion of the vnode structure.
|
||||
@ -207,7 +209,7 @@ struct denode {
|
||||
((dep)->de_Attributes & ATTR_DIRECTORY) ? 0 : (dep)->de_FileSize), \
|
||||
putushort((dp)->deHighClust, (dep)->de_StartCluster >> 16))
|
||||
|
||||
#ifdef _KERNEL
|
||||
#if defined(_KERNEL) || defined(MAKEFS)
|
||||
|
||||
#define VTODE(vp) ((struct denode *)(vp)->v_data)
|
||||
#define DETOV(de) ((de)->de_vnode)
|
||||
@ -277,4 +279,6 @@ int deupdat(struct denode *dep, int waitfor);
|
||||
int removede(struct denode *pdep, struct denode *dep);
|
||||
int detrunc(struct denode *dep, u_long length, int flags, struct ucred *cred);
|
||||
int doscheckpath( struct denode *source, struct denode *target);
|
||||
#endif /* _KERNEL */
|
||||
#endif /* _KERNEL || MAKEFS */
|
||||
#endif /* !_FS_MSDOSFS_DENODE_H_ */
|
||||
|
||||
|
@ -133,7 +133,7 @@ struct winentry {
|
||||
#define DD_YEAR_MASK 0xFE00 /* year - 1980 */
|
||||
#define DD_YEAR_SHIFT 9
|
||||
|
||||
#ifdef _KERNEL
|
||||
#if defined(_KERNEL) || defined(MAKEFS)
|
||||
struct mbnambuf {
|
||||
size_t nb_len;
|
||||
int nb_last_id;
|
||||
@ -159,5 +159,5 @@ int win2unixfn(struct mbnambuf *nbp, struct winentry *wep, int chksum,
|
||||
uint8_t winChksum(uint8_t *name);
|
||||
int winSlotCnt(const u_char *un, size_t unlen, struct msdosfsmount *pmp);
|
||||
size_t winLenFixup(const u_char *un, size_t unlen);
|
||||
#endif /* _KERNEL */
|
||||
#endif /* _KERNEL || MAKEFS */
|
||||
#endif /* !_FS_MSDOSFS_DIRENTRY_H_ */
|
||||
|
@ -48,6 +48,8 @@
|
||||
* October 1992
|
||||
*/
|
||||
|
||||
#ifndef _FS_MSDOSFS_FAT_H_
|
||||
#define _FS_MSDOSFS_FAT_H_
|
||||
/*
|
||||
* Some useful cluster numbers.
|
||||
*/
|
||||
@ -78,7 +80,7 @@
|
||||
|
||||
#define MSDOSFSEOF(pmp, cn) ((((cn) | ~(pmp)->pm_fatmask) & CLUST_EOFS) == CLUST_EOFS)
|
||||
|
||||
#ifdef _KERNEL
|
||||
#if defined(_KERNEL) || defined(MAKEFS)
|
||||
/*
|
||||
* These are the values for the function argument to the function
|
||||
* fatentry().
|
||||
@ -101,4 +103,5 @@ int extendfile(struct denode *dep, u_long count, struct buf **bpp, u_long *ncp,
|
||||
void fc_purge(struct denode *dep, u_int frcn);
|
||||
int markvoldirty(struct msdosfsmount *pmp, int dirty);
|
||||
|
||||
#endif /* _KERNEL */
|
||||
#endif /* _KERNEL || MAKEFS */
|
||||
#endif /* !_FS_MSDOSFS_FAT_H_ */
|
||||
|
Loading…
x
Reference in New Issue
Block a user