public inbox for linux-arm-kernel@lists.infradead.org 
 help / color / mirror / Atom feed
From: sergei.shtylyov@cogentembedded•com (Sergei Shtylyov)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH v8 2/3] ahci_xgene: Skip the PHY and clock initialization if already configured by the firmware.
Date: Sat, 23 Aug 2014 22:43:57 +0400	[thread overview]
Message-ID: <53F8E0ED.6030802@cogentembedded.com> (raw)
In-Reply-To: <1408819047-17224-3-git-send-email-stripathi@apm.com>

Hello.

On 08/23/2014 10:37 PM, Suman Tripathi wrote:

> This patch implements the feature to skip the PHY and clock
> initialization if it is already configured by the firmware.

> Signed-off-by: Loc Ho <lho@apm•com>
> Signed-off-by: Suman Tripathi <stripathi@apm•com>
> ---
>   drivers/ata/ahci_xgene.c | 16 ++++++++++++++++
>   1 file changed, 16 insertions(+)

> diff --git a/drivers/ata/ahci_xgene.c b/drivers/ata/ahci_xgene.c
> index f416495..fd9c137 100644
> --- a/drivers/ata/ahci_xgene.c
> +++ b/drivers/ata/ahci_xgene.c
> @@ -145,6 +145,15 @@ static unsigned int xgene_ahci_qc_issue(struct ata_queued_cmd *qc)
>   	return rc;
>   }
>
> +static bool xgene_ahci_is_memram_inited(struct xgene_ahci_context *ctx)
> +{
> +	void __iomem *diagcsr = ctx->csr_diag;
> +
> +	return (readl(diagcsr + CFG_MEM_RAM_SHUTDOWN) == 0 &&
> +	        readl(diagcsr + BLOCK_MEM_RDY) == 0xFFFFFFFF) ?
> +		true : false;

    Just return the result of &&, that should be enough.

WBR, Sergei

       reply	other threads:[~2014-08-23 18:43 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1408819047-17224-1-git-send-email-stripathi@apm.com>
     [not found] ` <1408819047-17224-3-git-send-email-stripathi@apm.com>
2014-08-23 18:43   ` Sergei Shtylyov [this message]
     [not found] ` <1408819047-17224-4-git-send-email-stripathi@apm.com>
2014-08-25 19:30   ` [PATCH v8 3/3] ahci_xgene: Fix the link down in first attempt for the APM X-Gene SoC AHCI SATA host controller driver Tejun Heo
     [not found]     ` <CAOHikRDpLBAnH4pmFzfu_RXFUZNAWPc-Q34zS1_Mx-odOmXonA@mail.gmail.com>
2014-08-26 15:29       ` Tejun Heo

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=53F8E0ED.6030802@cogentembedded.com \
    --to=sergei.shtylyov@cogentembedded$(echo .)com \
    --cc=linux-arm-kernel@lists$(echo .)infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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