All of lore.kernel.org
 help / color / mirror / Atom feed
From: Kevin Hilman <khilman@kernel.org>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: devicetree@vger.kernel.org,
	James Liao <jamesjj.liao@mediatek.com>,
	linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org,
	kernel@pengutronix.de, Matthias Brugger <matthias.bgg@gmail.com>,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver
Date: Tue, 10 Mar 2015 09:00:19 -0700	[thread overview]
Message-ID: <7hoao0yh9o.fsf@deeprootsystems.com> (raw)
In-Reply-To: <20150310144053.GH24885@pengutronix.de> (Sascha Hauer's message of "Tue, 10 Mar 2015 15:40:53 +0100")

Sascha Hauer <s.hauer@pengutronix.de> writes:

> On Tue, Mar 10, 2015 at 10:41:42AM +0100, Sascha Hauer wrote:
>> > > +	if (data->bus_prot_mask) {
>> > > +		u32 mask = data->bus_prot_mask;
>> > > +		struct regmap *infracfg = scp->infracfg;
>> > > +
>> > > +		regmap_update_bits(infracfg, INFRA_TOPAXI_PROTECTEN, mask, 0);
>> > > +
>> > > +		expired = jiffies + HZ;
>> > > +
>> > > +		while (1) {
>> > > +			u32 val;
>> > > +
>> > > +			ret = regmap_read(infracfg, INFRA_TOPAXI_PROTECTSTA1, &val);
>> > > +			if (ret)
>> > > +				return ret;
>> > > +
>> > > +			if (!(val & mask))
>> > > +				break;
>> > > +
>> > > +			cpu_relax();
>> > > +			if (time_after(jiffies, expired))
>> > > +				return -EIO;
>> > > +		}
>> > > +	}
>> > 
>> > This whole "Clear bus protection bits" part seems like it should be an
>> > API in the infracfg driver.
>> 
>> Ok, can do.
>
> Since the infracfg driver (which is really a clk driver) currently is
> pending for inclusion I don't want to add more patches to it. I decided
> to drop the protection bits for now and come back to this once the
> infracfg driver is merged.

Makes sense to me.  Hopefully by then, we can have a bit more clarity
from the MTK folks also.

Kevin

WARNING: multiple messages have this Message-ID (diff)
From: Kevin Hilman <khilman-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
To: Sascha Hauer <s.hauer-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org>
Cc: devicetree-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	James Liao <jamesjj.liao-NuS5LvNUpcJWk0Htik3J/w@public.gmane.org>,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-mediatek-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org,
	kernel-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org,
	Matthias Brugger
	<matthias.bgg-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
	linux-arm-kernel-IAPFreCvJWM7uuMidbF8XUB+6BGkLq7r@public.gmane.org
Subject: Re: [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver
Date: Tue, 10 Mar 2015 09:00:19 -0700	[thread overview]
Message-ID: <7hoao0yh9o.fsf@deeprootsystems.com> (raw)
In-Reply-To: <20150310144053.GH24885-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org> (Sascha Hauer's message of "Tue, 10 Mar 2015 15:40:53 +0100")

Sascha Hauer <s.hauer-bIcnvbaLZ9MEGnE8C9+IrQ@public.gmane.org> writes:

> On Tue, Mar 10, 2015 at 10:41:42AM +0100, Sascha Hauer wrote:
>> > > +	if (data->bus_prot_mask) {
>> > > +		u32 mask = data->bus_prot_mask;
>> > > +		struct regmap *infracfg = scp->infracfg;
>> > > +
>> > > +		regmap_update_bits(infracfg, INFRA_TOPAXI_PROTECTEN, mask, 0);
>> > > +
>> > > +		expired = jiffies + HZ;
>> > > +
>> > > +		while (1) {
>> > > +			u32 val;
>> > > +
>> > > +			ret = regmap_read(infracfg, INFRA_TOPAXI_PROTECTSTA1, &val);
>> > > +			if (ret)
>> > > +				return ret;
>> > > +
>> > > +			if (!(val & mask))
>> > > +				break;
>> > > +
>> > > +			cpu_relax();
>> > > +			if (time_after(jiffies, expired))
>> > > +				return -EIO;
>> > > +		}
>> > > +	}
>> > 
>> > This whole "Clear bus protection bits" part seems like it should be an
>> > API in the infracfg driver.
>> 
>> Ok, can do.
>
> Since the infracfg driver (which is really a clk driver) currently is
> pending for inclusion I don't want to add more patches to it. I decided
> to drop the protection bits for now and come back to this once the
> infracfg driver is merged.

Makes sense to me.  Hopefully by then, we can have a bit more clarity
from the MTK folks also.

Kevin
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

WARNING: multiple messages have this Message-ID (diff)
From: khilman@kernel.org (Kevin Hilman)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver
Date: Tue, 10 Mar 2015 09:00:19 -0700	[thread overview]
Message-ID: <7hoao0yh9o.fsf@deeprootsystems.com> (raw)
In-Reply-To: <20150310144053.GH24885@pengutronix.de> (Sascha Hauer's message of "Tue, 10 Mar 2015 15:40:53 +0100")

Sascha Hauer <s.hauer@pengutronix.de> writes:

> On Tue, Mar 10, 2015 at 10:41:42AM +0100, Sascha Hauer wrote:
>> > > +	if (data->bus_prot_mask) {
>> > > +		u32 mask = data->bus_prot_mask;
>> > > +		struct regmap *infracfg = scp->infracfg;
>> > > +
>> > > +		regmap_update_bits(infracfg, INFRA_TOPAXI_PROTECTEN, mask, 0);
>> > > +
>> > > +		expired = jiffies + HZ;
>> > > +
>> > > +		while (1) {
>> > > +			u32 val;
>> > > +
>> > > +			ret = regmap_read(infracfg, INFRA_TOPAXI_PROTECTSTA1, &val);
>> > > +			if (ret)
>> > > +				return ret;
>> > > +
>> > > +			if (!(val & mask))
>> > > +				break;
>> > > +
>> > > +			cpu_relax();
>> > > +			if (time_after(jiffies, expired))
>> > > +				return -EIO;
>> > > +		}
>> > > +	}
>> > 
>> > This whole "Clear bus protection bits" part seems like it should be an
>> > API in the infracfg driver.
>> 
>> Ok, can do.
>
> Since the infracfg driver (which is really a clk driver) currently is
> pending for inclusion I don't want to add more patches to it. I decided
> to drop the protection bits for now and come back to this once the
> infracfg driver is merged.

Makes sense to me.  Hopefully by then, we can have a bit more clarity
from the MTK folks also.

Kevin

  reply	other threads:[~2015-03-10 16:00 UTC|newest]

Thread overview: 75+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-09  8:09 [RFC] Mediatek SCPSYS power domain support Sascha Hauer
2015-03-09  8:09 ` Sascha Hauer
2015-03-09  8:09 ` Sascha Hauer
2015-03-09  8:10 ` [PATCH 1/4] dt-bindings: soc: Add documentation for the MediaTek SCPSYS unit Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09 20:46   ` Kevin Hilman
2015-03-09 20:46     ` Kevin Hilman
2015-03-10  8:02     ` Sascha Hauer
2015-03-10  8:02       ` Sascha Hauer
2015-03-10  8:02       ` Sascha Hauer
2015-03-09  8:10 ` [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09 21:35   ` Kevin Hilman
2015-03-09 21:35     ` Kevin Hilman
2015-03-10  9:41     ` Sascha Hauer
2015-03-10  9:41       ` Sascha Hauer
2015-03-10  9:41       ` Sascha Hauer
2015-03-10 14:40       ` Sascha Hauer
2015-03-10 14:40         ` Sascha Hauer
2015-03-10 16:00         ` Kevin Hilman [this message]
2015-03-10 16:00           ` Kevin Hilman
2015-03-10 16:00           ` Kevin Hilman
2015-03-11  3:16       ` James Liao
2015-03-11  3:16         ` James Liao
2015-03-11  3:16         ` James Liao
2015-03-11  9:03         ` Sascha Hauer
2015-03-11  9:03           ` Sascha Hauer
2015-03-11  9:03           ` Sascha Hauer
2015-03-11 17:14           ` Kevin Hilman
2015-03-11 17:14             ` Kevin Hilman
2015-03-12  7:21             ` Sascha Hauer
2015-03-12  7:21               ` Sascha Hauer
2015-03-09  8:10 ` [PATCH 3/4] ARM64: MediaTek: Add generic pm domain support Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09  8:10 ` [PATCH 4/4] ARM64: MediaTek MT8173: Add SCPSYS device node Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09  8:10   ` Sascha Hauer
2015-03-09 20:43 ` [RFC] Mediatek SCPSYS power domain support Kevin Hilman
2015-03-09 20:43   ` Kevin Hilman
2015-03-10 15:40 [PATCH v1] " Sascha Hauer
2015-03-10 15:41 ` [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver Sascha Hauer
2015-03-10 15:41   ` Sascha Hauer
2015-03-10 15:41   ` Sascha Hauer
2015-03-11 11:10   ` Paul Bolle
2015-03-11 11:10     ` Paul Bolle
2015-03-31 16:27   ` Kevin Hilman
2015-03-31 16:27     ` Kevin Hilman
2015-04-13 10:55     ` Sascha Hauer
2015-04-13 10:55       ` Sascha Hauer
2015-04-13 10:55       ` Sascha Hauer
2015-05-08 12:16   ` Matthias Brugger
2015-05-08 12:16     ` Matthias Brugger
2015-05-08 12:16     ` Matthias Brugger
2015-05-08 12:19     ` Sascha Hauer
2015-05-08 12:19       ` Sascha Hauer
2015-05-08 12:19       ` Sascha Hauer
2015-05-08 12:28       ` Matthias Brugger
2015-05-08 12:28         ` Matthias Brugger
2015-05-08 12:28         ` Matthias Brugger
2015-05-08 12:51         ` Sascha Hauer
2015-05-08 12:51           ` Sascha Hauer
2015-05-08 12:51           ` Sascha Hauer
2015-05-08 15:51           ` Matthias Brugger
2015-05-08 15:51             ` Matthias Brugger
2015-05-08 15:51             ` Matthias Brugger
2015-05-11 13:11 [PATCH v2] Mediatek SCPSYS power domain support Sascha Hauer
2015-05-11 13:11 ` [PATCH 2/4] soc: Mediatek: Add SCPSYS power domain driver Sascha Hauer
2015-05-11 13:11   ` Sascha Hauer
2015-05-11 13:11   ` Sascha Hauer
2015-05-26 22:35   ` Kevin Hilman
2015-05-26 22:35     ` Kevin Hilman
2015-05-26 22:35     ` Kevin Hilman
2015-05-27  6:24     ` Sascha Hauer
2015-05-27  6:24       ` Sascha Hauer
2015-05-28 17:22       ` Kevin Hilman
2015-05-28 17:22         ` Kevin Hilman

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=7hoao0yh9o.fsf@deeprootsystems.com \
    --to=khilman@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=jamesjj.liao@mediatek.com \
    --cc=kernel@pengutronix.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=matthias.bgg@gmail.com \
    --cc=s.hauer@pengutronix.de \
    /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.