From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 7B87CC7EE37 for ; Fri, 9 Jun 2023 20:32:36 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229803AbjFIUcf (ORCPT ); Fri, 9 Jun 2023 16:32:35 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41330 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229537AbjFIUcc (ORCPT ); Fri, 9 Jun 2023 16:32:32 -0400 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 92032E47 for ; Fri, 9 Jun 2023 13:31:45 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1686342704; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=kqBodWvsMAtzK0roMuBBNkvevtML0piZ6ybEx/MweaE=; b=QTdgM9lVtL4CFMnYLPm5bLxb+YopEa1Dn5HSuGxRP9fg79EoMsJdDtSSQALeb40gtBbjPU zx7r6f/HNtf1HH9tTxshaDEn7t5BKGis2Ecf/Gwy53Qq/muj/dEKsUTUTc74o/Z4HkHutK 4+oPCzAH0QdrSoG+hVVe87EJZ1YyIvw= Received: from mail-qv1-f70.google.com (mail-qv1-f70.google.com [209.85.219.70]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-91-_CYW7p-oN0yoUWL8KO-iGg-1; Fri, 09 Jun 2023 16:31:43 -0400 X-MC-Unique: _CYW7p-oN0yoUWL8KO-iGg-1 Received: by mail-qv1-f70.google.com with SMTP id 6a1803df08f44-62619240316so23896016d6.3 for ; Fri, 09 Jun 2023 13:31:43 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686342703; x=1688934703; h=in-reply-to:content-transfer-encoding:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=kqBodWvsMAtzK0roMuBBNkvevtML0piZ6ybEx/MweaE=; b=VzgquTZ+2pB+XHvfp6RfxW28xwF8/oT4Xo+ZdoRNEn284qpk9H2PCc1hAEIYhGqIqX eCCLjFfqNSOVyv8btqIgtKaL0aB5tkQDFeLBn1ZDdgQqHDg2XMG4+6YA5CPBiCqqVanE 59ZoLxSSzXRS5DwtlFG5bgvU/yoJi7E6l6akZ+bsVivMbJ7oIxy7KFgk1YOrOAqBj2wo 9rj8mSZ/vcA9bIhKaIQBPQMZCL7ZnwFIK1PlSYRWy1LQc4V7PobD9mF38wu+ZyXdvUCu 4fRWGSt3V8qxZ4QcoNjxIF5RScfzD0vqYo6KEjEyH+q88h5IyZRQQrTCb3tDShw6gmCm lc5w== X-Gm-Message-State: AC+VfDyKBQ2E26Jd5x+cFiy8sAkacEWnrzvAyujmfd1ICxcNJqUE3aNA bEEtNyN1l2gwfOLdXB6FbRZaRFBGMBeFRtI7+/CmikK6h0CPQT8t/jF5p+jTAvImmW9GPsPa6nD aAi5gFu2RhGk2DKcs4QMnlTw= X-Received: by 2002:a05:6214:124a:b0:626:3a5a:f8dc with SMTP id r10-20020a056214124a00b006263a5af8dcmr3512868qvv.57.1686342703123; Fri, 09 Jun 2023 13:31:43 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ78w0WDf0o6qhufepqm2d8bEB8MBtf2WH2t9YiWbkCms2QdUrQ0M7FAIP95SCC+cHOEnZuU1A== X-Received: by 2002:a05:6214:124a:b0:626:3a5a:f8dc with SMTP id r10-20020a056214124a00b006263a5af8dcmr3512845qvv.57.1686342702858; Fri, 09 Jun 2023 13:31:42 -0700 (PDT) Received: from localhost (pool-68-160-166-30.bstnma.fios.verizon.net. [68.160.166.30]) by smtp.gmail.com with ESMTPSA id m24-20020ae9e718000000b007578622c861sm1250201qka.108.2023.06.09.13.31.42 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 09 Jun 2023 13:31:42 -0700 (PDT) Date: Fri, 9 Jun 2023 16:31:41 -0400 From: Mike Snitzer To: Sarthak Kukreti Cc: Jens Axboe , Christoph Hellwig , Joe Thornber , "Michael S. Tsirkin" , "Darrick J. Wong" , Jason Wang , Bart Van Assche , Dave Chinner , linux-kernel@vger.kernel.org, Joe Thornber , linux-block@vger.kernel.org, dm-devel@redhat.com, Andreas Dilger , Stefan Hajnoczi , linux-fsdevel@vger.kernel.org, Theodore Ts'o , linux-ext4@vger.kernel.org, Brian Foster , Alasdair Kergon Subject: Re: [PATCH v7 0/5] Introduce provisioning primitives Message-ID: References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jun 07 2023 at 7:27P -0400, Mike Snitzer wrote: > On Mon, Jun 05 2023 at 5:14P -0400, > Sarthak Kukreti wrote: > > > On Sat, Jun 3, 2023 at 8:57 AM Mike Snitzer wrote: > > > > > > We all just need to focus on your proposal and Joe's dm-thin > > > reservation design... > > > > > > [Sarthak: FYI, this implies that it doesn't really make sense to add > > > dm-thinp support before Joe's design is implemented. Otherwise we'll > > > have 2 different responses to REQ_OP_PROVISION. The one that is > > > captured in your patchset isn't adequate to properly handle ensuring > > > upper layer (like XFS) can depend on the space being available across > > > snapshot boundaries.] > > > > > Ack. Would it be premature for the rest of the series to go through > > (REQ_OP_PROVISION + support for loop and non-dm-thinp device-mapper > > targets)? I'd like to start using this as a reference to suggest > > additions to the virtio-spec for virtio-blk support and start looking > > at what an ext4 implementation would look like. > > Please drop the dm-thin.c and dm-snap.c changes. dm-snap.c would need > more work to provide the type of guarantee XFS requires across > snapshot boundaries. I'm inclined to _not_ add dm-snap.c support > because it is best to just use dm-thin. > > And FYI even your dm-thin patch will be the starting point for the > dm-thin support (we'll keep attribution to you for all the code in a > separate patch). > > > Fair points, I certainly don't want to derail this conversation; I'd > > be happy to see this work merged sooner rather than later. > > Once those dm target changes are dropped I think the rest of the > series is fine to go upstream now. Feel free to post a v8. FYI, I've made my latest code available in this 'dm-6.5-provision-support' branch (based on 'dm-6.5'): https://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm.git/log/?h=dm-6.5-provision-support It's what v8 should be plus the 2 dm-thin patches (that I don't think should go upstream yet, but are theoretically useful for Dave and Joe). The "dm thin: complete interface for REQ_OP_PROVISION support" commit establishes all the dm-thin interface I think is needed. The FIXME in process_provision_bio() (and the patch header) cautions against upper layers like XFS using this dm-thinp support quite yet. Otherwise we'll have the issue where dm-thinp's REQ_OP_PROVISION support initially doesn't provide the guarantee that XFS needs across snapshots (which is: snapshots inherit all previous REQ_OP_PROVISION). Mike