Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp259187pxv; Thu, 24 Jun 2021 07:20:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxSaHn9wJH8pZ5ELOmFHTTbj4J2xXp0a4VQZ7RfQ14yftxCXL2A+IIbtUiDydAtKW5EW48j X-Received: by 2002:a02:b786:: with SMTP id f6mr4914971jam.65.1624544446447; Thu, 24 Jun 2021 07:20:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624544446; cv=none; d=google.com; s=arc-20160816; b=RP9QDOwXr8syqSAsXCKLo+kgePiCi4vcyY1KdThb1Qu7sk6UIyRIcwP+n8dOMgLwEh j9jHCq7q8h1PdxCESkpB7+UozrjWcCa0+OKxXU7koowTkpNhJyte/1IJ5VZrjtWouB/P nAeLzwPP6DhJfsoLYToK4qpNmDDOe12Q+4i4ldO/AgE/sE0xrOnkcvW/2kSp4Hvat0le EZ0XFQM/aRcVfvXL087n1LnTBmWTWchnNo+K7Za5RHtNYbJlhayL23OOKWdroB1wZ8W2 Irbh0zwBa2Zl/qUuGra0kPh/7LhFRuuWNIClseHS/kONXd9xv5MrLu7Qh6BSFcuUecdJ u2qQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=394U6srmln3yD0HoN+CQEP/2Dh23OahPAjLQRpfSj3s=; b=m4lfSYG7cdB25MnCGthXKdmIMzXUdiMcsg/x5ms3nVRBZTWkbB7D3pdHBCUthAXtfZ s1q0BSpgqoMVmE3UpCj/D5so4VLdmm67Pqhv6zs5i3WmpdF+X3vd3sE/v5pQRB3gb/mW FtRZ+iIbZOp4mQhCnAbAlMIlJnCx/TWpmX/E4C+4juihSbql2tQWz/sz+LRoKNlAkNhI cpqDPsbbfU/KPKWXqAT8+XVS1Z8Uj6RuGE/LYyIH/HVKsghaZ8TgaUPDpPEnkS7VFPUF o7LCup6/m0M6fCkZdCu5MaxRWie1PPDOcA1Rqm6HjhNEdfzk0FHUDufjZ9fcPMUC41p3 gO3A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u6si3454718ilq.55.2021.06.24.07.20.34; Thu, 24 Jun 2021 07:20:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231969AbhFXOU0 (ORCPT + 99 others); Thu, 24 Jun 2021 10:20:26 -0400 Received: from szxga02-in.huawei.com ([45.249.212.188]:5424 "EHLO szxga02-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229878AbhFXOUZ (ORCPT ); Thu, 24 Jun 2021 10:20:25 -0400 Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.54]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4G9hwR2GpQz73tq; Thu, 24 Jun 2021 22:14:47 +0800 (CST) Received: from dggemi759-chm.china.huawei.com (10.1.198.145) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2176.2; Thu, 24 Jun 2021 22:18:03 +0800 Received: from [10.67.102.67] (10.67.102.67) by dggemi759-chm.china.huawei.com (10.1.198.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Thu, 24 Jun 2021 22:18:02 +0800 Subject: Re: [PATCH net-next 1/3] arm64: barrier: add DGH macros to control memory accesses merging To: Mark Rutland , Will Deacon CC: , , , , , , , , , , References: <1624360271-17525-1-git-send-email-huangguangbin2@huawei.com> <1624360271-17525-2-git-send-email-huangguangbin2@huawei.com> <20210622121630.GC30757@willie-the-truck> <20210622123221.GA71782@C02TD0UTHF1T.local> From: "huangguangbin (A)" Message-ID: <7561019b-f8e6-2191-5aba-3464f06be537@huawei.com> Date: Thu, 24 Jun 2021 22:18:03 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.2.2 MIME-Version: 1.0 In-Reply-To: <20210622123221.GA71782@C02TD0UTHF1T.local> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.67.102.67] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggemi759-chm.china.huawei.com (10.1.198.145) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2021/6/22 20:32, Mark Rutland wrote: > On Tue, Jun 22, 2021 at 01:16:31PM +0100, Will Deacon wrote: >> On Tue, Jun 22, 2021 at 07:11:09PM +0800, Guangbin Huang wrote: >>> From: Xiongfeng Wang >>> >>> DGH prohibits merging memory accesses with Normal-NC or Device-GRE >>> attributes before the hint instruction with any memory accesses >>> appearing after the hint instruction. Provide macros to expose it to the >>> arch code. >> >> Hmm. >> >> The architecture states: >> >> | DGH is a hint instruction. A DGH instruction is not expected to be >> | performance optimal to merge memory accesses with Normal Non-cacheable >> | or Device-GRE attributes appearing in program order before the hint >> | instruction with any memory accesses appearing after the hint instruction >> | into a single memory transaction on an interconnect. >> >> which doesn't make a whole lot of sense to me, in all honesty. > > I think there are some missing words, and this was supposed to say > something like: > > | DGH is a hint instruction. A DGH instruction *indicates that it* is > | not expected to be performance optimal to merge memory accesses with > | Normal Non-cacheable or Device-GRE attributes appearing in program > | order before the hint instruction with any memory accesses appearing > | after the hint instruction into a single memory transaction on an > | interconnect. > > ... i.e. it's a hint to the CPU to avoid merging accesses which are > either side of the DGH, so that the prior accesses don't get > indefinitely delayed waiting to be merged. > > I'll try to get the documentation fixed, since as-is the wording does > not make sense. > > Thanks, > Mark. > . > Thanks very much, we will fix the documentation. Thanks, Guangbin, .