From patchwork Wed Apr 5 14:21:47 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 9664285 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id B1515602B5 for ; Wed, 5 Apr 2017 14:24:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A6342206E2 for ; Wed, 5 Apr 2017 14:24:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9B1DA28307; Wed, 5 Apr 2017 14:24:02 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2AEFD206E2 for ; Wed, 5 Apr 2017 14:24:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754914AbdDEOYB (ORCPT ); Wed, 5 Apr 2017 10:24:01 -0400 Received: from bombadil.infradead.org ([65.50.211.133]:37522 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755203AbdDEOWn (ORCPT ); Wed, 5 Apr 2017 10:22:43 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=References:In-Reply-To:Message-Id: Date:Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=9BmiGWJ7DrsN+IWvhi7/vJbkG/8Ls9PiJ4VNZ33N6LA=; b=SaqmI/ITtWX36GglHfEGq/8P4 xQRm2VdArOQmcsG3nAf4uxHnjYpm7W7m0CdnYLdP3Eq64O5S/dFC/twgDtZTDShglazg5p9YHLDo5 hIhyZEWGRr0yK55PMKkMty+3ASuMV6Kr8VwyhHPeOp49NV8MDCmMSbj2OkpxDbBmLdIIAE+5Wt8JO 9fRfqWLLyKVRG/9IxjAtOeEXXGbrTe3WRb1Blt/7mjXmGUuJmoVRdllVuqOpkdWiOkwi46q56pnq5 JyX2PuR5T9/mrrdM8i9SZaR5k6ZKggFC36VZ6XP9V2RZ35IcwSGQ/eB/kRLAKeYgSQvfD5bepSuaa nI/58kiFQ==; Received: from 80-109-146-114.cable.dynamic.surfer.at ([80.109.146.114] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.87 #1 (Red Hat Linux)) id 1cvlpX-000312-Rf; Wed, 05 Apr 2017 14:22:40 +0000 From: Christoph Hellwig To: axboe@kernel.dk, martin.petersen@oracle.com, agk@redhat.com, snitzer@redhat.com, shli@kernel.org, philipp.reisner@linbit.com, lars.ellenberg@linbit.com Cc: 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: [PATCH 09/27] block: stop using blkdev_issue_write_same for zeroing Date: Wed, 5 Apr 2017 16:21:47 +0200 Message-Id: <20170405142205.6477-10-hch@lst.de> X-Mailer: git-send-email 2.11.0 In-Reply-To: <20170405142205.6477-1-hch@lst.de> References: <20170405142205.6477-1-hch@lst.de> X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-block-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-block@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We'll always use the WRITE ZEROES code for zeroing now. Signed-off-by: Christoph Hellwig Reviewed-by: Martin K. Petersen Reviewed-by: Hannes Reinecke --- block/blk-lib.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/block/blk-lib.c b/block/blk-lib.c index e5b853f2b8a2..2a8d638544a7 100644 --- a/block/blk-lib.c +++ b/block/blk-lib.c @@ -364,10 +364,6 @@ int blkdev_issue_zeroout(struct block_device *bdev, sector_t sector, return 0; } - if (!blkdev_issue_write_same(bdev, sector, nr_sects, gfp_mask, - ZERO_PAGE(0))) - return 0; - blk_start_plug(&plug); ret = __blkdev_issue_zeroout(bdev, sector, nr_sects, gfp_mask, &bio, discard);