public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Sagar Dharia <sdharia@codeaurora.org>
To: Mark Brown <broonie@kernel.org>
Cc: gregkh@linuxfoundation.org, bp@suse.de, poeschel@lemonage.de,
	treding@nvidia.com, gong.chen@linux.intel.com,
	andreas.noever@gmail.com, alan@linux.intel.com,
	mathieu.poirier@linaro.org, daniel@ffwll.ch, oded.gabbay@amd.com,
	jkosina@suse.cz, sharon.dvir1@mail.huji.ac.il, joe@perches.com,
	davem@davemloft.net, james.hogan@imgtec.com,
	michael.opdenacker@free-electrons.com,
	daniel.thompson@linaro.org, robh+dt@kernel.org,
	pawel.moll@arm.com, mark.rutland@arm.com,
	ijc+devicetree@hellion.org.uk, galak@codeaurora.org,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	kheitke@audience.com, mlocke@codeaurora.org,
	agross@codeaurora.org, linux-arm-msm@vger.kernel.org
Subject: Re: [PATCH V3 4/6] slim: qcom: Add Qualcomm Slimbus controller driver
Date: Mon, 17 Aug 2015 17:44:20 -0600	[thread overview]
Message-ID: <55D271D4.6020903@codeaurora.org> (raw)
In-Reply-To: <20150814183106.GE10748@sirena.org.uk>

On 8/14/2015 12:31 PM, Mark Brown wrote:
> On Mon, Aug 03, 2015 at 12:59:48AM -0600, Sagar Dharia wrote:
>
>> +/**
>> + * Qualcomm slimbus controller may experience interference on the lines
>> + * causing some early messages (e.g. logical-address assignment) to be
>> + * NACKed. Retry after sometime (typically 1 superframe)
>> + */
>> +static void msm_slim_wait_retry(struct msm_slim_ctrl *dev)
>> +{
>> +	int msec_per_frm = 0;
>> +	int sfr_per_sec;
>> +
>> +	/* Wait for 1 superframe, or default time and then retry */
>> +	sfr_per_sec = dev->framer.superfreq /
>> +			(1 << (SLIM_MAX_CLK_GEAR - dev->ctrl.clkgear));
>> +	if (sfr_per_sec)
>> +		msec_per_frm = MSEC_PER_SEC / sfr_per_sec;
>> +	if (msec_per_frm < DEF_RETRY_MS)
>> +		msec_per_frm = DEF_RETRY_MS;
>> +	msleep(msec_per_frm);
>> +}
> This looks like logic which might be usefully pulled out to the
> framework - I bet this isn't an issue unique to your controller, the
> users (well, one user) look like cases where the bus might be
> destabilised by devices powering up and trying to enumerate under less
> than ideal electrical conditions which seems like something that's
> likely to affect other hardware.

I agree, I will move this to the framework.

Thanks
Sagar

>
>> +	rclk = devm_clk_get(&pdev->dev, "core_clk");
>> +	if (IS_ERR(rclk)) {
>> +		/* unlikely that this is probe-defer */
>> +		dev_err(&pdev->dev, "rclk get failed:%ld\n", PTR_ERR(rclk));
>> +		devm_clk_put(&pdev->dev, hclk);
> No need to call devm_clk_put() explicitly in your probe function.


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


  reply	other threads:[~2015-08-17 23:44 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-03  6:59 [PATCH V3 0/6] Introduce framework for SLIMbus device drivers Sagar Dharia
2015-08-03  6:59 ` [PATCH V3 1/6] SLIMbus: Device management on SLIMbus Sagar Dharia
2015-08-14 18:17   ` Mark Brown
2015-08-03  6:59 ` [PATCH V3 2/6] of/slimbus: OF helper for SLIMbus Sagar Dharia
2015-08-03 16:13   ` Rob Herring
2015-08-04 17:27     ` Mark Brown
2015-08-06 19:10     ` Sagar Dharia
2015-08-03  6:59 ` [PATCH V3 3/6] slimbus: Add messaging APIs to slimbus framework Sagar Dharia
2015-08-14 18:25   ` Mark Brown
2015-08-14 18:33     ` Mark Brown
2015-08-03  6:59 ` [PATCH V3 4/6] slim: qcom: Add Qualcomm Slimbus controller driver Sagar Dharia
2015-08-14 18:31   ` Mark Brown
2015-08-17 23:44     ` Sagar Dharia [this message]
2015-08-03  6:59 ` [PATCH V3 5/6] slimbus: Add support for 'clock-pause' feature Sagar Dharia
2015-08-14 18:39   ` Mark Brown
2015-08-17 23:43     ` Sagar Dharia
2015-08-03  6:59 ` [PATCH V3 6/6] slim: qcom: Add runtime-pm support using clock-pause feature Sagar Dharia
2015-08-14 18:43   ` Mark Brown
2015-08-14 18:46 ` [PATCH V3 0/6] Introduce framework for SLIMbus device drivers Mark Brown

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=55D271D4.6020903@codeaurora.org \
    --to=sdharia@codeaurora.org \
    --cc=agross@codeaurora.org \
    --cc=alan@linux.intel.com \
    --cc=andreas.noever@gmail.com \
    --cc=bp@suse.de \
    --cc=broonie@kernel.org \
    --cc=daniel.thompson@linaro.org \
    --cc=daniel@ffwll.ch \
    --cc=davem@davemloft.net \
    --cc=devicetree@vger.kernel.org \
    --cc=galak@codeaurora.org \
    --cc=gong.chen@linux.intel.com \
    --cc=gregkh@linuxfoundation.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=james.hogan@imgtec.com \
    --cc=jkosina@suse.cz \
    --cc=joe@perches.com \
    --cc=kheitke@audience.com \
    --cc=linux-arm-msm@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=mathieu.poirier@linaro.org \
    --cc=michael.opdenacker@free-electrons.com \
    --cc=mlocke@codeaurora.org \
    --cc=oded.gabbay@amd.com \
    --cc=pawel.moll@arm.com \
    --cc=poeschel@lemonage.de \
    --cc=robh+dt@kernel.org \
    --cc=sharon.dvir1@mail.huji.ac.il \
    --cc=treding@nvidia.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