Received: by 2002:a05:6a10:6006:0:0:0:0 with SMTP id w6csp869320pxa; Thu, 27 Aug 2020 19:03:19 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxf/nwPKQmDWBmIKddgON9bPlJ1nV26jkZbuqJSzaVR7LFlpNKr47e1E0GBgJe/zpwfSmnR X-Received: by 2002:a05:6402:156:: with SMTP id s22mr22188583edu.372.1598580199639; Thu, 27 Aug 2020 19:03:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1598580199; cv=none; d=google.com; s=arc-20160816; b=q+++6stX+NgOm0327yzDgAj0yACmIefFTHBU6h5M6qVUDUzt++GhW31XhqhhKnTqSL +Z+/6jFxxXILiIgmJwAndAFOhbFFxwIRkjNNygtREEmHxlBWCepn3W9KG3YLKmQrXD3T YzEDTfZmj5qqLhosyognabszlT/xGtlz5nn7eGf28mRPPrnLm2H0+2Ei5p/W50egN1Vc fMu2XsP2x/YDCagrblpcTUaweE2Z4LT2Z1z+UnYcp6ziqX6qna4/xFtu0Plgf8H2iDOi mbbRHpuIrEOQGI0fpPM5nEp87ETADe7A/WEY8C2TX7T1S19e9ax6U72slZQVxPpakFTT BcbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=kx+ln6T9TWctUDbCl46AtAAbYjnh2n2AE154SnsS6xg=; b=ht/H/tIz/lhXXL+bo5rFcXglWxU+NKoGZcicuDqlVsXqCeNZSyrjrj8GY/xHf5vh63 FpCw738fRDMiHW0VYriYpKjUHTXLZ5/DScdy2wsZEQwKZbA+HI8WASDYyze1zE/baVeX qGbFNF4Is4vL7t0gp488ruT8VRcJAmZKhhPuK6Tnkng7/2BPIf7RxRCpTRw+rFtMZvan x0cfmDrBVeQ6IKKA6EqLK2XQTYYXonlmjc6hwufmDQ7hTgSVon7/C8GcwP6igMB4H42O /boprjO21Dar9cK3gJwbKzmmErQqtaMQ7zC/dVnQe2ECTWo+aJjH+HFl+8/69kFt1UUn pX5g== 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 g6si2593725edv.515.2020.08.27.19.02.56; Thu, 27 Aug 2020 19:03:19 -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 S1728258AbgH1CAv (ORCPT + 99 others); Thu, 27 Aug 2020 22:00:51 -0400 Received: from brightrain.aerifal.cx ([216.12.86.13]:47530 "EHLO brightrain.aerifal.cx" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727972AbgH1CAu (ORCPT ); Thu, 27 Aug 2020 22:00:50 -0400 Date: Thu, 27 Aug 2020 22:00:48 -0400 From: Rich Felker To: Christoph Hellwig Cc: Yoshinori Sato , linux-sh@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 09/10] sh: don't allow non-coherent DMA for NOMMU Message-ID: <20200828020045.GT3265@brightrain.aerifal.cx> References: <20200714121856.955680-1-hch@lst.de> <20200714121856.955680-10-hch@lst.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200714121856.955680-10-hch@lst.de> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 14, 2020 at 02:18:55PM +0200, Christoph Hellwig wrote: > The code handling non-coherent DMA depends on being able to remap code > as non-cached. But that can't be done without an MMU, so using this > option on NOMMU builds is broken. > > Signed-off-by: Christoph Hellwig > --- > arch/sh/Kconfig | 3 ++- > 1 file changed, 2 insertions(+), 1 deletion(-) > > diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig > index f8027eee08edae..337eb496c45a0a 100644 > --- a/arch/sh/Kconfig > +++ b/arch/sh/Kconfig > @@ -61,6 +61,7 @@ config SUPERH > select MAY_HAVE_SPARSE_IRQ > select MODULES_USE_ELF_RELA > select NEED_SG_DMA_LENGTH > + select NO_DMA if !MMU && !DMA_COHERENT > select NO_GENERIC_PCI_IOPORT_MAP if PCI > select OLD_SIGACTION > select OLD_SIGSUSPEND > @@ -135,7 +136,7 @@ config DMA_COHERENT > bool This change broke SD card support on J2 because MMC_SPI spuriously depends on HAS_DMA. It looks like it can be fixed just by removing that dependency from drivers/mmc/host/Kconfig. Rich