From mboxrd@z Thu Jan 1 00:00:00 1970 From: Tejun Heo Subject: Re: [RFC v3 05/13] ahci-platform: Pass ahci_host_priv ptr to ahci_platform_data init method Date: Sun, 19 Jan 2014 06:30:51 -0500 Message-ID: <20140119113051.GD11123@htj.dyndns.org> References: <1390088935-7193-1-git-send-email-hdegoede@redhat.com> <1390088935-7193-6-git-send-email-hdegoede@redhat.com> Reply-To: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Return-path: Sender: linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org In-Reply-To: <1390088935-7193-6-git-send-email-hdegoede-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org> List-Post: , List-Help: , List-Archive: List-Subscribe: , List-Unsubscribe: , Content-Disposition: inline To: Hans de Goede Cc: Oliver Schinagl , Maxime Ripard , Richard Zhu , linux-ide-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org, devicetree , linux-sunxi-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-Id: devicetree@vger.kernel.org On Sun, Jan 19, 2014 at 12:48:47AM +0100, Hans de Goede wrote: > Some ahci_platform_data->init methods need access to the ahci_host_priv data. > > Note: > > When calling ahci_platform_data->init the ata_host has not been allocated yet, > so access to ahci_host_priv through the dev argument is not possible. > > The hpriv->mmio argument may seem redundant, but it is useful for drivers > which live outside of drivers/ata and thus don't know the contents of the > ahci_platform_data data type. Wouldn't the right thing to do be moving them under drivers/ata? Thanks. -- tejun