Skip to content

Commit

Permalink
libspl/include: remove unused/empty headers
Browse files Browse the repository at this point in the history
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Closes openzfs#13447
  • Loading branch information
nabijaczleweli authored and andrewc12 committed Sep 23, 2022
1 parent 01c7b63 commit 35b6b2b
Show file tree
Hide file tree
Showing 24 changed files with 6 additions and 604 deletions.
2 changes: 0 additions & 2 deletions include/libzfs.h
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,8 @@
#include <sys/mnttab.h>
#include <sys/param.h>
#include <sys/types.h>
#include <sys/varargs.h>
#include <sys/fs/zfs.h>
#include <sys/avl.h>
#include <ucred.h>
#include <libzfs_core.h>

#ifdef __cplusplus
Expand Down
1 change: 0 additions & 1 deletion include/thread_pool.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@
#define _THREAD_POOL_H_ extern __attribute__((visibility("default")))

#include <sys/types.h>
#include <thread.h>
#include <pthread.h>

#ifdef __cplusplus
Expand Down
13 changes: 0 additions & 13 deletions lib/libspl/include/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -2,18 +2,11 @@ libspldir = $(includedir)/libspl
libspl_HEADERS = \
%D%/assert.h \
%D%/atomic.h \
%D%/libdevinfo.h \
%D%/libgen.h \
%D%/libshare.h \
%D%/limits.h \
%D%/locale.h \
%D%/statcommon.h \
%D%/stdlib.h \
%D%/string.h \
%D%/stropts.h \
%D%/thread.h \
%D%/tzfile.h \
%D%/ucred.h \
%D%/umem.h \
%D%/unistd.h \
%D%/zone.h
Expand All @@ -40,8 +33,6 @@ libspl_sys_HEADERS = \
%D%/sys/dkio.h \
%D%/sys/dklabel.h \
%D%/sys/feature_tests.h \
%D%/sys/int_limits.h \
%D%/sys/int_types.h \
%D%/sys/inttypes.h \
%D%/sys/isa_defs.h \
%D%/sys/kmem.h \
Expand All @@ -59,18 +50,14 @@ libspl_sys_HEADERS = \
%D%/sys/stack.h \
%D%/sys/stdtypes.h \
%D%/sys/string.h \
%D%/sys/stropts.h \
%D%/sys/sunddi.h \
%D%/sys/systeminfo.h \
%D%/sys/time.h \
%D%/sys/trace_spl.h \
%D%/sys/trace_zfs.h \
%D%/sys/types.h \
%D%/sys/types32.h \
%D%/sys/tzfile.h \
%D%/sys/uio.h \
%D%/sys/va_list.h \
%D%/sys/varargs.h \
%D%/sys/vnode.h \
%D%/sys/wmsum.h \
%D%/sys/zone.h
Expand Down
30 changes: 0 additions & 30 deletions lib/libspl/include/libdevinfo.h

This file was deleted.

45 changes: 0 additions & 45 deletions lib/libspl/include/limits.h

This file was deleted.

35 changes: 0 additions & 35 deletions lib/libspl/include/locale.h

This file was deleted.

2 changes: 1 addition & 1 deletion lib/libspl/include/os/freebsd/sys/byteorder.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@
#include <sys/endian.h>
#include <netinet/in.h>
#include <sys/isa_defs.h>
#include <sys/int_types.h>
#include <inttypes.h>

#if defined(__GNUC__) && defined(_ASM_INLINES) && \
(defined(__i386) || defined(__amd64))
Expand Down
4 changes: 2 additions & 2 deletions lib/libspl/include/os/freebsd/sys/mnttab.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ extern int _sol_getmntent(FILE *fp, struct mnttab *mp);
extern int getextmntent(const char *path, struct extmnttab *entry,
struct stat64 *statbuf);
extern void statfs2mnttab(struct statfs *sfs, struct mnttab *mp);
char *hasmntopt(struct mnttab *mnt, char *opt);
int getmntent(FILE *fp, struct mnttab *mp);
extern char *hasmntopt(struct mnttab *mnt, char *opt);
extern int getmntent(FILE *fp, struct mnttab *mp);

#endif
1 change: 0 additions & 1 deletion lib/libspl/include/os/freebsd/sys/zfs_context_os.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,5 @@
#define ZFS_CONTEXT_OS_H_

#define HAVE_LARGE_STACKS 1
#define ZFS_EXPORTS_PATH "/etc/zfs/exports"

#endif
2 changes: 1 addition & 1 deletion lib/libspl/include/os/linux/sys/byteorder.h
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
#endif

#include <sys/isa_defs.h>
#include <sys/int_types.h>
#include <inttypes.h>

#ifdef __cplusplus
extern "C" {
Expand Down
25 changes: 0 additions & 25 deletions lib/libspl/include/stropts.h

This file was deleted.

30 changes: 0 additions & 30 deletions lib/libspl/include/sys/int_limits.h

This file was deleted.

32 changes: 0 additions & 32 deletions lib/libspl/include/sys/int_types.h

This file was deleted.

35 changes: 1 addition & 34 deletions lib/libspl/include/sys/kstat.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,39 +92,6 @@ typedef struct kstat {
void *ks_lock; /* protects this kstat's data */
} kstat_t;

#ifdef _SYSCALL32

typedef int32_t kid32_t;

typedef struct kstat32 {
/*
* Fields relevant to both kernel and user
*/
hrtime_t ks_crtime;
caddr32_t ks_next; /* struct kstat pointer */
kid32_t ks_kid;
char ks_module[KSTAT_STRLEN];
uint8_t ks_resv;
int32_t ks_instance;
char ks_name[KSTAT_STRLEN];
uint8_t ks_type;
char ks_class[KSTAT_STRLEN];
uint8_t ks_flags;
caddr32_t ks_data; /* type-specific data */
uint32_t ks_ndata;
size32_t ks_data_size;
hrtime_t ks_snaptime;
/*
* Fields relevant to kernel only (only needed here for padding)
*/
int32_t _ks_update;
caddr32_t _ks_private;
int32_t _ks_snapshot;
caddr32_t _ks_lock;
} kstat32_t;

#endif /* _SYSCALL32 */

/*
* kstat structure and locking strategy
*
Expand Down Expand Up @@ -467,7 +434,7 @@ typedef struct kstat_named {
* 64-bit compilation environments or 32-bit non-maximally conformant
* C89 or C90 ANSI C compilation environments (cc -Xt and cc -Xa). In the
* C99 ANSI C compilation environment, the long long type is supported.
* The _INT64_TYPE is defined by the implementation (see sys/int_types.h).
* The _INT64_TYPE is defined by the implementation (see sys/inttypes.h).
*/
#if defined(_INT64_TYPE)
int64_t i64;
Expand Down
29 changes: 0 additions & 29 deletions lib/libspl/include/sys/stropts.h

This file was deleted.

2 changes: 1 addition & 1 deletion lib/libspl/include/sys/types.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include <sys/feature_tests.h>
#include_next <sys/types.h>
#include <sys/types32.h>
#include <sys/va_list.h>
#include <stdarg.h>
#include <sys/stdtypes.h>

#ifndef HAVE_INTTYPES
Expand Down
Loading

0 comments on commit 35b6b2b

Please sign in to comment.