51d660957625eb2c0eea93f4bd8a861357fc366d
[feed/packages.git] / utils / btrfs-progs / patches / 010-64bit.patch
1 From b5159062f079d451f23d7f2a0e7d9e2f84934f94 Mon Sep 17 00:00:00 2001
2 From: Rosen Penev <rosenp@gmail.com>
3 Date: Sat, 29 Jan 2022 17:09:56 -0800
4 Subject: [PATCH] btrfs-progs: fix 64-bit mips and powerpc types
5
6 The kernel uses 'unsigned long' for u64 specifically for ppc64 and
7 mips64.
8
9 Remove asm/types.h include as it will get included properly later.
10
11 Fixe -Wformat warnings.
12
13 Signed-off-by: Rosen Penev <rosenp@gmail.com>
14 Signed-off-by: David Sterba <dsterba@suse.com>
15 ---
16 cmds/receive-dump.c | 1 -
17 kerncompat.h | 5 +++++
18 2 files changed, 5 insertions(+), 1 deletion(-)
19
20 --- a/cmds/receive-dump.c
21 +++ b/cmds/receive-dump.c
22 @@ -31,7 +31,6 @@
23 #include <stdlib.h>
24 #include <time.h>
25 #include <ctype.h>
26 -#include <asm/types.h>
27 #include <uuid/uuid.h>
28 #include "common/utils.h"
29 #include "cmds/commands.h"
30 --- a/kerncompat.h
31 +++ b/kerncompat.h
32 @@ -19,6 +19,11 @@
33 #ifndef __KERNCOMPAT_H__
34 #define __KERNCOMPAT_H__
35
36 +#ifndef __SANE_USERSPACE_TYPES__
37 +/* For PPC64 to get LL64 types */
38 +#define __SANE_USERSPACE_TYPES__
39 +#endif
40 +
41 #include <stdio.h>
42 #include <stdlib.h>
43 #include <errno.h>