From mboxrd@z Thu Jan 1 00:00:00 1970 From: Damian Hobson-Garcia Date: Thu, 15 Dec 2011 02:58:12 +0000 Subject: Re: [PATCH 48/57] fbdev: sh_mobile_meram: Allocate ICBs automatically Message-Id: <4EE96244.3090302@igel.co.jp> List-Id: References: <1323784972-24205-49-git-send-email-laurent.pinchart@ideasonboard.com> In-Reply-To: <1323784972-24205-49-git-send-email-laurent.pinchart@ideasonboard.com> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: linux-fbdev@vger.kernel.org Hi Laurent, On 2011/12/13 23:02, Laurent Pinchart wrote: > Instead of manually specifying the ICBs to use in platform data, > allocate them automatically at runtime. > > The MERAM registration function now returns a pointer to an opaque MERAM > object, which is passed to the update and unregistration functions. > > Signed-off-by: Laurent Pinchart > --- So one concern that I have about this is in regards to sharing ICBs with user-space drivers. Since there are user space drivers (via UIO) for blocks like the VEU, that may want to have access to MERAM, we need a way to communicate which ICBs are free to user space. With the hard-coded platform data we could easily assume that kernel drivers would use, for example, the upper 16 ICBs and so user-space drivers were free to use the lower 16. One simple temporary workaround might be to provide a range of useable ICBs in the platform data. The MERAM memory allocation range can always easily be tweaked by using the meram_resources structure. Thanks, Damian