Skip to content

Commit

Permalink
Make struct vdev_disk_t be platform private
Browse files Browse the repository at this point in the history
Linux defines different vdev_disk_t members to macOS, but they are
only used in vdev_disk.c so move the declaration there.

Reviewed-by: Ryan Moeller <ryan@ixsystems.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: Jorgen Lundman <lundman@lundman.net>
Closes #10452
  • Loading branch information
lundman authored Jun 16, 2020
1 parent ba54b18 commit d366c8f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 8 deletions.
8 changes: 0 additions & 8 deletions include/sys/vdev_disk.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,5 @@

#ifdef _KERNEL
#include <sys/vdev.h>

typedef struct vdev_disk {
ddi_devid_t vd_devid;
char *vd_minor;
struct block_device *vd_bdev;
krwlock_t vd_lock;
} vdev_disk_t;

#endif /* _KERNEL */
#endif /* _SYS_VDEV_DISK_H */
5 changes: 5 additions & 0 deletions module/os/linux/zfs/vdev_disk.c
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,11 @@
#include <linux/msdos_fs.h>
#include <linux/vfs_compat.h>

typedef struct vdev_disk {
struct block_device *vd_bdev;
krwlock_t vd_lock;
} vdev_disk_t;

/*
* Unique identifier for the exclusive vdev holder.
*/
Expand Down

0 comments on commit d366c8f

Please sign in to comment.