Received: by 2002:a25:7ec1:0:0:0:0:0 with SMTP id z184csp778681ybc; Sat, 16 Nov 2019 08:31:59 -0800 (PST) X-Google-Smtp-Source: APXvYqwHS2D2LdAyUCmtkP4/xm2rg4DHvWTtzkSdCyo1zrMg7fXD18+UCF24X4iaxhkTY4bPwre5 X-Received: by 2002:a17:906:7f8a:: with SMTP id f10mr11306712ejr.209.1573921919625; Sat, 16 Nov 2019 08:31:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1573921919; cv=none; d=google.com; s=arc-20160816; b=Iwjd3EybP514ZTKjfuilMFDtr95B0bCtkhFNKiB28FrQRuzBgfxtOBLy8vxOFeWOSk sMRSzqEbzMLxkYTmAztdBInqIkCKNjnd9J1T06ovJXOm+dFWBEgwALstm/NsVeP3f9wR FKtSh+5qDiSC13BTSpUD036iCHz1tb9bVPvuW15/syEj5ugd6+u/g7hVnebB8oVgijes 6Q7kK5qsw9QldaNUbpSVY7IkcU3HBshnd5AjF1N4eQywmSq6IcwitpDEPLJRXVriCvT6 NcDDKy9umTd541RvqMmhoQKx/NWTaypHZ6GLqJIS4satoQQp0ud5jNyCYqVNWNlJ0U74 L6UQ== 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:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=qSwoWYAgUmrcHd0AHER01mXA1RLWNp8YHDF53UQJ+d4=; b=ATYzhlp8wZ6S1CorByFu4os8x9ERlfhAh6CQzKBHxvxk1/Ue34yC8nmJDjQDmtftqe /yQOj2GrIs5JtqN/f9AzpekGAi757Zfm6SOgyoE7i5gxwqL2iyIAsMrjVOO5SUXTiiQU wp6A1XUTHmmSHPekwKtbhv9KobkYhAEz+mNwlr3XPW2TJ6pveNvXSGJQc+0uinQeH4jz gSu5tqsYMQPIWc4jEF/rMnMT5nykMnsOCr8IbDqX9N1RVy1Xil8fdF1PNMRJFuTC9XCw cUPzpSCLGyW58J071sdIc6hEQRQtRTO6OMgev1Cg1A7AhMljiVvFR3n12g7yFqNfy/jr nSIQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=J8MYdDZR; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m15si7916087ejk.320.2019.11.16.08.31.35; Sat, 16 Nov 2019 08:31:59 -0800 (PST) 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.org header.s=default header.b=J8MYdDZR; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1732080AbfKPQ1J (ORCPT + 99 others); Sat, 16 Nov 2019 11:27:09 -0500 Received: from mail.kernel.org ([198.145.29.99]:44886 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727962AbfKPPlj (ORCPT ); Sat, 16 Nov 2019 10:41:39 -0500 Received: from sasha-vm.mshome.net (unknown [50.234.116.4]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 2103320830; Sat, 16 Nov 2019 15:41:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1573918899; bh=1UHd5Z+iO61oz8qaxXgGlqrU6/ESGUcvWsJ5GK3etOY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=J8MYdDZRxS10ql0g6lEnXSQiHHdYXMXNp0FddstZmy0SCLtnlLwZoSVcD7v8Diff5 vQWCrhMRB0gJusD0dbsLL+K6dln4EG5bEO2tw1d38F67Y3ssExtp6OO0xWQcU2Cp3Z aQRXnIQ1uF/y5FgKi0L39YCh/ZeS4A6hFDQsgC1w= From: Sasha Levin To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Su Yue , David Sterba , Sasha Levin , linux-btrfs@vger.kernel.org Subject: [PATCH AUTOSEL 4.19 027/237] btrfs: defrag: use btrfs_mod_outstanding_extents in cluster_pages_for_defrag Date: Sat, 16 Nov 2019 10:37:42 -0500 Message-Id: <20191116154113.7417-27-sashal@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20191116154113.7417-1-sashal@kernel.org> References: <20191116154113.7417-1-sashal@kernel.org> MIME-Version: 1.0 X-stable: review X-Patchwork-Hint: Ignore Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Su Yue [ Upstream commit 28c4a3e21ad030d7571ee9b1b246a5cbfd886627 ] Since commit 8b62f87bad9c ("Btrfs: rework outstanding_extents"), manual operations of outstanding_extent in btrfs_inode are replaced by btrfs_mod_outstanding_extents(). The one in cluster_pages_for_defrag seems to be lost, so replace it of btrfs_mod_outstanding_extents(). Fixes: 8b62f87bad9c ("Btrfs: rework outstanding_extents") Signed-off-by: Su Yue Reviewed-by: David Sterba Signed-off-by: David Sterba Signed-off-by: Sasha Levin --- fs/btrfs/ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/ioctl.c b/fs/btrfs/ioctl.c index 7592beb53fc4e..00ff4349b4579 100644 --- a/fs/btrfs/ioctl.c +++ b/fs/btrfs/ioctl.c @@ -1337,7 +1337,7 @@ static int cluster_pages_for_defrag(struct inode *inode, if (i_done != page_cnt) { spin_lock(&BTRFS_I(inode)->lock); - BTRFS_I(inode)->outstanding_extents++; + btrfs_mod_outstanding_extents(BTRFS_I(inode), 1); spin_unlock(&BTRFS_I(inode)->lock); btrfs_delalloc_release_space(inode, data_reserved, start_index << PAGE_SHIFT, -- 2.20.1