summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch
diff options
context:
space:
mode:
authorMaxin B. John <maxin.john@intel.com>2016-02-10 18:35:12 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-02-11 12:27:50 +0000
commitf0d5478de47cb7dd45141a279f067be869a2f4c5 (patch)
treeb342fcc0c9ddef95918745e9eceed377d0738422 /meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch
parent79d5041a9c9ff16ca254d99f87c9ad0f178d48e6 (diff)
downloadpoky-f0d5478de47cb7dd45141a279f067be869a2f4c5.tar.gz
mdadm: update to version 3.4
3.3.4 -> 3.4 a) Removed the following upstreamed patch: 1. 0001-Define-_POSIX_C_SOURCE-if-undefined.patch b) Added following patches to fix uclibc,musl and x32 build failures 1. 0001-mdadm.h-bswap-is-already-defined-in-uclibc.patch 2. 0001-util.c-include-poll.h-instead-of-sys-poll.h.patch 3. 0001-Fix-some-type-comparison-problems.patch 4. 0001-Fix-the-path-of-corosync-and-dlm-header-files-check.patch (From OE-Core rev: e1ae012388e4321b95cd79c014af135cf6c419ad) Signed-off-by: Maxin B. John <maxin.john@intel.com> Signed-off-by: Ross Burton <ross.burton@intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch')
-rw-r--r--meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch50
1 files changed, 50 insertions, 0 deletions
diff --git a/meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch b/meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch
new file mode 100644
index 0000000000..ee482b5ca0
--- /dev/null
+++ b/meta/recipes-extended/mdadm/files/0001-Fix-some-type-comparison-problems.patch
@@ -0,0 +1,50 @@
1From 835baf02fd42012bbc0603dffb1f80c6ecf0fb9e Mon Sep 17 00:00:00 2001
2From: Xiao Ni <xni@redhat.com>
3Date: Mon, 8 Feb 2016 11:18:52 +0200
4Subject: [PATCH] Fix some type comparison problems
5
6As 26714713cd2bad9e0bf7f4669f6cc4659ceaab6c said, 32 bit signed
7timestamps will overflow in the year 2038. It already changed the
8utime and ctime in struct mdu_array_info_s from int to unsigned
9int. So we need to change the values that compared with them to
10unsigned int too.
11
12Upstream-Status: Backport
13
14Signed-off-by : Xiao Ni <xni@redhat.com>
15Signed-off-by: Maxin B. John <maxin.john@intel.com>
16---
17
18 Monitor.c | 2 +-
19 util.c | 2 +-
20 2 files changed, 2 insertions(+), 2 deletions(-)
21
22diff --git a/Monitor.c b/Monitor.c
23index f19c2e5..6df80f9 100644
24--- a/Monitor.c
25+++ b/Monitor.c
26@@ -33,7 +33,7 @@
27 struct state {
28 char *devname;
29 char devnm[32]; /* to sync with mdstat info */
30- long utime;
31+ unsigned int utime;
32 int err;
33 char *spare_group;
34 int active, working, failed, spare, raid;
35diff --git a/util.c b/util.c
36index 3e6d293..96a806d 100644
37--- a/util.c
38+++ b/util.c
39@@ -1267,7 +1267,7 @@ struct supertype *guess_super_type(int fd, enum guess_types guess_type)
40 */
41 struct superswitch *ss;
42 struct supertype *st;
43- time_t besttime = 0;
44+ unsigned int besttime = 0;
45 int bestsuper = -1;
46 int i;
47
48--
492.4.0
50