From: Peter Korsgaard <jacmet@sunsite.dk>
To: grant.likely@secretlab.ca, linux-kernel@vger.kernel.org
Cc: Peter Korsgaard <jacmet@sunsite.dk>
Subject: [PATCHv2 1/3] mcp23s08: get rid of setup/teardown callbacks
Date: Fri, 15 Jul 2011 10:25:30 +0200 [thread overview]
Message-ID: <1310718332-10438-1-git-send-email-jacmet@sunsite.dk> (raw)
There's no in-tree users, and bus notifiers are more generic anyway.
Signed-off-by: Peter Korsgaard <jacmet@sunsite.dk>
---
drivers/gpio/gpio-mcp23s08.c | 19 -------------------
include/linux/spi/mcp23s08.h | 9 ---------
2 files changed, 0 insertions(+), 28 deletions(-)
diff --git a/drivers/gpio/gpio-mcp23s08.c b/drivers/gpio/gpio-mcp23s08.c
index da3e04f..ef61234 100644
--- a/drivers/gpio/gpio-mcp23s08.c
+++ b/drivers/gpio/gpio-mcp23s08.c
@@ -432,14 +432,6 @@ static int mcp23s08_probe(struct spi_device *spi)
* handled here...
*/
- if (pdata->setup) {
- status = pdata->setup(spi,
- pdata->base, data->ngpio,
- pdata->context);
- if (status < 0)
- dev_dbg(&spi->dev, "setup --> %d\n", status);
- }
-
return 0;
fail:
@@ -459,20 +451,9 @@ fail:
static int mcp23s08_remove(struct spi_device *spi)
{
struct mcp23s08_driver_data *data = spi_get_drvdata(spi);
- struct mcp23s08_platform_data *pdata = spi->dev.platform_data;
unsigned addr;
int status = 0;
- if (pdata->teardown) {
- status = pdata->teardown(spi,
- pdata->base, data->ngpio,
- pdata->context);
- if (status < 0) {
- dev_err(&spi->dev, "%s --> %d\n", "teardown", status);
- return status;
- }
- }
-
for (addr = 0; addr < ARRAY_SIZE(data->mcp); addr++) {
int tmp;
diff --git a/include/linux/spi/mcp23s08.h b/include/linux/spi/mcp23s08.h
index c42cff8..2d676d5 100644
--- a/include/linux/spi/mcp23s08.h
+++ b/include/linux/spi/mcp23s08.h
@@ -22,13 +22,4 @@ struct mcp23s08_platform_data {
* base to base+15 (or base+31 for s17 variant).
*/
unsigned base;
-
- void *context; /* param to setup/teardown */
-
- int (*setup)(struct spi_device *spi,
- int gpio, unsigned ngpio,
- void *context);
- int (*teardown)(struct spi_device *spi,
- int gpio, unsigned ngpio,
- void *context);
};
--
1.7.5.4
next reply other threads:[~2011-07-15 8:25 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-07-15 8:25 Peter Korsgaard [this message]
2011-07-15 8:25 ` [PATCHv2 2/3] mcp23s08: isolate spi specific parts Peter Korsgaard
2011-07-15 8:25 ` [PATCHv2 3/3] mcp23s08: add i2c support Peter Korsgaard
2011-07-15 19:56 ` [PATCHv2 1/3] mcp23s08: get rid of setup/teardown callbacks Grant Likely
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=1310718332-10438-1-git-send-email-jacmet@sunsite.dk \
--to=jacmet@sunsite.dk \
--cc=grant.likely@secretlab.ca \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®