PPC440 Power Management Registers
A message that is not in the archive (sent off-list or not yet received): [email protected]
A message that is not in the archive (sent off-list or not yet received): [email protected]
PATCH 1/1 PPC440 Power Management Registers
Hello Stefan,
I had a look at all PPC440 processor manuals from AMCC and see that my patch applies to all of them. In other words the #else portion is never used. Therefore I am submitting a patch that cleans up this code quite nicely.
Another observation that I made is that the PPC440EPx and PPC440GPx require more than 32 bits to control the power management functions. Therefore I defined a second set of registers cpc1_er, cpc1_fr, cpc1_sr for these processors. These can be used as placeholders for future development.
Let me know if this sounds good to you.
Regards,
Eugene
-----Original Message-----
From: Stefan Roese [mailto:sr at denx.de]
Sent: April 4, 2008 10:05 AM
To: Eugene O'Brien
Subject: Re: Patch for PPC440EP
Hi Eugene,
Quoted 4 lines · Eugene O'Brien
Here is patch for the PPC440EP. The DCR addresses of the power management registers were not correctly defined. This patch corrects that. You can check the PPC440EP UM p301 to confirm. I also used the BDI2000 to double check.
Thanks.
I suggest the following change:
Instead of:
-#if defined(CONFIG_440GX) || \ +#if defined(CONFIG_440GX) || defined(CONFIG_440EP) || \
please use:
+ defined(CONFIG_440EP) || defined(CONFIG_440GR) || \
This way 440GP will be added too. And if we're at it, please check if 440EPx
and 440GRx also need this change. If yes, please include them too.
And please post the patch to the mailing list for review. I can't accept
patches without public review nowadays, since we changed the development
process.
Thanks for your input.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: pow_mgt_patch_2.txt
Url: http://lists.denx.de/pipermail/u-boot/attachments/20080407/cadf1d29/attachment.txt
PATCH 1/1 PPC440 Power Management Registers
Hi Eugene,
Quoted 4 lines · Eugene O'Brien
I had a look at all PPC440 processor manuals from AMCC and see that my patch applies to all of them. In other words the #else portion is never used. Therefore I am submitting a patch that cleans up this code quite nicely.
Great, thanks.
Quoted 5 lines
Another observation that I made is that the PPC440EPx and PPC440GPx require more than 32 bits to control the power management functions. Therefore I defined a second set of registers
cpc1_er,cpc1_fr,cpc1_srfor these processors. These can be used as placeholders for future development.
I would prefer to add those when really needed. Let's try to include only defines that are used. This way the headers don't get "polluted" even more.
Quoted 1 line
Let me know if this sounds good to you.
Could you please resend you patch without those new registers? And please send it inline and add a proper Signed-off-by line as described here:
http://www.denx.de/wiki/UBoot/Patches
I suggest to use git-send-email for sending patches.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 PPC440 Power Management Registers
Hello Stefan,
Here is an updated patch correcting only the pre-existing power management register definitions. (I might add that these definitions are not currently used in the U-Boot source tree either.)
CHANGELOG:
ppc440: Fix power mgt definitions for PPC440
Corrected DCR addresses of PPC440 power management registers. All AMCC PPC440 processors conform to the same DCR address usage for these registers.
include/ppc440.h +1 -3
@@ -1726,17 +1726,10 @@#else #define CNTRL_DCR_BASE 0x0b0#endif -#if defined(CONFIG_440GX ) || \ - defined(CONFIG_440SP ) || defined(CONFIG_440SPE ) || \ - defined(CONFIG_460EX ) || defined(CONFIG_460GT ) +#define cpc0_er (CNTRL_DCR_BASE+0x00)/* CPM enable
register */
#define cpc0_fr (CNTRL_DCR_BASE+0x01) /* CPM force
register */
#define cpc0_sr (CNTRL_DCR_BASE+0x02) /* CPM status
register */
-#else
-#define cpc0_sr (CNTRL_DCR_BASE+0x00) /* CPM status
register */
-#define cpc0_er (CNTRL_DCR_BASE+0x01) /* CPM enable
register */
-#define cpc0_fr (CNTRL_DCR_BASE+0x02) /* CPM force
register */
-#endif
#define cpc0_sys0 (CNTRL_DCR_BASE+0x30) /* System configuration
reg 0 */
#define cpc0_sys1 (CNTRL_DCR_BASE+0x31) /* System configuration
reg 1 */
Regards,
Eugene
-----Original Message-----
From: Stefan Roese [mailto:sr at denx.de]
Sent: April 8, 2008 7:30 AM
To: u-boot-users at lists.sourceforge.net
Cc: Eugene O'Brien
Subject: Re: [U-Boot-Users] [PATCH] PPC440 Power Management Registers
Hi Eugene,
Quoted 2 lines · Eugene O'Brien
I had a look at all PPC440 processor manuals from AMCC and see that my patch applies to all of them. In other words the #else portion is
never
Quoted 2 lines
used. Therefore I am submitting a patch that cleans up this code quite nicely.
Great, thanks.
Quoted 3 lines
Another observation that I made is that the PPC440EPx and PPC440GPx require more than 32 bits to control the power management functions. Therefore I defined a second set of registers
cpc1_er,cpc1_fr,
cpc1_sr
Quoted 2 lines
for these processors. These can be used as placeholders for future development.
I would prefer to add those when really needed. Let's try to include only
defines that are used. This way the headers don't get "polluted" even more.
Quoted 1 line
Let me know if this sounds good to you.
Could you please resend you patch without those new registers? And please send
it inline and add a proper Signed-off-by line as described here:
http://www.denx.de/wiki/UBoot/Patches
I suggest to use git-send-email for sending patches.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 PPC440 Power Management Registers
Hi Eugene,
Quoted 6 lines · Eugene O'Brien
Here is an updated patch correcting only the pre-existing power management register definitions. (I might add that these definitions are not currently used in the U-Boot source tree either.)
CHANGELOG:
Quoted 7 lines
ppc440: Fix power mgt definitions for PPC440
Corrected DCR addresses of PPC440 power management registers. All AMCC PPC440 processors conform to the same DCR address usage for these registers.
Signed-off-by Eugene O'Brien <[email protected]>
Unfortunately now your patch is line wrapped. And even if it wasn't line wrapped, it couldn't be applied using git-am (which makes life so much easier for me) because of the lines above and below the real patch.
I there a chance that you can create this patch by using git-format-patch? I know it is a lot of work for such a small patch, but once you've got all this git patch stuff working, you can send patches much easier in the future.
Thanks.
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 PPC440 Power Management Registers
Quoted 4 lines · In message <[email protected]> you wrote:
Unfortunately now your patch is line wrapped. And even if it wasn't line wrapped, it couldn't be applied using git-am (which makes life so much easier for me) because of the lines above and below the real patch.
This is not a big problem; "git-am -i" will allow you to edit the commit message if needed.
Best regards,
Wolfgang Denk
Signature · 6 lines
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-10 Fax: (+49)-8142-66989-80 Email: wd at denx.de HANDLE WITH EXTREME CARE: This Product Contains Minute Electrically Charged Particles Moving at Velocities in Excess of Five Hundred Million Miles Per Hour.
PATCH 1/1 PPC440 Power Management Registers
Quoted 7 lines · Wolfgang Denk
Quoted 3 lines · In message <[email protected]> you wrote:
Unfortunately now your patch is line wrapped. And even if it wasn't line wrapped, it couldn't be applied using git-am (which makes life so much easier for me) because of the lines above and below the real patch.
This is not a big problem; "git-am -i" will allow you to edit the commit message if needed.
Right. But it would be better if it could be avoided. Less work for us custodians. ;)
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
PATCH 1/1 PPC440 Power Management Registers
Hello Stefan,
Well I am still trying to master GIT and the patch reporting process. On the last try I used the git diff command to create the patch. This time I created a separate U-Boot tree and committed this one change into it and used git-format-patch to generate the attached file.
Hopefully this approach meets your needs.
Regards,
Eugene
-----Original Message-----
From: Stefan Roese [mailto:sr at denx.de]
Sent: April 11, 2008 12:31 AM
To: u-boot-users at lists.sourceforge.net
Cc: Wolfgang Denk; Eugene O'Brien
Subject: Re: [U-Boot-Users] [PATCH] PPC440 Power Management Registers
Quoted 2 lines · Wolfgang Denk
Quoted 1 line · In message <[email protected]> you wrote:
Unfortunately now your patch is line wrapped. And even if it wasn't
line
Quoted 1 line
Quoted 1 line
wrapped, it couldn't be applied using git-am (which makes life so
much
Quoted 4 lines
Quoted 1 line
easier for me) because of the lines above and below the real patch.
This is not a big problem; "git-am -i" will allow you to edit the commit message if needed.
Right. But it would be better if it could be avoided. Less work for us custodians. ;)
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-ppc4xx-Fix-power-mgt-definitions-for-PPC440.patch
Type: application/octet-stream
Size: 1372 bytes
Desc: 0001-ppc4xx-Fix-power-mgt-definitions-for-PPC440.patch
Url : http://lists.denx.de/pipermail/u-boot/attachments/20080411/6a27df0a/attachment.obj
PATCH 1/1 PPC440 Power Management Registers
Hi Eugene,
Quoted 6 lines · Eugene O'Brien
Well I am still trying to master GIT and the patch reporting process. On the last try I used the git diff command to create the patch. This time I created a separate U-Boot tree and committed this one change into it and used git-format-patch to generate the attached file.
Hopefully this approach meets your needs.
Nearly perfect. Thanks a lot. To make it perfect you should send the generated patch inlined, best directly using the git-send-email command.
No need to send again, I have already committed this version locally and will push later. Thanks again.
BTW: You don't have to create a different tree (I suspect you cloned the repo again). All you need is a new branch. But working with branches might be another hurdle for you (as it has been for a a while ago :)).
Best regards,
Stefan
=====================================================================
DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel
HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany
Phone: +49-8142-66989-0 Fax: +49-8142-66989-80 Email: office at denx.de
=====================================================================