From 04f2f00b0273b561a0972161a3677ffe7bf732fb Mon Sep 17 00:00:00 2001 From: anolis-bot Date: Thu, 10 Nov 2022 16:18:24 +0800 Subject: [PATCH] update to util-linux-2.32.1-38.el8 Signed-off-by: anolis-bot --- 0076-libblkid-fix-Atari-prober-logic.patch | 47 +++++ 0077-libblkid-make-Atari-more-robust.patch | 129 ++++++++++++++ ...bblkid-allow-a-lot-of-mac-partitions.patch | 53 ++++++ ...id-limit-amount-of-parsed-partitions.patch | 85 +++++++++ ...e-sure-block-size-is-large-enough-fu.patch | 29 ++++ ...t-read-from-HW-when-use-sys-snapshot.patch | 40 +++++ ...gins-improve-prefixes-interpretation.patch | 84 +++++++++ 0083-tests-update-atari-blkid-tests.patch | 149 ++++++++++++++++ 0084-tests-update-atari-partx-tests.patch | 55 ++++++ 1001-hwclock-make-glibc-2.31-compatible.patch | 161 ------------------ ...eoverse-N2-to-ARM-identifiers-tables.patch | 24 --- ...-cpu-frequency-from-cpuinfo-on-arm64.patch | 24 --- dist | 1 + util-linux.spec | 69 ++++---- uuidd-tmpfiles.conf | 1 + 15 files changed, 706 insertions(+), 245 deletions(-) create mode 100644 0076-libblkid-fix-Atari-prober-logic.patch create mode 100644 0077-libblkid-make-Atari-more-robust.patch create mode 100644 0078-libblkid-allow-a-lot-of-mac-partitions.patch create mode 100644 0079-libblkid-limit-amount-of-parsed-partitions.patch create mode 100644 0080-libblkid-mac-make-sure-block-size-is-large-enough-fu.patch create mode 100644 0081-lscpu-don-t-read-from-HW-when-use-sys-snapshot.patch create mode 100644 0082-lslogins-improve-prefixes-interpretation.patch create mode 100644 0083-tests-update-atari-blkid-tests.patch create mode 100644 0084-tests-update-atari-partx-tests.patch delete mode 100644 1001-hwclock-make-glibc-2.31-compatible.patch delete mode 100644 1002-add-Neoverse-N2-to-ARM-identifiers-tables.patch delete mode 100644 1003-fix-lscpu-to-get-cpu-frequency-from-cpuinfo-on-arm64.patch create mode 100644 dist create mode 100644 uuidd-tmpfiles.conf diff --git a/0076-libblkid-fix-Atari-prober-logic.patch b/0076-libblkid-fix-Atari-prober-logic.patch new file mode 100644 index 0000000..98a492c --- /dev/null +++ b/0076-libblkid-fix-Atari-prober-logic.patch @@ -0,0 +1,47 @@ +From 214eaa70d8431161de03ea7903f814c102e87919 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Fri, 9 Oct 2020 13:06:08 +0200 +Subject: libblkid: fix Atari prober logic + +Addresses: https://github.com/karelzak/util-linux/issues/1159 +Addresses: https://github.com/karelzak/util-linux/issues/1116 +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Upstream: http://github.com/util-linux/util-linux/commit/282ceadc3a72fc07dd0388b8880fd751490bb87f +Signed-off-by: Karel Zak +--- + libblkid/src/partitions/atari.c | 12 +++++++----- + 1 file changed, 7 insertions(+), 5 deletions(-) + +diff --git a/libblkid/src/partitions/atari.c b/libblkid/src/partitions/atari.c +index 1224a577c..b469ef5a1 100644 +--- a/libblkid/src/partitions/atari.c ++++ b/libblkid/src/partitions/atari.c +@@ -199,11 +199,10 @@ static int probe_atari_pt(blkid_probe pr, + + hdsize = blkid_probe_get_size(pr) / 512; + +- /* Look for validly looking primary partition */ +- for (i = 0; ; i++) { +- if (i >= ARRAY_SIZE(rs->part)) +- goto nothing; +- ++ /* ++ * At least one valid partition required ++ */ ++ for (i = 0; i < 4; i++) { + if (IS_PARTDEF_VALID(rs->part[i], hdsize)) { + blkid_probe_set_magic(pr, + offsetof(struct atari_rootsector, part[i]), +@@ -213,6 +212,9 @@ static int probe_atari_pt(blkid_probe pr, + } + } + ++ if (i == 4) ++ goto nothing; ++ + if (blkid_partitions_need_typeonly(pr)) + /* caller does not ask for details about partitions */ + return BLKID_PROBE_OK; +-- +2.36.1 + diff --git a/0077-libblkid-make-Atari-more-robust.patch b/0077-libblkid-make-Atari-more-robust.patch new file mode 100644 index 0000000..9f19c48 --- /dev/null +++ b/0077-libblkid-make-Atari-more-robust.patch @@ -0,0 +1,129 @@ +From e7f0f5d3a80324e1430e979b0a170ded77b380e2 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Tue, 13 Oct 2020 16:19:20 +0200 +Subject: libblkid: make Atari more robust + +* ignore large disks +* check in-table stored device size +* check bad sectors list +* check partition dimensions against in-table device size + +Addresses: https://github.com/karelzak/util-linux/issues/1159 +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Upstream: http://github.com/util-linux/util-linux/commit/282ceadc3a72fc07dd0388b8880fd751490bb87f +Signed-off-by: Karel Zak +--- + libblkid/src/partitions/atari.c | 66 ++++++++++++++++++++++++--------- + 1 file changed, 48 insertions(+), 18 deletions(-) + +diff --git a/libblkid/src/partitions/atari.c b/libblkid/src/partitions/atari.c +index b469ef5a1..c3f77117a 100644 +--- a/libblkid/src/partitions/atari.c ++++ b/libblkid/src/partitions/atari.c +@@ -74,16 +74,27 @@ static int linux_isalnum(unsigned char c) { + + #define IS_ACTIVE(partdef) ((partdef).flags & 1) + +-#define IS_PARTDEF_VALID(partdef, hdsize) \ +- ( \ +- (partdef).flags & 1 && \ +- isalnum((partdef).id[0]) && \ +- isalnum((partdef).id[1]) && \ +- isalnum((partdef).id[2]) && \ +- be32_to_cpu((partdef).start) <= (hdsize) && \ +- be32_to_cpu((partdef).start) + \ +- be32_to_cpu((partdef).size) <= (hdsize) \ +- ) ++static int is_valid_dimension(uint32_t start, uint32_t size, uint32_t maxoff) ++{ ++ uint64_t end = start + size; ++ ++ return end >= start ++ && 0 < start && start <= maxoff ++ && 0 < size && size <= maxoff ++ && 0 < end && end <= maxoff; ++} ++ ++static int is_valid_partition(struct atari_part_def *part, uint32_t maxoff) ++{ ++ uint32_t start = be32_to_cpu(part->start), ++ size = be32_to_cpu(part->size); ++ ++ return (part->flags & 1) ++ && isalnum(part->id[0]) ++ && isalnum(part->id[1]) ++ && isalnum(part->id[2]) ++ && is_valid_dimension(start, size, maxoff); ++} + + static int is_id_common(char *id) + { +@@ -184,12 +195,20 @@ static int probe_atari_pt(blkid_probe pr, + unsigned i; + int has_xgm = 0; + int rc = 0; +- off_t hdsize; ++ uint32_t rssize; /* size in sectors from root sector */ ++ uint64_t size; /* size in sectors from system */ + + /* Atari partition is not defined for other sector sizes */ + if (blkid_probe_get_sectorsize(pr) != 512) + goto nothing; + ++ size = blkid_probe_get_size(pr) / 512; ++ ++ /* Atari is not well defined to support large disks */ ++ if (size > INT32_MAX) ++ goto nothing; ++ ++ /* read root sector */ + rs = (struct atari_rootsector *) blkid_probe_get_sector(pr, 0); + if (!rs) { + if (errno) +@@ -197,17 +216,29 @@ static int probe_atari_pt(blkid_probe pr, + goto nothing; + } + +- hdsize = blkid_probe_get_size(pr) / 512; ++ rssize = be32_to_cpu(rs->hd_size); ++ ++ /* check number of sectors stored in the root sector */ ++ if (rssize < 2 || rssize > size) ++ goto nothing; ++ ++ /* check list of bad blocks */ ++ if ((rs->bsl_start || rs->bsl_len) ++ && !is_valid_dimension(be32_to_cpu(rs->bsl_start), ++ be32_to_cpu(rs->bsl_len), ++ rssize)) ++ goto nothing; + + /* + * At least one valid partition required + */ + for (i = 0; i < 4; i++) { +- if (IS_PARTDEF_VALID(rs->part[i], hdsize)) { +- blkid_probe_set_magic(pr, +- offsetof(struct atari_rootsector, part[i]), +- sizeof(rs->part[i].flags) + sizeof(rs->part[i].id), +- (unsigned char *) &rs->part[i]); ++ if (is_valid_partition(&rs->part[i], rssize)) { ++ if (blkid_probe_set_magic(pr, ++ offsetof(struct atari_rootsector, part[i]), ++ sizeof(rs->part[i].flags) + sizeof(rs->part[i].id), ++ (unsigned char *) &rs->part[i])) ++ goto err; + break; + } + } +@@ -234,7 +265,6 @@ static int probe_atari_pt(blkid_probe pr, + blkid_partlist_increment_partno(ls); + continue; + } +- + if (!memcmp(p->id, "XGM", 3)) { + has_xgm = 1; + rc = parse_extended(pr, ls, tab, p); +-- +2.36.1 + diff --git a/0078-libblkid-allow-a-lot-of-mac-partitions.patch b/0078-libblkid-allow-a-lot-of-mac-partitions.patch new file mode 100644 index 0000000..9cf4dc9 --- /dev/null +++ b/0078-libblkid-allow-a-lot-of-mac-partitions.patch @@ -0,0 +1,53 @@ +From 2348779e225dd581c32c00108e017f5c1924e706 Mon Sep 17 00:00:00 2001 +From: Samanta Navarro +Date: Sun, 8 Nov 2020 11:45:18 +0000 +Subject: libblkid: allow a lot of mac partitions + +If the map count is set to INT_MAX then the for loop does not stop +because its check is never false. + +I have not found a correct upper limit. The other partition logics have +a maximum amount (exception is atari.c). + +The loop itself wouldn't be endless. If the iteration reaches block 0 +then the signature will be wrong. This means that map count = INT_MAX +case would fail even if such a setup would be correct on disk. + +Upstream: http://github.com/util-linux/util-linux/commit/8f22adaaf30e9fd3bf83da0213b4a6525c9305cd +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Signed-off-by: Samanta Navarro +--- + libblkid/src/partitions/mac.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/libblkid/src/partitions/mac.c b/libblkid/src/partitions/mac.c +index 4713d6042..2be91a620 100644 +--- a/libblkid/src/partitions/mac.c ++++ b/libblkid/src/partitions/mac.c +@@ -123,12 +123,12 @@ static int probe_mac_pt(blkid_probe pr, + ssf = block_size / 512; + nblks = be32_to_cpu(p->map_count); + +- for (i = 1; i <= nblks; ++i) { ++ for (i = 0; i < nblks; ++i) { + blkid_partition par; + uint32_t start; + uint32_t size; + +- p = (struct mac_partition *) get_mac_block(pr, block_size, i); ++ p = (struct mac_partition *) get_mac_block(pr, block_size, i + 1); + if (!p) { + if (errno) + return -errno; +@@ -141,7 +141,7 @@ static int probe_mac_pt(blkid_probe pr, + DBG(LOWPROBE, ul_debug( + "mac: inconsistent map_count in partition map, " + "entry[0]: %d, entry[%d]: %d", +- nblks, i - 1, ++ nblks, i, + be32_to_cpu(p->map_count))); + } + +-- +2.36.1 + diff --git a/0079-libblkid-limit-amount-of-parsed-partitions.patch b/0079-libblkid-limit-amount-of-parsed-partitions.patch new file mode 100644 index 0000000..e202558 --- /dev/null +++ b/0079-libblkid-limit-amount-of-parsed-partitions.patch @@ -0,0 +1,85 @@ +From 24f5385f4a54b90f4b7674e23f30567591962bcb Mon Sep 17 00:00:00 2001 +From: Samanta Navarro +Date: Tue, 10 Nov 2020 11:48:04 +0100 +Subject: libblkid: limit amount of parsed partitions + +The linux kernel does not support more than 256 partitions +(DISK_MAX_PARTS). The atari and mac block devices have no such limits. + +Use dos logical partition limit for atari as well (100). +Use the kernel limit for mac (256). + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Upstream: http://github.com/util-linux/util-linux/commit/c70b4f2a5b99876d230b8f4f413c3bb3ee6647f1 +Signed-off-by: Karel Zak +Signed-off-by: Samanta Navarro +--- + libblkid/src/partitions/atari.c | 6 +++++- + libblkid/src/partitions/mac.c | 15 +++++++++++---- + 2 files changed, 16 insertions(+), 5 deletions(-) + +diff --git a/libblkid/src/partitions/atari.c b/libblkid/src/partitions/atari.c +index c3f77117a..fdd5498b5 100644 +--- a/libblkid/src/partitions/atari.c ++++ b/libblkid/src/partitions/atari.c +@@ -141,12 +141,16 @@ static int parse_extended(blkid_probe pr, blkid_partlist ls, + blkid_parttable tab, struct atari_part_def *part) + { + uint32_t x0start, xstart; +- unsigned i = 0; ++ unsigned ct = 0, i = 0; + int rc; + + x0start = xstart = be32_to_cpu(part->start); + while (1) { + struct atari_rootsector *xrs; ++ ++ if (++ct > 100) ++ break; ++ + xrs = (struct atari_rootsector *) blkid_probe_get_sector(pr, xstart); + if (!xrs) { + if (errno) +diff --git a/libblkid/src/partitions/mac.c b/libblkid/src/partitions/mac.c +index 2be91a620..092d31d32 100644 +--- a/libblkid/src/partitions/mac.c ++++ b/libblkid/src/partitions/mac.c +@@ -79,7 +79,7 @@ static int probe_mac_pt(blkid_probe pr, + blkid_partlist ls; + uint16_t block_size; + uint16_t ssf; /* sector size fragment */ +- uint32_t nblks, i; ++ uint32_t nblks, nprts, i; + + + /* The driver descriptor record is always located at physical block 0, +@@ -122,8 +122,15 @@ static int probe_mac_pt(blkid_probe pr, + + ssf = block_size / 512; + nblks = be32_to_cpu(p->map_count); +- +- for (i = 0; i < nblks; ++i) { ++ if (nblks > 256) { ++ nprts = 256; ++ DBG(LOWPROBE, ul_debug( ++ "mac: map_count too large, entry[0]: %u, " ++ "enforcing limit of %u", nblks, nprts)); ++ } else ++ nprts = nblks; ++ ++ for (i = 0; i < nprts; ++i) { + blkid_partition par; + uint32_t start; + uint32_t size; +@@ -140,7 +147,7 @@ static int probe_mac_pt(blkid_probe pr, + if (be32_to_cpu(p->map_count) != nblks) { + DBG(LOWPROBE, ul_debug( + "mac: inconsistent map_count in partition map, " +- "entry[0]: %d, entry[%d]: %d", ++ "entry[0]: %u, entry[%u]: %u", + nblks, i, + be32_to_cpu(p->map_count))); + } +-- +2.36.1 + diff --git a/0080-libblkid-mac-make-sure-block-size-is-large-enough-fu.patch b/0080-libblkid-mac-make-sure-block-size-is-large-enough-fu.patch new file mode 100644 index 0000000..2eafd83 --- /dev/null +++ b/0080-libblkid-mac-make-sure-block-size-is-large-enough-fu.patch @@ -0,0 +1,29 @@ +From 7180c1ad36a1f419e20e90ddfad0b2f77d8c018f Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Thu, 2 Jun 2022 16:02:54 +0200 +Subject: libblkid: (mac) make sure block size is large enough [fuzzing] + +Upstream: http://github.com/util-linux/util-linux/commit/4e12fbca62be10b09503cecc7507757874043474 +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Reported-by: Thibault Guittet +Signed-off-by: Karel Zak +--- + libblkid/src/partitions/mac.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/libblkid/src/partitions/mac.c b/libblkid/src/partitions/mac.c +index 092d31d32..75a558b0a 100644 +--- a/libblkid/src/partitions/mac.c ++++ b/libblkid/src/partitions/mac.c +@@ -93,6 +93,8 @@ static int probe_mac_pt(blkid_probe pr, + } + + block_size = be16_to_cpu(md->block_size); ++ if (block_size < sizeof(struct mac_partition)) ++ goto nothing; + + /* The partition map always begins at physical block 1, + * the second block on the disk. +-- +2.36.1 + diff --git a/0081-lscpu-don-t-read-from-HW-when-use-sys-snapshot.patch b/0081-lscpu-don-t-read-from-HW-when-use-sys-snapshot.patch new file mode 100644 index 0000000..0f12cee --- /dev/null +++ b/0081-lscpu-don-t-read-from-HW-when-use-sys-snapshot.patch @@ -0,0 +1,40 @@ +From c223ad8f05d2d20a80e21dbb4b6240f11909f92c Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Thu, 14 Jul 2022 13:10:16 +0200 +Subject: lscpu: don;t read from HW when use /sys snapshot + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2069187 +Signed-off-by: Karel Zak +--- + sys-utils/lscpu.c | 8 ++++++-- + 1 file changed, 6 insertions(+), 2 deletions(-) + +diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c +index 70a797dd6..01f8fba35 100644 +--- a/sys-utils/lscpu.c ++++ b/sys-utils/lscpu.c +@@ -1850,7 +1850,10 @@ print_summary(struct lscpu_desc *desc, struct lscpu_modifier *mod) + } + } else { + if (desc->is_cluster) { +- int sockets = get_number_of_physical_sockets_from_dmi(); ++ int sockets = 0; ++ ++ if (mod->system == SYSTEM_LIVE) ++ sockets = get_number_of_physical_sockets_from_dmi(); + + if (sockets > 0) + add_summary_n(tb, _("Socket(s):"), sockets); +@@ -2109,7 +2112,8 @@ int main(int argc, char *argv[]) + qsort(desc->ecaches, desc->necaches, + sizeof(struct cpu_cache), cachecmp); + +- desc->is_cluster = is_fallback_to_cluster(desc); ++ if (mod->system == SYSTEM_LIVE) ++ desc->is_cluster = is_fallback_to_cluster(desc); + + read_nodes(desc); + read_hypervisor(desc, mod); +-- +2.36.1 + diff --git a/0082-lslogins-improve-prefixes-interpretation.patch b/0082-lslogins-improve-prefixes-interpretation.patch new file mode 100644 index 0000000..e41d75c --- /dev/null +++ b/0082-lslogins-improve-prefixes-interpretation.patch @@ -0,0 +1,84 @@ +From 818cd2018ca66e804ea30066c44572ca128a24a7 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Tue, 7 Jun 2022 09:11:56 +0200 +Subject: lslogins: improve prefixes interpretation + +It seems that for example 'passwd --lock' uses two exclamation marks +in password field. It seems better to assume arbitrary number of '!' +and '*' prefixes. + +The patch also makes description of the PWD-EMPTY output field more +explicit. + +Upstream: http://github.com/util-linux/util-linux/commit/c51cba1e838ae7e36a843ec785543492bb8737cd +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2093166 +Signed-off-by: Karel Zak +--- + login-utils/lslogins.c | 31 +++++++++++++++++++++++++------ + 1 file changed, 25 insertions(+), 6 deletions(-) + +diff --git a/login-utils/lslogins.c b/login-utils/lslogins.c +index 6f804aa35..b81afc6c7 100644 +--- a/login-utils/lslogins.c ++++ b/login-utils/lslogins.c +@@ -216,7 +216,7 @@ static const struct lslogins_coldesc coldescs[] = + { + [COL_USER] = { "USER", N_("user name"), N_("Username"), 0.1, SCOLS_FL_NOEXTREMES }, + [COL_UID] = { "UID", N_("user ID"), "UID", 1, SCOLS_FL_RIGHT}, +- [COL_PWDEMPTY] = { "PWD-EMPTY", N_("password not required"), N_("Password not required"), 1, SCOLS_FL_RIGHT }, ++ [COL_PWDEMPTY] = { "PWD-EMPTY", N_("password not defined"), N_("Password not required (empty)"), 1, SCOLS_FL_RIGHT }, + [COL_PWDDENY] = { "PWD-DENY", N_("login by password disabled"), N_("Login by password disabled"), 1, SCOLS_FL_RIGHT }, + [COL_PWDLOCK] = { "PWD-LOCK", N_("password defined, but locked"), N_("Password is locked"), 1, SCOLS_FL_RIGHT }, + [COL_NOLOGIN] = { "NOLOGIN", N_("log in disabled by nologin(8) or pam_nologin(8)"), N_("No login"), 1, SCOLS_FL_RIGHT }, +@@ -755,16 +755,24 @@ static struct lslogins_user *get_user_info(struct lslogins_control *ctl, const c + break; + case COL_PWDEMPTY: + if (shadow) { +- if (!*shadow->sp_pwdp) /* '\0' */ ++ const char *p = shadow->sp_pwdp; ++ ++ while (p && (*p == '!' || *p == '*')) ++ p++; ++ ++ if (!p || !*p) + user->pwd_empty = STATUS_TRUE; + } else + user->pwd_empty = STATUS_UNKNOWN; + break; + case COL_PWDDENY: + if (shadow) { +- if ((*shadow->sp_pwdp == '!' || +- *shadow->sp_pwdp == '*') && +- !valid_pwd(shadow->sp_pwdp + 1)) ++ const char *p = shadow->sp_pwdp; ++ ++ while (p && (*p == '!' || *p == '*')) ++ p++; ++ ++ if (p && *p && p != shadow->sp_pwdp && !valid_pwd(p)) + user->pwd_deny = STATUS_TRUE; + } else + user->pwd_deny = STATUS_UNKNOWN; +@@ -772,7 +780,18 @@ static struct lslogins_user *get_user_info(struct lslogins_control *ctl, const c + + case COL_PWDLOCK: + if (shadow) { +- if (*shadow->sp_pwdp == '!' && valid_pwd(shadow->sp_pwdp + 1)) ++ const char *p = shadow->sp_pwdp; ++ int i = 0; ++ ++ /* 'passwd --lock' uses two exclamation marks, ++ * shadow(5) describes the lock as "field which ++ * starts with an exclamation mark". Let's ++ * support more '!' ... ++ */ ++ while (p && *p == '!') ++ p++, i++; ++ ++ if (i != 0 && (!*p || valid_pwd(p))) + user->pwd_lock = STATUS_TRUE; + } else + user->pwd_lock = STATUS_UNKNOWN; +-- +2.36.1 + diff --git a/0083-tests-update-atari-blkid-tests.patch b/0083-tests-update-atari-blkid-tests.patch new file mode 100644 index 0000000..6bd93f0 --- /dev/null +++ b/0083-tests-update-atari-blkid-tests.patch @@ -0,0 +1,149 @@ +From 78be9c320883e77c2b5fdc676277a51efc98c723 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Tue, 13 Oct 2020 16:29:19 +0200 +Subject: tests: update atari blkid tests + +The old images of the atari label are truncated and in-table stored +sizes do not match with real images sizes -- libblkid checks it now. + +I have no idea how to generate ICD format, let's ignore it in tests +for now. + +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Upstream: http://github.com/util-linux/util-linux/commit/0d061b6e68bc74ce7d61524097b5d0f3becee437 +Signed-off-by: Karel Zak +--- + tests/expected/blkid/lowprobe-pt-atari-icd | 8 -------- + tests/expected/blkid/lowprobe-pt-atari-primary | 3 +++ + tests/expected/blkid/lowprobe-pt-atari-xgm | 10 +++------- + tests/ts/blkid/images-pt/atari-icd.img.xz | Bin 1920 -> 0 bytes + tests/ts/blkid/images-pt/atari-primary.img.xz | Bin 0 -> 932 bytes + tests/ts/blkid/images-pt/atari-xgm.img.xz | Bin 1920 -> 956 bytes + 6 files changed, 6 insertions(+), 15 deletions(-) + delete mode 100644 tests/expected/blkid/lowprobe-pt-atari-icd + create mode 100644 tests/expected/blkid/lowprobe-pt-atari-primary + delete mode 100644 tests/ts/blkid/images-pt/atari-icd.img.xz + create mode 100644 tests/ts/blkid/images-pt/atari-primary.img.xz + +diff --git a/tests/expected/blkid/lowprobe-pt-atari-icd b/tests/expected/blkid/lowprobe-pt-atari-icd +deleted file mode 100644 +index 29942b123..000000000 +--- a/tests/expected/blkid/lowprobe-pt-atari-icd ++++ /dev/null +@@ -1,8 +0,0 @@ +-size: 8388608, sector size: 512, PT: atari, offset: 0, id=(null) +---- +-#1: 65 4032 0x0 type='FAT' +-#2: 4097 904 0x0 type='FOO' +-#4: 12289 4096 0x0 type='BAR' +-#5: 5002 1999 0x0 type='GEM' +-#6: 7003 3238 0x0 type='RAW' +-#7: 10241 2048 0x0 type='RAW' +diff --git a/tests/expected/blkid/lowprobe-pt-atari-primary b/tests/expected/blkid/lowprobe-pt-atari-primary +new file mode 100644 +index 000000000..472821e47 +--- /dev/null ++++ b/tests/expected/blkid/lowprobe-pt-atari-primary +@@ -0,0 +1,3 @@ ++size: 5242880, sector size: 512, PT: atari, offset: 0, id=(null) ++--- ++#1: 2 10238 0x0 type='RAW' +diff --git a/tests/expected/blkid/lowprobe-pt-atari-xgm b/tests/expected/blkid/lowprobe-pt-atari-xgm +index 4b7756655..a7dae6995 100644 +--- a/tests/expected/blkid/lowprobe-pt-atari-xgm ++++ b/tests/expected/blkid/lowprobe-pt-atari-xgm +@@ -1,8 +1,4 @@ +-size: 8388608, sector size: 512, PT: atari, offset: 0, id=(null) ++size: 5242880, sector size: 512, PT: atari, offset: 0, id=(null) + --- +-#1: 65 4032 0x0 type='FAT' +-#2: 4097 904 0x0 type='FOO' +-#3: 5002 1999 0x0 type='GEM' +-#4: 7003 3238 0x0 type='RAW' +-#5: 10241 2048 0x0 type='RAW' +-#6: 12289 4096 0x0 type='BAR' ++#1: 2 9 0x0 type='RAW' ++#2: 14 10226 0x0 type='RAW' +diff --git a/tests/ts/blkid/images-pt/atari-icd.img.xz b/tests/ts/blkid/images-pt/atari-icd.img.xz +deleted file mode 100644 +index 00a2aba49a8f940c35b788fd693f966a31cd1aaf..0000000000000000000000000000000000000000 +GIT binary patch +literal 0 +HcmV?d00001 + +literal 1920 +zcmexsUKJ6=z`*kC+7>q^21Q0O1_p)_{ilon|NqLI8OvZIducK^Ecg5@jkusTr=nRy9*!Bn(bM`eR*oT<-}u76EuU~ +zr&{jenxVc;S-qm~ZIsPAhf|HgcYYYo_5QBSWhxk^uDJZlk@ka|=4h`oy~sXG;MryA +zIO|(4yiWFOUJ0<66IC1R`kF;$O2rLg_J2GWu-_F>bn|D|)EpJ!*v${KQj{VzR>(-u`|K~x`ZzH*T0p2&o +zI-4YzQ@78Q>MqMUn_j_J&?R}Ab%JX4g_GgC#kn_Er2N@;{G{oT!>g3%?{7LTl&~r1 +z*sPkJ_H4EL-ks8A5cG>Zb+_(`db`H=OHtd`KiM;({>U6}*_GC3*O{IFD%<~0_S{B} +zIAt^L!kb^-#2H7;7G8c(H`jXWaenqoR^eP0x0jjMz0;S=ntyt=$t<^43C^Wa`_>-0 +zn)7LCqnV7@rul}KIZjS|we9MTwfEKjD!a`sVqAVcbjH02iV_QaLoQ$Lm6>2)J5?)m +z+4ZM<_KLr<4xZ|{k^g93P-0R3!R;b!3l;9v+iG1rUa|31OFLJYVQ4>WuO;!puhEVbK`;3BdWnazD_hVWL>)9 +zUH-uWUw59169reTO_1GnZlk(HOk~^3w4jK6F9(a&E)Q>o&j0_BF`3~_aq#lL`_|PM +zO3mNiYnWFsZ@F^(8;#Sg7pKnXs?(bINxk&DxBzBB&bSbuc_Kc+u-9hd96{dU62 +zdy9&v9!&J;nWpuKafAQ2KRiy8H+G)6azfr>>9!ZUEsJ{hn{EH;vMu55vVwblapfAb +zxMqapUGF~CVIOb!`-J}sVcYGG8+IwL_`%kF^K1PzUTOPUszzJx7yZuII0hq?niBJy +ztHOi*X|1ZF(LqR~lKc93~ +zM{UwbNSDCeSh)377bwKEDG0HlkOiq$@C5SPZ)#xt%D~Ft{N&Fs28N&OuDBU3?>)l6 +bc!#f{p@D_bU0QSFk@Vk8zq^21Q0O1_p)_{ilon|NG21IhKJT|L>o5D`zuK%~gJC<+=Ii +zjxFDrre11~o8UX~^*sr`-ND)CA`-a`g{vlPsQ4ms_SS~eoI5Q;loOk08+!D2evoWh +za^cV`_b30BuKD=6`BwT2=4;0@BCk29bN`)lS>&4=``*}-hYFe|Np9+Tq~OEO|Ip}x +zJ4;5zolM)LTaTWs>#-B)sg`FET(veqcGtO$>Jl-LZ7YVQ4>WuO;!puhEVbK`;3BdWnazD_hVWL>)9UH-uWUw59169<{qE8fUY +zo&R5eQJdjSaq#lL`_|PMO3mNiYnWFsZ@F^(8;#Sg7pKnXs?(bINxk&DxBzBB&b +zSbuc_{}AvSO=2{V-+t2s#$OCG2V;Pp`LJObFuO6V(c5G(m3T!1071TaDPc176 +z%r3#|+u3QZtfaEW{3%z$%QU-cGO>PfMsWxu0c{gkG*2F%lPd=M1Y0KMdb1z~F#!dT +z0hR!nlZ*pGlY9kID9q|Q?7#p305pfRGwmY1>Hq(WLc?9R2t|ec6RBZT@27Sz` +zOOUBo_werj4>Y!M_jnW_X5LT!U5BJX(|7z_`gvmiFY#+&QGZnQ(jc275rI8N1mYN% +z7v%B{<<#dXY{%}<@y#~8tP9hXhdGhPLXas^?`1i>3YaIhBPV!{?OHspK+1tr-1sq_ +zOZO`ZH4#=PA*a;DhrzO(E3P%s2bvJ((;Hqp+UQEjk15npIGkF2Q$_0pB(dp;yn_5C +zKjIcSPFeWwJAX-pwI>0p^9vxJ5{vOrh0paF?UCzL@0Je2X%OGwl&9sLSXEoYL7KSi +z7kK;C!)?P%&jT1dJAlLZ%9j=5dAv$#2>cZVkYtBX;b +zKkd4%t<0bN;Bxyi9^Oz(*%pa{7z1UunHr0BY|UqQ4u5cp8OsHbC2P>hSGyMrvv_3u +zzQ@Tm#KWp1pTB~~5@51y#+rP&KL&li?#e9y5l&so-G1aJhbZ^bTDPy{ypVsyoJ$?4 +zJI$^(&-ERT{vFP-2wo#L3vt=>>|Qfkn-izOEp0os#}5b6I#&uf+o6-(AknAKCP^m+ +zEB^#2tYI)UL`(v`beQMaSJV*sS*EXE2$I<^GcOj!0Hii26j3aN*&gGTU5Zv+1i&@u +zjId2o5C}?3I%5GFBrU@lP*l(vtk2>ZTe5f +z$zE{PRc+w5GMeW^E4f@oa+%ryKCLFeKmd=m8Cq32;k}|hR%L!j^w4xxgPa6z%)Qy@ +zimjI||1RsAlMMk+M(8o4AFk??@Qc3})r~lth`4dR`1> +z^;L1tHfbGi`%8!rY(mS3KU@Hh&`z%=D3oy@J&z>elMn+h2}%2(tDpZ60W6XOI|uL2 +zV$Ccjl9Rv!HWZKL5CJQa1C*2A0vVHh0)H=n0rda{07K;b`Tzg` +l001+77wRp|PznG6*$#k!fCRGE)_JkSXZr#G00004Sz1dOv2XwY + +-- +2.36.1 + diff --git a/0084-tests-update-atari-partx-tests.patch b/0084-tests-update-atari-partx-tests.patch new file mode 100644 index 0000000..2d004cd --- /dev/null +++ b/0084-tests-update-atari-partx-tests.patch @@ -0,0 +1,55 @@ +From cf74ece6486dabfd4b84c90435348c04ff72ef54 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Tue, 13 Oct 2020 18:34:39 +0200 +Subject: tests: update atari partx tests + +Upstream: http://github.com/util-linux/util-linux/commit/017c0308c7d3b0d84bfc11e5863220bc32d640ba +Addresses: https://bugzilla.redhat.com/show_bug.cgi?id=2060030 +Signed-off-by: Karel Zak +--- + tests/expected/partx/partx-image-atari-icd | 7 ------- + tests/expected/partx/partx-image-atari-primary | 2 ++ + tests/expected/partx/partx-image-atari-xgm | 10 +++------- + 3 files changed, 5 insertions(+), 14 deletions(-) + delete mode 100644 tests/expected/partx/partx-image-atari-icd + create mode 100644 tests/expected/partx/partx-image-atari-primary + +diff --git a/tests/expected/partx/partx-image-atari-icd b/tests/expected/partx/partx-image-atari-icd +deleted file mode 100644 +index 8677dff03..000000000 +--- a/tests/expected/partx/partx-image-atari-icd ++++ /dev/null +@@ -1,7 +0,0 @@ +-NR START END SECTORS SIZE NAME UUID +- 1 65 4096 4032 2M +- 2 4097 5000 904 452K +- 4 12289 16384 4096 2M +- 5 5002 7000 1999 999.5K +- 6 7003 10240 3238 1.6M +- 7 10241 12288 2048 1M +diff --git a/tests/expected/partx/partx-image-atari-primary b/tests/expected/partx/partx-image-atari-primary +new file mode 100644 +index 000000000..044d319be +--- /dev/null ++++ b/tests/expected/partx/partx-image-atari-primary +@@ -0,0 +1,2 @@ ++NR START END SECTORS SIZE NAME UUID ++ 1 2 10239 10238 5M +diff --git a/tests/expected/partx/partx-image-atari-xgm b/tests/expected/partx/partx-image-atari-xgm +index 248d6a56a..557327c04 100644 +--- a/tests/expected/partx/partx-image-atari-xgm ++++ b/tests/expected/partx/partx-image-atari-xgm +@@ -1,7 +1,3 @@ +-NR START END SECTORS SIZE NAME UUID +- 1 65 4096 4032 2M +- 2 4097 5000 904 452K +- 3 5002 7000 1999 999.5K +- 4 7003 10240 3238 1.6M +- 5 10241 12288 2048 1M +- 6 12289 16384 4096 2M ++NR START END SECTORS SIZE NAME UUID ++ 1 2 10 9 4.5K ++ 2 14 10239 10226 5M +-- +2.36.1 + diff --git a/1001-hwclock-make-glibc-2.31-compatible.patch b/1001-hwclock-make-glibc-2.31-compatible.patch deleted file mode 100644 index d4908a6..0000000 --- a/1001-hwclock-make-glibc-2.31-compatible.patch +++ /dev/null @@ -1,161 +0,0 @@ -From e42f9f05a96c9e0129722b15fc638d4133ac1ecb Mon Sep 17 00:00:00 2001 -From: J William Piggott -Date: Tue, 19 Apr 2022 23:22:11 -0400 -Subject: [PATCH] hwclock: make glibc 2.31 compatible -______________________________________________________ -GNU C Library NEWS -- history of user-visible changes. -Version 2.31 -Deprecated and removed features, and other changes affecting compatibility: - -* The settimeofday function can still be used to set a system-wide time - zone when the operating system supports it. This is because the Linux - kernel reused the API, on some architectures, to describe a system-wide - time-zone-like offset between the software clock maintained by the kernel, - and the "RTC" clock that keeps time when the system is shut down. - - However, to reduce the odds of this offset being set by accident, - settimeofday can no longer be used to set the time and the offset - simultaneously. If both of its two arguments are non-null, the call - will fail (setting errno to EINVAL). - - Callers attempting to set this offset should also be prepared for the call - to fail and set errno to ENOSYS; this already happens on the Hurd and on - some Linux architectures. The Linux kernel maintainers are discussing a - more principled replacement for the reused API. After a replacement - becomes available, we will change settimeofday to fail with ENOSYS on all - platforms when its 'tzp' argument is not a null pointer. - - settimeofday itself is obsolescent according to POSIX. Programs that set - the system time should use clock_settime and/or the adjtime family of - functions instead. We may cease to make settimeofday available to newly - linked binaries after there is a replacement for Linux's time-zone-like - offset API. -______________________________________________________ - -hwclock(8) had one settimeofday(2) call where both args were set for ---hctosys when the RTC was ticking UTC. This allowed setting the system -time, timezone, and locking the warp_clock function with a single call. -That operation now takes 3 calls of settimeofday(2). - -Although this common operation now takes three calls, the overall logic -for the set_system_clock() function was simplified. - -Co-Author: Karel Zak -Signed-off-by: J William Piggott ---- - sys-utils/hwclock.c | 70 ++++++++++++++++++++++----------------------- - 1 file changed, 35 insertions(+), 35 deletions(-) - -diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c -index b83e710..19e7410 100644 ---- a/sys-utils/hwclock.c -+++ b/sys-utils/hwclock.c -@@ -583,28 +583,28 @@ display_time(struct timeval hwctime) - * tz.tz_minuteswest argument and sets PCIL (see below). At boot settimeofday(2) - * has one-shot access to this function as shown in the table below. - * -- * +-------------------------------------------------------------------+ -- * | settimeofday(tv, tz) | -- * |-------------------------------------------------------------------| -- * | Arguments | System Time | PCIL | | warp_clock | -- * | tv | tz | set | warped | set | firsttime | locked | -- * |---------|---------|---------------|------|-----------|------------| -- * | pointer | NULL | yes | no | no | 1 | no | -- * | pointer | pointer | yes | no | no | 0 | yes | -- * | NULL | ptr2utc | no | no | no | 0 | yes | -- * | NULL | pointer | no | yes | yes | 0 | yes | -- * +-------------------------------------------------------------------+ -+ * +-------------------------------------------------------------------------+ -+ * | settimeofday(tv, tz) | -+ * |-------------------------------------------------------------------------| -+ * | Arguments | System Time | TZ | PCIL | | warp_clock | -+ * | tv | tz | set | warped | set | set | firsttime | locked | -+ * |---------|---------|---------------|-----|------|-----------|------------| -+ * | pointer | NULL | yes | no | no | no | 1 | no | -+ * | NULL | ptr2utc | no | no | yes | no | 0 | yes | -+ * | NULL | pointer | no | yes | yes | yes | 0 | yes | -+ * +-------------------------------------------------------------------------+ - * ptr2utc: tz.tz_minuteswest is zero (UTC). - * PCIL: persistent_clock_is_local, sets the "11 minute mode" timescale. - * firsttime: locks the warp_clock function (initialized to 1 at boot). -+ * Since glibc v2.31 settimeofday() will fail if both args are non NULL - * - * +---------------------------------------------------------------------------+ - * | op | RTC scale | settimeofday calls | - * |---------|-----------|-----------------------------------------------------| - * | systz | Local | 1) warps system time*, sets PCIL* and kernel tz | - * | systz | UTC | 1st) locks warp_clock* 2nd) sets kernel tz | -- * | hctosys | Local | 1st) sets PCIL* 2nd) sets system time and kernel tz | -- * | hctosys | UTC | 1) sets system time and kernel tz | -+ * | hctosys | Local | 1st) sets PCIL* & kernel tz 2nd) sets system time | -+ * | hctosys | UTC | 1st) locks warp* 2nd) sets tz 3rd) sets system time | - * +---------------------------------------------------------------------------+ - * * only on first call after boot - */ -@@ -615,41 +615,41 @@ set_system_clock(const struct hwclock_control *ctl, - struct tm broken; - int minuteswest; - int rc = 0; -- const struct timezone tz_utc = { 0 }; - - localtime_r(&newtime.tv_sec, &broken); - minuteswest = -get_gmtoff(&broken) / 60; - - if (ctl->verbose) { -- if (ctl->hctosys && !ctl->universal) -- printf(_("Calling settimeofday(NULL, %d) to set " -- "persistent_clock_is_local.\n"), minuteswest); -- if (ctl->systz && ctl->universal) -+ if (ctl->universal) { - puts(_("Calling settimeofday(NULL, 0) " -- "to lock the warp function.")); -+ "to lock the warp_clock function.")); -+ if (!( ctl->universal && !minuteswest )) -+ printf(_("Calling settimeofday(NULL, %d) " -+ "to set the kernel timezone.\n"), -+ minuteswest); -+ } else -+ printf(_("Calling settimeofday(NULL, %d) to warp " -+ "System time, set PCIL and the kernel tz.\n"), -+ minuteswest); -+ - if (ctl->hctosys) -- printf(_("Calling settimeofday(%ld.%06ld, %d)\n"), -- newtime.tv_sec, newtime.tv_usec, minuteswest); -- else { -- printf(_("Calling settimeofday(NULL, %d) "), minuteswest); -- if (ctl->universal) -- puts(_("to set the kernel timezone.")); -- else -- puts(_("to warp System time.")); -- } -+ printf(_("Calling settimeofday(%ld.%06ld, NULL) " -+ "to set the System time.\n"), -+ newtime.tv_sec, newtime.tv_usec); - } - - if (!ctl->testing) { -+ const struct timezone tz_utc = { 0 }; - const struct timezone tz = { minuteswest }; -- -- if (ctl->hctosys && !ctl->universal) /* set PCIL */ -- rc = settimeofday(NULL, &tz); -- if (ctl->systz && ctl->universal) /* lock warp_clock */ -+ /* If UTC RTC: lock warp_clock and PCIL */ -+ if (ctl->universal) - rc = settimeofday(NULL, &tz_utc); -- if (!rc && ctl->hctosys) -- rc = settimeofday(&newtime, &tz); -- else if (!rc) -+ /* Set kernel tz; if localtime RTC: warp_clock and set PCIL */ -+ if (!rc && !( ctl->universal && !minuteswest )) - rc = settimeofday(NULL, &tz); -+ /* Set the System Clock */ -+ if ((!rc || errno == ENOSYS) && ctl->hctosys) -+ rc = settimeofday(&newtime, NULL); - - if (rc) { - warn(_("settimeofday() failed")); --- -2.27.0 - diff --git a/1002-add-Neoverse-N2-to-ARM-identifiers-tables.patch b/1002-add-Neoverse-N2-to-ARM-identifiers-tables.patch deleted file mode 100644 index 9b6afb1..0000000 --- a/1002-add-Neoverse-N2-to-ARM-identifiers-tables.patch +++ /dev/null @@ -1,24 +0,0 @@ -From dc11290085e49ec47be148447104f50ce3e7244b Mon Sep 17 00:00:00 2001 -From: rpm-build -Date: Tue, 27 Sep 2022 11:21:16 +0800 -Subject: [PATCH] add Neoverse-N2 to ARM identifiers tables - ---- - sys-utils/lscpu-arm.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/sys-utils/lscpu-arm.c b/sys-utils/lscpu-arm.c -index 2b178a7..697a4b2 100644 ---- a/sys-utils/lscpu-arm.c -+++ b/sys-utils/lscpu-arm.c -@@ -80,6 +80,7 @@ static const struct id_part arm_part[] = { - { 0xd21, "Cortex-M33" }, - { 0xd41, "Cortex-A78" }, - { 0xd42, "Cortex-A78AE" }, -+ { 0xd49, "Neoverse-N2" }, - { 0xd4a, "Neoverse-E1" }, - { 0xd4b, "Cortex-A78C" }, - { -1, "unknown" }, --- -2.31.1 - diff --git a/1003-fix-lscpu-to-get-cpu-frequency-from-cpuinfo-on-arm64.patch b/1003-fix-lscpu-to-get-cpu-frequency-from-cpuinfo-on-arm64.patch deleted file mode 100644 index 1893c87..0000000 --- a/1003-fix-lscpu-to-get-cpu-frequency-from-cpuinfo-on-arm64.patch +++ /dev/null @@ -1,24 +0,0 @@ -From 117b51eb538673be49bf0e619d2307a65963d1dd Mon Sep 17 00:00:00 2001 -From: rpm-build -Date: Tue, 27 Sep 2022 15:31:51 +0800 -Subject: [PATCH] fix lscpu to get cpu frequency from cpuinfo on arm64 - ---- - sys-utils/lscpu.c | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/sys-utils/lscpu.c b/sys-utils/lscpu.c -index 70a797d..a7014a0 100644 ---- a/sys-utils/lscpu.c -+++ b/sys-utils/lscpu.c -@@ -433,6 +433,7 @@ read_basicinfo(struct lscpu_desc *desc, struct lscpu_modifier *mod) - else if (lookup(buf, "stepping", &desc->stepping)) ; - else if (lookup(buf, "CPU variant", &desc->stepping)) ; /* aarch64 */ - else if (lookup(buf, "cpu MHz", &desc->mhz)) ; -+ else if (lookup(buf, "CPU MHz", &desc->mhz)) ; /* aarch64 */ - else if (lookup(buf, "cpu MHz dynamic", &desc->dynamic_mhz)) ; /* s390 */ - else if (lookup(buf, "cpu MHz static", &desc->static_mhz)) ; /* s390 */ - else if (lookup(buf, "flags", &desc->flags)) ; /* x86 */ --- -2.31.1 - diff --git a/dist b/dist new file mode 100644 index 0000000..9c0e36e --- /dev/null +++ b/dist @@ -0,0 +1 @@ +an8 diff --git a/util-linux.spec b/util-linux.spec index dcad610..09a9cf1 100644 --- a/util-linux.spec +++ b/util-linux.spec @@ -1,9 +1,8 @@ -%define anolis_release .0.3 ### Header Summary: A collection of basic system utilities Name: util-linux Version: 2.32.1 -Release: 35%{anolis_release}%{?dist} +Release: 38%{?dist} License: GPLv2 and GPLv2+ and LGPLv2+ and BSD with advertising and Public Domain Group: System Environment/Base URL: http://en.wikipedia.org/wiki/Util-linux @@ -54,6 +53,7 @@ Source2: util-linux-remote.pamd Source3: util-linux-chsh-chfn.pamd Source4: util-linux-60-raw.rules Source5: adjtime +Source6: uuidd-tmpfiles.conf Source12: util-linux-su.pamd Source13: util-linux-su-l.pamd Source14: util-linux-runuser.pamd @@ -245,12 +245,22 @@ Patch74: 0074-Complete-Linux-PAM-compliance-for-forked-child-in-su.patch # 2058176 - losetup Retry LOOP_SET_STATUS64 on EAGAIN Patch75: 0075-lib-loopdev-retry-LOOP_SET_STATUS64-and-LOOP_SET_BLO.patch -# Begin: Anolis customized patches -# hwclock: make glibc 2.31 compatible -Patch1001: 1001-hwclock-make-glibc-2.31-compatible.patch -Patch1002: 1002-add-Neoverse-N2-to-ARM-identifiers-tables.patch -Patch1003: 1003-fix-lscpu-to-get-cpu-frequency-from-cpuinfo-on-arm64.patch -# End: Anolis customized patches +### RHEL-8.7 +### +# 2060030 - Please backport patches for atari partition detection to RHEL 8 +Patch76: 0076-libblkid-fix-Atari-prober-logic.patch +Patch77: 0077-libblkid-make-Atari-more-robust.patch +Patch78: 0078-libblkid-allow-a-lot-of-mac-partitions.patch +Patch79: 0079-libblkid-limit-amount-of-parsed-partitions.patch +Patch80: 0080-libblkid-mac-make-sure-block-size-is-large-enough-fu.patch +# 2069187 - Internal testsuite for lscpu failed on aarch64 +Patch81: 0081-lscpu-don-t-read-from-HW-when-use-sys-snapshot.patch +# 2093166 - lslogins reports incorrect "Password is locked" status +Patch82: 0082-lslogins-improve-prefixes-interpretation.patch +# 2060030 - Please backport patches for atari partition detection to RHEL 8 +Patch83: 0083-tests-update-atari-blkid-tests.patch +Patch84: 0084-tests-update-atari-partx-tests.patch + %description The util-linux package contains a large variety of low-level system @@ -486,9 +496,7 @@ mkdir -p ${RPM_BUILD_ROOT}%{_bindir} mkdir -p ${RPM_BUILD_ROOT}%{_mandir}/man{1,6,8,5} mkdir -p ${RPM_BUILD_ROOT}%{_sbindir} mkdir -p ${RPM_BUILD_ROOT}%{_sysconfdir}/{pam.d,security/console.apps} -mkdir -p ${RPM_BUILD_ROOT}/var/log -touch ${RPM_BUILD_ROOT}/var/log/lastlog -chmod 0664 ${RPM_BUILD_ROOT}/var/log/lastlog +mkdir -p ${RPM_BUILD_ROOT}%{_tmpfilesdir} # install util-linux make install DESTDIR=${RPM_BUILD_ROOT} @@ -507,6 +515,7 @@ echo '.so man8/raw.8' > $RPM_BUILD_ROOT%{_mandir}/man8/rawdevices.8 mv ${RPM_BUILD_ROOT}%{_sbindir}/raw ${RPM_BUILD_ROOT}%{_bindir}/raw # And a dirs uuidd needs that the makefiles don't create +install -m 644 %{SOURCE6} ${RPM_BUILD_ROOT}%{_tmpfilesdir}/uuidd.conf install -d ${RPM_BUILD_ROOT}/run/uuidd install -d ${RPM_BUILD_ROOT}/var/lib/libuuid @@ -594,22 +603,6 @@ find $RPM_BUILD_ROOT%{_mandir}/man8 -regextype posix-egrep \ -printf "%{_mandir}/man8/%f*\n" >> %{name}.files %post -# only for minimal buildroots without /var/log -[ -d /var/log ] || mkdir -p /var/log -touch /var/log/lastlog -chown root:utmp /var/log/lastlog -chmod 0664 /var/log/lastlog -# Fix the file context, do not use restorecon -if [ -x /usr/sbin/selinuxenabled ] && /usr/sbin/selinuxenabled; then - SECXT=$( /usr/sbin/matchpathcon -n /var/log/lastlog 2> /dev/null ) - if [ -n "$SECXT" ]; then - # Selinux enabled, but without policy? It's true for buildroots - # without selinux stuff on host machine with enabled selinux. - # We don't want to use any RPM dependence on selinux policy for - # matchpathcon(2). SELinux policy should be optional. - /usr/bin/chcon "$SECXT" /var/log/lastlog >/dev/null 2>&1 || : - fi -fi if [ ! -L /etc/mtab ]; then ln -sf ../proc/self/mounts /etc/mtab || : fi @@ -687,7 +680,6 @@ fi %attr(755,root,root) %{_bindir}/login %attr(2755,root,tty) %{_bindir}/write -%ghost %attr(0664,root,utmp) %verify(not md5 size mtime) /var/log/lastlog %ghost %verify(not md5 size mtime) %config(noreplace,missingok) /etc/mtab %{_unitdir}/fstrim.* @@ -1030,6 +1022,7 @@ fi %dir %attr(2775, uuidd, uuidd) /var/lib/libuuid %dir %attr(2775, uuidd, uuidd) /run/uuidd %{compldir}/uuidd +%{_tmpfilesdir}/uuidd.conf %files -n libfdisk @@ -1116,14 +1109,18 @@ fi %{_libdir}/python*/site-packages/libmount/ %changelog -* Tue Sep 27 2022 Forrestly 2.32.1-35.0.3 -- [Patch] lscpu: fix lscpu to get cpu frequency from cpuinfo on arm64 - -* Tue Sep 27 2022 Forrestly 2.32.1-35.0.2 -- [Patch] lscpu: add Neoverse-N2 to ARM identifiers tables - -* Tue May 17 2022 Weitao Zhou 2.32.1-35.0.1 -- [Patch] hwclock: better compatibility for both glibc2.28 and glibc2.31 +* Mon Aug 22 2022 Karel Zak 2.32.1-38 +- improve tmpfiles.d use in spec file (related to #2059241) + +* Fri Jul 15 2022 Karel Zak 2.32.1-37 +- update atari partition tests (related to #2060030) + +* Thu Jul 14 2022 Karel Zak 2.32.1-36 +- fix #2060030 - Please backport patches for atari partition detection to RHEL 8 +- fix #2069187 - Internal testsuite for lscpu failed on aarch64 +- fix #2093166 - lslogins reports incorrect "Password is locked" status +- fix #2059241 - rpm -V / --verify reports bad user/group/mtime for /run/uuidd +- fix #2044592 - Move /var/log/lastlog ownership to systemd * Tue Mar 08 2022 Karel Zak 2.32.1-35 - fix #2058176 - losetup Retry LOOP_SET_STATUS64 on EAGAIN diff --git a/uuidd-tmpfiles.conf b/uuidd-tmpfiles.conf new file mode 100644 index 0000000..4158c7d --- /dev/null +++ b/uuidd-tmpfiles.conf @@ -0,0 +1 @@ +d /run/uuidd 2775 uuidd uuidd -- Gitee