Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754022Ab1EBRRO (ORCPT ); Mon, 2 May 2011 13:17:14 -0400 Received: from arroyo.ext.ti.com ([192.94.94.40]:40930 "EHLO arroyo.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751198Ab1EBRRN convert rfc822-to-8bit (ORCPT ); Mon, 2 May 2011 13:17:13 -0400 From: "Nori, Sekhar" To: Subhasish Ghosh , Greg KH CC: Greg KH , "davinci-linux-open-source@linux.davincidsp.com" , "linux-arm-kernel@lists.infradead.org" , "Watkins, Melissa" , "sachi@mistralsolutions.com" , Andrew Morton , Randy Dunlap , open list Date: Mon, 2 May 2011 22:45:53 +0530 Subject: RE: [PATCH v4 08/11] tty: add pruss SUART driver Thread-Topic: [PATCH v4 08/11] tty: add pruss SUART driver Thread-Index: AcwIo45QBYecflReRyCZEfZ25IMRNgAR9/yw Message-ID: References: <1303474109-6212-1-git-send-email-subhasish@mistralsolutions.com> <1303474109-6212-9-git-send-email-subhasish@mistralsolutions.com> <20110425212056.GA29313@kroah.com> <20110426124519.GC5977@suse.de> <35F38DB5B5C4408EA80AF0DB8A6FA178@subhasishg> In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: acceptlanguage: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1698 Lines: 42 On Mon, May 02, 2011 at 14:04:11, Subhasish Ghosh wrote: > >> SG - So, should I call the sram_alloc() in the platform setup function. > > > > Can you please shed some light on how SRAM > > is being used in the driver? Looking at the > > driver, it looks like it is used as a shared > > buffer between the PRU firmware and kernel. > > > > If yes, how do you cope with dynamic allocation > > of SRAM? That is, how do you inform the firmware > > what portion of SRAM has been allocated to the > > driver? > > > > Also, usage of SRAM is not required for basic driver > > function, correct? So, a platform which does not > > have SRAM to spare for this driver could still have > > a portion of SDRAM/DDR allocated to be used as the > > shared buffer? I guess SRAM was used only for lower > > access times. But it should still be possible to > > sustain lower baudrates with SDRAM/DDR? > > The sram is allocated dynamically in the driver. > After allocation, we write the pointer into the PRU, so in case the > driver allocates memory form the DDR, it will write this info into the > PRU and it will work. But, because of DDR access latencies, the UART > will work only for lower baud rates. Thanks for the clarification. In this case, the driver should use platform callbacks to get/put fast fifo space. In case this callback is not populated by the platform or returns an error, the driver should fall back to allocating from DDR. Thanks, Sekhar -- 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/