From owner-freebsd-fs@freebsd.org Fri Nov 9 13:16:28 2018 Return-Path: Delivered-To: freebsd-fs@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 B84C911302BB for ; Fri, 9 Nov 2018 13:16:28 +0000 (UTC) (envelope-from jack@gandi.net) Received: from gandi.net (mail12.gandi.net [IPv6:2001:4b98:dc4:5:ae1f:6bff:fe2d:9fdc]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id C0B7E7AAD5 for ; Fri, 9 Nov 2018 13:16:27 +0000 (UTC) (envelope-from jack@gandi.net) Received: from thinkpad-gandi (tgordon.gandi.net [217.70.181.24]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by gandi.net (Postfix) with ESMTPS id 27FD7160432; Fri, 9 Nov 2018 13:16:17 +0000 (UTC) Date: Fri, 9 Nov 2018 14:16:17 +0100 From: Jack Halford To: freebsd-fs@freebsd.org Cc: fatih@gandi.net Subject: d_off support Message-ID: <20181109131617.pm26wjv4eg6fqdvl@thinkpad-gandi> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Disposition: inline User-Agent: NeoMutt/20180716 X-Rspamd-Queue-Id: C0B7E7AAD5 X-Spamd-Result: default: False [-2.96 / 200.00]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.998,0]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2001:4b98:dc4:5::/64]; NEURAL_HAM_LONG(-1.00)[-0.998,0]; MIME_GOOD(-0.10)[text/plain]; TO_DN_NONE(0.00)[]; DMARC_NA(0.00)[gandi.net]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[mail8.gandi.net,mail12.gandi.net]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.69)[-0.688,0]; IP_SCORE(-0.47)[asn: 203476(-2.31), country: FR(-0.02)]; FROM_EQ_ENVFROM(0.00)[]; R_DKIM_NA(0.00)[]; MID_RHS_NOT_FQDN(0.50)[]; ASN(0.00)[asn:203476, ipnet:2001:4b98:dc4::/48, country:FR]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[] X-Rspamd-Server: mx1.freebsd.org X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 Nov 2018 13:16:28 -0000 Hello all, With the new 'd_off' field in struct dirent, we've (gandi.net) pushed a patch[1] to add support for it in multiple filesystems. Our specific usecase is for a userspace nfs server (nfs-ganesha) with zfs. At the moment we cache direntry offsets by calling lseek once per entry, with the patch we can get the offset directly from getdirentries calls which provides a significant speedup. [1]: https://reviews.freebsd.org/D17917