Skip to contentSkip to conversation

Atmel LCD driver GUARDTIME fix

PATCH New Mark Jackson 3 participants 5 messages Jun 16, 2009 – Jun 22, 2009

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

PATCH 1/1 Atmel LCD driver GUARDTIME fix

This patch correctly sets up the guard time parameter in the Atmel LCDC driver.

This works on the AVR32 platform, but needs to be tested under the AT91 platform which shares the same code base.

---
  drivers/video/atmel_lcdfb.c |    5 +++--
  1 files changed, 3 insertions(+), 2 deletions(-)
drivers/video/atmel_lcdfb.c +3 -2
index 3a51cc7..14f578e 100644
@@ -42,6 +42,7 @@ short console_row;
  /* configurable parameters */
  #define ATMEL_LCDC_CVAL_DEFAULT		0xc8
  #define ATMEL_LCDC_DMA_BURST_LEN	8
+#define ATMEL_LCDC_GUARD_TIME		2
 
  #if defined(CONFIG_AT91SAM9263) || defined(CONFIG_AT91CAP9)
  #define ATMEL_LCDC_FIFO_SIZE		2048
@@ -69,7 +70,7 @@ void lcd_ctrl_init(void *lcdbase)
 
  	/* Turn off the LCD controller and the DMA controller */
  	lcdc_writel(panel_info.mmio, ATMEL_LCDC_PWRCON,
-		    1 << ATMEL_LCDC_GUARDT_OFFSET);
+		    ATMEL_LCDC_GUARD_TIME << ATMEL_LCDC_GUARDT_OFFSET);
 
  	/* Wait for the LCDC core to become idle */
  	while (lcdc_readl(panel_info.mmio, ATMEL_LCDC_PWRCON) & ATMEL_LCDC_BUSY)
@@ -150,7 +151,7 @@ void lcd_ctrl_init(void *lcdbase)
 
  	lcdc_writel(panel_info.mmio, ATMEL_LCDC_DMACON, ATMEL_LCDC_DMAEN);
  	lcdc_writel(panel_info.mmio, ATMEL_LCDC_PWRCON,
-		    (1 << ATMEL_LCDC_GUARDT_OFFSET) | ATMEL_LCDC_PWR);
+		    (ATMEL_LCDC_GUARD_TIME << ATMEL_LCDC_GUARDT_OFFSET) | ATMEL_LCDC_PWR);
  }
 
  ulong calc_fbsize(void)
#1 lore raw

PATCH 1/1 Atmel LCD driver GUARDTIME fix

Quoted 8 lines · Mark Jackson

This patch correctly sets up the guard time parameter in the Atmel LCDC driver.

This works on the AVR32 platform, but needs to be tested under the AT91 platform which shares the same code base.

---

does not apply

Best Regards,
J.

#2 lore raw

PATCH 1/1 Atmel LCD driver GUARDTIME fix

Quoted 10 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 8 lines · Mark Jackson

This patch correctly sets up the guard time parameter in the Atmel LCDC driver.

This works on the AVR32 platform, but needs to be tested under the AT91 platform which shares the same code base.

---

does not apply

Sorry ... does that mean the patch fails in some way, or that this patch is not relevant ?

Mark

#3 lore raw

PATCH 1/1 Atmel LCD driver GUARDTIME fix

Quoted 1 line · Mark Jackson

Jean-Christophe PLAGNIOL-VILLARD wrote:

...

Quoted 4 lines
Quoted 1 line

does not apply

Sorry ... does that mean the patch fails in some way, or that this patch is not relevant ?

ag at wker:~/git/u-boot$ patch -p1 --dry-run < ~/devel/u-boot-video/\[U-Boot\]\ \[PATCH\]\ Atmel\ LCD\ driver\ GUARDTIME\ fix.eml patching file drivers/video/atmel_lcdfb.c
Hunk #1 FAILED at 42.
Hunk #2 FAILED at 70.
Hunk #3 FAILED@151.
3 out of 3 hunks FAILED -- saving rejects to file drivers/video/atmel_lcdfb.c.rej

please rebase on top of u-boot/master branch. TIA.

Best regards,
Anatolij

#4 lore raw

PATCH 1/1 Atmel LCD driver GUARDTIME fix

Quoted 7 lines · Anatolij Gustschin
Quoted 1 line · Mark Jackson

Jean-Christophe PLAGNIOL-VILLARD wrote:

...

Quoted 3 lines
Quoted 1 line

does not apply

Sorry ... does that mean the patch fails in some way, or that this patch is not relevant ?

Quoted 8 lines

ag at wker:~/git/u-boot$ patch -p1 --dry-run < ~/devel/u-boot-video/\[U-Boot\]\ \[PATCH\]\ Atmel\ LCD\ driver\ GUARDTIME\ fix.eml patching file drivers/video/atmel_lcdfb.c
Hunk #1 FAILED at 42.
Hunk #2 FAILED at 70.
Hunk #3 FAILED at 151.
3 out of 3 hunks FAILED -- saving rejects to file drivers/video/atmel_lcdfb.c.rej

please rebase on top of u-boot/master branch. TIA.

Hmmm ... this is strange. The patch *is* based on the latest gut master !!

I mailed the patch to both u-boot at lists.denx.de and u-boot at avr32linux.org mailing lists (the same email, I just added both ml address in the To: box)

Looking at mail that came in on the u-boot ML, I can see that an space at the start of most of the patch lines ... argh !!

The patch itself works fine ... it looks like one of the mail servers has mangled my patch.

I'll try it again ... and CC you all in.

Regards
Mark