From patchwork Tue Mar 19 14:55:27 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Jain X-Patchwork-Id: 13596750 Received: from mx0a-00069f02.pphosted.com (mx0a-00069f02.pphosted.com [205.220.165.32]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E177B651A1 for ; Tue, 19 Mar 2024 14:58:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=205.220.165.32 ARC-Seal: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710860309; cv=fail; b=Uh4QINkZi+zsAa5rBsp9+DqHIM3A4Z6MGkZ7oBYp4an/GOv6bP6VuYpIrqXAwZYcXSI1PB6pAc3lEo4C462J0jv3u4iWjqDkRwB/r/OJlvrHYjTAHFHXXTqXiaZeVXqXqkV0AbZDbBKmrHhrInmL/T1f9B0sQ3QCK9kpC/PCR7k= ARC-Message-Signature: i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710860309; c=relaxed/simple; bh=8qkBHx2/fgVMvoBBFIYg+KYOHXcHWlAZSP0I67SVZoM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: Content-Type:MIME-Version; b=qK5NFrzYlIKyrz0vUzLF/hFItNEZc4mtGoKGohA4NoVjzjLr/ioOKy/gnnwWuO1K51dRFs8/8Gfd4vCIQmcOeMqpgTMW4hCECAjTwl18WtN0+WF105fs70Wi5EV4TG7FJM4WWfUiuIZaEKY4r4a71jieMWzW/2Ks4/vfGC6wMT4= ARC-Authentication-Results: i=2; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oracle.com; spf=pass smtp.mailfrom=oracle.com; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b=UMCvaxd9; dkim=pass (1024-bit key) header.d=oracle.onmicrosoft.com header.i=@oracle.onmicrosoft.com header.b=Jeicszgv; arc=fail smtp.client-ip=205.220.165.32 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=oracle.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=oracle.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=oracle.com header.i=@oracle.com header.b="UMCvaxd9"; dkim=pass (1024-bit key) header.d=oracle.onmicrosoft.com header.i=@oracle.onmicrosoft.com header.b="Jeicszgv" Received: from pps.filterd (m0246617.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.17.1.19/8.17.1.19) with ESMTP id 42JAHT1E010227 for ; Tue, 19 Mar 2024 14:58:27 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2023-11-20; bh=Mz8NPVPakTqc4Js7l/NICNWL3SIAvWcEHj3bpysIyVI=; b=UMCvaxd9b1qUks5dpUphPUtGMvE7I/TufgWmB/VZFEhtEPWRgJ+SvdSRT/Rvo+dJ049Z bWtPvUvpAdGIO2IgP2OpCkq4JMfJlEmLGvimYDen0lREC/jt9VRhTJ04jRGx8/Vm64pd 5QkqP6S5jBXVSp1Kguhmj8fvzNW1RF14GOstYt7Q3ocl/Irv715sQppzC0cMiBG/ZrB9 iykimCfJVV1zuTDCOoVPfZX7aEJStALwDZCg9xRKBtIqYPoDcYPBKxl63m9oitDOz5nn dWkytC63qjs3mhpeJ9w7YU2oBY6zOOZNpcz1Wloupo2MdaaWRQV4SGhD9XOHG5TBeWHd Kw== Received: from phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (phxpaimrmta01.appoci.oracle.com [138.1.114.2]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 3ww3yu5ky7-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Tue, 19 Mar 2024 14:58:25 +0000 Received: from pps.filterd (phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com [127.0.0.1]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 42JDoDHU007468 for ; Tue, 19 Mar 2024 14:58:24 GMT Received: from nam10-bn7-obe.outbound.protection.outlook.com (mail-bn7nam10lp2101.outbound.protection.outlook.com [104.47.70.101]) by phxpaimrmta01.imrmtpd1.prodappphxaev1.oraclevcn.com (PPS) with ESMTPS id 3ww1v6cp0x-3 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK) for ; Tue, 19 Mar 2024 14:58:24 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=d4l867FIToEKjunNKLf289QP5m9RDZbnoayIgyO3aTsmNHlsUOUbeTNR7327Nb3+4G4aID5NmlthQj5rfnTPVJyjl/JQJg1U9RU1BKgH6Rsb6+U1rZ3gRut7BbXZZDxBdKCfYiUeRaWP6mh5amQOR3zNSwYzBla3ujGLJdO7DqCAT+DALqsEYluIFq0pO5gkxy2XwgG4DCQ2iUhQ1F7IvdVA4qLW0Katqa8DBwlrKjrD6tCIC1W0ZD+7Lq3ITFCzZwz8INLfNQYuCtrTtzD9D0AMRRIcQ3nnxR14c47tD5soWI9Y5L3STMYkZX4DOx4vE1yt9NNEeNJV5gLBFQY+6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=Mz8NPVPakTqc4Js7l/NICNWL3SIAvWcEHj3bpysIyVI=; b=eRoAGwHk6R8fG6NqC7KtborJjzAvaR2RKtw4JJm6l/NL+eZh8Lar5C47EPxrOLPuLYcPKBTetTfygMX3F6e3E5qFvmr8GBoIIVerIB8cWpVfwDx3CslwkbfCN/iRUg6oBJEtgswlpC+EvuB9v+Rvf4zUCvzOky2GzWxoe2D4dvhpa6q3a/zo9+aZ9c4WjqolzUO12IkOUsrF+l2V+X6Dz6q6XZpNpsCff/BVfior+jmcwyFzaUU6z9In3WTu2jvBjm6+LdCV+d+jYeoI2VuRNGyczmnANfcU+jPAZJNEXHNzJnNwsCMPKTHFolcKAQh4QPYp4I+3lcNGfL0XnnnFKQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Mz8NPVPakTqc4Js7l/NICNWL3SIAvWcEHj3bpysIyVI=; b=JeicszgvSiFvMw09eSZu5qENnDxlXf3AC2jXz0h9VmXypX5aT+VANv6BEgfDR5eH6/EuiWSQP198jpM4MbMAt7h0zaqn7elqen7ioOUmtm/8X2iuzn9AxBnC1UBHbyrwcRb5M6+bIDDR4Q+adwsj03vhkp76CTxGwOY4ojeepAs= Received: from PH0PR10MB5706.namprd10.prod.outlook.com (2603:10b6:510:148::10) by PH8PR10MB6479.namprd10.prod.outlook.com (2603:10b6:510:22d::22) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7362.34; Tue, 19 Mar 2024 14:58:10 +0000 Received: from PH0PR10MB5706.namprd10.prod.outlook.com ([fe80::814:3d5c:443b:17b]) by PH0PR10MB5706.namprd10.prod.outlook.com ([fe80::814:3d5c:443b:17b%7]) with mapi id 15.20.7386.025; Tue, 19 Mar 2024 14:58:10 +0000 From: Anand Jain To: linux-btrfs@vger.kernel.org Cc: Anand Jain Subject: [PATCH 19/29] btrfs: mark_garbage_root rename err to ret2 Date: Tue, 19 Mar 2024 20:25:27 +0530 Message-ID: <417f039ffc4db265a98214c8f86e9a36dbfb1c31.1710857863.git.anand.jain@oracle.com> X-Mailer: git-send-email 2.42.0 In-Reply-To: References: X-ClientProxiedBy: MA0PR01CA0085.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a01:ae::6) To PH0PR10MB5706.namprd10.prod.outlook.com (2603:10b6:510:148::10) Precedence: bulk X-Mailing-List: linux-btrfs@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PH0PR10MB5706:EE_|PH8PR10MB6479:EE_ X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: PxuZpoUPPz205gpMWz8wVZCHBGn7Jbuh4798eIYDva0i9QYtjiaXIAxbqzDxGRdggGP+5qSFa8kz9Y66ozqvJ8OiJGI+HC388sLYHWJC3DpvQUEzFqJleCCVH3ihehb5ExdHyHrdYvqQDXqnimc2e53GT8MXlWvGh++v8CNFZypCus+5/8DTJI8thz7SDp2CCk8JAsw0NRZAmPP+1dwGK4DXyfdGlCae6SAgXFmCbc4ysP5RJstcgKNwrW6oqK2ABpJB+eOE6WUavUXxRq79CvgycA6luVg85eDzyicAC48Sg2pFphbxaIj38ogHZUCQmx1+/HQHIz1joQC34molEUbErBbOyzSgfEzHsKf24Whi6GzNnuNAOsSQL7dFJ8opOTO2sjh4qefVq5Bm/Z99ycSRJsPsSIMJtntGz1rJVgF0fcYX6m/rqJbcGCI+blF0s+qYBgHRkGozGIKh+dZ0VwPsDt36GmqC1OSuzgheW1OYsH9t6HP+1uUGqgAimijJyKhaog18vjJZf4S+Gou1Ctf/c7jTfEOTrGocis/ZMDkjv9/nmTfn5IrJ9yWtj2fFcefvZrpi2M5DwyZedwZkKVBh7q1kYheGgbLBoVH1zvzEjEiT1GLmtSe8D2umWFxajFJsroUQ2zd3XqWVxncLX7xAh5T6H2MRmXpY3+qjmTI= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:PH0PR10MB5706.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(366007)(1800799015)(376005);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 0cvKyoXwJJiifeTBND/kGbwyGptrGbmDZlJIAo4wP6I6hZ9EkpgxPuZoDf839j0Vdq1qc9XcghTE64P75Qv2qbNEjm9BJWEmX2s06UMP0ek7PMYTK3pHKBgBPJm3CV5FrbEbqfRBvKqCZNkWzLwD4flQwhsNGKN9Rzg1iivsrJ5DYO6ES4fETBjih/K4M8Tup+iW5e67bcyu+eTcwhMzjpl/vU50yZqf/u3w42Ee32W4MQm2rWNtOxQ5+EGh4UaOU7GrLFr2Y9EQBFAaUgl788ZGAvqRFRoGB0xmSx+daLkK9cJTklzHO0yI/L3l4UJQyffNmi6RNP3vRfX/tAkS04ZlJn29OKIZ2SK5tdriSZ9TfquO805tBeep4JDSEtPRtXoQZa/F5xgwyH+J/RczNBjRbhi2YfPhgSMdQ1vmonPvvi7OMBqCX7/yYOxysfT/oM/TPJA+63D6ROuxzew+z/Zq6o/MMkDV8V5oX+O4/L+hvi0NLbtTtorOX+rEI+nJE4yV/Y1EL7qRiawujxbVYka2s6MLxIfPVdb1ijXmbYC3RffZiNtx35P25/yJ+q2zjHY0tjeZWdKd7cpzSx8UvbnLrrgLdYG5kLWIjYm8C6qjwM1AALF3dBuzOOgUagCrS2eaWF8BiQlQ3xmhFdP7DWNnJ6v5SrJy09PmEtugEgeQMRp6+d5LsMr0iKbWAN2HnuqtMzXE4w7yoegNHpZ5ZOxxlDcM0MYEBDriJWROxJSmCP9H7S/sK22j2OQE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X6fohti7mIYng08U59K7u0CpsKgdwmQdrcvKvLDBiEOKiHprtmqVEvsTFWURdPeqYRqgwkFso9i9psCtlMDdPb7pQ73FC2AJWbKdyAJKBHod876dDddUWK/h5UOiqVIp2vPoixr1eoZHpfFdWyF0LMcrLk97hH0D7NB5SpxvMuTDugPGGN6ZyXaOpUsQdKk6wKMet87jKevSVbxdNn3dt2FL5Cg3BOSNCxHk749MZk1KT1EpR/g0yb2kvi3u9H0Zr0OUcPMnrVv0V5i5yl+lspzQU3w7eEI2zhCkyRhf5S5qSHPe6EqwTFZGXLHCZ4XMm8IWxrJ70pATndhGnjV8uZKYbeDVVddc9LoHdPpSvbGGiDLQPql/saJj08anwjQrWr1PUYFk92DVPiRC/TcKc6ByVW+RGiOypQBjlP1aJ/skHr0S+TDKjAuvEGnFHHGRoe7kVc9MzGiIEtJ9XTArdsedi+l/+WTewepDMBymHoh/6GDCyvyzOOLRUYzuD9CqrutQ+mBd0= X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 35e291ab-402e-46e0-bc2b-08dc4824fe93 X-MS-Exchange-CrossTenant-AuthSource: PH0PR10MB5706.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Mar 2024 14:58:10.7822 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Hent8fyAdZm/3bNAA0V8ZGtHSL50hRckDocxJXFpcNRgs8ZcKMkoA1cpaORmmtGwqgMUHYIyxoiEq5+thLTNpw== X-MS-Exchange-Transport-CrossTenantHeadersStamped: PH8PR10MB6479 X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.272,Aquarius:18.0.1011,Hydra:6.0.619,FMLib:17.11.176.26 definitions=2024-03-19_04,2024-03-18_03,2023-05-22_02 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 bulkscore=0 mlxlogscore=999 malwarescore=0 adultscore=0 suspectscore=0 mlxscore=0 phishscore=0 spamscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2403140000 definitions=main-2403190114 X-Proofpoint-GUID: tCNuskWrJEmekk-iAcq0S4P6E76EbYsM X-Proofpoint-ORIG-GUID: tCNuskWrJEmekk-iAcq0S4P6E76EbYsM In this function, the variable err is used as the second return value. If it is not zero, rename it to ret2. Signed-off-by: Anand Jain --- fs/btrfs/relocation.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/fs/btrfs/relocation.c b/fs/btrfs/relocation.c index 030262943190..6f8747c907d5 100644 --- a/fs/btrfs/relocation.c +++ b/fs/btrfs/relocation.c @@ -4223,7 +4223,8 @@ static noinline_for_stack int mark_garbage_root(struct btrfs_root *root) { struct btrfs_fs_info *fs_info = root->fs_info; struct btrfs_trans_handle *trans; - int ret, err; + int ret; + int ret2; trans = btrfs_start_transaction(fs_info->tree_root, 0); if (IS_ERR(trans)) @@ -4236,9 +4237,10 @@ static noinline_for_stack int mark_garbage_root(struct btrfs_root *root) ret = btrfs_update_root(trans, fs_info->tree_root, &root->root_key, &root->root_item); - err = btrfs_end_transaction(trans); - if (err) - return err; + ret2 = btrfs_end_transaction(trans); + if (ret2) + return ret2; + return ret; }