From patchwork Fri Oct 9 01:48:26 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabio Estevam X-Patchwork-Id: 7358641 X-Patchwork-Delegate: bhelgaas@google.com Return-Path: X-Original-To: patchwork-linux-pci@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id D87B79F1B9 for ; Fri, 9 Oct 2015 01:48:56 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 14900207A8 for ; Fri, 9 Oct 2015 01:48:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 72658207AD for ; Fri, 9 Oct 2015 01:48:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754911AbbJIBsx (ORCPT ); Thu, 8 Oct 2015 21:48:53 -0400 Received: from mail-qk0-f171.google.com ([209.85.220.171]:35944 "EHLO mail-qk0-f171.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753361AbbJIBsx (ORCPT ); Thu, 8 Oct 2015 21:48:53 -0400 Received: by qkht68 with SMTP id t68so27074380qkh.3 for ; Thu, 08 Oct 2015 18:48:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=gIRSLyurRsofxp+NSrsh01wbAN5c6REO8Bg+rfD/UnE=; b=ZIt9ciiczZmtqMjVPFumcRxZ82Blc/1ivfLeGVyuuLSv9cUVoH/Y9etfti5CylsDP3 vmpzHi8z/1WLep2M1NAa/uB+owgiTdTgDWn48PIszlWW4RwyrSiBN8+8ImnH0TXF+XB7 qANhBiMrnwWWQ3oFz5sV7M3BHpDZXG63rBAuHX5oRXfCRcu06m2JtTUat9aRDYNS5GN6 /he2bfhTM80NVgwR4aaDbUGETIP4/6ivU0t4/FDdxkPjaJLsH68RxyExlbPHihrWYNMA EKYYZ3bLut6VfYOHdkUaAr7AWteMgsQ07KkhxOm54eBPJNCGOV9OP7+jeUU5ifI0iofk YdyQ== X-Received: by 10.55.192.81 with SMTP id o78mr12061472qki.97.1444355332333; Thu, 08 Oct 2015 18:48:52 -0700 (PDT) Received: from localhost.localdomain ([189.5.18.107]) by smtp.gmail.com with ESMTPSA id j193sm19837745qhc.17.2015.10.08.18.48.49 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 08 Oct 2015 18:48:51 -0700 (PDT) From: Fabio Estevam To: bhelgaas@google.com Cc: pratyush.anand@gmail.com, m-karicheri2@ti.com, l.stach@pengutronix.de, linux-pci@vger.kernel.org, Fabio Estevam Subject: [PATCH v2 2/2] PCI: imx6: Use define instead of hard coded value Date: Thu, 8 Oct 2015 22:48:26 -0300 Message-Id: <1444355306-21486-2-git-send-email-festevam@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1444355306-21486-1-git-send-email-festevam@gmail.com> References: <1444355306-21486-1-git-send-email-festevam@gmail.com> Sender: linux-pci-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-pci@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, T_DKIM_INVALID, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Fabio Estevam Use LTSSM_STATE_RCVRY_LOCK define instead of hard coded value in order to improve the code readability; Signed-off-by: Fabio Estevam Reviewed-by: Lucas Stach --- Changes since v1: - None drivers/pci/host/pci-imx6.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/pci/host/pci-imx6.c b/drivers/pci/host/pci-imx6.c index 6f43086..4e7b577 100644 --- a/drivers/pci/host/pci-imx6.c +++ b/drivePCIE_PHY_DEBUG_R0_LTSSM_MASKrs/pci/host/pci-imx6.c @@ -508,7 +508,7 @@ static int imx6_pcie_link_up(struct pcie_port *pp) if (rx_valid & PCIE_PHY_RX_ASIC_OUT_VALID) return 0; - if ((debug_r0 & PCIE_PHY_DEBUG_R0_LTSSM_MASK) != 0x0d) + if ((debug_r0 & PCIE_PHY_DEBUG_R0_LTSSM_MASK) != LTSSM_STATE_RCVRY_LOCK) return 0; dev_err(pp->dev, "transition to gen2 is stuck, reset PHY!\n");