powerpc: retire bzero

Unused since ba96f37758 ("Use __builtin for various mem* and b* (e.g. bzero)
routines.")

Reviewed by:	jhibbits
Sponsored by:   Rubicon Communications, LLC ("Netgate")
This commit is contained in:
Mateusz Guzik 2021-08-23 16:19:03 +00:00
parent c69cc8d101
commit 11cb9a096c

View File

@ -836,44 +836,6 @@ DB_SHOW_COMMAND(frame, db_show_frame)
}
#endif
#undef bzero
void
bzero(void *buf, size_t len)
{
caddr_t p;
p = buf;
while (((vm_offset_t) p & (sizeof(u_long) - 1)) && len) {
*p++ = 0;
len--;
}
while (len >= sizeof(u_long) * 8) {
*(u_long*) p = 0;
*((u_long*) p + 1) = 0;
*((u_long*) p + 2) = 0;
*((u_long*) p + 3) = 0;
len -= sizeof(u_long) * 8;
*((u_long*) p + 4) = 0;
*((u_long*) p + 5) = 0;
*((u_long*) p + 6) = 0;
*((u_long*) p + 7) = 0;
p += sizeof(u_long) * 8;
}
while (len >= sizeof(u_long)) {
*(u_long*) p = 0;
len -= sizeof(u_long);
p += sizeof(u_long);
}
while (len) {
*p++ = 0;
len--;
}
}
/* __stack_chk_fail_local() is called in secure-plt (32-bit). */
#if !defined(__powerpc64__)
extern void __stack_chk_fail(void);