Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752791AbbGOP7z (ORCPT ); Wed, 15 Jul 2015 11:59:55 -0400 Received: from mail-pd0-f179.google.com ([209.85.192.179]:34074 "EHLO mail-pd0-f179.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752279AbbGOP7w (ORCPT ); Wed, 15 Jul 2015 11:59:52 -0400 Date: Wed, 15 Jul 2015 08:59:46 -0700 From: Brian Norris To: Marek Vasut , hramrach@gmail.com Cc: Michal Suchanek , Richard Cochran , Geert Uytterhoeven , Mark Rutland , Krzysztof Kozlowski , Geert Uytterhoeven , MTD Maling List , Alison Chaiken , Bean Huo =?utf-8?B?6ZyN5paM5paMIChiZWFuaHVvKQ==?= , "linux-samsung-soc@vger.kernel.org" , Russell King , Vinod Koul , =?utf-8?B?UmFmYcWCIE1pxYJlY2tp?= , Kukjin Kim , Ben Hutchings , "devicetree@vger.kernel.org" , Pawel Moll , Ian Campbell , Kumar Gala , Mark Brown , Dan Williams , "linux-arm-kernel@lists.infradead.org" , "grmoore@altera.com" , "linux-kernel@vger.kernel.org" , linux-spi , Huang Shijie , Rob Herring , Han Xu , Knut Wohlrab , dmaengine , David Woodhouse Subject: Re: [PATCH 08/11] MTD: m25p80: Add option to limit SPI transfer size. Message-ID: <20150715155946.GB21362@localhost> References: <20150604171547.GA1530@localhost.localdomain> <201507151352.27689.marex@denx.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <201507151352.27689.marex@denx.de> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1395 Lines: 32 Hi Michal, On Wed, Jul 15, 2015 at 01:52:27PM +0200, Marek Vasut wrote: > The problem is, if you add a new DT binding, you'd have to support it > forever, no matter how bad idea that binding turned out to be. Agreed, and a solid NAK to this patch. I could have sworn I gave such a response when this was originally being discussed a month ago. AFAICT, you have one of two general approaches available to you: 1. Fix up the SPI driver so that it knows how to break large SPI transfers up into smaller segments that its constituent hardware (DMA controllers, fast clocks, etc.) can handle. 2. Utilize/create a parameter within the SPI subsystem to communicate that the SPI master has a limited max transfer size (notably: NOT a per-device DT property, but a SPI API property), and modify SPI device drivers (like m25p80) to honor it. Mark Brown seemed open to this, and I thought he suggested it somewhere. It is most definitely wrong to put this information solely in the slave device DT (i.e., for the flash), when it is not a property of the flash device at all. It's a property of the SPI master and/or its clocks and DMA controllers. Brian -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/