Date: Sun, 25 Aug 2019 20:57:39 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r351494 - head/sys/amd64/amd64 Message-ID: <201908252057.x7PKvdtU082416@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: kib Date: Sun Aug 25 20:57:39 2019 New Revision: 351494 URL: https://svnweb.freebsd.org/changeset/base/351494 Log: amd64: If domain-local page for pcpu cannot be allocated, keep use existing one. Allocation failure is possible for instance when cpu domain has no memory. Reported and tested by: bcran Reviewed by: markj Sponsored by: The FreeBSD Foundation Modified: head/sys/amd64/amd64/mp_machdep.c Modified: head/sys/amd64/amd64/mp_machdep.c ============================================================================== --- head/sys/amd64/amd64/mp_machdep.c Sun Aug 25 20:36:52 2019 (r351493) +++ head/sys/amd64/amd64/mp_machdep.c Sun Aug 25 20:57:39 2019 (r351494) @@ -402,6 +402,8 @@ mp_realloc_pcpu(int cpuid, int domain) return; m = vm_page_alloc_domain(NULL, 0, domain, VM_ALLOC_NORMAL | VM_ALLOC_NOOBJ); + if (m == NULL) + return; na = PHYS_TO_DMAP(VM_PAGE_TO_PHYS(m)); pagecopy((void *)oa, (void *)na); pmap_qenter((vm_offset_t)&__pcpu[cpuid], &m, 1);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201908252057.x7PKvdtU082416>