Skip to contentSkip to conversation

ARM: Don't grab memory for LCD if FB address is defined

PATCH Superseded Minkyu Kang 5 participants 12 messages Mar 8, 2011 – Apr 25, 2011

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/3 ARM: Don't grab memory for LCD if FB address is defined

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
---
 arch/arm/lib/board.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
arch/arm/lib/board.c +4 -0
index c620d2c..5a4d2bd 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
 #endif /* CONFIG_VFD */
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
Signature · 1 line
1.7.1
#1 lore raw

PATCH 1/3 ARM: Don't grab memory for LCD if FB address is defined

Dear Minkyu Kang,

Quoted 13 lines · In message <[email protected]> you wrote:

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
---
 arch/arm/lib/board.c |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)
arch/arm/lib/board.c +0 -0
index c620d2c..5a4d2bd 100644

arch/arm/lib/board.c void board_init_f (ulong bootflag) · line 359

Quoted 4 lines
arch/arm/lib/board.c +1 -0
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
 #endif /* CONFIG_VFD */
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR

If you add a new CONFIG_ option, then you must document it (at least in the README).

Also, you must not split this into several patches, one for each architecture. All these changes must be done in a single commit.

Best regards,

Wolfgang Denk

Signature · 5 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
A good marriage would be between a blind wife and deaf husband.
                                               -- Michel de Montaigne
#2 lore raw

PATCH 1/3 ARM: Don't grab memory for LCD if FB address is defined

Dear Wolfgang,

Quoted 25 lines · Wolfgang Denk

Dear Minkyu Kang,

Quoted 15 lines · In message <[email protected]> you wrote:

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>

---
?arch/arm/lib/board.c | ? ?4 ++++
?1 files changed, 4 insertions(+), 0 deletions(-)

arch/arm/lib/board.c +0 -0
index c620d2c..5a4d2bd 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)

?#endif /* CONFIG_VFD */

Quoted 2 lines

?#ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR

If you add a new CONFIG_ option, then you must document it (at least in the README).

Quoted 3 lines

Also, you must not split this into several patches, one for each architecture. ?All these changes must be done in a single commit.

OK, I will.

Thanks
Minkyu Kang

Signature · 2 lines
from. prom.
www.promsoft.net
#3 lore raw

PATCH v2 1/1 Don't grab memory for LCD if FB address is defined

f FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Stefan Roese <[email protected]>
Cc Kim Phillips <[email protected]>
Cc Andy Fleming <[email protected]>
Cc Kumar Gala <[email protected]>

---
v2
add document

 arch/arm/lib/board.c     |    4 ++++
 arch/m68k/lib/board.c    |    4 ++++
 arch/powerpc/lib/board.c |    4 ++++
 doc/README.fb_addr       |   17 +++++++++++++++++
 4 files changed, 29 insertions(+), 0 deletions(-)
 create mode 100644 doc/README.fb_addr
arch/arm/lib/board.c +4 -0
index c620d2c..5a4d2bd 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
 #endif /* CONFIG_VFD */
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/m68k/lib/board.c +4 -0
index 7867ba5..a6cd9b8 100644
@@ -277,9 +277,13 @@ board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/powerpc/lib/board.c +4 -0
index b88cf6b..09c20e9 100644
@@ -453,9 +453,13 @@ void board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 #if defined(CONFIG_VIDEO) && defined(CONFIG_8xx)
doc/README.fb_addr new file +17 -0
new file mode 100644
index 0000000..ea8bca6
@@ -0,0 +1,17 @@
+Define CONFIG_FB_ADDR if you want to use specific address for frame buffer.
+Then system will reserve the frame buffer address to defined address instead of
+lcd_setmem (this function grab the memory for frame buffer by panel's size).
+
+Please see below code (in board_init_f function from arch/arm/lib/board.c)
+
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
+ 	/* reserve memory for LCD display (always full pages) */
+ 	addr = lcd_setmem (addr);
+ 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
+
+If you want this config option then please define it at your board config file
+
+#define CONFIG_FB_ADDR		0x00000000
Signature · 1 line
1.7.1
#4 lore raw

PATCH v2 1/1 Don't grab memory for LCD if FB address is defined

Hi Minkyu Kang,

Le 15/03/2011 09:35, Minkyu Kang a ?crit :

Quoted 87 lines

f FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud<[email protected]>
Cc Wolfgang Denk<[email protected]>
Cc Stefan Roese<[email protected]>
Cc Kim Phillips<[email protected]>
Cc Andy Fleming<[email protected]>
Cc Kumar Gala<[email protected]>

---
v2
add document

  arch/arm/lib/board.c     |    4 ++++
  arch/m68k/lib/board.c    |    4 ++++
  arch/powerpc/lib/board.c |    4 ++++
  doc/README.fb_addr       |   17 +++++++++++++++++
  4 files changed, 29 insertions(+), 0 deletions(-)

create mode 100644 doc/README.fb_addr

arch/arm/lib/board.c +4 -0
index c620d2c..5a4d2bd 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
  #endif /* CONFIG_VFD */
 
  #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
  	/* reserve memory for LCD display (always full pages) */
  	addr = lcd_setmem (addr);
  	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
  #endif /* CONFIG_LCD */
 
  	/*
arch/m68k/lib/board.c +4 -0
index 7867ba5..a6cd9b8 100644
@@ -277,9 +277,13 @@ board_init_f (ulong bootflag)
  	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
  #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
  	/* reserve memory for LCD display (always full pages) */
  	addr = lcd_setmem (addr);
  	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
  #endif /* CONFIG_LCD */
 
  	/*
arch/powerpc/lib/board.c +4 -0
index b88cf6b..09c20e9 100644
@@ -453,9 +453,13 @@ void board_init_f (ulong bootflag)
  	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
  #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
  	/* reserve memory for LCD display (always full pages) */
  	addr = lcd_setmem (addr);
  	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
  #endif /* CONFIG_LCD */
 
  #if defined(CONFIG_VIDEO)&&  defined(CONFIG_8xx)
doc/README.fb_addr new file +7 -0
new file mode 100644
index 0000000..ea8bca6
@@ -0,0 +1,17 @@
+Define CONFIG_FB_ADDR if you want to use specific address for frame buffer.
+Then system will reserve the frame buffer address to defined address instead of
+lcd_setmem (this function grab the memory for frame buffer by panel's size).
+
+Please see below code (in board_init_f function from arch/arm/lib/board.c)
+
+#ifdef CONFIG_FB_ADDR

doc/README.fb_addr line 17

Quoted 10 lines
doc/README.fb_addr new file +10 -0
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
+ 	/* reserve memory for LCD display (always full pages) */
+ 	addr = lcd_setmem (addr);
+ 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
+
+If you want this config option then please define it at your board config file
+
+#define CONFIG_FB_ADDR		0x00000000

Patch does not apply cleanly through git am due to whitespace errors (space before tabs).

Amicalement,

Signature · 1 line
Albert.
#5 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Stefan Roese <[email protected]>
Cc Kim Phillips <[email protected]>
Cc Andy Fleming <[email protected]>
Cc Kumar Gala <[email protected]>

---
v3
fix whitespace errors
v2
add document

 arch/arm/lib/board.c     |    4 ++++
 arch/m68k/lib/board.c    |    4 ++++
 arch/powerpc/lib/board.c |    4 ++++
 doc/README.fb_addr       |   17 +++++++++++++++++
 4 files changed, 29 insertions(+), 0 deletions(-)
 create mode 100644 doc/README.fb_addr
arch/arm/lib/board.c +4 -0
index c620d2c..5a4d2bd 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
 #endif /* CONFIG_VFD */
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/m68k/lib/board.c +4 -0
index 7867ba5..a6cd9b8 100644
@@ -277,9 +277,13 @@ board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/powerpc/lib/board.c +4 -0
index b88cf6b..09c20e9 100644
@@ -453,9 +453,13 @@ void board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 #if defined(CONFIG_VIDEO) && defined(CONFIG_8xx)
doc/README.fb_addr new file +17 -0
new file mode 100644
index 0000000..ea8bca6
@@ -0,0 +1,17 @@
+Define CONFIG_FB_ADDR if you want to use specific address for frame buffer.
+Then system will reserve the frame buffer address to defined address instead of
+lcd_setmem (this function grab the memory for frame buffer by panel's size).
+
+Please see below code (in board_init_f function from arch/arm/lib/board.c)
+
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
+	/* reserve memory for LCD display (always full pages) */
+	addr = lcd_setmem (addr);
+	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
+
+If you want this config option then please define it at your board config file
+
+#define CONFIG_FB_ADDR		0x00000000
Signature · 1 line
1.7.1
#6 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

Le 25/03/2011 01:50, Minkyu Kang a ?crit :

Quoted 10 lines

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud<[email protected]>
Cc Wolfgang Denk<[email protected]>
Cc Stefan Roese<[email protected]>
Cc Kim Phillips<[email protected]>
Cc Andy Fleming<[email protected]>
Cc Kumar Gala<[email protected]>

---

Applied to u-boot-arm/next, thanks.

Amicalement,

Signature · 1 line
Albert.
#7 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

Dear Albert,

Quoted 12 lines · In message <[email protected]> you wrote:

Le 25/03/2011 01:50, Minkyu Kang a ?crit :

Quoted 10 lines

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud<[email protected]>
Cc Wolfgang Denk<[email protected]>
Cc Stefan Roese<[email protected]>
Cc Kim Phillips<[email protected]>
Cc Andy Fleming<[email protected]>
Cc Kumar Gala<[email protected]>

---

Quoted 1 line

Applied to u-boot-arm/next, thanks.

Oops. Sorry, but I just added a late review comment.

Best regards,

Wolfgang Denk

Signature · 5 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
"Nature is very un-American.  Nature never hurries."
- William George Jordan
#8 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

In reply to Minkyu Kang

Dear Minkyu Kang,

Quoted 9 lines · In message <[email protected]> you wrote:

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Stefan Roese <[email protected]>
Cc Kim Phillips <[email protected]>
Cc Andy Fleming <[email protected]>
Cc Kumar Gala <[email protected]>

...

Quoted 10 lines
doc/README.fb_addr new file +7 -0
@@ -0,0 +1,17 @@
+Define CONFIG_FB_ADDR if you want to use specific address for frame buffer.
+Then system will reserve the frame buffer address to defined address instead of
+lcd_setmem (this function grab the memory for frame buffer by panel's size).
+
+Please see below code (in board_init_f function from arch/arm/lib/board.c)
+
+#ifdef CONFIG_FB_ADDR

doc/README.fb_addr line 17

Quoted 10 lines
doc/README.fb_addr new file +10 -0
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
+	/* reserve memory for LCD display (always full pages) */
+	addr = lcd_setmem (addr);
+	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
+
+If you want this config option then please define it at your board config file
+
+#define CONFIG_FB_ADDR		0x00000000

Sorry for the late review, but it makes littel sense to add individual README.* files for each and every CONFIG option. Please add the documentation (with a little less verbocity) to the top level README instead.

Best regards,

Wolfgang Denk

Signature · 5 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
When it is incorrect, it is, at least *authoritatively* incorrect.
                                    - Hitchiker's Guide To The Galaxy
#9 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

Le 25/04/2011 01:27, Wolfgang Denk a ?crit :

Quoted 30 lines

Dear Minkyu Kang,

Quoted 9 lines · In message<[email protected]> you wrote:

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud<[email protected]>
Cc Wolfgang Denk<[email protected]>
Cc Stefan Roese<[email protected]>
Cc Kim Phillips<[email protected]>
Cc Andy Fleming<[email protected]>
Cc Kumar Gala<[email protected]>

...

Quoted 17 lines
doc/README.fb_addr new file +14 -0
@@ -0,0 +1,17 @@
+Define CONFIG_FB_ADDR if you want to use specific address for frame buffer.
+Then system will reserve the frame buffer address to defined address instead of
+lcd_setmem (this function grab the memory for frame buffer by panel's size).
+
+Please see below code (in board_init_f function from arch/arm/lib/board.c)
+
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
+	/* reserve memory for LCD display (always full pages) */
+	addr = lcd_setmem (addr);
+	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
+
Quoted 8 lines

doc/README.fb_addr line 17

Quoted 3 lines
doc/README.fb_addr new file +3 -0
+If you want this config option then please define it at your board config file
+
+#define CONFIG_FB_ADDR		0x00000000

Sorry for the late review, but it makes littel sense to add individual README.* files for each and every CONFIG option. Please add the documentation (with a little less verbocity) to the top level README instead.

Minkyu: can you provide an quick-updated patch with the doc in the top level README? I'll rebase and replace accordingly.

Quoted 3 lines

Best regards,

Wolfgang Denk

Amicalement,

Signature · 1 line
Albert.
#10 lore raw

PATCH v3 1/1 Don't grab memory for LCD if FB address is defined

Dear Albert ARIBAUD,

Quoted 8 lines · Albert ARIBAUD
Quoted 4 lines

Sorry for the late review, but it makes littel sense to add individual README.* files for each and every CONFIG option. ?Please add the documentation (with a little less verbocity) to the top level README instead.

Minkyu: can you provide an quick-updated patch with the doc in the top level README? I'll rebase and replace accordingly.

OK. will send v4 patch.

Thanks.
Minkyu Kang

Signature · 2 lines
from. prom.
www.promsoft.net
#11 lore raw

PATCH v4 1/1 Don't grab memory for LCD if FB address is defined

If FB address is defined specific address then don't grab memory for LCD

Cc Albert Aribaud <[email protected]>
Cc Wolfgang Denk <[email protected]>
Cc Stefan Roese <[email protected]>
Cc Kim Phillips <[email protected]>
Cc Andy Fleming <[email protected]>
Cc Kumar Gala <[email protected]>

---
v4
move the document
v3
fix whitespace errors
v2
add document

 README                   |   14 ++++++++++++++
 arch/arm/lib/board.c     |    4 ++++
 arch/m68k/lib/board.c    |    4 ++++
 arch/powerpc/lib/board.c |    4 ++++
 4 files changed, 26 insertions(+), 0 deletions(-)
README +14 -0
index beb1cbb..c5533b4 100644
@@ -2009,6 +2009,20 @@ The following options need to be configured:
 		thus overwriting the architecutre dependent default
 		settings.
 
+- Frame Buffer Address:
+	CONFIG_FB_ADDR
+
+	Define CONFIG_FB_ADDR if you want to use specific address for
+	frame buffer.
+	Then system will reserve the frame buffer address to defined address
+	instead of lcd_setmem (this function grab the memory for frame buffer
+	by panel's size).
+
+	Please see board_init_f function.
+
+	If you want this config option then,
+	please define it at your board config file
+
 Legacy uImage format:
 
   Arg	Where			When
arch/arm/lib/board.c +4 -0
index dc46e21..db13ad1 100644
@@ -356,9 +356,13 @@ void board_init_f (ulong bootflag)
 #endif /* CONFIG_VFD */
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/m68k/lib/board.c +4 -0
index f824b34..6a892db 100644
@@ -277,9 +277,13 @@ board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 	/*
arch/powerpc/lib/board.c +4 -0
index 83fb074..aaa5add 100644
@@ -459,9 +459,13 @@ void board_init_f (ulong bootflag)
 	debug ("Top of RAM usable for U-Boot at: %08lx\n", addr);
 
 #ifdef CONFIG_LCD
+#ifdef CONFIG_FB_ADDR
+	gd->fb_base = CONFIG_FB_ADDR;
+#else
 	/* reserve memory for LCD display (always full pages) */
 	addr = lcd_setmem (addr);
 	gd->fb_base = addr;
+#endif /* CONFIG_FB_ADDR */
 #endif /* CONFIG_LCD */
 
 #if defined(CONFIG_VIDEO) && defined(CONFIG_8xx)
Signature · 1 line
1.7.1