All of lore.kernel.org
 help / color / mirror / Atom feed
From: Rajendra Nayak <rnayak@codeaurora.org>
To: Stephen Boyd <swboyd@chromium.org>,
	agross@kernel.org, bjorn.andersson@linaro.org,
	linus.walleij@linaro.org
Cc: linux-arm-msm@vger.kernel.org, linux-gpio@vger.kernel.org,
	linux-kernel@vger.kernel.org, psodagud@codeaurora.org,
	dianders@chromium.org
Subject: Re: [PATCH v2 1/2] pinctrl: qcom: Add egpio feature support
Date: Tue, 2 Nov 2021 16:08:53 +0530	[thread overview]
Message-ID: <67d5895f-0793-7916-067b-346425aeb548@codeaurora.org> (raw)
In-Reply-To: <CAE-0n51Ag_KK7wC4r7YFar=C5P-YLLVZHUyJrNAcMEpfwYFy2Q@mail.gmail.com>


On 10/30/2021 12:35 AM, Stephen Boyd wrote:
> Quoting Rajendra Nayak (2021-10-29 03:19:04)
>>
>>
>> On 10/29/2021 12:24 PM, Stephen Boyd wrote:
>>> Quoting Rajendra Nayak (2021-10-26 05:07:35)
>>>> From: Prasad Sodagudi <psodagud@codeaurora.org>
>>>>
>>>> egpio is a scheme which allows special power Island Domain IOs
>>>> (LPASS,SSC) to be reused as regular chip GPIOs by muxing regular
>>>> TLMM functions with Island Domain functions.
>>>> With this scheme, an IO can be controlled both by the cpu running
>>>> linux and the Island processor. This provides great flexibility to
>>>> re-purpose the Island IOs for regular TLMM usecases.
>>>>
>>>> 2 new bits are added to ctl_reg, egpio_present is a read only bit
>>>> which shows if egpio feature is available or not on a given gpio.
>>>> egpio_enable is the read/write bit and only effective if egpio_present
>>>> is 1. Once its set, the Island IO is controlled from Chip TLMM.
>>>> egpio_enable when set to 0 means the GPIO is used as Island Domain IO.
>>>>
>>>> To support this we add a new function 'egpio' which can be used to
>>>> set the egpio_enable to 0, for any other TLMM controlled functions
>>>> we set the egpio_enable to 1.
>>>>
>>>> Signed-off-by: Prasad Sodagudi <psodagud@codeaurora.org>
>>>> Signed-off-by: Rajendra Nayak <rnayak@codeaurora.org>
>>>> ---
>>>
>>> Does this supersede adding support for lpass pinctrl in this series[1]?
>>
>> No, the driver in [1] actually manages the LPASS TLMM instance, while this patch
>> makes it possible for the 'same' pins to be managed by the SoC TLMM instance.
>> On sc7280 SoC for instance GPIO144-158 maps to LPI-GPIO-0-14, and GPIO159-174
>> maps to SSC-GPIO-0-15.
> 
> How do we make sure that the LPASS pins are actually muxed out of the
> SoC and not blocked by eGPIO in this driver muxing out the pin as a
> gpio? Do they avoid conflicting with each other somehow?

No, currently they don't. The default value of egpio_enable is 0, so
if SoC TLMM grabs it first and sets it to 1 and then the LPASS TLMM tries
to grab it, perhaps it can find out and throw and error, though I don;t
think it does that today.
I am not sure how this can be caught when its the other way round (LPASS grabs it first)

-- 
QUALCOMM INDIA, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation

  reply	other threads:[~2021-11-02 10:39 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-26 12:07 [PATCH v2 1/2] pinctrl: qcom: Add egpio feature support Rajendra Nayak
2021-10-26 12:07 ` [PATCH v2 2/2] pinctrl: qcom: sc7280: Add egpio support Rajendra Nayak
2021-10-28 23:03   ` Bjorn Andersson
2021-10-28 23:01 ` [PATCH v2 1/2] pinctrl: qcom: Add egpio feature support Bjorn Andersson
2021-10-29  9:58   ` Rajendra Nayak
2021-10-29  6:54 ` Stephen Boyd
2021-10-29 10:19   ` Rajendra Nayak
2021-10-29 19:05     ` Stephen Boyd
2021-11-02 10:38       ` Rajendra Nayak [this message]
2021-11-01 21:04 ` Doug Anderson
2021-11-02 11:02   ` Rajendra Nayak

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=67d5895f-0793-7916-067b-346425aeb548@codeaurora.org \
    --to=rnayak@codeaurora.org \
    --cc=agross@kernel.org \
    --cc=bjorn.andersson@linaro.org \
    --cc=dianders@chromium.org \
    --cc=linus.walleij@linaro.org \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=psodagud@codeaurora.org \
    --cc=swboyd@chromium.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.