From owner-freebsd-virtualization@freebsd.org Fri Apr 5 19:23:38 2019 Return-Path: Delivered-To: freebsd-virtualization@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 B3D9A1558F29 for ; Fri, 5 Apr 2019 19:23:38 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C67CC70424; Fri, 5 Apr 2019 19:23:37 +0000 (UTC) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (localhost [127.0.0.1]) by gndrsh.dnsmgr.net (8.13.3/8.13.3) with ESMTP id x35JNZFg040752; Fri, 5 Apr 2019 12:23:35 -0700 (PDT) (envelope-from freebsd-rwg@gndrsh.dnsmgr.net) Received: (from freebsd-rwg@localhost) by gndrsh.dnsmgr.net (8.13.3/8.13.3/Submit) id x35JNZbU040751; Fri, 5 Apr 2019 12:23:35 -0700 (PDT) (envelope-from freebsd-rwg) From: "Rodney W. Grimes" Message-Id: <201904051923.x35JNZbU040751@gndrsh.dnsmgr.net> Subject: Re: emulated PCI device BAR size In-Reply-To: To: Chuck Tuffli Date: Fri, 5 Apr 2019 12:23:35 -0700 (PDT) CC: Jason Tubnor , "freebsd-virtualization@freebsd.org" X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Rspamd-Queue-Id: C67CC70424 X-Spamd-Bar: + Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [1.95 / 15.00]; ARC_NA(0.00)[]; TO_DN_EQ_ADDR_SOME(0.00)[]; FROM_HAS_DN(0.00)[]; RCPT_COUNT_THREE(0.00)[3]; TO_DN_SOME(0.00)[]; IP_SCORE(0.03)[ip: (0.13), ipnet: 69.59.192.0/19(0.06), asn: 13868(0.04), country: US(-0.06)]; MIME_GOOD(-0.10)[text/plain]; RCVD_TLS_LAST(0.00)[]; DMARC_NA(0.00)[dnsmgr.net]; AUTH_NA(1.00)[]; NEURAL_SPAM_MEDIUM(0.57)[0.574,0]; RCVD_COUNT_THREE(0.00)[3]; TO_MATCH_ENVRCPT_SOME(0.00)[]; NEURAL_SPAM_SHORT(0.17)[0.170,0]; MX_GOOD(-0.01)[cached: gndrsh.dnsmgr.net]; NEURAL_SPAM_LONG(0.29)[0.288,0]; R_SPF_NA(0.00)[]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:13868, ipnet:69.59.192.0/19, country:US]; FREEMAIL_CC(0.00)[gmail.com]; MID_RHS_MATCH_FROM(0.00)[] X-BeenThere: freebsd-virtualization@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Discussion of various virtualization techniques FreeBSD supports." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 05 Apr 2019 19:23:38 -0000 > On Sat, Mar 23, 2019 at 6:44 PM Jason Tubnor wrote: > > > > > > > > On Sun., 24 Mar. 2019, 6:35 am Chuck Tuffli, wrote: > >> > >> On Mon, Mar 18, 2019 at 10:15 AM Chuck Tuffli wrote: > >> > >> > > >> > So my question is how to best fix this. The easiest would be to add a > >> > check to the BAR size calculation in pci_nvme.c along the lines of: > >> > #define NVME_MMIO_SPACE_MIN (1 << 14) > >> > ... > >> > pci_membar_sz = MAX( , > >> > NVME_MMIO_SPACE_MIN); > >> > >> I went down this route and have a patch up for review > >> (https://reviews.freebsd.org/D19676) if anyone is interested. > >> > >> --chuck > > > > > > I've built and installed this patch on FreeBSD 12.0-STABLE-amd64-20190314-r345117. Testing occurred against Windows 10 Pro guest with a presented NVMe bhyve device and all IO transactions worked without issue. > > > > Can this be committed to head and MFD to 12-STABLE. Thanks! > > Committed with r345956. MFC in 2 weeks if nothing pops up. Thanks > again for all your testing! A small prod Chuck you should of mentioned Jason in the commit message for his testing work. I know it is easy to forget this, but it is the right thing to do. Jason, I'll thank you here, in a more personal maner, for working with Chuck on getting this fixed. Thanks, -- Rod Grimes rgrimes@freebsd.org