public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Grant Likely <grant.likely@secretlab.ca>
To: Sasha Levin <sasha.levin@oracle.com>,
	rob.herring@calxeda.com, srinivas.kandagatla@st.com
Cc: devicetree-discuss@lists.ozlabs.org,
	linux-kernel@vger.kernel.org,
	Sasha Levin <sasha.levin@oracle.com>
Subject: Re: [PATCH] of/mdio: fix build errors when CONFIG_OF isn't set
Date: Wed, 14 Nov 2012 16:11:35 +0000	[thread overview]
Message-ID: <20121114161135.71E153E0B1E@localhost> (raw)
In-Reply-To: <1349886683-26351-1-git-send-email-sasha.levin@oracle.com>

On Wed, 10 Oct 2012 12:31:23 -0400, Sasha Levin <sasha.levin@oracle.com> wrote:
> Commit f9dc9ac5 ("of/mdio: Add dummy functions in of_mdio.h.") has added
> empty stubs into of_mdio.h which were not static, this causes build errors
> when these symbols were defined across several objects.
> 
> Fix it by marking those stubs as 'static inline'.
> 
> Signed-off-by: Sasha Levin <sasha.levin@oracle.com>

Acked-by: Grant Likely <grant.likely@secretlab.ca>

Rob, can you please pick up into your merge branch for device tree?

Thanks,
g.

> ---
>  include/linux/of_mdio.h | 10 +++++-----
>  1 file changed, 5 insertions(+), 5 deletions(-)
> 
> diff --git a/include/linux/of_mdio.h b/include/linux/of_mdio.h
> index 6ef49b8..7f17b9c 100644
> --- a/include/linux/of_mdio.h
> +++ b/include/linux/of_mdio.h
> @@ -26,17 +26,17 @@ extern struct phy_device *of_phy_connect_fixed_link(struct net_device *dev,
>  extern struct mii_bus *of_mdio_find_bus(struct device_node *mdio_np);
>  
>  #else /* CONFIG_OF */
> -int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)
> +static inline int of_mdiobus_register(struct mii_bus *mdio, struct device_node *np)
>  {
>  	return -ENOSYS;
>  }
>  
> -struct phy_device *of_phy_find_device(struct device_node *phy_np)
> +static inline struct phy_device *of_phy_find_device(struct device_node *phy_np)
>  {
>  	return NULL;
>  }
>  
> -struct phy_device *of_phy_connect(struct net_device *dev,
> +static inline struct phy_device *of_phy_connect(struct net_device *dev,
>  					 struct device_node *phy_np,
>  					 void (*hndlr)(struct net_device *),
>  					 u32 flags, phy_interface_t iface)
> @@ -44,14 +44,14 @@ struct phy_device *of_phy_connect(struct net_device *dev,
>  	return NULL;
>  }
>  
> -struct phy_device *of_phy_connect_fixed_link(struct net_device *dev,
> +static inline struct phy_device *of_phy_connect_fixed_link(struct net_device *dev,
>  					 void (*hndlr)(struct net_device *),
>  					 phy_interface_t iface)
>  {
>  	return NULL;
>  }
>  
> -struct mii_bus *of_mdio_find_bus(struct device_node *mdio_np)
> +static inline struct mii_bus *of_mdio_find_bus(struct device_node *mdio_np)
>  {
>  	return NULL;
>  }
> -- 
> 1.7.12
> 

-- 
Grant Likely, B.Sc, P.Eng.
Secret Lab Technologies, Ltd.

  reply	other threads:[~2012-11-14 16:11 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-10 16:31 [PATCH] of/mdio: fix build errors when CONFIG_OF isn't set Sasha Levin
2012-11-14 16:11 ` Grant Likely [this message]
2012-11-14 17:10   ` Rob Herring
2012-11-14 17:22     ` 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=20121114161135.71E153E0B1E@localhost \
    --to=grant.likely@secretlab.ca \
    --cc=devicetree-discuss@lists.ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rob.herring@calxeda.com \
    --cc=sasha.levin@oracle.com \
    --cc=srinivas.kandagatla@st.com \
    /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