Skip to content

Commit d08f547

Browse files
committed
Merge release 0.14.1 into factory
2 parents 18c17be + f626171 commit d08f547

11 files changed

Lines changed: 127 additions & 26 deletions

File tree

.github/actions/spelling/patterns.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,9 @@
1515
\b0x[0-9a-f]{8}\b
1616
\b0x[0-9a-f]{16}\b
1717

18+
# Commit SHAs
19+
\b[0-9a-f]{7}\b
20+
1821
# WWNN/WWPN (NAA identifiers)
1922
\b(?:0x)?10[0-9a-f]{14}\b
2023
\b(?:0x|3)?[25][0-9a-f]{15}\b

.github/workflows/spelling.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,23 @@ on:
8686
- 'opened'
8787
- 'reopened'
8888
- 'synchronize'
89+
paths:
90+
- '.github/workflows/spelling.yml'
91+
- 'README*'
92+
- 'NEWS.md'
93+
- '**.3'
94+
- '**.5'
95+
- '**.8'
96+
- '**.8'
97+
- '**.in'
98+
- '**.service'
99+
- '**.socket'
100+
- '**.rules'
101+
- '**/libdmmp.h'
102+
- '**/mpath_valid.h'
103+
- '**/mpath_cmd.h'
104+
- '**/mpath_persist.h'
105+
- '.github/actions/spelling/*'
89106

90107
jobs:
91108
spelling:

NEWS.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,28 @@ release. These bug fixes will be tracked in stable branches.
99

1010
See [README.md](README.md) for additional information.
1111

12+
## multipath-tools 0.14.1, 2026/01
13+
14+
### Bug fixes
15+
16+
* kpartx: Fix freeing static buffer when operating on regular files.
17+
Fixes 0.14.0. Commit fab5d44.
18+
Fixes [#139](https://github.com/opensvc/multipath-tools/issues/139).
19+
* Fix initialization of paths that were offline during path detection.
20+
Commit 1942fb1.
21+
* Fix printing the "path offline" log message for offline paths that don't
22+
have a path checker configured. Commit 1a364a1.
23+
24+
### Other changes
25+
26+
* If path devices that are members of multipath maps aren't detected during
27+
multipathd startup or `reconfigure`, don't add them to newly created maps
28+
in the first place. In previous versions, such paths would be added to the
29+
maps, only to be removed later. Commit a04be55.
30+
* Improve the detection of "busy" state in the `show status` command, such
31+
that reading udev events from udevd is also counted as busy.
32+
Commit 7fdd93b.
33+
1234
## multipath-tools 0.14.0, 2026/01
1335

1436
### User-visible changes

kpartx/devmapper.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
/*
22
* Copyright (c) 2004, 2005 Christophe Varoqui
33
*/
4+
#define _GNU_SOURCE
45
#include <stdio.h>
56
#include <stdlib.h>
67
#include <string.h>
@@ -699,14 +700,13 @@ int dm_find_part(const char *parent, const char *delim, int part,
699700

700701
char *nondm_create_uuid(dev_t devt)
701702
{
702-
#define NONDM_UUID_BUFLEN (34 + sizeof(NONDM_UUID_PREFIX) + \
703-
sizeof(NONDM_UUID_SUFFIX))
704-
static char uuid_buf[NONDM_UUID_BUFLEN];
705-
snprintf(uuid_buf, sizeof(uuid_buf), "%s_%u:%u_%s",
706-
NONDM_UUID_PREFIX, major(devt), minor(devt),
707-
NONDM_UUID_SUFFIX);
708-
uuid_buf[NONDM_UUID_BUFLEN-1] = '\0';
709-
return uuid_buf;
703+
char *uuid;
704+
705+
if (asprintf(&uuid, "%s_%u:%u_%s", NONDM_UUID_PREFIX, major(devt),
706+
minor(devt), NONDM_UUID_SUFFIX) >= 0)
707+
return uuid;
708+
else
709+
return NULL;
710710
}
711711

712712
int nondm_parse_uuid(const char *uuid, unsigned int *major, unsigned int *minor)

kpartx/kpartx.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,8 +334,11 @@ main(int argc, char **argv){
334334
* This allows deletion of partitions created with older kpartx
335335
* versions which didn't use the fake UUID during creation.
336336
*/
337-
if (!uuid && !(what == DELETE && force_devmap))
337+
if (!uuid && !(what == DELETE && force_devmap)) {
338338
uuid = nondm_create_uuid(buf.st_rdev);
339+
if (!uuid)
340+
exit(1);
341+
}
339342

340343
if (delim == NULL) {
341344
delim = xmalloc(DELIM_SIZE);

libmultipath/configure.c

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1114,7 +1114,17 @@ int coalesce_paths (struct vectors *vecs, vector mpvec, char *refwwid,
11141114
continue;
11151115
}
11161116

1117-
/* 4. path is out of scope */
1117+
/*
1118+
* 4. The path wasn't found in path_discovery. It only exists
1119+
* in an old map.
1120+
*/
1121+
if (pp1->initialized == INIT_PARTIAL ||
1122+
pp1->initialized == INIT_REMOVED) {
1123+
orphan_path(pp1, "path not found");
1124+
continue;
1125+
}
1126+
1127+
/* 5. path is out of scope */
11181128
if (refwwid && strncmp(pp1->wwid, refwwid, WWID_SIZE - 1))
11191129
continue;
11201130

libmultipath/discovery.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2585,6 +2585,8 @@ int pathinfo(struct path *pp, struct config *conf, int mask)
25852585
* Recoverable error, for example faulty or offline path
25862586
*/
25872587
pp->chkrstate = pp->state = PATH_DOWN;
2588+
if (mask & DI_IOCTL && pp->ioctl_info == IOCTL_INFO_NOT_REQUESTED)
2589+
pp->ioctl_info = IOCTL_INFO_SKIPPED;
25882590
if (pp->initialized == INIT_NEW || pp->initialized == INIT_FAILED)
25892591
memset(pp->wwid, 0, WWID_SIZE);
25902592

libmultipath/structs_vec.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -315,7 +315,8 @@ int adopt_paths(vector pathvec, struct multipath *mpp,
315315
pp->dev, mpp->alias);
316316
continue;
317317
}
318-
if (pp->initialized == INIT_REMOVED)
318+
if (pp->initialized == INIT_REMOVED ||
319+
pp->initialized == INIT_PARTIAL)
319320
continue;
320321
if (mpp->queue_mode == QUEUE_MODE_RQ &&
321322
pp->bus == SYSFS_BUS_NVME &&

libmultipath/uevent.c

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ static pthread_cond_t *uev_condp = &uev_cond;
5252
static uev_trigger *my_uev_trigger;
5353
static void *my_trigger_data;
5454
static int servicing_uev;
55+
static int adding_uev; /* uatomic access only */
5556

5657
struct uevent_filter_state {
5758
struct list_head uevq;
@@ -70,13 +71,14 @@ static void reset_filter_state(struct uevent_filter_state *st)
7071

7172
int is_uevent_busy(void)
7273
{
73-
int empty, servicing;
74+
int empty, servicing, adding;
7475

7576
pthread_mutex_lock(uevq_lockp);
7677
empty = list_empty(&uevq);
7778
servicing = servicing_uev;
79+
adding = uatomic_read(&adding_uev);
7880
pthread_mutex_unlock(uevq_lockp);
79-
return (!empty || servicing);
81+
return (!empty || servicing || adding);
8082
}
8183

8284
struct uevent * alloc_uevent (void)
@@ -730,6 +732,7 @@ int uevent_listen(struct udev *udev)
730732
int fdcount, events;
731733
struct pollfd ev_poll = { .fd = fd, .events = POLLIN, };
732734

735+
uatomic_set(&adding_uev, 0);
733736
fdcount = poll(&ev_poll, 1, -1);
734737
if (fdcount < 0) {
735738
if (errno == EINTR)
@@ -739,6 +742,8 @@ int uevent_listen(struct udev *udev)
739742
err = -errno;
740743
break;
741744
}
745+
uatomic_set(&adding_uev, 1);
746+
742747
events = uevent_receive_events(fd, &uevlisten_tmp, monitor);
743748
if (events <= 0)
744749
continue;

libmultipath/version.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@
1111
#ifndef VERSION_H_INCLUDED
1212
#define VERSION_H_INCLUDED
1313

14-
#define VERSION_CODE 0x000E00
14+
#define VERSION_CODE 0x000E01
1515
/* MMDDYY, in hex */
16-
#define DATE_CODE 0x01101A
16+
#define DATE_CODE 0x01171A
1717

1818
#define PROG "multipath-tools"
1919

0 commit comments

Comments
 (0)