From mboxrd@z Thu Jan 1 00:00:00 1970 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 smtp.subspace.kernel.org (Postfix) with ESMTPS id 5BEB33B4EA3; Mon, 1 Jun 2026 14:43:36 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=213.95.11.211 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780325017; cv=none; b=gNoP+6AuYZ1qiaCdHf3h3plWjGTrHVxs5fyuHZ9hLLiLYWSbl75fPpUsCT/jme7H+DMS4fo01ok6VaZ+LasqWio1ygiST+ZC++dMw7tUQX2iXdvDuiaTDccNxFFFHmNKes8+jiaBqGorRjC74vjWK6i/PWNBDHydmOdC8bMK25w= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780325017; c=relaxed/simple; bh=m5ZUc4gAQRze2UVAcz5pyvxHsM4wU7vTSIol0yQAQwc=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=hiMox9BHMJLlwKxA+j6iRpU193t/oMSWmWiTgcBYYehupGFBbcUyriYA5hafNk7HinP31/m+aUOHQXOkJ5Xiw6tkbsxyAJZXyQX554lMd+xS35fs1b4an6DRyMxQ/rHObjKhivCPdF2IZ2xhmqe0pLExxN86KnoIPv0lEwCp4T0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lst.de; spf=pass smtp.mailfrom=lst.de; arc=none smtp.client-ip=213.95.11.211 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=lst.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=lst.de Received: by verein.lst.de (Postfix, from userid 2407) id DB2CC68B05; Mon, 1 Jun 2026 16:43:32 +0200 (CEST) Date: Mon, 1 Jun 2026 16:43:32 +0200 From: Christoph Hellwig To: Greg Ungerer Cc: Angelo Dureghello , Arnd Bergmann , linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org, dmaengine@vger.kernel.org, linux-can@vger.kernel.org, linux-spi@vger.kernel.org, Vladimir Oltean , Christoph Hellwig Subject: Re: [RFC 4/4] m68k: coldfire: fix non-standard readX()/writeX() functions Message-ID: <20260601144332.GC4918@lst.de> References: <20260506142644.3234270-8-gerg@kernel.org> <40aefc39-bd98-460d-8aa7-5dd79f562e0d@app.fastmail.com> <9391b782-7727-47fa-ac37-05cd50821d35@app.fastmail.com> <2b532d56-dce4-4f6d-84e0-2fd87d5494f8@kernel.org> Precedence: bulk X-Mailing-List: dmaengine@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2b532d56-dce4-4f6d-84e0-2fd87d5494f8@kernel.org> User-Agent: Mutt/1.5.17 (2007-11-01) On Sun, May 31, 2026 at 11:42:26PM +1000, Greg Ungerer wrote: > I don't think that is right. The way the underlying data cache is setup for > MMU ColdFire (via the ACR/CACR registers) means that individual pages cannot > be marked as non-cached. So coherent memory allocations are not possible - > at least the way things are today. > > It would be possible to set aside a chunk of RAM at kernel startup time > to use as a pool for coherent allocations (since it could be marked as > non-cached via the ACR/CACR registers), but there is no code to support doing > that today. With CONFIG_DMA_GLOBAL_POOL there is some generic code dealing with most of this. But if this driver worked on coldfire in the past, it must have been fine with non-coherent memory and could use the non-coherent allocator.