Remove dead code from the powerpc uma_small_alloc().

32-bit Book-E doesn't set UMA_MD_SMALL_ALLOC, and 32-bit OEA platforms
have a 32-bit vm_paddr_t.  Moreover, this code was wrong in that it
leaked the page if the check failed.

Reviewed by:	jhibbits
MFC after:	1 week
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D23991
This commit is contained in:
Mark Johnston 2020-03-06 20:44:22 +00:00
parent 7ba6f5493d
commit 3eac6de2f0

View File

@ -66,11 +66,6 @@ uma_small_alloc(uma_zone_t zone, vm_size_t bytes, int domain, u_int8_t *flags,
return (NULL);
pa = VM_PAGE_TO_PHYS(m);
/* On book-e sizeof(void *) < sizeof(vm_paddr_t) */
if ((vm_offset_t)pa != pa)
return (NULL);
#ifdef __powerpc64__
if ((wait & M_NODUMP) == 0)
dump_add_page(pa);