summaryrefslogtreecommitdiff
path: root/arch/x86/boot/compressed/string.c
blob: 212004ec787de87e788b94a00f5b15bfc055b585 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#include "misc.h"

/* Avoid intereference from any defines in string_32.h */
#undef memcmp
int memcmp(const void *s1, const void *s2, size_t len)
{
	u8 diff;
	asm("repe; cmpsb; setnz %0"
	    : "=qm" (diff), "+D" (s1), "+S" (s2), "+c" (len));
	return diff;
}

#include "../string.c"