Received: by 2002:ac0:946b:0:0:0:0:0 with SMTP id j40csp2729388imj; Mon, 11 Feb 2019 07:37:27 -0800 (PST) X-Google-Smtp-Source: AHgI3IYFjSNL6mrjxztGDfKKdmxZG1StPzrONd0GbCNbNYkDB+42xJrej90vjtbwxwaTUKUMIPWc X-Received: by 2002:a17:902:7d86:: with SMTP id a6mr5926446plm.41.1549899447696; Mon, 11 Feb 2019 07:37:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1549899447; cv=none; d=google.com; s=arc-20160816; b=Q0tiDeLdaWiptTsDo6G8b8M28oOGOfEwoXKqA8mZKwlw1AsaJN49cHvlylo6F2zTTI CLIq2JQ8bmWnB2gcdgadNLhkLn1SV920km5lx7cbt3B+gNNm+4wS1U5lhHVmJI8ROv4o TKHzM80+fJhCOnVxbz+fx5Kxwo0bkYM+0Hs4AUHQZQqrcN8bhRYu4H+dlJcOssdZS7lD C0cgHHOPcDLYl7vW7EkWzN3cdNDgNdurJBpZcPGoYYJU85CGYrxm+PHgQE1j7xwSCRRl kilp5oNnhlYmVJ6SJgjY9dUT+zeozzmrSroC8+2nWR8eO9MjnPou8S+jwS7U1/mkHzEY FC7A== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=mA4R2jlfN2QaIBZA1s4s4u6JP09LhrfIIyqmdfEVG8Q=; b=gv+9p4TQEHnOW/zpWxUX81rVr2gwia33HMjmBF/mEewa1pdX8B2/fzAt+rVD/ewiW5 dxPdwBPhdjl/HdAzDAJK/Owmu2G+dQtvLgL0Zo6HNId+tvKlIImIxAAc5By711vwDdeA E0rLY51JiZrWCbRo+GkMY2qmrl0JqD+mjMaLy/IG/AV/2NfXx1BvwhYVlVeYVkYcih1Q OVlW63uOifPxJyatdYZ/FxIcmzTL38a3WYq61SmrJO5jIE3LDlWSTFhDs8d0oDXX3uyI nutOAarM2sSTZV8zWE9acqOd2TD1RnDCSjxexYAynUjSq4MqjalzA1SjgMOFOAz1XrwP 2puw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="a/LIUDRI"; 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 c1si9928607pls.326.2019.02.11.07.37.11; Mon, 11 Feb 2019 07:37:27 -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="a/LIUDRI"; 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 S2388699AbfBKPfj (ORCPT + 99 others); Mon, 11 Feb 2019 10:35:39 -0500 Received: from mail.kernel.org ([198.145.29.99]:38648 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733153AbfBKOwX (ORCPT ); Mon, 11 Feb 2019 09:52:23 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 97B20214DA; Mon, 11 Feb 2019 14:52:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1549896743; bh=CMj7OnYv5bRVvqyDaE8QqzSu2Aqt2fz/Bh07KMwF0gQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=a/LIUDRIlpY+aq5QLpX+WwVcmLnPm6JrB1Dc+bBJ+Dqn0IVDe8GQUmyKFzdKRs3Jo 9dwdFSlEmNTjd8Czqt487XzkJDuwzZQ8Onx41GCIgO2SByhbMD4gSeewlAxJZjmr4X uaXTbYlcnxLlF5wSqnlLycad4ou7pxVAD8oYTWU4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Ye Yin , "Darrick J. Wong" , Luis Chamberlain , Sasha Levin Subject: [PATCH 4.19 255/313] fs/xfs: fix f_ffree value for statfs when project quota is set Date: Mon, 11 Feb 2019 15:18:55 +0100 Message-Id: <20190211141910.372677531@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190211141852.749630980@linuxfoundation.org> References: <20190211141852.749630980@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ commit de7243057e7cefa923fa5f467c0f1ec24eef41d2 upsream. When project is set, we should use inode limit minus the used count Signed-off-by: Ye Yin Reviewed-by: Darrick J. Wong Signed-off-by: Darrick J. Wong Signed-off-by: Luis Chamberlain Signed-off-by: Sasha Levin --- fs/xfs/xfs_qm_bhv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/xfs/xfs_qm_bhv.c b/fs/xfs/xfs_qm_bhv.c index 73a1d77ec187..3091e4bc04ef 100644 --- a/fs/xfs/xfs_qm_bhv.c +++ b/fs/xfs/xfs_qm_bhv.c @@ -40,7 +40,7 @@ xfs_fill_statvfs_from_dquot( statp->f_files = limit; statp->f_ffree = (statp->f_files > dqp->q_res_icount) ? - (statp->f_ffree - dqp->q_res_icount) : 0; + (statp->f_files - dqp->q_res_icount) : 0; } } -- 2.19.1