* [U-Boot] [PATCH] arm: imx: Change iomux functions to void type
@ 2013-04-11 9:06 Stefan Roese
2013-04-11 18:53 ` Marek Vasut
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Stefan Roese @ 2013-04-11 9:06 UTC (permalink / raw)
To: u-boot
They never return anything also than 0, so lets change the function
to void instead.
Signed-off-by: Stefan Roese <sr@denx.de>
---
arch/arm/imx-common/iomux-v3.c | 18 +++++-------------
arch/arm/include/asm/imx-common/iomux-v3.h | 4 ++--
2 files changed, 7 insertions(+), 15 deletions(-)
diff --git a/arch/arm/imx-common/iomux-v3.c b/arch/arm/imx-common/iomux-v3.c
index 08fad78..7fe5ce7 100644
--- a/arch/arm/imx-common/iomux-v3.c
+++ b/arch/arm/imx-common/iomux-v3.c
@@ -30,7 +30,7 @@ static void *base = (void *)IOMUXC_BASE_ADDR;
/*
* configures a single pad in the iomuxer
*/
-int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
+void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
{
u32 mux_ctrl_ofs = (pad & MUX_CTRL_OFS_MASK) >> MUX_CTRL_OFS_SHIFT;
u32 mux_mode = (pad & MUX_MODE_MASK) >> MUX_MODE_SHIFT;
@@ -50,22 +50,14 @@ int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
if (!(pad_ctrl & NO_PAD_CTRL) && pad_ctrl_ofs)
__raw_writel(pad_ctrl, base + pad_ctrl_ofs);
-
- return 0;
}
-int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
- unsigned count)
+void imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
+ unsigned count)
{
iomux_v3_cfg_t const *p = pad_list;
int i;
- int ret;
- for (i = 0; i < count; i++) {
- ret = imx_iomux_v3_setup_pad(*p);
- if (ret)
- return ret;
- p++;
- }
- return 0;
+ for (i = 0; i < count; i++)
+ imx_iomux_v3_setup_pad(*p++);
}
diff --git a/arch/arm/include/asm/imx-common/iomux-v3.h b/arch/arm/include/asm/imx-common/iomux-v3.h
index c34bb76..70bf3cd 100644
--- a/arch/arm/include/asm/imx-common/iomux-v3.h
+++ b/arch/arm/include/asm/imx-common/iomux-v3.h
@@ -97,8 +97,8 @@ typedef u64 iomux_v3_cfg_t;
#define MUX_CONFIG_SION (0x1 << 4)
-int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
-int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
+void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
+void imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
unsigned count);
#endif /* __MACH_IOMUX_V3_H__*/
--
1.8.2.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [U-Boot] [PATCH] arm: imx: Change iomux functions to void type
2013-04-11 9:06 [U-Boot] [PATCH] arm: imx: Change iomux functions to void type Stefan Roese
@ 2013-04-11 18:53 ` Marek Vasut
2013-04-13 20:53 ` Stefano Babic
2013-04-16 11:04 ` Stefano Babic
2 siblings, 0 replies; 4+ messages in thread
From: Marek Vasut @ 2013-04-11 18:53 UTC (permalink / raw)
To: u-boot
Dear Stefan Roese,
> They never return anything also than 0, so lets change the function
> to void instead.
>
> Signed-off-by: Stefan Roese <sr@denx.de>
Add my:
Reviewed-by: Marek Vasut <marex@denx.de>
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 4+ messages in thread
* [U-Boot] [PATCH] arm: imx: Change iomux functions to void type
2013-04-11 9:06 [U-Boot] [PATCH] arm: imx: Change iomux functions to void type Stefan Roese
2013-04-11 18:53 ` Marek Vasut
@ 2013-04-13 20:53 ` Stefano Babic
2013-04-16 11:04 ` Stefano Babic
2 siblings, 0 replies; 4+ messages in thread
From: Stefano Babic @ 2013-04-13 20:53 UTC (permalink / raw)
To: u-boot
On 11/04/2013 11:06, Stefan Roese wrote:
> They never return anything also than 0, so lets change the function
> to void instead.
>
> Signed-off-by: Stefan Roese <sr@denx.de>
> ---
> arch/arm/imx-common/iomux-v3.c | 18 +++++-------------
> arch/arm/include/asm/imx-common/iomux-v3.h | 4 ++--
> 2 files changed, 7 insertions(+), 15 deletions(-)
>
> diff --git a/arch/arm/imx-common/iomux-v3.c b/arch/arm/imx-common/iomux-v3.c
> index 08fad78..7fe5ce7 100644
> --- a/arch/arm/imx-common/iomux-v3.c
> +++ b/arch/arm/imx-common/iomux-v3.c
> @@ -30,7 +30,7 @@ static void *base = (void *)IOMUXC_BASE_ADDR;
> /*
> * configures a single pad in the iomuxer
> */
> -int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
> +void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
> {
> u32 mux_ctrl_ofs = (pad & MUX_CTRL_OFS_MASK) >> MUX_CTRL_OFS_SHIFT;
> u32 mux_mode = (pad & MUX_MODE_MASK) >> MUX_MODE_SHIFT;
> @@ -50,22 +50,14 @@ int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad)
>
> if (!(pad_ctrl & NO_PAD_CTRL) && pad_ctrl_ofs)
> __raw_writel(pad_ctrl, base + pad_ctrl_ofs);
> -
> - return 0;
> }
>
> -int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
> - unsigned count)
> +void imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
> + unsigned count)
> {
> iomux_v3_cfg_t const *p = pad_list;
> int i;
> - int ret;
>
> - for (i = 0; i < count; i++) {
> - ret = imx_iomux_v3_setup_pad(*p);
> - if (ret)
> - return ret;
> - p++;
> - }
> - return 0;
> + for (i = 0; i < count; i++)
> + imx_iomux_v3_setup_pad(*p++);
> }
> diff --git a/arch/arm/include/asm/imx-common/iomux-v3.h b/arch/arm/include/asm/imx-common/iomux-v3.h
> index c34bb76..70bf3cd 100644
> --- a/arch/arm/include/asm/imx-common/iomux-v3.h
> +++ b/arch/arm/include/asm/imx-common/iomux-v3.h
> @@ -97,8 +97,8 @@ typedef u64 iomux_v3_cfg_t;
>
> #define MUX_CONFIG_SION (0x1 << 4)
>
> -int imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
> -int imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
> +void imx_iomux_v3_setup_pad(iomux_v3_cfg_t pad);
> +void imx_iomux_v3_setup_multiple_pads(iomux_v3_cfg_t const *pad_list,
> unsigned count);
>
> #endif /* __MACH_IOMUX_V3_H__*/
>
Right, I will put it into -next branch.
Regards,
Stefano
--
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================
^ permalink raw reply [flat|nested] 4+ messages in thread
* [U-Boot] [PATCH] arm: imx: Change iomux functions to void type
2013-04-11 9:06 [U-Boot] [PATCH] arm: imx: Change iomux functions to void type Stefan Roese
2013-04-11 18:53 ` Marek Vasut
2013-04-13 20:53 ` Stefano Babic
@ 2013-04-16 11:04 ` Stefano Babic
2 siblings, 0 replies; 4+ messages in thread
From: Stefano Babic @ 2013-04-16 11:04 UTC (permalink / raw)
To: u-boot
On 11/04/2013 11:06, Stefan Roese wrote:
> They never return anything also than 0, so lets change the function
> to void instead.
>
> Signed-off-by: Stefan Roese <sr@denx.de>
> ---
Applied to u-boot-imx, -next branch, thanks.
Best regards,
Stefano Babic
--
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de
=====================================================================
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2013-04-16 11:04 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-11 9:06 [U-Boot] [PATCH] arm: imx: Change iomux functions to void type Stefan Roese
2013-04-11 18:53 ` Marek Vasut
2013-04-13 20:53 ` Stefano Babic
2013-04-16 11:04 ` Stefano Babic
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).