From: jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org
To: spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Cc: dbrownell-Rn4VEauK+AKRv+LV9MX5uipxlwaOVQ5f@public.gmane.org,
ben-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org
Subject: [PATCH 6/6] SPI: S3C64XX: Add new parameter to cs callback
Date: Mon, 18 Jan 2010 18:50:15 +0900 [thread overview]
Message-ID: <1263808215-16544-6-git-send-email-jassisinghbrar@gmail.com> (raw)
In-Reply-To: <1263808215-16544-5-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
From: Jassi Brar <jassi.brar-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
Since most of the chip-selects are simply going to be like
gpio_set_value, it would do good to have the same callback type
so that it could simply be made to point at gpio_set_value.
Signed-off-by: Jassi Brar <jassi.brar-Sze3O3UU22JBDgjK7y7TUQ@public.gmane.org>
---
drivers/spi/spi_s3c64xx.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/drivers/spi/spi_s3c64xx.c b/drivers/spi/spi_s3c64xx.c
index 9fa0b99..32db695 100644
--- a/drivers/spi/spi_s3c64xx.c
+++ b/drivers/spi/spi_s3c64xx.c
@@ -300,13 +300,14 @@ static inline void enable_cs(struct s3c64xx_spi_driver_data *sdd,
if (sdd->tgl_spi != spi) { /* if last mssg on diff device */
/* Deselect the last toggled device */
cs = sdd->tgl_spi->controller_data;
- cs->set_level(spi->mode & SPI_CS_HIGH ? 0 : 1);
+ cs->set_level(cs->line,
+ spi->mode & SPI_CS_HIGH ? 0 : 1);
}
sdd->tgl_spi = NULL;
}
cs = spi->controller_data;
- cs->set_level(spi->mode & SPI_CS_HIGH ? 1 : 0);
+ cs->set_level(cs->line, spi->mode & SPI_CS_HIGH ? 1 : 0);
}
static int wait_for_xfer(struct s3c64xx_spi_driver_data *sdd,
@@ -386,7 +387,7 @@ static inline void disable_cs(struct s3c64xx_spi_driver_data *sdd,
if (sdd->tgl_spi == spi)
sdd->tgl_spi = NULL;
- cs->set_level(spi->mode & SPI_CS_HIGH ? 0 : 1);
+ cs->set_level(cs->line, spi->mode & SPI_CS_HIGH ? 0 : 1);
}
static void s3c64xx_spi_config(struct s3c64xx_spi_driver_data *sdd)
--
1.6.2.5
------------------------------------------------------------------------------
Throughout its 18-year history, RSA Conference consistently attracts the
world's best and brightest in the field, creating opportunities for Conference
attendees to learn about information security's most important issues through
interactions with peers, luminaries and emerging and established companies.
http://p.sf.net/sfu/rsaconf-dev2dev
next prev parent reply other threads:[~2010-01-18 9:50 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-01-18 9:50 [PATCH 1/6] SPI: S3C64XX: Rename s3c64xx_spi_cntrlr_info jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w
[not found] ` <1263808215-16544-1-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 9:50 ` [PATCH 2/6] SPI: S3C64XX: Differentiate ip and rate clock jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w
[not found] ` <1263808215-16544-2-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 9:50 ` [PATCH 3/6] SPI: S3C64XX: Move src_clk to local driver data jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w
[not found] ` <1263808215-16544-3-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 9:50 ` [PATCH 4/6] SPI: S3C64XX: Check before mem-region release jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w
[not found] ` <1263808215-16544-4-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 9:50 ` [PATCH 5/6] SPI: S3C64XX: Include moved header jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w
[not found] ` <1263808215-16544-5-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 9:50 ` jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w [this message]
[not found] ` <1263808215-16544-6-git-send-email-jassisinghbrar-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2010-01-18 18:15 ` [PATCH 6/6] SPI: S3C64XX: Add new parameter to cs callback Grant Likely
[not found] ` <fa686aa41001181015g6b3d35fdy8ee0f5134a8ca1a5-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-18 23:49 ` jassi brar
2010-01-18 18:13 ` [PATCH 5/6] SPI: S3C64XX: Include moved header Grant Likely
[not found] ` <fa686aa41001181013i62142f3fs5c387a406f3b7d59-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-18 23:46 ` jassi brar
2010-01-18 18:12 ` [PATCH 4/6] SPI: S3C64XX: Check before mem-region release Grant Likely
[not found] ` <fa686aa41001181012s57c0e863s6b9b6b2724514a9f-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-18 23:42 ` jassi brar
[not found] ` <1b68c6791001181542p618a8d47n45a120e51cfed1f1-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-19 2:32 ` Grant Likely
[not found] ` <fa686aa41001181832r3d2462f6y87649244b8afc5f2-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-19 9:52 ` jassi brar
[not found] ` <1b68c6791001190152m652fd117k468893144af8dcfe-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-21 1:35 ` jassi brar
[not found] ` <1b68c6791001201735w3060c54blfa85b547917727c2-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-21 1:46 ` jassi brar
[not found] ` <1b68c6791001201746p313234bbkdf5fe5db0dcecd9f-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-21 2:55 ` Grant Likely
[not found] ` <fa686aa41001201855m5c054d90nb3652a5b0d3ffd86-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-21 3:06 ` jassi brar
[not found] ` <1b68c6791001201906r45c52f71h7f5ea396e91ef3b8-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-21 15:00 ` Grant Likely
2010-01-21 15:10 ` Carl-Daniel Hailfinger
2010-01-22 14:51 ` Ralf Baechle
2010-01-18 17:58 ` [PATCH 2/6] SPI: S3C64XX: Differentiate ip and rate clock Grant Likely
[not found] ` <fa686aa41001180958l15df3a9dyfa5869b6f53c8fcb-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org>
2010-01-18 23:40 ` jassi brar
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=1263808215-16544-6-git-send-email-jassisinghbrar@gmail.com \
--to=jassisinghbrar-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
--cc=ben-SMNkleLxa3Z6Wcw2j4pizdi2O/JbrIOy@public.gmane.org \
--cc=dbrownell-Rn4VEauK+AKRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
--cc=spi-devel-general-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
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;
as well as URLs for NNTP newsgroup(s).