Remove unnecessary references to slavery

The horrible effects of human slavery continue to impact society.  The
casual use of the term "slave" in computer software is an unnecessary
reference to a painful human experience.

This commit removes all possible references to the term "slave".

Implementation notes:

The zpool.d/slaves script is renamed to dm-deps, which uses the same
terminology as `dmsetup deps`.

References to the `/sys/class/block/$dev/slaves` directory remain.  This
directory name is determined by the Linux kernel.  Although
`dmsetup deps` provides the same information, it unfortunately requires
elevated privileges, whereas the `/sys/...` directory is world-readable.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Signed-off-by: Matthew Ahrens <mahrens@delphix.com>
Closes #10435
This commit is contained in:
Matthew Ahrens
2020-06-10 17:07:59 -07:00
committed by GitHub
parent feff3f69fc
commit f66434268c
8 changed files with 42 additions and 48 deletions
+5 -1
View File
@@ -203,7 +203,11 @@ dm_get_underlying_path(const char *dm_name)
if (dp == NULL)
goto end;
/* Return first sd* entry in /sys/block/dm-N/slaves/ */
/*
* Return first entry (that isn't itself a directory) in the
* directory containing device-mapper dependent (underlying)
* devices.
*/
while ((ep = readdir(dp))) {
if (ep->d_type != DT_DIR) { /* skip "." and ".." dirs */
size = asprintf(&path, "/dev/%s", ep->d_name);