Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp4196412pxj; Tue, 8 Jun 2021 08:36:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy1kjuqMgssfZQMLhZI/0H7PbBxFjoXypBJ3zczdO41QsaDHNieD3fFHJQKMJIJSOk0O6mK X-Received: by 2002:aa7:dbc9:: with SMTP id v9mr26314214edt.183.1623166596493; Tue, 08 Jun 2021 08:36:36 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623166596; cv=none; d=google.com; s=arc-20160816; b=u0N6x2hWvp4p5afDD2fOfbCjTMlAPYhrtYnIWvc5jgIHgfvkuDJbXR2OriVK5mHJIc ZU3+TbRdGvYgIMuWgVe6A0aGjfhKGAU6BwsgLfUz/cXIWVbBXdn34HjYc1hqafeoK3aQ GgZ1/3ZroC+YyLszNSEs/0k9zu84W4IXAeLC3J+2flZoMmj2JOhsWTlhPOXrLyBwQmD5 Ylc0Z+JSSfSg/rULqhHANl4F5o11fEhVHiyVy5hDIsIO2j+7t/9CALaa0Wb1uYRghZYA orHX+x9JPEMq4J0dgwuP/JeQcaEYJHk+wZOSTiQa4NY/zbiHl2FdoI+UCR6PrnBoAikQ 2gHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date; bh=XqA/R5l6UG/ioD7IWzmBZbhELdgbBLflkAwY9/uSLfk=; b=ApHHVzkUJDUr8tVyOGW2YqBplJnRxD6bJm2ytPHhcgXo0znFhr1NMwOnMTIIfM0gSt ZtylqyirrQzjacsPloS3z64aY/ht5Y5zSo2RskjCenefJJPiIyqzSOVXMVRONzIZzZVF j++ARu5l6zG1EJ8subKxQp2rwbw2pCcEYj5UR/btZfFfqnAZwXMdJ+x85sumAoWJe7bM yQmrmO7Z06cMKjuUrQvdyPtXx/CgoiboCi2PTG4wcrOuGO4DrDw0H5uq20GMna+sO6yE aek3rCcWdFbANlyp1/ByGS0lCqijRbabMBw4kMAYJQ2cx4yBf/ty0blxLmfCZcs6AT9M pM1Q== 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id co3si14434edb.121.2021.06.08.08.36.11; Tue, 08 Jun 2021 08:36:36 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231573AbhFHPeB (ORCPT + 99 others); Tue, 8 Jun 2021 11:34:01 -0400 Received: from verein.lst.de ([213.95.11.211]:51289 "EHLO verein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231268AbhFHPd7 (ORCPT ); Tue, 8 Jun 2021 11:33:59 -0400 Received: by verein.lst.de (Postfix, from userid 2407) id 7F6FC68B05; Tue, 8 Jun 2021 17:32:03 +0200 (CEST) Date: Tue, 8 Jun 2021 17:32:03 +0200 From: 'Christoph Hellwig' To: David Laight Cc: 'Christoph Hellwig' , Guo Ren , Nick Kossifidis , Drew Fustini , Anup Patel , Palmer Dabbelt , "wefu@redhat.com" , Wei Wu =?utf-8?B?KOWQtOS8nyk=?= , linux-riscv , Linux Kernel Mailing List , linux-arch , "linux-sunxi@lists.linux.dev" , Guo Ren , Paul Walmsley , Benjamin Koch , Matteo Croce , Wei Fu Subject: Re: [PATCH RFC 0/3] riscv: Add DMA_COHERENT support Message-ID: <20210608153203.GA6802@lst.de> References: <20210519064435.GA3076809@x1> <20210519065352.GA31590@lst.de> <29733b0931d9dd6a2f0b6919067c7efe@mailhost.ics.forth.gr> <20210607062701.GB24060@lst.de> <2db975b5f24149b19191120b9f0f506b@AcuMS.aculab.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2db975b5f24149b19191120b9f0f506b@AcuMS.aculab.com> User-Agent: Mutt/1.5.17 (2007-11-01) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jun 08, 2021 at 03:00:17PM +0000, David Laight wrote: > It is almost impossible to interface to many ethernet chips without > either coherent or uncached memory for the descriptor rings. > The status bits on the transmit ring are particularly problematic. > > The receive ring can be done with writeback+invalidate provided you > fill a cache line at a time. It is horrible, but it has been done. Take a look at: drivers/net/ethernet/i825xx/lasi_82596.c and drivers/net/ethernet/seeq/sgiseeq.c