From patchwork Fri Dec 12 14:06:16 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 420494 X-Patchwork-Delegate: sjg@chromium.org 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 33AA8140082 for ; Sat, 13 Dec 2014 01:07:36 +1100 (AEDT) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id CCB564BA86; Fri, 12 Dec 2014 15:07:12 +0100 (CET) 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 eJCKfCDQ1ci3; Fri, 12 Dec 2014 15:07:12 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 60C9B4BAD1; Fri, 12 Dec 2014 15:07:03 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 3DEBC4BA7B for ; Fri, 12 Dec 2014 15:06:50 +0100 (CET) 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 ectCeI790YLK for ; Fri, 12 Dec 2014 15:06:50 +0100 (CET) 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-pd0-f172.google.com (mail-pd0-f172.google.com [209.85.192.172]) by theia.denx.de (Postfix) with ESMTPS id 9798F4BA95 for ; Fri, 12 Dec 2014 15:06:48 +0100 (CET) Received: by mail-pd0-f172.google.com with SMTP id y13so7209763pdi.31 for ; Fri, 12 Dec 2014 06:06:47 -0800 (PST) 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=pFjbO0RCIvmMelAPTrHxiRCmkHj55ZOmpStiwbwH6VY=; b=jfAsJahJKkS/nu0srpR7oXfPPNnXKqe7rLQg2GxLo8YwlfPVbLgTv6/hmXBptNcyJ0 /dg+b4RzpioCitFCxboJMY7EwLL4LpZcH6/E5qbXHFoREiU1abzusz/ukgMVyFJ2HfdC PdlNdMJoYH6up4uBADNOBAbOaXhrGFGIGbfiRNIdz8DXgvI+11zRGUzekU8REOMaQqRa 5UDFkKghmVYjexUGHmbbHxLX94AbQQuGabR3/qY9pacHkWhX8BDL6gGt39Nc8wheNSH4 oTbOOsJH+Q3ziUfkPrS0WMQhdIOAcKnEoSxWLz6qH6bVS0iEMKwuJfQ+RmWyX2M6dG5r Td2A== X-Received: by 10.68.69.66 with SMTP id c2mr26568524pbu.81.1418393206932; Fri, 12 Dec 2014 06:06:46 -0800 (PST) Received: from localhost.localdomain ([49.248.59.149]) by mx.google.com with ESMTPSA id py1sm1672015pdb.74.2014.12.12.06.06.44 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 12 Dec 2014 06:06:46 -0800 (PST) From: Jagannadha Sutradharudu Teki To: u-boot@lists.denx.de Date: Fri, 12 Dec 2014 19:36:16 +0530 Message-Id: <1418393176-16002-7-git-send-email-jagannadh.teki@gmail.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1418393176-16002-1-git-send-email-jagannadh.teki@gmail.com> References: <1418393176-16002-1-git-send-email-jagannadh.teki@gmail.com> Subject: [U-Boot] [PATCH v2 6/6] x86: ich-spi: Set the tx operation mode for ich 7 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.13 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: Bin Meng ICH 7 SPI controller only supports byte program (02h) for SST flash. Word program (ADh) is not supported. Signed-off-by: Bin Meng Reviewed-by: Jagannadha Sutradharudu Teki --- drivers/spi/ich.c | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/spi/ich.c b/drivers/spi/ich.c index 0ef8bd4..d5cea39 100644 --- a/drivers/spi/ich.c +++ b/drivers/spi/ich.c @@ -141,9 +141,14 @@ struct spi_slave *spi_setup_slave(unsigned int bus, unsigned int cs, ich->slave.max_write_size = ctlr.databytes; ich->speed = max_hz; - /* ICH 7 SPI controller only supports array read command */ - if (ctlr.ich_version == 7) + /* + * ICH 7 SPI controller only supports array read command + * and byte program command for SST flash + */ + if (ctlr.ich_version == 7) { ich->slave.op_mode_rx = SPI_OPM_RX_AS; + ich->slave.op_mode_tx = SPI_OPM_TX_BP; + } return &ich->slave; }