All of lore.kernel.org
 help / color / mirror / Atom feed
From: Neil Armstrong <narmstrong@baylibre.com>
To: Stephen Boyd <sboyd@codeaurora.org>
Cc: linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org
Subject: Re: [PATCH 1/2] clk: Add Oxford Semiconductor OXNAS Standard Clocks
Date: Sun, 3 Apr 2016 15:56:26 +0200	[thread overview]
Message-ID: <5701210A.4060807@baylibre.com> (raw)
In-Reply-To: <20160402005045.GX18567@codeaurora.org>

On 04/02/2016 02:50 AM, Stephen Boyd wrote:
> On 04/01, Neil Armstrong wrote:
>> +	if (!onecell_data)
>> +		return -ENOMEM;
>> +
>> +	regmap = syscon_node_to_regmap(of_get_parent(np));
> 
> Can we use dev_get_regmap(&pdev->dev.parent) here instead? I'd
> prefer device APIs over DT APIs here. 
> 

It will not work here since the parent node is a syscon, the call to syscon_node_to_regmap() will call of_syscon_register() and create the regmap, the dev_get_regmap() needs a proper platform device registered as regmap here.

Neil

WARNING: multiple messages have this Message-ID (diff)
From: narmstrong@baylibre.com (Neil Armstrong)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 1/2] clk: Add Oxford Semiconductor OXNAS Standard Clocks
Date: Sun, 3 Apr 2016 15:56:26 +0200	[thread overview]
Message-ID: <5701210A.4060807@baylibre.com> (raw)
In-Reply-To: <20160402005045.GX18567@codeaurora.org>

On 04/02/2016 02:50 AM, Stephen Boyd wrote:
> On 04/01, Neil Armstrong wrote:
>> +	if (!onecell_data)
>> +		return -ENOMEM;
>> +
>> +	regmap = syscon_node_to_regmap(of_get_parent(np));
> 
> Can we use dev_get_regmap(&pdev->dev.parent) here instead? I'd
> prefer device APIs over DT APIs here. 
> 

It will not work here since the parent node is a syscon, the call to syscon_node_to_regmap() will call of_syscon_register() and create the regmap, the dev_get_regmap() needs a proper platform device registered as regmap here.

Neil

  parent reply	other threads:[~2016-04-03 13:56 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-04-01 14:26 [PATCH 0/2] clk: Add Oxford Semiconductor OXNAS Clocks support Neil Armstrong
2016-04-01 14:26 ` Neil Armstrong
2016-04-01 14:26 ` [PATCH 1/2] clk: Add Oxford Semiconductor OXNAS Standard Clocks Neil Armstrong
2016-04-01 14:26   ` Neil Armstrong
2016-04-02  0:50   ` Stephen Boyd
2016-04-02  0:50     ` Stephen Boyd
2016-04-02 10:45     ` Neil Armstrong
2016-04-02 10:45       ` Neil Armstrong
2016-04-03 13:56     ` Neil Armstrong [this message]
2016-04-03 13:56       ` Neil Armstrong
2016-04-07 23:31       ` Stephen Boyd
2016-04-07 23:31         ` Stephen Boyd
2016-04-11 14:00         ` Neil Armstrong
2016-04-11 14:00           ` Neil Armstrong
2016-04-11 22:04           ` Stephen Boyd
2016-04-11 22:04             ` Stephen Boyd
2016-04-01 14:26 ` [PATCH 2/2] dt-bindings: Add Oxford Semiconductor OXNAS Standard Clocks bindings Neil Armstrong
2016-04-01 14:26   ` Neil Armstrong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5701210A.4060807@baylibre.com \
    --to=narmstrong@baylibre.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sboyd@codeaurora.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.