From patchwork Fri Apr 3 22:12:16 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allison Henderson X-Patchwork-Id: 11473849 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 7BC4492C for ; Fri, 3 Apr 2020 22:14:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 5954B206F6 for ; Fri, 3 Apr 2020 22:14:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="GP3bbYXS" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729159AbgDCWOm (ORCPT ); Fri, 3 Apr 2020 18:14:42 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:58524 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729143AbgDCWOm (ORCPT ); Fri, 3 Apr 2020 18:14:42 -0400 Received: from pps.filterd (aserp2120.oracle.com [127.0.0.1]) by aserp2120.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 033M9fd6093012 for ; Fri, 3 Apr 2020 22:14:41 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : subject : date : message-id : in-reply-to : references; s=corp-2020-01-29; bh=q+3SA1mPS/RiDyEVQNxLLgAsZ9vPvJdu7yk5nolZrFQ=; b=GP3bbYXSJJ8UrEgHvUgn6mep3psLaQIi1iT3lwo7sQoGdKtwg3VLUZmMAqN12Q6+XlPO iLYIJ+no3qTTaPMDdKHdmA0GKtwH9Vc3+YJiNsKA86av4t2c9EC4xC0W0gtKDe0WguJa mNi+h5//ePS+YS08pvKYNFEsMNgoj6wJDzHfxqJu5807I14o6OhX0RUkMx79I7ncedRq +q0NypXhg9zpKMXiI6yuLf5p6q/+woP94VNZJjjNTAMP9RlHL1dgY80VAwVoFX1K/f9J wjcAOuaHGuEzfNwPFYKAa4CqH5S8Hcou5hwGoIftRDGj9tvj6NiDShe3UjaHspBbm+Dw qA== Received: from userp3020.oracle.com (userp3020.oracle.com [156.151.31.79]) by aserp2120.oracle.com with ESMTP id 303yunp0w9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 03 Apr 2020 22:14:41 +0000 Received: from pps.filterd (userp3020.oracle.com [127.0.0.1]) by userp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 033M8N3x062367 for ; Fri, 3 Apr 2020 22:12:40 GMT Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userp3020.oracle.com with ESMTP id 302ga617p0-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Fri, 03 Apr 2020 22:12:40 +0000 Received: from abhmp0010.oracle.com (abhmp0010.oracle.com [141.146.116.16]) by userv0121.oracle.com (8.14.4/8.13.8) with ESMTP id 033MCek8029202 for ; Fri, 3 Apr 2020 22:12:40 GMT Received: from localhost.localdomain (/67.1.1.216) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 03 Apr 2020 15:12:39 -0700 From: Allison Collins To: linux-xfs@vger.kernel.org Subject: [PATCH v8 07/20] xfs: Pull up trans roll from xfs_attr3_leaf_setflag Date: Fri, 3 Apr 2020 15:12:16 -0700 Message-Id: <20200403221229.4995-8-allison.henderson@oracle.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200403221229.4995-1-allison.henderson@oracle.com> References: <20200403221229.4995-1-allison.henderson@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9580 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 mlxlogscore=999 bulkscore=0 mlxscore=0 spamscore=0 adultscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004030171 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9580 signatures=668685 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 phishscore=0 lowpriorityscore=0 malwarescore=0 adultscore=0 priorityscore=1501 mlxlogscore=999 bulkscore=0 suspectscore=1 mlxscore=0 spamscore=0 impostorscore=0 clxscore=1015 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2003020000 definitions=main-2004030171 Sender: linux-xfs-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-xfs@vger.kernel.org New delayed allocation routines cannot be handling transactions so pull them up into the calling functions Signed-off-by: Allison Collins Reviewed-by: Darrick J. Wong Reviewed-by: Brian Foster Reviewed-by: Chandan Rajendra --- fs/xfs/libxfs/xfs_attr.c | 5 +++++ fs/xfs/libxfs/xfs_attr_leaf.c | 5 +---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/fs/xfs/libxfs/xfs_attr.c b/fs/xfs/libxfs/xfs_attr.c index f8c7582..ec5890a 100644 --- a/fs/xfs/libxfs/xfs_attr.c +++ b/fs/xfs/libxfs/xfs_attr.c @@ -1134,6 +1134,11 @@ xfs_attr_node_removename( error = xfs_attr3_leaf_setflag(args); if (error) goto out; + + error = xfs_trans_roll_inode(&args->trans, args->dp); + if (error) + goto out; + error = xfs_attr_rmtval_remove(args); if (error) goto out; diff --git a/fs/xfs/libxfs/xfs_attr_leaf.c b/fs/xfs/libxfs/xfs_attr_leaf.c index ab87bae..b588f8e 100644 --- a/fs/xfs/libxfs/xfs_attr_leaf.c +++ b/fs/xfs/libxfs/xfs_attr_leaf.c @@ -2835,10 +2835,7 @@ xfs_attr3_leaf_setflag( XFS_DA_LOGRANGE(leaf, name_rmt, sizeof(*name_rmt))); } - /* - * Commit the flag value change and start the next trans in series. - */ - return xfs_trans_roll_inode(&args->trans, args->dp); + return 0; } /*