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 A9CEDC3DA4A for ; Thu, 22 Aug 2024 05:32:46 +0000 (UTC) Received: from boromir.ozlabs.org (localhost [127.0.0.1]) by lists.ozlabs.org (Postfix) with ESMTP id 4WqBg10sSyz2yD5; Thu, 22 Aug 2024 15:32:45 +1000 (AEST) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=lst.de Authentication-Results: lists.ozlabs.org; arc=none smtp.remote-ip=213.95.11.211 Authentication-Results: lists.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lst.de (client-ip=213.95.11.211; helo=verein.lst.de; envelope-from=hch@lst.de; receiver=lists.ozlabs.org) Received: from verein.lst.de (verein.lst.de [213.95.11.211]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 4WqBg023PRz2y8l for ; Thu, 22 Aug 2024 15:32:43 +1000 (AEST) Received: by verein.lst.de (Postfix, from userid 2407) id 512C9227A8E; Thu, 22 Aug 2024 07:32:38 +0200 (CEST) Date: Thu, 22 Aug 2024 07:32:38 +0200 From: Christoph Hellwig To: LEROY Christophe Cc: Christian Lamparter , Benjamin Herrenschmidt , Paul Mackerras , Michael Ellerman , "linux-kernel@vger.kernel.org" , "linuxppc-dev@lists.ozlabs.org" , Stan Johnson , Finn Thain , Christoph Hellwig Subject: Re: [PATCH v2] powerpc: warn on emulation of dcbz instruction in kernel mode Message-ID: <20240822053238.GA2028@lst.de> References: <2e3acfe63d289c6fba366e16973c9ab8369e8b75.1631803922.git.christophe.leroy@csgroup.eu> <17fa6450-6613-4c34-804b-e47246e7b39c@isd.uni-stuttgart.de> <9dbf73fe-a459-4956-8dbc-e919d9728f5e@cs-soprasteria.com> X-Mailing-List: linuxppc-dev@lists.ozlabs.org List-Id: List-Help: List-Post: List-Subscribe: , , List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9dbf73fe-a459-4956-8dbc-e919d9728f5e@cs-soprasteria.com> User-Agent: Mutt/1.5.17 (2007-11-01) On Thu, Aug 22, 2024 at 05:25:10AM +0000, LEROY Christophe wrote: > > and this results in a call to dma_direct_allocation(), which has one > > innocent looking memset(): > > > memset() can't be used on non-cached memory, memset_io() has to be used > instead. No, we use memset on uncached memory all the time. Note that uncached memory != __iomem memory, for which you DO have to use memset_io.