From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935798AbbCDIAu (ORCPT ); Wed, 4 Mar 2015 03:00:50 -0500 Received: from pegase1.c-s.fr ([93.17.236.30]:21653 "EHLO mailhub1.si.c-s.fr" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933205AbbCDIAr (ORCPT ); Wed, 4 Mar 2015 03:00:47 -0500 Message-ID: <54F6BBA7.8040008@c-s.fr> Date: Wed, 04 Mar 2015 09:00:39 +0100 From: leroy christophe User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: Mark Brown CC: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org, linux-spi@vger.kernel.org Subject: Re: [PATCH] spi: fsl-spi: use of_iomap() to map parameter ram on CPM1 References: <20150226161142.D08681A2360@localhost.localdomain> <20150303184403.GE21293@sirena.org.uk> In-Reply-To: <20150303184403.GE21293@sirena.org.uk> Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Le 03/03/2015 19:44, Mark Brown a écrit : > On Thu, Feb 26, 2015 at 05:11:42PM +0100, Christophe Leroy wrote: >> On CPM2, the SPI parameter RAM is dynamically allocated in the dualport RAM >> whereas in CPM1, it is statically allocated to a default address with >> capability to relocate it somewhere else via the use of CPM micropatch. >> The address of the parameter RAM is given by the boot loader and expected >> to be mapped via of_iomap() > Why are we using of_iomap() rather than a generic I/O mapping function > here? Euh ... because all drivers for powerpc seems to be using of_iomap(), as on powerpc the HW is described by the bootloader in a OF device tree. Today, of_iomap() is at least used in FSL SPI, FSL UART, SPI mpc52xx, UART mpc52xx, i2c-mpc, i2c-cpm, freescale ethernet drivers, etc .... Is it not correct ?