From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ned Forrester Subject: Re: [PATCH 2/3] [SPI] Add new mode: SPI_LOOP Date: Thu, 26 Jul 2007 23:34:45 -0400 Message-ID: <46A967D5.30606@whoi.edu> References: <20070726134754.GA3539@localhost.localdomain> <20070726135051.GB5550@localhost.localdomain> <200707262007.07537.david-b@pacbell.net> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org, Stephen Street , linuxppc-dev-mnsaURCQ41sdnm+yROfE0A@public.gmane.org To: David Brownell Return-path: In-Reply-To: <200707262007.07537.david-b-yBeKhBN/0LDR7s880joybQ@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: spi-devel-general-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org Errors-To: spi-devel-general-bounces-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org List-Id: linux-spi.vger.kernel.org David Brownell wrote: > On Thursday 26 July 2007, Anton Vorontsov wrote: >> Loopback mode is supported by various controllers, this mode >> is useful for testing, especially in conjunction with spidev >> driver. > > ISTR that Stephen Street provided a loopback mode for debug > in his pxa2xx_spi code. And I know you're fight that this > mode shows up in a lot of hardware. > > Comments, anyone? This seems like a fair way to expose this > mechanism. And I tend to agree that it'd mostly be useful in > conjunction with "spidev". Yes, it is in pxa2xx_spi. It is passed in a structure that is attached to spi_board_info.controller_data. I have used it to great effect to test data modes in the driver for which I have no external hardware support: various bits/word, clock frequencies, fifo thresholds, dma burst sizes, etc. It works for me if this is moved to struct spi_device. I don't think I have any code that could be readily turned into a generic test program. -- Ned Forrester nforrester-/d+BM93fTQY@public.gmane.org Oceanographic Systems Lab 508-289-2226 Applied Ocean Physics and Engineering Dept. Woods Hole Oceanographic Institution Woods Hole, MA 02543, USA http://www.whoi.edu/sbl/liteSite.do?litesiteid=7212 http://www.whoi.edu/hpb/Site.do?id=1532 http://www.whoi.edu/page.do?pid=10079 ------------------------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/