From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: Re: always use REQ_OP_WRITE_ZEROES for zeroing offload Date: Wed, 5 Apr 2017 14:08:26 +0200 Message-ID: <20170405120826.GA2275@lst.de> References: <20170331163313.31821-1-hch@lst.de> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline In-Reply-To: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: drbd-dev-bounces-cunTk1MwBs8qoQakbn7OcQ@public.gmane.org Errors-To: drbd-dev-bounces-cunTk1MwBs8qoQakbn7OcQ@public.gmane.org To: "Martin K. Petersen" Cc: axboe-tSWWG44O7X1aa/9Udqfwiw@public.gmane.org, linux-raid-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-scsi-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, snitzer-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org, philipp.reisner-63ez5xqkn6DQT0dZR+AlfA@public.gmane.org, linux-block-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, dm-devel-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org, lars.ellenberg-63ez5xqkn6DQT0dZR+AlfA@public.gmane.org, shli-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org, Christoph Hellwig , agk-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org, drbd-dev-cunTk1MwBs8qoQakbn7OcQ@public.gmane.org List-Id: linux-raid.ids On Wed, Apr 05, 2017 at 07:40:36AM -0400, Martin K. Petersen wrote: > > This series makes REQ_OP_WRITE_ZEROES the only zeroing offload > > supported by the block layer, and switches existing implementations > > of REQ_OP_DISCARD that correctly set discard_zeroes_data to it, > > removes incorrect discard_zeroes_data, and also switches WRITE SAME > > based zeroing in SCSI to this new method. > > Very, very nice. I think this is the correct approach. > > I'm going to send two follow-up patches that allow us to use UNMAP for > discards and WRITE SAME w/ UNMAP for zeroout. That appears to be the > preferred configuration for most storage devices. Thanks, I'll resend it with your nitpicks fixed, your follow on patches tacked on and the various reviewed-by tags in a bit. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 5 Apr 2017 14:08:26 +0200 From: Christoph Hellwig To: "Martin K. Petersen" Cc: Christoph Hellwig , axboe@kernel.dk, agk@redhat.com, snitzer@redhat.com, shli@kernel.org, philipp.reisner@linbit.com, lars.ellenberg@linbit.com, linux-block@vger.kernel.org, linux-scsi@vger.kernel.org, drbd-dev@lists.linbit.com, dm-devel@redhat.com, linux-raid@vger.kernel.org Subject: Re: always use REQ_OP_WRITE_ZEROES for zeroing offload Message-ID: <20170405120826.GA2275@lst.de> References: <20170331163313.31821-1-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii In-Reply-To: List-ID: On Wed, Apr 05, 2017 at 07:40:36AM -0400, Martin K. Petersen wrote: > > This series makes REQ_OP_WRITE_ZEROES the only zeroing offload > > supported by the block layer, and switches existing implementations > > of REQ_OP_DISCARD that correctly set discard_zeroes_data to it, > > removes incorrect discard_zeroes_data, and also switches WRITE SAME > > based zeroing in SCSI to this new method. > > Very, very nice. I think this is the correct approach. > > I'm going to send two follow-up patches that allow us to use UNMAP for > discards and WRITE SAME w/ UNMAP for zeroout. That appears to be the > preferred configuration for most storage devices. Thanks, I'll resend it with your nitpicks fixed, your follow on patches tacked on and the various reviewed-by tags in a bit.