diff mbox

[2/7] pinctrl: imx header, conditional probe functions

Message ID 1375439907-10462-3-git-send-email-mpa@pengutronix.de (mailing list archive)
State New, archived
Headers show

Commit Message

Markus Pargmann Aug. 2, 2013, 10:38 a.m. UTC
The functions are not available if included by imx1 core driver.

Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
---
 drivers/pinctrl/pinctrl-imx.h | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Shawn Guo Aug. 5, 2013, 5:43 a.m. UTC | #1
On Fri, Aug 02, 2013 at 12:38:22PM +0200, Markus Pargmann wrote:
> The functions are not available if included by imx1 core driver.
> 

Does imx1 core driver include the header?

Shawn

> Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
> ---
>  drivers/pinctrl/pinctrl-imx.h | 4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/drivers/pinctrl/pinctrl-imx.h b/drivers/pinctrl/pinctrl-imx.h
> index bcedd99..446fc01 100644
> --- a/drivers/pinctrl/pinctrl-imx.h
> +++ b/drivers/pinctrl/pinctrl-imx.h
> @@ -89,7 +89,11 @@ struct imx_pinctrl_soc_info {
>  #define IMX_MUX_MASK	0x7
>  #define IOMUXC_CONFIG_SION	(0x1 << 4)
>  
> +#if IS_ENABLED(PINCTRL_IMX)
> +
>  int imx_pinctrl_probe(struct platform_device *pdev,
>  			struct imx_pinctrl_soc_info *info);
>  int imx_pinctrl_remove(struct platform_device *pdev);
> +
> +#endif
>  #endif /* __DRIVERS_PINCTRL_IMX_H */
> -- 
> 1.8.3.2
>
Markus Pargmann Aug. 9, 2013, 1:31 p.m. UTC | #2
On Mon, Aug 05, 2013 at 01:43:15PM +0800, Shawn Guo wrote:
> On Fri, Aug 02, 2013 at 12:38:22PM +0200, Markus Pargmann wrote:
> > The functions are not available if included by imx1 core driver.
> > 
> 
> Does imx1 core driver include the header?

I removed the include to simplify some structs.

Thanks

Markus

> 
> Shawn
> 
> > Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
> > ---
> >  drivers/pinctrl/pinctrl-imx.h | 4 ++++
> >  1 file changed, 4 insertions(+)
> > 
> > diff --git a/drivers/pinctrl/pinctrl-imx.h b/drivers/pinctrl/pinctrl-imx.h
> > index bcedd99..446fc01 100644
> > --- a/drivers/pinctrl/pinctrl-imx.h
> > +++ b/drivers/pinctrl/pinctrl-imx.h
> > @@ -89,7 +89,11 @@ struct imx_pinctrl_soc_info {
> >  #define IMX_MUX_MASK	0x7
> >  #define IOMUXC_CONFIG_SION	(0x1 << 4)
> >  
> > +#if IS_ENABLED(PINCTRL_IMX)
> > +
> >  int imx_pinctrl_probe(struct platform_device *pdev,
> >  			struct imx_pinctrl_soc_info *info);
> >  int imx_pinctrl_remove(struct platform_device *pdev);
> > +
> > +#endif
> >  #endif /* __DRIVERS_PINCTRL_IMX_H */
> > -- 
> > 1.8.3.2
> > 
> 
>
diff mbox

Patch

diff --git a/drivers/pinctrl/pinctrl-imx.h b/drivers/pinctrl/pinctrl-imx.h
index bcedd99..446fc01 100644
--- a/drivers/pinctrl/pinctrl-imx.h
+++ b/drivers/pinctrl/pinctrl-imx.h
@@ -89,7 +89,11 @@  struct imx_pinctrl_soc_info {
 #define IMX_MUX_MASK	0x7
 #define IOMUXC_CONFIG_SION	(0x1 << 4)
 
+#if IS_ENABLED(PINCTRL_IMX)
+
 int imx_pinctrl_probe(struct platform_device *pdev,
 			struct imx_pinctrl_soc_info *info);
 int imx_pinctrl_remove(struct platform_device *pdev);
+
+#endif
 #endif /* __DRIVERS_PINCTRL_IMX_H */