Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 1 | From bb6db01cc19940bb5162c1cc0c9b5f8e4c209822 Mon Sep 17 00:00:00 2001 |
| 2 | From: Changqing Li <changqing.li@windriver.com> |
| 3 | Date: Fri, 1 Mar 2024 10:34:06 +0800 |
| 4 | Subject: [PATCH 02/12] RH: Remove the property blacklist exception builtin |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 5 | |
| 6 | Multipath set the default property blacklist exceptions to |
| 7 | (ID_SCSI_VPD|ID_WWN). This has the effect of blacklisting some internal |
| 8 | devices. These devices may never have multiple paths, but it is nice |
| 9 | to be able to set multipath up on them all the same. This patch simply |
| 10 | removes the default, and makes it so that if no property |
| 11 | blacklist_exception is given, then devices aren't failed for not matching |
| 12 | it. |
| 13 | |
| 14 | Signed-off-by: Benjamin Marzinski <bmarzins@redhat.com> |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 15 | |
| 16 | Upsteam-Status: Pending |
| 17 | |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 18 | [OP: Rebase to 0.9.3] |
| 19 | Signed-off-by: Ovidiu Panait <ovidiu.panait@windriver.com> |
Patrick Williams | 520786c | 2023-06-25 16:20:36 -0500 | [diff] [blame] | 20 | |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 21 | Rebase to 0.9.8 |
| 22 | Signed-off-by: Changqing Li <changqing.li@windriver.com> |
Patrick Williams | 03514f1 | 2024-04-05 07:04:11 -0500 | [diff] [blame^] | 23 | |
| 24 | Upstream-Status: Pending |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 25 | --- |
| 26 | libmultipath/blacklist.c | 16 +++++----------- |
| 27 | 1 file changed, 5 insertions(+), 11 deletions(-) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 28 | |
| 29 | diff --git a/libmultipath/blacklist.c b/libmultipath/blacklist.c |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 30 | index 75100b20..4fdaca76 100644 |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 31 | --- a/libmultipath/blacklist.c |
| 32 | +++ b/libmultipath/blacklist.c |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 33 | @@ -221,15 +221,6 @@ setup_default_blist (struct config * conf) |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 34 | struct hwentry *hwe; |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 35 | int i; |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 36 | |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 37 | - if (nvme_multipath_enabled()) { |
| 38 | - if (store_ble(conf->blist_devnode, "!^(sd[a-z]|dasd[a-z])", |
| 39 | - ORIGIN_DEFAULT)) |
| 40 | - return 1; |
| 41 | - } else { |
| 42 | - if (store_ble(conf->blist_devnode, "!^(sd[a-z]|dasd[a-z]|nvme[0-9])", |
| 43 | - ORIGIN_DEFAULT)) |
| 44 | - return 1; |
| 45 | - } |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 46 | if (store_ble(conf->elist_property, "(SCSI_IDENT_|ID_WWN)", ORIGIN_DEFAULT)) |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 47 | return 1; |
Andrew Geissler | 517393d | 2023-01-13 08:55:19 -0600 | [diff] [blame] | 48 | |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 49 | @@ -464,8 +455,11 @@ filter_property(const struct config *conf, struct udev_device *udev, |
Brad Bishop | 00ab237 | 2019-10-14 11:06:18 -0400 | [diff] [blame] | 50 | r = MATCH_NOTHING; |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 51 | } |
| 52 | |
| 53 | - log_filter(devname, NULL, NULL, NULL, env, NULL, r, lvl); |
| 54 | - return r; |
| 55 | + if (VECTOR_SIZE(conf->elist_property)) { |
| 56 | + log_filter(devname, NULL, NULL, NULL, env, NULL, r, lvl); |
| 57 | + return r; |
| 58 | + } |
| 59 | + return 0; |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 60 | } |
| 61 | |
Brad Bishop | 1932369 | 2019-04-05 15:28:33 -0400 | [diff] [blame] | 62 | static void free_ble(struct blentry *ble) |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 63 | -- |
Patrick Williams | b58112e | 2024-03-07 11:16:36 -0600 | [diff] [blame] | 64 | 2.25.1 |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 65 | |