linux-next: manual merge of the arm-soc tree with the arm tree

January 05th, 2012 - 08:10 pm ET by Stephen Rothwell | Report spam

Hi all,

Today's linux-next merge of the arm-soc tree got a conflict in
arch/arm/mach-imx/mm-imx5.c between commit 9bdd46257ab3 ("ARM: plat-mxc:
hook special idle handlers to arm_pm_idle") from the arm tree and commit
010dc8af8f28 ("ARM: mx5: use generic irq chip pm interface for pm
functions on") from the arm-soc tree.

I fixed it up (I think - see below) and can carry the fix as necessary.
Cheers,
Stephen Rothwell sfr@canb.auug.org.au

diff --cc arch/arm/mach-imx/mm-imx5.c
index 65139a6,bc17dfe..0000000
a/arch/arm/mach-imx/mm-imx5.c
+++ b/arch/arm/mach-imx/mm-imx5.c
@@@ -21,9 -22,27 +22,24 @@@
#include <mach/devices-common.h>
#include <mach/iomux-v3.h>

+ static struct clk *gpc_dvfs_clk;
+
static void imx5_idle(void)
{
- if (!need_resched()) {
- /* gpc clock is needed for SRPG */
- if (gpc_dvfs_clk == NULL) {
- gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
- if (IS_ERR(gpc_dvfs_clk))
- goto err0;
- }
- clk_enable(gpc_dvfs_clk);
- mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
- if (tzic_enable_wake())
- goto err1;
- cpu_do_idle();
-err1:
- clk_disable(gpc_dvfs_clk);
++ /* gpc clock is needed for SRPG */
++ if (gpc_dvfs_clk == NULL) {
++ gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
++ if (IS_ERR(gpc_dvfs_clk))
++ goto err0;
+ }
++ clk_enable(gpc_dvfs_clk);
+ mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
++ if (tzic_enable_wake())
++ goto err1;
++ cpu_do_idle();
++err1:
++ clk_disable(gpc_dvfs_clk);
+ err0:
- local_irq_enable();
}

/*



To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
email Follow the discussionReplies 4 repliesReplies Make a reply

Similar topics

Replies

#1 Shawn Guo
January 06th, 2012 - 11:40 pm ET | Report spam
Hi Stephen,

On Fri, Jan 06, 2012 at 12:03:45PM +1100, Stephen Rothwell wrote:
diff --cc arch/arm/mach-imx/mm-imx5.c
index 65139a6,bc17dfe..0000000
a/arch/arm/mach-imx/mm-imx5.c
+++ b/arch/arm/mach-imx/mm-imx5.c
@@@ -21,9 -22,27 +22,24 @@@
#include <mach/devices-common.h>
#include <mach/iomux-v3.h>

+ static struct clk *gpc_dvfs_clk;
+
static void imx5_idle(void)
{
- if (!need_resched()) {
- /* gpc clock is needed for SRPG */
- if (gpc_dvfs_clk == NULL) {
- gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
- if (IS_ERR(gpc_dvfs_clk))
- goto err0;
- }
- clk_enable(gpc_dvfs_clk);
- mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
- if (tzic_enable_wake())
- goto err1;
- cpu_do_idle();
-err1:
- clk_disable(gpc_dvfs_clk);
++ /* gpc clock is needed for SRPG */
++ if (gpc_dvfs_clk == NULL) {
++ gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
++ if (IS_ERR(gpc_dvfs_clk))
++ goto err0;
+ }
++ clk_enable(gpc_dvfs_clk);
+ mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
++ if (tzic_enable_wake())
++ goto err1;
++ cpu_do_idle();
++err1:
++ clk_disable(gpc_dvfs_clk);
+ err0:
- local_irq_enable();



This results in a compile error.

CC arch/arm/mach-imx/mm-imx5.o
arch/arm/mach-imx/mm-imx5.c: In function ‘imx5_idle’:
arch/arm/mach-imx/mm-imx5.c:42:1: error: label at end of compound statement

Regards,
Shawn

}

/*


To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Replies Reply to this message
#2 Shawn Guo
January 07th, 2012 - 12:40 am ET | Report spam
On Fri, Jan 06, 2012 at 12:03:45PM +1100, Stephen Rothwell wrote:
Hi all,

Today's linux-next merge of the arm-soc tree got a conflict in
arch/arm/mach-imx/mm-imx5.c between commit 9bdd46257ab3 ("ARM: plat-mxc:
hook special idle handlers to arm_pm_idle") from the arm tree and commit
010dc8af8f28 ("ARM: mx5: use generic irq chip pm interface for pm
functions on") from the arm-soc tree.

I fixed it up (I think - see below) and can carry the fix as necessary.



Hi Stephen,

When I was testing this fix on next-20120106, I spotted another compile
error from this file.

CC arch/arm/mach-imx/mm-imx5.o
arch/arm/mach-imx/mm-imx5.c:58:24: error: redefinition of ‘mx50_io_desc’
arch/arm/mach-imx/mm-imx5.c:48:24: note: previous definition of ‘mx50_io_desc’ was here
arch/arm/mach-imx/mm-imx5.c:48:24: warning: ‘mx50_io_desc’ defined but not used

The fix could just be removing the duplication.

Regards,
Shawn


8<-
@@ -53,16 +54,6 @@ static struct map_desc mx50_io_desc[] __initdata = {
};

/*
- * Define the MX50 memory map.
- */
-static struct map_desc mx50_io_desc[] __initdata = {
- imx_map_entry(MX50, TZIC, MT_DEVICE),
- imx_map_entry(MX50, SPBA0, MT_DEVICE),
- imx_map_entry(MX50, AIPS1, MT_DEVICE),
- imx_map_entry(MX50, AIPS2, MT_DEVICE),
-};
-
-/*
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Replies Reply to this message
#3 Stephen Rothwell
January 07th, 2012 - 01:50 am ET | Report spam

Hi Shawn,

On Sat, 7 Jan 2012 13:48:31 +0800 Shawn Guo wrote:

On Fri, Jan 06, 2012 at 12:03:45PM +1100, Stephen Rothwell wrote:
>
> Today's linux-next merge of the arm-soc tree got a conflict in
> arch/arm/mach-imx/mm-imx5.c between commit 9bdd46257ab3 ("ARM: plat-mxc:
> hook special idle handlers to arm_pm_idle") from the arm tree and commit
> 010dc8af8f28 ("ARM: mx5: use generic irq chip pm interface for pm
> functions on") from the arm-soc tree.
>
> I fixed it up (I think - see below) and can carry the fix as necessary.

When I was testing this fix on next-20120106, I spotted another compile
error from this file.

CC arch/arm/mach-imx/mm-imx5.o
arch/arm/mach-imx/mm-imx5.c:58:24: error: redefinition of ‘mx50_io_desc’
arch/arm/mach-imx/mm-imx5.c:48:24: note: previous definition of ‘mx50_io_desc’ was here
arch/arm/mach-imx/mm-imx5.c:48:24: warning: ‘mx50_io_desc’ defined but not used

The fix could just be removing the duplication.



Yeah, sometimes (I think it has happened to me about 3 times over the
last 2.5 years) both sides of a merge will insert the same function and
git does not notice (they are to far apart or the context is not unique)
and inserts them both as part of the automatic merge.

Cheers,
Stephen Rothwell
http://www.canb.auug.org.au/~sfr/



To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Replies Reply to this message
#4 Stephen Rothwell
January 07th, 2012 - 02:00 am ET | Report spam

Hi Shawn,

On Sat, 7 Jan 2012 12:44:42 +0800 Shawn Guo wrote:

On Fri, Jan 06, 2012 at 12:03:45PM +1100, Stephen Rothwell wrote:
> diff --cc arch/arm/mach-imx/mm-imx5.c
> index 65139a6,bc17dfe..0000000
> a/arch/arm/mach-imx/mm-imx5.c
> +++ b/arch/arm/mach-imx/mm-imx5.c
> @@@ -21,9 -22,27 +22,24 @@@
> #include <mach/devices-common.h>
> #include <mach/iomux-v3.h>
>
> + static struct clk *gpc_dvfs_clk;
> +
> static void imx5_idle(void)
> {
> - if (!need_resched()) {
> - /* gpc clock is needed for SRPG */
> - if (gpc_dvfs_clk == NULL) {
> - gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
> - if (IS_ERR(gpc_dvfs_clk))
> - goto err0;
> - }
> - clk_enable(gpc_dvfs_clk);
> - mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
> - if (tzic_enable_wake())
> - goto err1;
> - cpu_do_idle();
> -err1:
> - clk_disable(gpc_dvfs_clk);
> ++ /* gpc clock is needed for SRPG */
> ++ if (gpc_dvfs_clk == NULL) {
> ++ gpc_dvfs_clk = clk_get(NULL, "gpc_dvfs");
> ++ if (IS_ERR(gpc_dvfs_clk))
> ++ goto err0;
> + }
> ++ clk_enable(gpc_dvfs_clk);
> + mx5_cpu_lp_set(WAIT_UNCLOCKED_POWER_OFF);
> ++ if (tzic_enable_wake())
> ++ goto err1;
> ++ cpu_do_idle();
> ++err1:
> ++ clk_disable(gpc_dvfs_clk);
> + err0:
> - local_irq_enable();

This results in a compile error.

CC arch/arm/mach-imx/mm-imx5.o
arch/arm/mach-imx/mm-imx5.c: In function ‘imx5_idle’:
arch/arm/mach-imx/mm-imx5.c:42:1: error: label at end of compound statement



Ooops. Sorry about that. Just remove the label and turn the "goto err0"
into "return".

Cheers,
Stephen Rothwell
http://www.canb.auug.org.au/~sfr/



To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
email Follow the discussion Replies Reply to this message
Help Create a new topicReplies Make a reply
Search Make your own search