mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Suman Anna <s-anna@ti.com>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Lee Jones <lee.jones@linaro.org>,
	Pankaj Dubey <pankaj.dubey@samsung.com>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Linux ARM <linux-arm-kernel@lists.infradead.org>
Subject: Re: syscon regmap for disabled node?
Date: Mon, 19 Feb 2018 18:06:59 -0600	[thread overview]
Message-ID: <112b03a1-8f2d-dddf-529c-e70561722722@ti.com> (raw)
In-Reply-To: <CAK8P3a25wQiCreFB3qBuyE86GvwmjpZmqyTszF-ZBJRDPwHotQ@mail.gmail.com>

On 02/17/2018 01:51 PM, Arnd Bergmann wrote:
> On Sat, Feb 17, 2018 at 2:40 AM, Suman Anna <s-anna@ti.com> wrote:
>> Hi Pankaj, Arnd, Lee,
>>
>> I am testing some code to use a syscon/regmap interface and I find that
>> the syscon/regmap is initialized even on a disabled device node using a
>> "syscon" compatible property when I have expected it to fail. Prior to
>> commit bdb0066df96e ("mfd: syscon: Decouple syscon interface from
>> platform devices"), the driver would have never probed, and the
>> of_syscon_register() only checks for the compatible, but not if the
>> device node is available. Is this intentional or a bug?
> 
> My guess would be that nothing relies on the current behavior and that
> it could be changed if it causes problems, but it's hard to tell for the general
> case.
> 
> Can you describe why you have a disabled syscon node? Most uses of the
> status property are for on-chip devices that we disable because nothing is
> connected to them, but that seems unlikely for a syscon.

I am just testing the failure paths in my code by specifically disabling
the syscon node, and to my surprise, the code went through fine when I
had expected the syscon_node_to_regmap() call to fail.

regards
Suman

      reply	other threads:[~2018-02-20  0:07 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-02-17  1:40 Suman Anna
2018-02-17 19:51 ` Arnd Bergmann
2018-02-20  0:06   ` Suman Anna [this message]

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=112b03a1-8f2d-dddf-529c-e70561722722@ti.com \
    --to=s-anna@ti.com \
    --cc=arnd@arndb.de \
    --cc=lee.jones@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pankaj.dubey@samsung.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®