parent
caa3318d49
commit
dfde8dec4c
36
util-linux-2.21-lscpu-SIGFPE.patch
Normal file
36
util-linux-2.21-lscpu-SIGFPE.patch
Normal file
@ -0,0 +1,36 @@
|
||||
diff -up util-linux-2.21.2/sys-utils/lscpu.c.kzak util-linux-2.21.2/sys-utils/lscpu.c
|
||||
--- util-linux-2.21.2/sys-utils/lscpu.c.kzak 2012-05-25 11:44:59.041195655 +0200
|
||||
+++ util-linux-2.21.2/sys-utils/lscpu.c 2012-11-16 11:50:59.350150439 +0100
|
||||
@@ -605,16 +605,26 @@ read_topology(struct lscpu_desc *desc, i
|
||||
|
||||
/* threads within one core */
|
||||
nthreads = CPU_COUNT_S(setsize, thread_siblings);
|
||||
+ if (!nthreads)
|
||||
+ nthreads = 1;
|
||||
+
|
||||
/* cores within one socket */
|
||||
ncores = CPU_COUNT_S(setsize, core_siblings) / nthreads;
|
||||
- /* number of sockets within one book.
|
||||
- * Because of odd / non-present cpu maps and to keep
|
||||
- * calculation easy we make sure that nsockets and
|
||||
- * nbooks is at least 1.
|
||||
+ if (!ncores)
|
||||
+ ncores = 1;
|
||||
+
|
||||
+ /* number of sockets within one book. Because of odd /
|
||||
+ * non-present cpu maps and to keep calculation easy we make
|
||||
+ * sure that nsockets and nbooks is at least 1.
|
||||
*/
|
||||
- nsockets = desc->ncpus / nthreads / ncores ?: 1;
|
||||
+ nsockets = desc->ncpus / nthreads / ncores;
|
||||
+ if (!nsockets)
|
||||
+ nsockets = 1;
|
||||
+
|
||||
/* number of books */
|
||||
- nbooks = desc->ncpus / nthreads / ncores / nsockets ?: 1;
|
||||
+ nbooks = desc->ncpus / nthreads / ncores / nsockets;
|
||||
+ if (!nbooks)
|
||||
+ nbooks = 1;
|
||||
|
||||
/* all threads, see also read_basicinfo()
|
||||
* -- fallback for kernels without
|
36
util-linux-2.21-mount-commas.patch
Normal file
36
util-linux-2.21-mount-commas.patch
Normal file
@ -0,0 +1,36 @@
|
||||
From 5e7b834002aa0ce97a1b0104e8710664ad954595 Mon Sep 17 00:00:00 2001
|
||||
From: Dave Reisner <dreisner@archlinux.org>
|
||||
Date: Sun, 3 Jun 2012 12:25:47 -0400
|
||||
Subject: [PATCH] libmount: trim leading commas from each options string
|
||||
|
||||
Fixes a bug in option string parsing wherein a line such as:
|
||||
|
||||
ro,relatime,,nosuid,nodev
|
||||
|
||||
Will be seen as only the tokens "ro" and "relatime" after the parser
|
||||
encounters a zero length (and erroneously declared NULL) option.
|
||||
|
||||
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
|
||||
---
|
||||
libmount/src/optstr.c | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/libmount/src/optstr.c b/libmount/src/optstr.c
|
||||
index af5953b..66d2a06 100644
|
||||
--- a/libmount/src/optstr.c
|
||||
+++ b/libmount/src/optstr.c
|
||||
@@ -62,6 +62,11 @@ static int mnt_optstr_parse_next(char **optstr, char **name, size_t *namesz,
|
||||
if (valsz)
|
||||
*valsz = 0;
|
||||
|
||||
+ /* trim leading commas as to not invalidate option
|
||||
+ * strings with multiple consecutive commas */
|
||||
+ while (optstr0 && *optstr0 == ',')
|
||||
+ optstr0++;
|
||||
+
|
||||
for (p = optstr0; p && *p; p++) {
|
||||
if (!start)
|
||||
start = p; /* begin of the option item */
|
||||
--
|
||||
1.7.11.7
|
||||
|
@ -2,7 +2,7 @@
|
||||
Summary: A collection of basic system utilities
|
||||
Name: util-linux
|
||||
Version: 2.21.2
|
||||
Release: 2%{?dist}
|
||||
Release: 3%{?dist}
|
||||
License: GPLv2 and GPLv2+ and GPLv3+ and LGPLv2+ and BSD with advertising and Public Domain
|
||||
Group: System Environment/Base
|
||||
URL: http://kernel.org/~kzak/util-linux/
|
||||
@ -83,6 +83,10 @@ Patch4: util-linux-2.21-ipcs-32bit.patch
|
||||
Patch5: util-linux-2.21-mount-sloppy.patch
|
||||
# 826122 - uuidd fails to start
|
||||
Patch6: util-linux-2.21-uuidd-rundir.patch
|
||||
# 873983 - mount: /dev/mapper/myvg-usrlv is already mounted or /usr busy
|
||||
Patch7: util-linux-2.21-mount-commas.patch
|
||||
# 875461 - read_topology: Process /usr/bin/lscpu was killed by signal 8 (SIGFPE)
|
||||
Patch8: util-linux-2.21-lscpu-SIGFPE.patch
|
||||
|
||||
%description
|
||||
The util-linux package contains a large variety of low-level system
|
||||
@ -715,6 +719,10 @@ fi
|
||||
|
||||
|
||||
%changelog
|
||||
* Fri Nov 16 2012 Karel Zak <kzak@redhat.com> 2.21.2-3
|
||||
- fix #873983 - mount: /dev/mapper/myvg-usrlv is already mounted or /usr busy
|
||||
- fix #875461 - read_topology: Process /usr/bin/lscpu was killed by signal 8 (SIGFPE)
|
||||
|
||||
* Mon Jun 18 2012 Karel Zak <kzak@redhat.com> 2.21.2-2
|
||||
- fix #825836 - Problems with automount map using quota
|
||||
- fix #826122 - uuidd fails to start
|
||||
|
Loading…
Reference in New Issue
Block a user