lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20121114161135.71E153E0B1E@localhost>
Date:	Wed, 14 Nov 2012 16:11:35 +0000
From:	Grant Likely <grant.likely@...retlab.ca>
To:	Sasha Levin <sasha.levin@...cle.com>, rob.herring@...xeda.com,
	srinivas.kandagatla@...com
Cc:	devicetree-discuss@...ts.ozlabs.org, linux-kernel@...r.kernel.org,
	Sasha Levin <sasha.levin@...cle.com>
Subject: Re: [PATCH] of/mdio: fix build errors when CONFIG_OF isn't set

On Wed, 10 Oct 2012 12:31:23 -0400, Sasha Levin <sasha.levin@...cle.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@...cle.com>

Acked-by: Grant Likely <grant.likely@...retlab.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.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ