Received: by 2002:a05:6359:6284:b0:131:369:b2a3 with SMTP id se4csp88252rwb; Fri, 4 Aug 2023 09:32:38 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGUfdSNdMiGojM7q4JL5QERcJFofUn5gjFWc1JCH1oNsG3yC7c9k8/zgzdAx2PVre60BM2d X-Received: by 2002:a19:914d:0:b0:4fb:772a:af12 with SMTP id y13-20020a19914d000000b004fb772aaf12mr1547639lfj.21.1691166758517; Fri, 04 Aug 2023 09:32:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1691166758; cv=none; d=google.com; s=arc-20160816; b=QzUBHPaiqhaJymiGcIikmLr5V8+hasUFLuAOG9xhdv5x9T1jT/OXFZC/8FGHug/euM 7H2u7xygEHHy4YfybhQ7RRR6gmfbRz++9LG8cc9w+UzAsIaOOYELekux0kKo7Ry2L4No B6W8xV3Up4MJfEy3MXmLg3ioXvBbtkuYEZ9xan4q9vkL+kZMx/UmcwT+UnbDU3tbyUZp 4LBPenYqjjYTywnXk8CGPGh6Cjq2UEFcya/2S7YtI7VqsrFzMLC6jBF6U5PuvwHnOxsi 5mKOFd/oZ6VlE1/ud328umEqrfOpEFhSLpmRyjmY8RPpeMQsQnOQUIWWPLejjXsEW8JI Twmg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=haxLgvz1q5Yk+iNcNNjz/9sW15Tc+C/ITeGdkf6c1Xw=; fh=kMP2mvqIfRlmAQk7phFOSUQpNKNjeiiG/ZGVGxxa6iI=; b=AsFjfTm1WdgawamLJn8+rtS//fVkjrCBONuZn3QFfACO79QQFA5TnI868EMvGmbITB MhWCHKi63pBqVa7/B7CPFihWgtqTnyu3X0Yfo+iNNapT8sTnjLAKuWFDydV6L7biotKR V/th23Zv0Ra9g+GdihcC8DgvAUr9rhsy2nRZuEfHe2826CYA+sQHN93BQCUcxM8CgEV6 WjcM3qIj4T0qVbEldnI3iX+HgKNkwL1oD6ISkYZTnXDC3NfKg/q5bgOkBH3Cg4doREEX GJtwKpGQ+REQxL/0wAS8n116Ep3Aj0MEICkkp8f3HDyZmhmks8NiG1gREFsviJqZA10L OXHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=RJB6NZdN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qh28-20020a170906ecbc00b0099b7a166dccsi1989623ejb.308.2023.08.04.09.32.13; Fri, 04 Aug 2023 09:32:38 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=RJB6NZdN; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231856AbjHDO7e (ORCPT + 99 others); Fri, 4 Aug 2023 10:59:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41802 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229714AbjHDO7d (ORCPT ); Fri, 4 Aug 2023 10:59:33 -0400 Received: from mail-ej1-x632.google.com (mail-ej1-x632.google.com [IPv6:2a00:1450:4864:20::632]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 621E7AC for ; Fri, 4 Aug 2023 07:59:32 -0700 (PDT) Received: by mail-ej1-x632.google.com with SMTP id a640c23a62f3a-99bccc9ec02so316478766b.2 for ; Fri, 04 Aug 2023 07:59:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1691161171; x=1691765971; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:from:to:cc:subject:date:message-id:reply-to; bh=haxLgvz1q5Yk+iNcNNjz/9sW15Tc+C/ITeGdkf6c1Xw=; b=RJB6NZdNzd1Lh6Jqc36CBFKIVo8cAM5yWAWNitJuwtX2kayu+YJa0b9NxROOhM8QGX MknqGyaLe098qy454ihbfmo3j9gWn0mL+lx8faq4CnLIxhzXLK5NdeFSgCooWJEjqXRD 5JDmWJgP/tHIGq4tmaXUiwuyv3/gPxduVPGbs0bXzjfjtyzoXzv86C2AXJJETh1UiQxx eoBI8irmtXaxOTj9njvL7v7TeDmAue1fUXBnIv4IM4nRXmMoOEORDBN2BQB34hyUTP8S WUKosBTUZezVw8tVUbRQs1aZpQ+yNQKCUVl76lthEr9a/7h1iwqcUmsY16kJlHS91zaI 5PBA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1691161171; x=1691765971; h=in-reply-to:content-disposition:mime-version:references:message-id :subject:cc:to:from:date:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=haxLgvz1q5Yk+iNcNNjz/9sW15Tc+C/ITeGdkf6c1Xw=; b=W/5Y1BRWrEOuY6leh+Gw8LXS0jQS7YtXlEKOaJhEObJT6oEAvZYJeo7OqL6CPD7h0x lbiqYPhjEap/su3Jh8oxQGpGMYdyd9zRMd/D9/W0Kin5V0obOVbN7ttEm/w++PkBx3A1 xyNdH2/bJdSoY4tRNxUGjrCFSQ8Yo0C8nP+HRSVjprEDG2z0SabNB9HE1ex7HW/3fe1K vzdd6w12rmDG9KzMicheAYYj6aG0QLy7LbocpmujA005BlSXWREpjGeH59TPw9/xUTgI HlwZlmLOoQN6+bHVStbO5A38c6KUGMkQWFHnAzCF6UTVoGypWykuu/0aKdHoINCc/QLy qLRA== X-Gm-Message-State: AOJu0YyFK4iouSdiLJ6388hNQ6RNZYdwEGkPPm4RbTBNSafwr0Eqvs8r N6S6ReHIGhkNhhgY3T+wbMM= X-Received: by 2002:a17:906:100c:b0:991:c9da:70da with SMTP id 12-20020a170906100c00b00991c9da70damr2010322ejm.61.1691161170479; Fri, 04 Aug 2023 07:59:30 -0700 (PDT) Received: from andrea (host-82-57-177-142.retail.telecomitalia.it. [82.57.177.142]) by smtp.gmail.com with ESMTPSA id re8-20020a170906d8c800b00992076f4a01sm1413167ejb.190.2023.08.04.07.59.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Aug 2023 07:59:29 -0700 (PDT) Date: Fri, 4 Aug 2023 16:59:25 +0200 From: Andrea Parri To: Mathieu Desnoyers Cc: paulmck@kernel.org, paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, mmaas@google.com, hboehm@google.com, striker@us.ibm.com Subject: Re: [RFC PATCH] membarrier: riscv: Provide core serializing command Message-ID: References: <20230803040111.5101-1-parri.andrea@gmail.com> <4bf79f06-4593-134a-04dd-b8f89e96a1b8@efficios.com> <65350c17-3fcf-a057-a280-f6a5d36dcb21@efficios.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <65350c17-3fcf-a057-a280-f6a5d36dcb21@efficios.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_BLOCKED,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > What is the relationship between FENCE.I and instruction cache flush on > RISC-V ? The exact nature of this relationship is implementation-dependent. From commentary included in the ISA portion referred to in the changelog: A simple implementation can flush the local instruction cache and the instruction pipeline when the FENCE.I is executed. A more complex implementation might snoop the instruction (data) cache on every data (instruction) cache miss, or use an inclusive unified private L2 cache to invalidate lines from the primary instruction cache when they are being written by a local store instruction. If instruction and data caches are kept coherent in this way, or if the memory system consists of only uncached RAMs, then just the fetch pipeline needs to be flushed at a FENCE.I. [..] Mmh, does this help? Andrea