From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 3FCC0C77B75 for ; Sat, 6 May 2023 08:37:30 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:Subject:Cc:To:From:Mime-Version: Message-ID:Date:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To: References:List-Owner; bh=SdvmodNl/mIeNul+nun1lpDIb+sFTfrkVvIo6AuzeQo=; b=JcO 3vYhqvNy8kCAzbgEqGQfzwEn5R30sCx/HRXDstW6fJbm7DCRpkkvmIo3D1ZWhRmBnJRMr5ApxLBl/ 8K/idODt78gxlwEwBol93Pcj/7ibjgn17q/auN9iMzMWL2X915A0FeFKtPItAJj0Nu7U6v1YXqCrH DVY36tXGRpFWiC1PUsswGrDbDJ8qKhRkT9i2rluE+LVSmkoZhiiAAbYDpHI6Rp6gZZPUvIQ/vDTmS 0kAj82C1lMdiz6lQtZZ/rHuMhCjXa/nCf3jirb2vdQFBiFOJVxy65u9Y+9uNuEdQCLGwMao07ninT j3TI3iKxWbdZVGfIjuqXi326wLHc9nQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1pvDPJ-00CtnK-0D; Sat, 06 May 2023 08:36:45 +0000 Received: from mxhk.zte.com.cn ([63.216.63.35]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1pvDPG-00Ctlr-0E for linux-arm-kernel@lists.infradead.org; Sat, 06 May 2023 08:36:43 +0000 Received: from mse-fl1.zte.com.cn (unknown [10.5.228.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mxhk.zte.com.cn (FangMail) with ESMTPS id 4QD19z10Nwz5B15R; Sat, 6 May 2023 16:36:39 +0800 (CST) Received: from xaxapp03.zte.com.cn ([10.88.97.17]) by mse-fl1.zte.com.cn with SMTP id 3468aSm2011905; Sat, 6 May 2023 16:36:28 +0800 (+08) (envelope-from ye.xingchen@zte.com.cn) Received: from mapi (xaxapp02[null]) by mapi (Zmail) with MAPI id mid31; Sat, 6 May 2023 16:36:31 +0800 (CST) Date: Sat, 6 May 2023 16:36:31 +0800 (CST) X-Zmail-TransId: 2afa6456118fffffffffc0a-70564 X-Mailer: Zmail v1.0 Message-ID: <202305061636313011243@zte.com.cn> Mime-Version: 1.0 From: To: Cc: , , , , Subject: =?UTF-8?B?W1BBVENIXSBhcm02NDogbW06IHVzZSBiaXRtYXBfemVybygpIEFQSQ==?= X-MAIL: mse-fl1.zte.com.cn 3468aSm2011905 X-Fangmail-Gw-Spam-Type: 0 X-Fangmail-Anti-Spam-Filtered: true X-Fangmail-MID-QID: 64561197.000/4QD19z10Nwz5B15R X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230506_013642_269100_C2D35A3B X-CRM114-Status: UNSURE ( 9.73 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Ye Xingchen bitmap_zero() is faster than bitmap_clear(), so use bitmap_zero() instead of bitmap_clear(). Signed-off-by: Ye Xingchen --- arch/arm64/mm/context.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/mm/context.c b/arch/arm64/mm/context.c index e1e0dca01839..ed0bf7f8e8ce 100644 --- a/arch/arm64/mm/context.c +++ b/arch/arm64/mm/context.c @@ -95,7 +95,7 @@ static void set_reserved_asid_bits(void) else if (arm64_kernel_unmapped_at_el0()) set_kpti_asid_bits(asid_map); else - bitmap_clear(asid_map, 0, NUM_USER_ASIDS); + bitmap_zero(asid_map, NUM_USER_ASIDS); } #define asid_gen_match(asid) \ -- 2.25.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 21963C77B75 for ; Sat, 6 May 2023 08:36:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231694AbjEFIgn (ORCPT ); Sat, 6 May 2023 04:36:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36914 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229872AbjEFIgl (ORCPT ); Sat, 6 May 2023 04:36:41 -0400 Received: from mxhk.zte.com.cn (mxhk.zte.com.cn [63.216.63.35]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 9BE60659F for ; Sat, 6 May 2023 01:36:40 -0700 (PDT) Received: from mse-fl1.zte.com.cn (unknown [10.5.228.132]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mxhk.zte.com.cn (FangMail) with ESMTPS id 4QD19z10Nwz5B15R; Sat, 6 May 2023 16:36:39 +0800 (CST) Received: from xaxapp03.zte.com.cn ([10.88.97.17]) by mse-fl1.zte.com.cn with SMTP id 3468aSm2011905; Sat, 6 May 2023 16:36:28 +0800 (+08) (envelope-from ye.xingchen@zte.com.cn) Received: from mapi (xaxapp02[null]) by mapi (Zmail) with MAPI id mid31; Sat, 6 May 2023 16:36:31 +0800 (CST) Date: Sat, 6 May 2023 16:36:31 +0800 (CST) X-Zmail-TransId: 2afa6456118fffffffffc0a-70564 X-Mailer: Zmail v1.0 Message-ID: <202305061636313011243@zte.com.cn> Mime-Version: 1.0 From: To: Cc: , , , , Subject: =?UTF-8?B?W1BBVENIXSBhcm02NDogbW06IHVzZSBiaXRtYXBfemVybygpIEFQSQ==?= Content-Type: text/plain; charset="UTF-8" X-MAIL: mse-fl1.zte.com.cn 3468aSm2011905 X-Fangmail-Gw-Spam-Type: 0 X-Fangmail-Anti-Spam-Filtered: true X-Fangmail-MID-QID: 64561197.000/4QD19z10Nwz5B15R Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Ye Xingchen bitmap_zero() is faster than bitmap_clear(), so use bitmap_zero() instead of bitmap_clear(). Signed-off-by: Ye Xingchen --- arch/arm64/mm/context.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/mm/context.c b/arch/arm64/mm/context.c index e1e0dca01839..ed0bf7f8e8ce 100644 --- a/arch/arm64/mm/context.c +++ b/arch/arm64/mm/context.c @@ -95,7 +95,7 @@ static void set_reserved_asid_bits(void) else if (arm64_kernel_unmapped_at_el0()) set_kpti_asid_bits(asid_map); else - bitmap_clear(asid_map, 0, NUM_USER_ASIDS); + bitmap_zero(asid_map, NUM_USER_ASIDS); } #define asid_gen_match(asid) \ -- 2.25.1