Skip to content

Commit a9a1710

Browse files
rhvgoyalH. Peter Anvin
authored andcommitted
x86, boot: Remove misc.h inclusion from compressed/string.c
Given the fact that we removed inclusion of boot.h from boot/string.c does not look like we need misc.h inclusion in compressed/string.c. So remove it. misc.h was also pulling in string_32.h which in turn had macros for memcmp and memcpy. So we don't need to #undef memcmp and memcpy anymore. Signed-off-by: Vivek Goyal <vgoyal@redhat.com> Link: http://lkml.kernel.org/r/1398447972-27896-3-git-send-email-vgoyal@redhat.com Signed-off-by: H. Peter Anvin <hpa@zytor.com>
1 parent 3d37922 commit a9a1710

2 files changed

Lines changed: 0 additions & 10 deletions

File tree

‎arch/x86/boot/compressed/string.c‎

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
1-
#include "misc.h"
21
#include "../string.c"
32

4-
/* misc.h might pull in string_32.h which has a macro for memcpy. undef that */
5-
#undef memcpy
6-
73
#ifdef CONFIG_X86_32
84
void *memcpy(void *dest, const void *src, size_t n)
95
{

‎arch/x86/boot/string.c‎

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,6 @@
1515
#include <linux/types.h>
1616
#include "ctype.h"
1717

18-
/*
19-
* This file gets included in compressed/string.c which might pull in
20-
* string_32.h and which in turn maps memcmp to __builtin_memcmp(). Undo
21-
* that first.
22-
*/
23-
#undef memcmp
2418
int memcmp(const void *s1, const void *s2, size_t len)
2519
{
2620
u8 diff;

0 commit comments

Comments
 (0)