Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752819AbcCJJBz (ORCPT ); Thu, 10 Mar 2016 04:01:55 -0500 Received: from mail-wm0-f67.google.com ([74.125.82.67]:35925 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934335AbcCJJBp (ORCPT ); Thu, 10 Mar 2016 04:01:45 -0500 MIME-Version: 1.0 In-Reply-To: <20160306214206.GW8418@lukather> References: <1456466217-6793-1-git-send-email-plaes@plaes.org> <1456466217-6793-2-git-send-email-plaes@plaes.org> <20160226122504.GR18327@sirena.org.uk> <20160306214206.GW8418@lukather> From: Michal Suchanek Date: Thu, 10 Mar 2016 10:01:04 +0100 Message-ID: Subject: Re: [PATCH 1/2] spi: sun4i: add DMA support To: Maxime Ripard Cc: Mark Brown , Priit Laes , Chen-Yu Tsai , linux-spi , "linux-arm-kernel@lists.infradead.org" , Linux Kernel Mailing List , =?UTF-8?Q?Emilio_L=C3=B3pez?= Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1216 Lines: 32 Hello, On 6 March 2016 at 22:42, Maxime Ripard wrote: > On Fri, Feb 26, 2016 at 01:51:51PM +0100, Michal Suchanek wrote: >> Besides this non-technical objection there were multiple technical >> objections. >> >> IIRC one was that the driver does not handle the case when the DMA >> channels are not available. As I understand it the channels are >> exclusively reserved for a particular peripherial on sunxi platform so >> this ShoulNotHappen(tm). So it's probably fine for the driver to fail >> probe when you have broken DT or no DMA engine support for sunxi >> platform. > > There's a quite trivial scenario that would trigger this: if the dma > driver or dmaengine is not enabled / loaded. There are other trivial scenarios under which the driver will fail like loading wrong DT, not compiling or loading the sunxi pinmux driver, and whatnot. When you misconfigure your kernel it does not work. So long as the driver just fails and does not crash and burn it's normal. Since the driver is pretty much useless without DMA as it is now (63 byte transfer limit) losing the non-DMA functionality when DMA engine is not compiled-in does not seem that terrible. Thanks Michal