Message ID | 20240814161944.55347-8-sidhartha.kumar@oracle.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 91806C531DC for <linux-mm@archiver.kernel.org>; Wed, 14 Aug 2024 16:20:28 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 860886B009E; Wed, 14 Aug 2024 12:20:09 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 810786B00A0; Wed, 14 Aug 2024 12:20:09 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5CB386B00A1; Wed, 14 Aug 2024 12:20:09 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0016.hostedemail.com [216.40.44.16]) by kanga.kvack.org (Postfix) with ESMTP id 16ACE6B009E for <linux-mm@kvack.org>; Wed, 14 Aug 2024 12:20:09 -0400 (EDT) Received: from smtpin09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id B444781058 for <linux-mm@kvack.org>; Wed, 14 Aug 2024 16:20:08 +0000 (UTC) X-FDA: 82451362896.09.9F16315 Received: from mx0b-00069f02.pphosted.com (mx0b-00069f02.pphosted.com [205.220.177.32]) by imf21.hostedemail.com (Postfix) with ESMTP id 970B61C0010 for <linux-mm@kvack.org>; Wed, 14 Aug 2024 16:20:06 +0000 (UTC) Authentication-Results: imf21.hostedemail.com; dkim=pass header.d=oracle.com header.s=corp-2023-11-20 header.b=F3mLM2xR; spf=pass (imf21.hostedemail.com: domain of sidhartha.kumar@oracle.com designates 205.220.177.32 as permitted sender) smtp.mailfrom=sidhartha.kumar@oracle.com; dmarc=pass (policy=reject) header.from=oracle.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1723652394; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=yQLRA/Ga16U7VMfZQaR29Wpf+8YrtU3+vrypmAwrPwY=; b=V25ZCHLzFmYQyWb1byu120dyXwypfXBfqs+k+FCvBhfI2GgtaAtkOpsMgZA2n7PUiJYNKC UZg1AVc1z31+U9AY1LW84QGolydPn9rDaJkCzqmR75f6yeY4WE4r8t3eeQKR8lnxc91V7m tIbWRviF8djH1dR1qtHhMNTf32+yGmc= ARC-Authentication-Results: i=1; imf21.hostedemail.com; dkim=pass header.d=oracle.com header.s=corp-2023-11-20 header.b=F3mLM2xR; spf=pass (imf21.hostedemail.com: domain of sidhartha.kumar@oracle.com designates 205.220.177.32 as permitted sender) smtp.mailfrom=sidhartha.kumar@oracle.com; dmarc=pass (policy=reject) header.from=oracle.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1723652394; a=rsa-sha256; cv=none; b=OKQ4sPg7Xe2LHRNcTwmgaSU4Xhn8W0b7KCkTHJ/cScHp43APT0AL/4tw94ypolWXF2N62D KdtxLP31adPISDAKbe0FCizlGIHfbUBYnHoJrOapJS6WWLXQP7U1ocxauR/38+NhLXPFfT WYgaieMO9Lm1BMccFrjxWfIFhiPbjio= Received: from pps.filterd (m0246631.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.18.1.2/8.18.1.2) with ESMTP id 47EBtWAs015137; Wed, 14 Aug 2024 16:19:54 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 :mime-version:content-transfer-encoding; s=corp-2023-11-20; bh=y QLRA/Ga16U7VMfZQaR29Wpf+8YrtU3+vrypmAwrPwY=; b=F3mLM2xR4tJ3Oq+yS Z6ZG4TQX6FgoktAaKwRIiQ2RwkyHITAtmNWhllAFHYq8TDsWJCV8nQGV0iMiw7Sy 1A/eFAAXojAnoTXeiip2NCWbq5Mcp4WoFZ6x6GHdbUvH5CJkiMH269kO78MGveuO FShW7X+nLVVzrgD2rtesW/YSWmtwNH9vkui/mmoQbaRHY6BqWZeyFTFdm6vTbjZX HzPGiHln13VHhEPsLdBFvAYIHtNB2vsXe+S1zkhNmpRzhdZCwdLv7HMHDN6sX9Th bAKDvXXRfc6gorraHM5btgJn4L+uzx6yKt8sy6Z292px5dTuMpcSAeqz5HqPy7iN +5ShQ== Received: from iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta02.appoci.oracle.com [147.154.18.20]) by mx0b-00069f02.pphosted.com (PPS) with ESMTPS id 40wy030v8q-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 14 Aug 2024 16:19:54 +0000 (GMT) Received: from pps.filterd (iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (8.17.1.19/8.17.1.19) with ESMTP id 47EFCIm0021084; Wed, 14 Aug 2024 16:19:53 GMT Received: from pps.reinject (localhost [127.0.0.1]) by iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTPS id 40wxngn7nn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 14 Aug 2024 16:19:53 +0000 Received: from iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com [127.0.0.1]) by pps.reinject (8.17.1.5/8.17.1.5) with ESMTP id 47EGIvCA035951; Wed, 14 Aug 2024 16:19:53 GMT Received: from sidkumar-mac.us.oracle.com (dhcp-10-65-174-212.vpn.oracle.com [10.65.174.212]) by iadpaimrmta02.imrmtpd1.prodappiadaev1.oraclevcn.com (PPS) with ESMTP id 40wxngn7gt-8; Wed, 14 Aug 2024 16:19:53 +0000 From: Sidhartha Kumar <sidhartha.kumar@oracle.com> To: linux-kernel@vger.kernel.org, maple-tree@lists.infradead.org Cc: linux-mm@kvack.org, akpm@linux-foundation.org, liam.howlett@oracle.com, willy@infradead.org, surenb@google.com, Sidhartha Kumar <sidhartha.kumar@oracle.com>, "Liam R. Howlett" <Liam.Howlett@oracle.com> Subject: [PATCH v4 07/17] maple_tree: use mas_store_gfp() in mtree_store_range() Date: Wed, 14 Aug 2024 12:19:34 -0400 Message-ID: <20240814161944.55347-8-sidhartha.kumar@oracle.com> X-Mailer: git-send-email 2.46.0 In-Reply-To: <20240814161944.55347-1-sidhartha.kumar@oracle.com> References: <20240814161944.55347-1-sidhartha.kumar@oracle.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.293,Aquarius:18.0.1039,Hydra:6.0.680,FMLib:17.12.28.16 definitions=2024-08-14_12,2024-08-13_02,2024-05-17_01 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 mlxscore=0 bulkscore=0 phishscore=0 malwarescore=0 suspectscore=0 spamscore=0 mlxlogscore=999 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2407110000 definitions=main-2408140111 X-Proofpoint-GUID: a4z5tUvF5q0S00dZBPlU9FsYu2pVjaT8 X-Proofpoint-ORIG-GUID: a4z5tUvF5q0S00dZBPlU9FsYu2pVjaT8 X-Rspam-User: X-Stat-Signature: qkzzmgqdm7pfsohzh1nctofcb4cw4m7t X-Rspamd-Queue-Id: 970B61C0010 X-Rspamd-Server: rspam11 X-HE-Tag: 1723652406-634325 X-HE-Meta: U2FsdGVkX18fhn4aYRKJ8R0hrrzHLfU0hVhkzFb4B44hG0HtHb7QAF9SQ/NUUNgwB/M6E3ztadvR4y2uTh9mWbphUc8u7bnkv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qsVblYi8ozeSjRzNzJe6Z1v8SZCdHosPksZ8BqIeWPXGmaHge7a+niUK8Gb3khXI9Ctllsii0e4gVJtW7cTVg= X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> List-Subscribe: <mailto:majordomo@kvack.org> List-Unsubscribe: <mailto:majordomo@kvack.org> |
Series |
Introduce a store type enum for the Maple tree
|
expand
|
diff --git a/lib/maple_tree.c b/lib/maple_tree.c index 8ba52ffa778e..e01e05be6301 100644 --- a/lib/maple_tree.c +++ b/lib/maple_tree.c @@ -6476,7 +6476,6 @@ int mtree_store_range(struct maple_tree *mt, unsigned long index, unsigned long last, void *entry, gfp_t gfp) { MA_STATE(mas, mt, index, last); - MA_WR_STATE(wr_mas, &mas, entry); int ret = 0; trace_ma_write(__func__, &mas, 0, entry); @@ -6487,17 +6486,9 @@ int mtree_store_range(struct maple_tree *mt, unsigned long index, return -EINVAL; mtree_lock(mt); -retry: - mas_wr_store_entry(&wr_mas); - if (mas_nomem(&mas, gfp)) - goto retry; - + ret = mas_store_gfp(&mas, entry, gfp); mtree_unlock(mt); - if (mas_is_err(&mas)) - ret = xa_err(mas.node); - - mas_destroy(&mas); return ret; } EXPORT_SYMBOL(mtree_store_range);