All of lore.kernel.org
 help / color / mirror / Atom feed
From: Magnus Damm <magnus.damm@gmail.com>
To: linux-sh@vger.kernel.org
Subject: [PATCH] sh: i2c compile fix for kfr2r09
Date: Thu, 20 Aug 2009 13:57:36 +0000	[thread overview]
Message-ID: <20090820135736.23974.96123.sendpatchset@rx1.opensource.se> (raw)

From: Magnus Damm <damm@igel.co.jp>

Fix the kfr2r09 board code so it compiles if CONFIG_I2C=n.

Signed-off-by: Magnus Damm <damm@igel.co.jp>
---

 arch/sh/boards/mach-kfr2r09/setup.c |    7 +++++++
 1 file changed, 7 insertions(+)

--- 0001/arch/sh/boards/mach-kfr2r09/setup.c
+++ work/arch/sh/boards/mach-kfr2r09/setup.c	2009-08-20 12:48:09.000000000 +0900
@@ -219,6 +219,7 @@ static struct platform_device *kfr2r09_d
 #define BSC_CS4WCR 0xfec10030
 #define PORT_MSELCRB 0xa4050182
 
+#ifdef CONFIG_I2C
 static int kfr2r09_usb0_gadget_i2c_setup(void)
 {
 	struct i2c_adapter *a;
@@ -261,6 +262,12 @@ static int kfr2r09_usb0_gadget_i2c_setup
 
 	return 0;
 }
+#else
+static int kfr2r09_usb0_gadget_i2c_setup(void)
+{
+	return -ENODEV;
+}
+#endif
 
 static int kfr2r09_usb0_gadget_setup(void)
 {

             reply	other threads:[~2009-08-20 13:57 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-08-20 13:57 Magnus Damm [this message]
2009-08-20 23:45 ` [PATCH] sh: i2c compile fix for kfr2r09 Paul Mundt

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=20090820135736.23974.96123.sendpatchset@rx1.opensource.se \
    --to=magnus.damm@gmail.com \
    --cc=linux-sh@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.