From owner-svn-src-head@freebsd.org Thu May 28 08:18:35 2020 Return-Path: Delivered-To: svn-src-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 6CB0932A358; Thu, 28 May 2020 08:18:35 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49XgZM2Kpnz48pK; Thu, 28 May 2020 08:18:35 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4B4DD230EA; Thu, 28 May 2020 08:18:35 +0000 (UTC) (envelope-from royger@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 04S8IZN0075813; Thu, 28 May 2020 08:18:35 GMT (envelope-from royger@FreeBSD.org) Received: (from royger@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 04S8IZ7q075812; Thu, 28 May 2020 08:18:35 GMT (envelope-from royger@FreeBSD.org) Message-Id: <202005280818.04S8IZ7q075812@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: royger set sender to royger@FreeBSD.org using -f From: =?UTF-8?Q?Roger_Pau_Monn=c3=a9?= Date: Thu, 28 May 2020 08:18:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r361578 - head/sys/x86/xen X-SVN-Group: head X-SVN-Commit-Author: royger X-SVN-Commit-Paths: head/sys/x86/xen X-SVN-Commit-Revision: 361578 X-SVN-Commit-Repository: base MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-head@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for the src tree for head/-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 28 May 2020 08:18:35 -0000 Author: royger Date: Thu May 28 08:18:34 2020 New Revision: 361578 URL: https://svnweb.freebsd.org/changeset/base/361578 Log: xenpv: do not use low 1MB for Xen mappings on i386 On amd64 we already avoid using memory below 4GB in order to prevent clashes with MMIO regions, but i386 was allowed to use any hole in the physical memory map in order to map Xen pages. Limit this to memory above the 1MB boundary on i386 in order to avoid clashes with the MMIO holes in that area. Sponsored by: Citrix Systems R&D MFC after: 1 week Modified: head/sys/x86/xen/xenpv.c Modified: head/sys/x86/xen/xenpv.c ============================================================================== --- head/sys/x86/xen/xenpv.c Thu May 28 08:05:46 2020 (r361577) +++ head/sys/x86/xen/xenpv.c Thu May 28 08:18:34 2020 (r361578) @@ -54,12 +54,14 @@ __FBSDID("$FreeBSD$"); * prevent clashes with MMIO/ACPI regions. * * Since this is not possible on i386 just use any available memory - * chunk and hope we don't clash with anything else. + * chunk above 1MB and hope we don't clash with anything else. */ #ifdef __amd64__ #define LOW_MEM_LIMIT 0x100000000ul +#elif defined(__i386__) +#define LOW_MEM_LIMIT 0x100000ul #else -#define LOW_MEM_LIMIT 0 +#error "Unsupported architecture" #endif static devclass_t xenpv_devclass;