Received: by 2002:a25:e7d8:0:0:0:0:0 with SMTP id e207csp563520ybh; Thu, 12 Mar 2020 07:08:06 -0700 (PDT) X-Google-Smtp-Source: ADFU+vuX+LSpKZsqgSgB7yumRZzS9Ri0hyQY7e+nKWHcn9YV77gJKOPKb7ZQE4GbbCiZCT0pP+yc X-Received: by 2002:aca:4ecc:: with SMTP id c195mr2615709oib.123.1584022086709; Thu, 12 Mar 2020 07:08:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584022086; cv=none; d=google.com; s=arc-20160816; b=WbwjUZ2nXEy4cPFMqT02i68sBIsY44b3++nSWB8W8JQttz8GzGSfYs8qNbx5PHoRdp M9V/ISLvAgcL9eFLcjU/yXP0DiM01s121c+1s9uJZNW8+XWlmCkAPbK2XaMy5JQS+nK7 buxK8jXFJnC8uSRRnacqhVk6rolqU40dylL3G5d3Q9UIIWDvCvxxtSqq1kjcshF1Vrtp hKuxxr1cTQgbx7RCgH8djrXc+B44iOEV0GVRNrAgAlpbDDWzXDP8YjbmFS1SHLQgfTaP tRSyp6Wlhh8TDJeWaXcqr48Sbb76UCdKN2XI2gz5ZO5O08CkdIs/qlJQqX1FkyE6sVA3 lz+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dkim-signature; bh=Pji13eSFjIMldkU9BYdIbo4HI44T8oed33naqFgVd6s=; b=Mh13e1XgBtwPgNxs9bHniC4Ecrm3+PxSldX50eLJAZEjI8GHGU7tLFijmNV36OppT2 ROAesj4iXXyESLWyk2TaNbdVClJi7SnHiYrX2S+d341jNQYIQuMUVXliF3TalgC0F1OW vYcrBQzl9b7SmaBlLjUkhT+lRz2s62h0Klm4QSh65L30+2U5j1KWAmZehJDWg8F4FQo5 Yeyp5vsSDali5UqSWZCrcSrDBZ51S4hYKEzKrRE8MZCPR6YFWFssAB8ckNnsfn/UF0ch 5nt1jli+SDnG9ZUIN7A0+AP24DHuLg/gQ7O3jycNBfg0xI8XW2o/djAUdQVD2RAJG020 M2rg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=zssgGwlH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e63si2905035oib.19.2020.03.12.07.07.49; Thu, 12 Mar 2020 07:08:06 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel-dk.20150623.gappssmtp.com header.s=20150623 header.b=zssgGwlH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727576AbgCLOGQ (ORCPT + 99 others); Thu, 12 Mar 2020 10:06:16 -0400 Received: from mail-il1-f195.google.com ([209.85.166.195]:45790 "EHLO mail-il1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727414AbgCLOGP (ORCPT ); Thu, 12 Mar 2020 10:06:15 -0400 Received: by mail-il1-f195.google.com with SMTP id p1so5537668ils.12 for ; Thu, 12 Mar 2020 07:06:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel-dk.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=Pji13eSFjIMldkU9BYdIbo4HI44T8oed33naqFgVd6s=; b=zssgGwlH8/VmLMRtLhaCwqZbq9RREsK0T5bf6PIvtt1VGFFLfPPnQnZejqOTYcE66h YC0y2su0NF5zACw1HZZsr7rjtUkogTsWqTu6Vm6/ie+LuGi85xrZGApcNLASkl90rCNH N3iKNDAKYS9oq8i9IEow8BJeJKPxUsJrlebRdwIF5eJPTF0cAwRj9ggXLmAxIDhdEZuG PvnpPrEInwbqPNIjvL3PzflYawxDa3mZi2TgaKLvf7ECZzHSxJx3KAoa2ry7Pf7aKJ1S y7gpjNa2PHKgoNp0XyIc9HwCBIQjRNDXD+/sV+kacNjm7ivwd82D7IAXuee/0UJ8BEOm eHVw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=Pji13eSFjIMldkU9BYdIbo4HI44T8oed33naqFgVd6s=; b=rQzng+XSHj2PiJgCQRj1db1jeZsvFymCjPsAgv4Ql7COA0U6gbnwijn6F/XNb5f5yQ GwwgJJpRrSXf1+PkeBseWfc0H8bhuDWozYwHCDWruBCjoBo4pKe8myjOVYlDVwZSx8am 0efOyeLm4Z/5RnE6RGLLt0T3e16fmpIFIXM3FEglMRxX2TLlC+9Rw1QDqpQfR7c/aJjG 8x8rAISoe/pZ+dThtvBOlQNnrCwFkfx/HWKFpU8Knnb7OHt274VSr5vBOYh4zn8Y+rv9 pIxZUdC0/yLpAAznUNyGtis4rTL/4SOxNY1am7VFpQMxb7B28dirRQTl3t0guSNEmNiF 76dQ== X-Gm-Message-State: ANhLgQ1gYU9JzFinRCbABSUhamE5IZmOKAojS2rcd+VNIC/zS2UAzvRU OLoj63EESfCo9lajEX/h9gzU8w== X-Received: by 2002:a92:c904:: with SMTP id t4mr959353ilp.209.1584021973514; Thu, 12 Mar 2020 07:06:13 -0700 (PDT) Received: from [192.168.1.159] ([65.144.74.34]) by smtp.gmail.com with ESMTPSA id d1sm6126275ilq.9.2020.03.12.07.06.12 (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Thu, 12 Mar 2020 07:06:12 -0700 (PDT) Subject: Re: [PATCH v2 0/5] Add support for block disk resize notification To: "Singh, Balbir" , "linux-kernel@vger.kernel.org" , "linux-block@vger.kernel.org" , "linux-nvme@lists.infradead.org" Cc: "hch@lst.de" , "Chaitanya.Kulkarni@wdc.com" , "jejb@linux.ibm.com" , "mst@redhat.com" References: <20200225200129.6687-1-sblbir@amazon.com> From: Jens Axboe Message-ID: <05bb1606-4cf1-dba3-22a0-5f8624b43767@kernel.dk> Date: Thu, 12 Mar 2020 08:06:11 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 3/2/20 9:03 PM, Singh, Balbir wrote: > On Tue, 2020-02-25 at 20:01 +0000, Balbir Singh wrote: >> Allow block/genhd to notify user space about disk size changes using a >> new helper set_capacity_revalidate_and_notify(), which is a wrapper >> on top of set_capacity(). set_capacity_revalidate_and_notify() will only >> notify >> iff the current capacity or the target capacity is not zero and the >> capacity really changes. >> >> Background: >> >> As a part of a patch to allow sending the RESIZE event on disk capacity >> change, Christoph (hch@lst.de) requested that the patch be made generic >> and the hacks for virtio block and xen block devices be removed and >> merged via a generic helper. >> >> This series consists of 5 changes. The first one adds the basic >> support for changing the size and notifying. The follow up patches >> are per block subsystem changes. Other block drivers can add their >> changes as necessary on top of this series. Since not all devices >> are resizable, the default was to add a new API and let users >> slowly convert over as needed. >> >> Testing: >> 1. I did some basic testing with an NVME device, by resizing it in >> the backend and ensured that udevd received the event. >> >> >> Changelog v2: >> - Rename disk_set_capacity to set_capacity_revalidate_and_notify >> - set_capacity_revalidate_and_notify can call revalidate disk >> if needed, a new bool parameter is passed (suggested by Bob Liu) >> > > Ping? It's not an urgent patchset, I am happy to wait if nothing else is > needed. It doesn't apply to the 5.7 branches, can you resend against for-5.7/block? -- Jens Axboe