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 E17F8C433EF for ; Mon, 3 Jan 2022 06:32:11 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231890AbiACGcK (ORCPT ); Mon, 3 Jan 2022 01:32:10 -0500 Received: from out30-43.freemail.mail.aliyun.com ([115.124.30.43]:51466 "EHLO out30-43.freemail.mail.aliyun.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231848AbiACGcJ (ORCPT ); Mon, 3 Jan 2022 01:32:09 -0500 X-Alimail-AntiSpam: AC=PASS;BC=-1|-1;BR=01201311R171e4;CH=green;DM=||false|;DS=||;FP=0|-1|-1|-1|0|-1|-1|-1;HT=e01e04426;MF=jefflexu@linux.alibaba.com;NM=1;PH=DS;RN=12;SR=0;TI=SMTPD_---0V0dXccU_1641191526; Received: from 192.168.31.65(mailfrom:jefflexu@linux.alibaba.com fp:SMTPD_---0V0dXccU_1641191526) by smtp.aliyun-inc.com(127.0.0.1); Mon, 03 Jan 2022 14:32:07 +0800 Message-ID: Date: Mon, 3 Jan 2022 14:32:05 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.3.2 Subject: Re: [PATCH v1 13/23] erofs: implement fscache-based data read Content-Language: en-US From: JeffleXu To: dhowells@redhat.com, linux-cachefs@redhat.com, xiang@kernel.org, chao@kernel.org, linux-erofs@lists.ozlabs.org Cc: linux-fsdevel@vger.kernel.org, joseph.qi@linux.alibaba.com, bo.liu@linux.alibaba.com, tao.peng@linux.alibaba.com, gerry@linux.alibaba.com, eguan@linux.alibaba.com, linux-kernel@vger.kernel.org References: <20211227125444.21187-1-jefflexu@linux.alibaba.com> <20211227125444.21187-14-jefflexu@linux.alibaba.com> In-Reply-To: <20211227125444.21187-14-jefflexu@linux.alibaba.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 12/27/21 8:54 PM, Jeffle Xu wrote: > > +static inline void do_copy_page(struct page *from, struct page *to, > + size_t offset, size_t len) > +{ > + char *vfrom, *vto; > + > + vfrom = kmap_atomic(from); > + vto = kmap_atomic(to); > + memcpy(vto, vfrom + offset, len); > + kunmap_atomic(vto); > + kunmap_atomic(vfrom); > +} > + It seems that this private function can be replaced by memcpy_page(). Will be done in the next version. -- Thanks, Jeffle 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 lists.ozlabs.org (lists.ozlabs.org [112.213.38.117]) (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 5EEE5C433EF for ; Mon, 3 Jan 2022 06:33:08 +0000 (UTC) Received: from boromir.ozlabs.org (localhost [IPv6:::1]) by lists.ozlabs.org (Postfix) with ESMTP id 4JS5Xf4Dymz2yp0 for ; Mon, 3 Jan 2022 17:33:06 +1100 (AEDT) Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=linux.alibaba.com (client-ip=115.124.30.57; helo=out30-57.freemail.mail.aliyun.com; envelope-from=jefflexu@linux.alibaba.com; receiver=) Received: from out30-57.freemail.mail.aliyun.com (out30-57.freemail.mail.aliyun.com [115.124.30.57]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4JS5XS3PV4z2xDV for ; Mon, 3 Jan 2022 17:32:52 +1100 (AEDT) X-Alimail-AntiSpam: AC=PASS; BC=-1|-1; BR=01201311R171e4; CH=green; DM=||false|; DS=||; FP=0|-1|-1|-1|0|-1|-1|-1; HT=e01e04426; MF=jefflexu@linux.alibaba.com; NM=1; PH=DS; RN=12; SR=0; TI=SMTPD_---0V0dXccU_1641191526; Received: from 192.168.31.65(mailfrom:jefflexu@linux.alibaba.com fp:SMTPD_---0V0dXccU_1641191526) by smtp.aliyun-inc.com(127.0.0.1); Mon, 03 Jan 2022 14:32:07 +0800 Message-ID: Date: Mon, 3 Jan 2022 14:32:05 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.3.2 Subject: Re: [PATCH v1 13/23] erofs: implement fscache-based data read Content-Language: en-US From: JeffleXu To: dhowells@redhat.com, linux-cachefs@redhat.com, xiang@kernel.org, chao@kernel.org, linux-erofs@lists.ozlabs.org References: <20211227125444.21187-1-jefflexu@linux.alibaba.com> <20211227125444.21187-14-jefflexu@linux.alibaba.com> In-Reply-To: <20211227125444.21187-14-jefflexu@linux.alibaba.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-BeenThere: linux-erofs@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development of Linux EROFS file system List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: tao.peng@linux.alibaba.com, linux-kernel@vger.kernel.org, joseph.qi@linux.alibaba.com, bo.liu@linux.alibaba.com, linux-fsdevel@vger.kernel.org, eguan@linux.alibaba.com, gerry@linux.alibaba.com Errors-To: linux-erofs-bounces+linux-erofs=archiver.kernel.org@lists.ozlabs.org Sender: "Linux-erofs" On 12/27/21 8:54 PM, Jeffle Xu wrote: > > +static inline void do_copy_page(struct page *from, struct page *to, > + size_t offset, size_t len) > +{ > + char *vfrom, *vto; > + > + vfrom = kmap_atomic(from); > + vto = kmap_atomic(to); > + memcpy(vto, vfrom + offset, len); > + kunmap_atomic(vto); > + kunmap_atomic(vfrom); > +} > + It seems that this private function can be replaced by memcpy_page(). Will be done in the next version. -- Thanks, Jeffle