lkml.org 
[lkml]   [2015]   [Jan]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v2 1/2] clk: qcom: gcc-msm8960: add child devices support.
On 01/30/15 14:00, Bjorn Andersson wrote:
> On Fri, Jan 30, 2015 at 1:16 PM, Stephen Boyd <sboyd@codeaurora.org> wrote:
>> On 01/30/15 10:06, Srinivas Kandagatla wrote:
> [..]
>>> Stephen Any comments?
>> I don't understand any of this. We should be making a specific tsens
>> device directly in the gcc driver probe and not doing any sort of
>> of_platform_populate(). This is what I had, but it probably could be
>> done better so that we can assign the struct device's of_node pointer
>> before registering on the platform bus.
>>
>> platform_device_register_data(&pdev->dev, "tsens8960-tm", -1,
>> &pdev->dev.of_node, sizeof(&pdev->dev.of_node));
>>
>> Then if we need to add any properties like #sensor-cells or coefficients
>> the tsens driver can use the same of_node that gcc is using.
>>
> That makes sense and the dt will describe the hardware nicely, but how
> do you get access to the register space from the tsens driver?
>
> Will dev_get_regmap(pdev->dev.parent, NULL); find the mmio regmap of
> gcc perhaps?
>

Yes that's the plan. We'll have to do slightly different stuff for 8974
where tsens is split out from gcc into its own space. That should still
be easy enough though by checking the of_node against some compatible
string.

--
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project



\
 
 \ /
  Last update: 2015-01-30 23:21    [W:2.717 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site