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 73420C05027 for ; Tue, 7 Feb 2023 01:46:12 +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:In-Reply-To:From:References:To:Subject: CC:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=d8K3swITAd3zvZh/OFTHWub3/WP4M+Vp9LwmHfD8kGc=; b=IfrG125jGU9Ex4 xlLjiQvelzV+dqlQ4Ha+7JGl6cBzd9f0g+VqQT2s1DhfXb7nafPsyIFcwN+8OHWiUQ5lpXYlciSMt oREull0YJ0lV3gH6Hw49/C5QHBM196LSSvYB1meN0TQYvBFDRcD32ItOT/X+SFZCRZW2ZrgpSIdYd HvuGAZSKVHKUv11INX4PE0dJ48WNkscmrOxavo0yNdUb/V2c1SN/bDG/mDjwNMa4oXlRv5fH9zUAW pPjs3g3l/tHRf4KpH4tFjplUk7TcaJIK8GA77GAlNjMWwXRSNjAxdhA0P2hT7pgFREiXUF5sDSlfF hmPY2uFlMNfzsQhgdGdQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pPD2S-00AOvq-OV; Tue, 07 Feb 2023 01:44:52 +0000 Received: from szxga08-in.huawei.com ([45.249.212.255]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pPD2H-00AOlZ-Jp for linux-arm-kernel@lists.infradead.org; Tue, 07 Feb 2023 01:44:49 +0000 Received: from dggpemm500014.china.huawei.com (unknown [172.30.72.54]) by szxga08-in.huawei.com (SkyGuard) with ESMTP id 4P9m8X3x00z16NPh; Tue, 7 Feb 2023 09:42:20 +0800 (CST) Received: from [10.174.178.120] (10.174.178.120) by dggpemm500014.china.huawei.com (7.185.36.153) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Tue, 7 Feb 2023 09:44:29 +0800 Message-ID: Date: Tue, 7 Feb 2023 09:44:29 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.7.0 CC: , Subject: Re: Question on "arm64: mm: Prototype to allow drivers to request PBHA values" Content-Language: en-US To: References: <3debf8fe-0182-4e82-bc59-cf40ac7ffb24@huawei.com> <53e27b13-9c97-2811-e941-4bad88a59eea@arm.com> From: mawupeng In-Reply-To: <53e27b13-9c97-2811-e941-4bad88a59eea@arm.com> X-Originating-IP: [10.174.178.120] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To dggpemm500014.china.huawei.com (7.185.36.153) X-CFilter-Loop: Reflected X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230206_174441_898429_EC47D369 X-CRM114-Status: GOOD ( 24.57 ) 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 On 2023/2/4 2:00, James Morse wrote: > Hi mawupeng, > > On 03/02/2023 08:30, mawupeng wrote: >> Thanks for your work on working out what linux needs to support to make use of >> existing SoCs using PBHA[1]. In your example, PBHA can be use memory >> compression or system-cache. > >> This patch set is perfect and covers a wide range of scenarios. What's you >> follow-up plan for this patch set? > > I was hoping we could collect together what PBHA is being used for in existing SoCs, to > work out which of those things we can support in mainline. > > Marc Z had some additional questions on IO and DMA. > > >> In this patch set, devicetree is using to pass the pbha-performance-only >> and pbha-no-aliases attributes to the OS. Since ACPI may be used to do >> such work and there is no suitable acpi table to represent these >> attributes at early acpi parse stage. >> >> Do you have any idea on how to pass these pbha related attributes via >> ACPI? > > The DT binding exists to tell the OS which PBHA values only affect performance, and which > ones mean the page can only be mapped once. > > There is no standard ACPI method that conveys this. I guess the ACPI people would specify > a GUID for each property, then return a Package() of values from something like a _DSM on > _SB. (...if that is allowed...). > > But! Without more of a story about what PBHA is used for, including IO and DMA - as well > as upstream drivers that use it, I think any ACPI support will be premature. > > > Can you share what your SoC uses PBHA for, what drivers need to use it. What happens if > its not supported? (is this a 0.1% performance change, or 10%?). What happens if devices > access those memory locations? (do they need configuring with PBHA bits too?) Thanks for your reply. We want to make a cache used by user tasks in OS(not dirvers), addition PTE flag for kernel page table shoule be introduced in pte. Since there are no avilable bit free in pte and PBHA can be used for such work. We have already disscussed with the hardware them, cache consistency is ensured by hardware. So there maybe no problem with IO and DMA in this scenario. This is just some very early work, but we need to mark sure can be used in the latest OS. Thanks, Ma Wupeng. > > > > Thanks, > > James > _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel