From patchwork Wed Dec 26 22:28:26 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 208237 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 9023B2C00BE for ; Thu, 27 Dec 2012 09:31:17 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 4BA494A100; Wed, 26 Dec 2012 23:30:58 +0100 (CET) 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 PVGvdUX9nGiA; Wed, 26 Dec 2012 23:30:58 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 65B5C4A11D; Wed, 26 Dec 2012 23:29:43 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id B2F414A018 for ; Wed, 26 Dec 2012 23:29:27 +0100 (CET) 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 hfPVkKbEzdYV for ; Wed, 26 Dec 2012 23:29:27 +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-qa0-f74.google.com (mail-qa0-f74.google.com [209.85.216.74]) by theia.denx.de (Postfix) with ESMTPS id 856904A0C6 for ; Wed, 26 Dec 2012 23:29:08 +0100 (CET) Received: by mail-qa0-f74.google.com with SMTP id r4so978414qaq.3 for ; Wed, 26 Dec 2012 14:29:07 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=9ZrBER6Xi2AR1MdarEPma5oZkBiEOc8FLA1qmeGq53k=; b=OUPdEpNZTC+A+bLbkAxWH3XWYwM6adep5XoeoHZuYwwLqCbdQtbA6Evfko4RIpfOb9 YU8QWOlN09k7u3CuijuAzMDxwwpeppYTqvKvzF4M8Fnr6d4pQmb7lpDCGIRMlmBYs0qB A14/f8KcPTkDLXkddo26bMk9wOBph/wCr9VpWIeF/SIIFGDHIWGbv13uqkFgo5kksqPO UUIdp/sUWvGYhf19qEepW3b6XZ3W2KpBYKFY5gxPbEDwLV2i82AXbZsL1CORicrAjjpw WbQMVLKwCmJ9X0XlytD8vhVEkzi9stm8s7g07ovJ67E5o8oHrIOHVsqZ9eXMl02So/P1 MJ7w== X-Received: by 10.236.151.39 with SMTP id a27mr13188198yhk.42.1356560946121; Wed, 26 Dec 2012 14:29:06 -0800 (PST) Received: from wpzn4.hot.corp.google.com (216-239-44-65.google.com [216.239.44.65]) by gmr-mx.google.com with ESMTPS id u20si1220710anj.3.2012.12.26.14.29.06 (version=TLSv1/SSLv3 cipher=AES128-SHA); Wed, 26 Dec 2012 14:29:06 -0800 (PST) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by wpzn4.hot.corp.google.com (Postfix) with ESMTP id 065AE820050; Wed, 26 Dec 2012 14:29:06 -0800 (PST) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id BC138162632; Wed, 26 Dec 2012 14:29:05 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Date: Wed, 26 Dec 2012 14:28:26 -0800 Message-Id: <1356560913-2205-9-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.7.7.3 In-Reply-To: <1356560913-2205-1-git-send-email-sjg@chromium.org> References: <1356560913-2205-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQkmubjAm4kVwbGPiSK8uPGK+DnxvoPj4E137qSHTc8aEFi9bY01Ii0j0vzwJqacHPOJnDcXAiR8xuB+Z2P+0hCEsT61wpTnX7t5s5TvyxvvVIUNk+ZM/LSMroxJ0bzq9npFA8y0scD8xH/5nV2rmXbjobi5QYGBOmw/RVJNMq4Y1g+R1L8aL5XdHaEmwguwKkVC5idX Cc: Graeme Russ , Tom Warren Subject: [U-Boot] [PATCH 08/15] spi: Add parameter for maximum write size 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 Some SPI controllers (e.g. Intel ICH) have a limit on the number of SPI bytes that can be written at a time. Add this as a parameter so that clients of the SPI interface can respect this value. Signed-off-by: Simon Glass --- include/spi.h | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/include/spi.h b/include/spi.h index ebc9652..3fe2e1e 100644 --- a/include/spi.h +++ b/include/spi.h @@ -49,10 +49,13 @@ * * bus: ID of the bus that the slave is attached to. * cs: ID of the chip select connected to the slave. + * max_write_size: If non-zero, the maximum number of bytes which can + * be written at once, excluding command bytes. */ struct spi_slave { unsigned int bus; unsigned int cs; + unsigned int max_write_size; }; /*-----------------------------------------------------------------------