From patchwork Fri Oct 19 03:45:03 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 192518 X-Patchwork-Delegate: trini@ti.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id D717C2C007A for ; Fri, 19 Oct 2012 14:48:39 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C2D534A541; Fri, 19 Oct 2012 05:47:53 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id cpnOg+4I5NPk; Fri, 19 Oct 2012 05:47:53 +0200 (CEST) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 755CA4A542; Fri, 19 Oct 2012 05:46:30 +0200 (CEST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 9BA8B4A4BF for ; Fri, 19 Oct 2012 05:46:00 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Ooej7KTSQLEG for ; Fri, 19 Oct 2012 05:45:59 +0200 (CEST) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-vb0-f74.google.com (mail-vb0-f74.google.com [209.85.212.74]) by theia.denx.de (Postfix) with ESMTPS id 8D27A4A4CE for ; Fri, 19 Oct 2012 05:45:43 +0200 (CEST) Received: by mail-vb0-f74.google.com with SMTP id s24so3907vbi.3 for ; Thu, 18 Oct 2012 20:45:40 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=I0Xkhozv1rSq2ieZ7DL6w/eukzgja/6UDSFUEUx0AGk=; b=EBZh7ZMS29YNvNI3/VfiN+5+CVot0lpcCbdECQ8eS4TfvNLTxtcjAUJjCH3+FYX3yN SO1zqEKL5fY97YiubZuwkyAKdrmo3xUVDL9wioCuw25HsRAqxlcPYFL7hFYGb+tvEiHd PmH3aJ+6F9lKjZ5KrqG6sWE1PsckyJjczRQjNulTd0bLdyqJfRG0chFAIJYKHCPWKiMF yKfXSacUCct/YnmY6dEhl5jcmlsf4gHRfTUaje6k96sMKEtqXNyIV5CZNsNLoR2eY/Fv hJIBraCv/PBu70+b7b/Vp8toXkrtv8XwR6t+4cBg/AJb04yVPogdD7hehcDvgB4C0+sp WEHA== Received: by 10.236.153.6 with SMTP id e6mr17928322yhk.20.1350618340760; Thu, 18 Oct 2012 20:45:40 -0700 (PDT) Received: from wpzn3.hot.corp.google.com (216-239-44-65.google.com [216.239.44.65]) by gmr-mx.google.com with ESMTPS id o6si37040yhn.7.2012.10.18.20.45.40 (version=TLSv1/SSLv3 cipher=AES128-SHA); Thu, 18 Oct 2012 20:45:40 -0700 (PDT) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by wpzn3.hot.corp.google.com (Postfix) with ESMTP id 96CF8100047; Thu, 18 Oct 2012 20:45:40 -0700 (PDT) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id 4C9D4160E37; Thu, 18 Oct 2012 20:45:40 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Date: Thu, 18 Oct 2012 20:45:03 -0700 Message-Id: <1350618317-6878-7-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.7.7.3 In-Reply-To: <1350618317-6878-1-git-send-email-sjg@chromium.org> References: <1350618317-6878-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQkIkwekpiu/QObd6N/UPVkrF60RFesE4VDY1YkIWBytk+ZJP4YdthXwmSRHXcbq07rT6alLpd/q5a4XJVG0kzEmJbqBCOcMtxMg0l3dbLkn1VBEUXl+VpM8TZp+I4vzT/C1f1Wm1eQpArRW/SAa98eruYyJTruZlnLqNesqch+y4wgi3+S00dXz8XsA2pKW+ynGANa9 Cc: Tom Rini , Stefan Reinauer , Rob Herring Subject: [U-Boot] [PATCH 06/20] ahci: Improve AHCI debugging X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de From: Stefan Reinauer - remove unused ssleep macro - add some useful debugging information Signed-off-by: Stefan Reinauer Signed-off-by: Simon Glass --- drivers/block/ahci.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/drivers/block/ahci.c b/drivers/block/ahci.c index ad397dc..af31c97 100644 --- a/drivers/block/ahci.c +++ b/drivers/block/ahci.c @@ -68,7 +68,6 @@ static void ahci_setup_port(struct ahci_ioports *port, unsigned long base, #define msleep(a) udelay(a * 1000) -#define ssleep(a) msleep(a * 1000) static int waiting_for_cmd_completed(volatile u8 *offset, int timeout_msec, @@ -153,6 +152,7 @@ static int ahci_host_init(struct ahci_probe_ent *probe_ent) tmp = readl(port_mmio + PORT_CMD); if (tmp & (PORT_CMD_LIST_ON | PORT_CMD_FIS_ON | PORT_CMD_FIS_RX | PORT_CMD_START)) { + debug("Port %d is active. Deactivating.\n", i); tmp &= ~(PORT_CMD_LIST_ON | PORT_CMD_FIS_ON | PORT_CMD_FIS_RX | PORT_CMD_START); writel_with_flush(tmp, port_mmio + PORT_CMD); @@ -163,6 +163,7 @@ static int ahci_host_init(struct ahci_probe_ent *probe_ent) msleep(500); } + debug("Spinning up port %d... ", i); writel(PORT_CMD_SPIN_UP, port_mmio + PORT_CMD); j = 0;