From owner-freebsd-hackers@freebsd.org Thu Jan 25 16:52:38 2018 Return-Path: Delivered-To: freebsd-hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 17A4DEBEC82 for ; Thu, 25 Jan 2018 16:52:38 +0000 (UTC) (envelope-from Hartmut.Brandt@dlr.de) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id A5735863A0 for ; Thu, 25 Jan 2018 16:52:37 +0000 (UTC) (envelope-from Hartmut.Brandt@dlr.de) Received: by mailman.ysv.freebsd.org (Postfix) id 5FE42EBEC7D; Thu, 25 Jan 2018 16:52:37 +0000 (UTC) Delivered-To: hackers@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 4C1ADEBEC7C for ; Thu, 25 Jan 2018 16:52:37 +0000 (UTC) (envelope-from Hartmut.Brandt@dlr.de) Received: from mailhost.dlr.de (mailhost.dlr.de [129.247.252.33]) (using TLSv1 with cipher ECDHE-RSA-AES256-SHA (256/256 bits)) (Client CN "mailhost.dlr.de", Issuer "DLR CA - G02" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id C0F878639F for ; Thu, 25 Jan 2018 16:52:36 +0000 (UTC) (envelope-from Hartmut.Brandt@dlr.de) Received: from DLREXHUB01.intra.dlr.de (172.21.152.130) by mailhost.dlr.de (172.21.163.101) with Microsoft SMTP Server (TLS) id 14.3.361.1; Thu, 25 Jan 2018 17:52:23 +0100 Received: from KNOP-BEAGLE.kn.op.dlr.de (129.247.178.136) by smtp.dlr.de (172.21.152.151) with Microsoft SMTP Server (TLS) id 14.3.361.1; Thu, 25 Jan 2018 17:52:28 +0100 Date: Thu, 25 Jan 2018 17:52:57 +0100 From: Hartmut Brandt X-X-Sender: brandt_h@KNOP-BEAGLE.kn.op.dlr.de To: Subject: allocating large piece of contiguous kernel memory Message-ID: User-Agent: Alpine 2.20 (BSF 67 2015-01-07) MIME-Version: 1.0 Content-Type: text/plain; format=flowed; charset="US-ASCII" X-TM-AS-Product-Ver: SMEX-11.0.0.4283-8.100.1062-23620.000 X-TM-AS-Result: No--0.126000-5.000000-31 X-TM-AS-MatchedID: 708712-708060-705262-708218-861157-303277-705388-709584-1 48004-148050-10018-41000-42000-42003-63 X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.25 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Jan 2018 16:52:38 -0000 Hi all, for a device driver communicating with an FPGA I would like to allocate an 8GByte piece or two 4GByte pieces of contiguous memory in the device driver. The machine is amd64 and has 256GByte. The maximum I can allocate is 512MByte. If I try more (in one piece or in two pieces) contigfree() crashes in pmap_resident_count_dec() with an "pmap resident count underflow". Is this something which is not supposed to work? Or is there something tunable or is this a bug? Regards, harti