From patchwork Thu Aug 27 00:28:31 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Allison Henderson X-Patchwork-Id: 11739759 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 D03E4722 for ; Thu, 27 Aug 2020 00:31:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id B8602207CD for ; Thu, 27 Aug 2020 00:31:15 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="uY+8QvR6" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726995AbgH0AbN (ORCPT ); Wed, 26 Aug 2020 20:31:13 -0400 Received: from aserp2120.oracle.com ([141.146.126.78]:55400 "EHLO aserp2120.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726444AbgH0AbN (ORCPT ); Wed, 26 Aug 2020 20:31:13 -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 07R0U0bW068451 for ; Thu, 27 Aug 2020 00:31:12 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=r0x2BSIyXCpHXjC2q6KFBDhAj4t029959eTU6EvbFFI=; b=uY+8QvR6GUaP5BRhLW8jozn4ifSwjI1axPZb0Mgr5laHgQ5ph2U3sxpRauhhZHHp4ulF IfIuwph/fpEizyoCbZrKXJKu+JnoeQoSduIH7qLjBrp2Ghi2vgARI7zjhTZQtRVT/E57 gic1CYS5h+i7CS7ItCJYQXbNN735IQmwewVg5YE9QEdD2uaqDb134uOkMaRfFIar/SIE boVu+PogpDcgqFTMb8MfigivdtQ2s1NmF2eW2rBGdovdTYT5n6z91fNwRu+hhoVmEOBU TSP48+DNQ1iYR9FYmlieGGbd0yQ4SNfSDRBzzFf/e4mYIs2bvmzL0BGwKCx3j9Kig+1S lQ== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by aserp2120.oracle.com with ESMTP id 333dbs3e2s-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL) for ; Thu, 27 Aug 2020 00:31:12 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 07R0Aqw3025926 for ; Thu, 27 Aug 2020 00:29:11 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by aserp3030.oracle.com with ESMTP id 333r9mswt9-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Thu, 27 Aug 2020 00:29:11 +0000 Received: from abhmp0012.oracle.com (abhmp0012.oracle.com [141.146.116.18]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id 07R0TBmK016885 for ; Thu, 27 Aug 2020 00:29:11 GMT Received: from localhost.localdomain (/67.1.244.254) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Wed, 26 Aug 2020 17:29:11 -0700 From: Allison Collins To: linux-xfs@vger.kernel.org Subject: [PATCH v12 07/32] xfsprogs: Pull up trans roll from xfs_attr3_leaf_setflag Date: Wed, 26 Aug 2020 17:28:31 -0700 Message-Id: <20200827002856.1131-8-allison.henderson@oracle.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200827002856.1131-1-allison.henderson@oracle.com> References: <20200827002856.1131-1-allison.henderson@oracle.com> X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9725 signatures=668679 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 malwarescore=0 mlxscore=0 bulkscore=0 adultscore=0 spamscore=0 mlxlogscore=999 phishscore=0 suspectscore=1 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2008270000 X-Proofpoint-Virus-Version: vendor=nai engine=6000 definitions=9725 signatures=668679 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 clxscore=1015 priorityscore=1501 impostorscore=0 phishscore=0 malwarescore=0 mlxlogscore=999 spamscore=0 mlxscore=0 lowpriorityscore=0 suspectscore=1 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2006250000 definitions=main-2008270001 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 --- libxfs/xfs_attr.c | 5 +++++ libxfs/xfs_attr_leaf.c | 5 +---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/libxfs/xfs_attr.c b/libxfs/xfs_attr.c index 8180134..5cdaac1 100644 --- a/libxfs/xfs_attr.c +++ b/libxfs/xfs_attr.c @@ -1132,6 +1132,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/libxfs/xfs_attr_leaf.c b/libxfs/xfs_attr_leaf.c index 2d4c91b..d34ead2 100644 --- a/libxfs/xfs_attr_leaf.c +++ b/libxfs/xfs_attr_leaf.c @@ -2827,10 +2827,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; } /*