From owner-freebsd-fs@FreeBSD.ORG Thu May 13 21:25:37 2010 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5700C106567A for ; Thu, 13 May 2010 21:25:37 +0000 (UTC) (envelope-from spawk@acm.poly.edu) Received: from acm.poly.edu (acm.poly.edu [128.238.9.200]) by mx1.freebsd.org (Postfix) with ESMTP id EA5CE8FC0A for ; Thu, 13 May 2010 21:25:36 +0000 (UTC) Received: (qmail 42837 invoked from network); 13 May 2010 21:25:36 -0000 Received: from unknown (HELO ?10.0.0.170?) (spawk@128.238.64.31) by acm.poly.edu with AES256-SHA encrypted SMTP; 13 May 2010 21:25:36 -0000 Message-ID: <4BEC6E20.2080005@acm.poly.edu> Date: Thu, 13 May 2010 17:24:48 -0400 From: Boris Kochergin User-Agent: Thunderbird 2.0.0.24 (X11/20100330) MIME-Version: 1.0 To: Pawel Jakub Dawidek References: <4BEB40EB.2030206@acm.poly.edu> <4BEBE634.4080102@FreeBSD.org> <20100513211750.GA2015@garage.freebsd.pl> In-Reply-To: <20100513211750.GA2015@garage.freebsd.pl> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-fs@freebsd.org, John Baldwin Subject: Re: ZFS and __FreeBSD_version X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 13 May 2010 21:25:37 -0000 Pawel Jakub Dawidek wrote: > On Thu, May 13, 2010 at 07:44:52AM -0400, John Baldwin wrote: > >> Boris Kochergin wrote: >> >>> Hi. Can __FreeBSD_version be bumped if ZFS's userland API is ever >>> changed again? I got slightly bitten by the >>> state_to_name()-to-zpool_state_to_name() change from version 6 to >>> version 13 and would like a reliable way of keeping track of this type >>> of stuff in the future. Thanks. >>> >> Yes, it should be bumped anytime the API changes. That is definitely a >> bug that it wasn't done properly last time. >> > > I must disagree here. libzfs API is for ZFS internal use only and is > subject to change at any time. This is true for OpenSolaris as well. > We, of course, can bump __FreeBSD_version if it helps, but one shouldn't > expect libzfs API being stable or there is any care taken to maintain > backward compatibility Sure, I understand that it's unstable, but a different __FreeBSD_version for each time it changes (which isn't that often in FreeBSD) would allow my code to do the right thing to cope with it, at the preprocessor. -Boris