Received: by 2002:a05:7412:419a:b0:f3:1519:9f41 with SMTP id i26csp432396rdh; Thu, 23 Nov 2023 07:48:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IHHMZ9VE1MeUdchOam4sCj9P1Jo1Slv6B0uUQnkgOoWK3GHh9QDfq9fSSqBHyqkpuFtfjI1 X-Received: by 2002:a05:6a21:150a:b0:18a:f462:5d3c with SMTP id nq10-20020a056a21150a00b0018af4625d3cmr10154pzb.12.1700754529776; Thu, 23 Nov 2023 07:48:49 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1700754529; cv=none; d=google.com; s=arc-20160816; b=cINSO3uhCEtsKXnLPJAWviqjyW9nqxc+8klawRj+bP6RL5E5Jek5gtt1DEfJS7LUnL sf5JO4KBTtiribeJBXek8M9/IUSlmq9acmfhoESz89Ubti7kJ84U91LCpsTKPNqv7coW pYDsTYCC4qAG07wMo2U/jR51DbQPKa1+MMXKpPbKSH07yN6E3riaaJva7TVURGXnwlW5 5Wxtpg96wzxibqi8vIFDvyJpZUbYFlJ10gRp13EPHOzc2d69glCkeAp2dcoO60tberC/ O52krDhZAAW5zBDYf08bTTprCzMISITfDwloMQFfdCIYj91VupwxwfsrcMbC8Mr/vleO jJxg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:in-reply-to:references:message-id :content-transfer-encoding:mime-version:subject:date:from :wdcironportexception:ironport-sdr:ironport-sdr:dkim-signature; bh=0EFhPzwCLUVfygSWN8ogLrBEHyZy8e7JjExtZfR5oRk=; fh=5/viNv8Fzx+nCNW5PGLTL+Se/9D0Q8TrzLPV3SudCmU=; b=b5WVxOG5UwAykGB+LeF+52DYWamqDX4751GVb4R3VkKsn+N9/Br4oYhCMgQQ+k6OMO eSDKoQTQdPwmdKwzVU3N6Nn+z2dvGLfN4BwVoUcmVw332pra3InT1u8efkgVkCpP38SC dGIspU58VUhsleuO9YI6dQ9hTV0zEC3l8afOlvkah9bq6O8yBKJRBnfRhol5egH2veB9 NY4PlAAHiNs7+A4vB8n2RPPVlFfVxSxt4FO+B7601hKt1E+56Z1vK3EA8S7Rs14mp2kg PnSxCGYGQ3Mv07sh8Jx4/XroSEbySxXKQD4aXLLgBXZPERJ8lUq8zWgto/AYOSBaKa9+ kq8Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=P9EkNK4F; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=wdc.com Return-Path: Received: from lipwig.vger.email (lipwig.vger.email. [23.128.96.33]) by mx.google.com with ESMTPS id x62-20020a636341000000b005acba4c9bf7si1452509pgb.770.2023.11.23.07.48.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 23 Nov 2023 07:48:49 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) client-ip=23.128.96.33; Authentication-Results: mx.google.com; dkim=fail header.i=@wdc.com header.s=dkim.wdc.com header.b=P9EkNK4F; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.33 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=wdc.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by lipwig.vger.email (Postfix) with ESMTP id 2DB82826CB55; Thu, 23 Nov 2023 07:48:47 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at lipwig.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346241AbjKWPsM (ORCPT + 99 others); Thu, 23 Nov 2023 10:48:12 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:36376 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346198AbjKWPr7 (ORCPT ); Thu, 23 Nov 2023 10:47:59 -0500 Received: from esa3.hgst.iphmx.com (esa3.hgst.iphmx.com [216.71.153.141]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 518B7D48; Thu, 23 Nov 2023 07:48:06 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=wdc.com; i=@wdc.com; q=dns/txt; s=dkim.wdc.com; t=1700754486; x=1732290486; h=from:date:subject:mime-version:content-transfer-encoding: message-id:references:in-reply-to:to:cc; bh=vE95KoUEUEVqVM2tCNXr7cBWfNJDvBLd3iEA6GxxuoA=; b=P9EkNK4Fyxefg8Nh9xZheLqRAzjo1ZK4VNhQDMHH61KV5IBmK7T0Xodh G5Ei9E3eNkSVidZQIFlKyjlVZW66MmaczkmRR45GSeVZCXy2n2aggSqJB id/Foqx2N27YHT4bWJf4jXxfCLZOmKnAj+23dQSF3LJZOiXnpGx57gEsj EV/kheFJhACIEFepUrKZyax2G8Iublty/j4hzFY+C+oyGRcnycsN5Zi3P P+G+nBZIFpnLdWPePqK7pv/JKA4fSIEleEuUdSaS9BdedRo5TukZtx6mb roPX/eQ5khZWcYvpkKlg9xigs+X+bFm0m0rwPp6z5VCrugbBtmUOvgl9K Q==; X-CSE-ConnectionGUID: vSiKT64CRkSzXsD+cCFD9w== X-CSE-MsgGUID: JbJTO0MlRye4ZiuVbGwA9Q== X-IronPort-AV: E=Sophos;i="6.04,222,1695657600"; d="scan'208";a="3129203" Received: from h199-255-45-14.hgst.com (HELO uls-op-cesaep01.wdc.com) ([199.255.45.14]) by ob1.hgst.iphmx.com with ESMTP; 23 Nov 2023 23:47:32 +0800 IronPort-SDR: Z7q65LVjTCH7EXeHHT7IptpGvmzIi2G7osYAHqE64cMT4u32kzGfFPHKTUinyp2CyKOOv209zY ur2iDFgzICKmCe7xOid7EkMkbIMSxPPshfnXGSE2uEGZMTcjfhSz1wTtxC2B/BXiKD197fC9pj p6mjFXBNYRYgYHjMWYpFAgQA6AbKsyuVWyxV1YzfsevMTQtRR3S5nSA5c9LRRtnlOqQafohhaz 4sidaBqF48gFZS1A20OB6envJSFNjGpkKVghW4i2D4CL5qVjhyWBp/yj4JHtGMvXNrK78buGjX JvE= Received: from uls-op-cesaip01.wdc.com ([10.248.3.36]) by uls-op-cesaep01.wdc.com with ESMTP/TLS/ECDHE-RSA-AES128-GCM-SHA256; 23 Nov 2023 06:58:48 -0800 IronPort-SDR: gkVSIe/USso4kaxtBj74U9WtW20W9HtzS5y0cPCf4P5av6WUtxN02k2Y05XzJ8A64gsSWzKdfW LoVxtCD8HDxOFtXB51dBnxYl1lbxXNYJ1HaW7hyx5z9v9ciB+w5CazhjurvOUq3SkWFVTs8d/G nCAUVbMqFxH+B1DdDjPOTzNaqDnPK3mESlziLPhR1L+5Y8PxE/iR6cwjYzk2Pd0mwrVpZXthrs 3VUnQwVXUuxoJ2wsc31rebxXPTso+V2iHOdK4slndG1h94pjbEJp+j4wk831skmZlJSs9pfBUk Nsc= WDCIronportException: Internal Received: from unknown (HELO redsun91.ssa.fujisawa.hgst.com) ([10.149.66.6]) by uls-op-cesaip01.wdc.com with ESMTP; 23 Nov 2023 07:47:29 -0800 From: Johannes Thumshirn Date: Thu, 23 Nov 2023 07:47:18 -0800 Subject: [PATCH v2 4/5] btrfs: use memset_page instead of opencoding it MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20231123-josef-generic-163-v2-4-ed1a79a8e51e@wdc.com> References: <20231123-josef-generic-163-v2-0-ed1a79a8e51e@wdc.com> In-Reply-To: <20231123-josef-generic-163-v2-0-ed1a79a8e51e@wdc.com> To: Chris Mason , Josef Bacik , David Sterba Cc: linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org, Christoph Hellwig , Naohiro Aota , Johannes Thumshirn X-Mailer: b4 0.12.3 X-Developer-Signature: v=1; a=ed25519-sha256; t=1700754443; l=836; i=johannes.thumshirn@wdc.com; s=20230613; h=from:subject:message-id; bh=vE95KoUEUEVqVM2tCNXr7cBWfNJDvBLd3iEA6GxxuoA=; b=YSp9DFeqHURIML2/TvPPdaOoHQ8vExnmR6thl23Knk6cdcnLsOpQafOiB4KrzeJhrnb9xhqpd U8H7KAaTp7YCNmiTquGZIEx5wSB1bNInUPch3TZFNmOQvnz/qTsLzhA X-Developer-Key: i=johannes.thumshirn@wdc.com; a=ed25519; pk=TGmHKs78FdPi+QhrViEvjKIGwReUGCfa+3LEnGoR2KM= X-Spam-Status: No, score=-0.6 required=5.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lipwig.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (lipwig.vger.email [0.0.0.0]); Thu, 23 Nov 2023 07:48:47 -0800 (PST) Use memset_page() in memset_extent_buffer() instead of opencoding it. This does not not change any functionality. Reviewed-by: Christoph Hellwig Reviewed-by: Josef Bacik Signed-off-by: Johannes Thumshirn --- fs/btrfs/extent_io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/btrfs/extent_io.c b/fs/btrfs/extent_io.c index c378094b5cc8..defe0fa04572 100644 --- a/fs/btrfs/extent_io.c +++ b/fs/btrfs/extent_io.c @@ -4195,7 +4195,7 @@ static void memset_extent_buffer(const struct extent_buffer *eb, int c, struct page *page = eb->pages[index]; assert_eb_page_uptodate(eb, page); - memset(page_address(page) + offset, c, cur_len); + memset_page(page, offset, c, cur_len); cur += cur_len; } -- 2.41.0