Send commitlog mailing list submissions to
        [email protected]

To subscribe or unsubscribe via the World Wide Web, visit
        http://lists.openmoko.org/mailman/listinfo/commitlog
or, via email, send a message with subject or body 'help' to
        [EMAIL PROTECTED]

You can reach the person managing the list at
        [EMAIL PROTECTED]

When replying, please edit your Subject line so it is more specific
than "Re: Contents of commitlog digest..."
Today's Topics:

   1. r3785 - trunk/src/host/xoo ([EMAIL PROTECTED])
   2. r3786 - trunk/src/target/u-boot/patches ([EMAIL PROTECTED])
   3. r3787 - trunk/src/target/u-boot/patches ([EMAIL PROTECTED])
   4. r3788 - trunk/src/target/kernel/patches ([EMAIL PROTECTED])
   5. r3789 - in trunk/src/target: kernel/scripts u-boot/scripts
      ([EMAIL PROTECTED])
   6. r3790 - trunk/src/target/kernel/patches ([EMAIL PROTECTED])
--- Begin Message ---
Author: mickey
Date: 2008-01-08 14:37:47 +0100 (Tue, 08 Jan 2008)
New Revision: 3785

Added:
   trunk/src/host/xoo/om-launch
Log:
xoo: add om-launch script


Added: trunk/src/host/xoo/om-launch
===================================================================
--- trunk/src/host/xoo/om-launch        2008-01-08 07:03:12 UTC (rev 3784)
+++ trunk/src/host/xoo/om-launch        2008-01-08 13:37:47 UTC (rev 3785)
@@ -0,0 +1,44 @@
+#!/bin/sh
+# Authored by Mickey.
+# (C) 2007 OpenMoko Inc.
+# MIT License
+
+THEDISPLAY=:1
+SERVER=Xephyr
+SHOWCURSOR="yes"
+OMTOPDIR=/local/pkg/openmoko
+OMDIR=$OMTOPDIR/src/target/OM-2007.2
+OMDATADIR=/usr/local/share
+THEMEDIR=$OMDIR/artwork/themes/openmoko-standard-2/gtk-2.0
+NEODATADIR=$OMDIR/daemons/neod/data
+
+xoo -xo '-dpi 285 -ac' -xd :1 -xn `which $SERVER` -t 'OpenMoko running on 
Neo1973' \
+         -d $OMTOPDIR/src/host/xoo/neo1973.xml &
+
+sleep 2 # give Xoo a chance to come up
+
+# set gconf variables
+gconftool-2 --type string --set /desktop/poky/interface/theme                  
   openmoko-standard-2
+gconftool-2 --type string --set /desktop/poky/interface/icon_theme             
   openmoko-standard
+gconftool-2 --type string --set /desktop/poky/interface/font_name              
   "Sans 5"
+gconftool-2 --type string --set /desktop/poky/interface/wallpaper              
   $OMDATADIR/wallpaper.png
+gconftool-2 --type bool   --set /desktop/poky/interface/digital_clock          
   1
+gconftool-2 --type int    --set /desktop/poky/peripherals/mouse/drag_threshold 
   8
+gconftool-2 --type int    --set /desktop/openmoko/neod/power_management        
   2
+
+# set env variables
+export DISPLAY=$THEDISPLAY
+export GTK_RC2_FILES=$THEMEDIR/gtkrc
+export PATH=/usr/local/bin:$PATH
+export LD_LIBRARY_PATH=/usr/local/lib
+
+# launch X clients, this is from /etc/matchbox/session
+
+openmoko-today &
+
+matchbox-window-manager -use_titlebar yes -use_desktop_mode decorated -theme 
openmoko-standard-2 -use_cursor $SHOWCURSOR $@ &
+
+matchbox-panel --start-applets systray,startup \
+  --end-applets 
openmoko-panel-battery,openmoko-panel-gsm,openmoko-panel-gps,openmoko-panel-usb,openmoko-panel-bt,keyboard
 --titlebar &
+
+exec neod


Property changes on: trunk/src/host/xoo/om-launch
___________________________________________________________________
Name: svn:executable
   + *




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2008-01-08 14:52:57 +0100 (Tue, 08 Jan 2008)
New Revision: 3786

Modified:
   trunk/src/target/u-boot/patches/uboot-gta02.patch
Log:
uboot-gta02.patch:
- board/neo1973/gta02/gta02.c (board_init): increase clock speed on GTA02 from
  FCLK = 211 MHz, HCLK = 70 MHz, PCLK = 35 MHz
  to
  FCLK = 400 MHz, HCLK = 100 MHz, PCLK = 50 MHz



Modified: trunk/src/target/u-boot/patches/uboot-gta02.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-gta02.patch   2008-01-08 13:37:47 UTC 
(rev 3785)
+++ trunk/src/target/u-boot/patches/uboot-gta02.patch   2008-01-08 13:52:57 UTC 
(rev 3786)
@@ -4,7 +4,7 @@
 ===================================================================
 --- u-boot.orig/Makefile
 +++ u-boot/Makefile
-@@ -2253,6 +2253,13 @@
+@@ -2276,6 +2276,13 @@
  sbc2410x_config: unconfig
        @$(MKCONFIG) $(@:_config=) arm arm920t sbc2410x NULL s3c24x0
  
@@ -92,7 +92,7 @@
 ===================================================================
 --- /dev/null
 +++ u-boot/board/neo1973/gta02/gta02.c
-@@ -0,0 +1,455 @@
+@@ -0,0 +1,458 @@
 +/*
 + * (C) 2006-2007 by OpenMoko, Inc.
 + * Author: Harald Welte <[EMAIL PROTECTED]>
@@ -150,8 +150,8 @@
 +#define U_M_SDIV      0x2
 +#else
 +/* configure GTA02v2 to low speed until we've increased the voltage */
-+#define M_MDIV 80
-+#define M_PDIV 8
++#define M_MDIV 42
++#define M_PDIV 1
 +#define M_SDIV 0
 +#define U_M_MDIV 88
 +#define U_M_PDIV 4
@@ -195,6 +195,9 @@
 +      /* configure UPLL */
 +      clk_power->UPLLCON = ((U_M_MDIV << 12) + (U_M_PDIV << 4) + U_M_SDIV);
 +
++      /* clock divide */
++      clk_power->CLKDIVN = 0x05; /* 1:4:8 */
++
 +      /* some delay between MPLL and UPLL */
 +      delay (8000);
 +




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2008-01-08 14:57:10 +0100 (Tue, 08 Jan 2008)
New Revision: 3787

Modified:
   trunk/src/target/u-boot/patches/uboot-gta02.patch
Log:
uboot-gta02.patch:
- board/neo1973/gta02/gta02.c: remove obsolete comment about needing a voltage
  increase



Modified: trunk/src/target/u-boot/patches/uboot-gta02.patch
===================================================================
--- trunk/src/target/u-boot/patches/uboot-gta02.patch   2008-01-08 13:52:57 UTC 
(rev 3786)
+++ trunk/src/target/u-boot/patches/uboot-gta02.patch   2008-01-08 13:57:10 UTC 
(rev 3787)
@@ -92,7 +92,7 @@
 ===================================================================
 --- /dev/null
 +++ u-boot/board/neo1973/gta02/gta02.c
-@@ -0,0 +1,458 @@
+@@ -0,0 +1,457 @@
 +/*
 + * (C) 2006-2007 by OpenMoko, Inc.
 + * Author: Harald Welte <[EMAIL PROTECTED]>
@@ -149,7 +149,6 @@
 +#define U_M_PDIV      0x2
 +#define U_M_SDIV      0x2
 +#else
-+/* configure GTA02v2 to low speed until we've increased the voltage */
 +#define M_MDIV 42
 +#define M_PDIV 1
 +#define M_SDIV 0




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2008-01-08 16:53:30 +0100 (Tue, 08 Jan 2008)
New Revision: 3788

Modified:
   trunk/src/target/kernel/patches/fbset-gta02-core.patch
   trunk/src/target/kernel/patches/fbset-smedia-glamo.patch
   trunk/src/target/kernel/patches/series
Log:
ddition of xrandr support for GTA02:
http://bugzilla.openmoko.org/cgi-bin/bugzilla/show_bug.cgi?id=1145

In particular, this is the kernel patch (changed GLAMO_LOG a little):
http://bugzilla.openmoko.org/cgi-bin/bugzilla/attachment.cgi?id=459

Note: this doesn't work yet but crashes the kernel at driver initialization
instead. Don't enable !

fbset-gta02-core.patch:
- arch/arm/mach-s3c2440/mach-gta02.c (gta02_glamo_pdata): increase maximum xres
  from 480 to 640, to support rotation

fbset-smedia-glamo.patch:
- drivers/video/glamo/glamo-fb.c (GLAMO_LOG): added optional logging function
- drivers/video/glamo/glamo-fb.c (reg_set_bit_mask, rotate_lcd,
  get_orientation, will_orientation_change): new helper functions for rotation
- drivers/video/glamo/glamo-fb.c (glamofb_activate_var): renamed to
  glamofb_update_lcd_controller and added handling of rotation
- drivers/video/glamo/glamo-fb.c (glamofb_set_par): use
  glamofb_update_lcd_controller instead of glamofb_activate_var
- drivers/video/glamo/glamo-regs.h: added rotation mode values

series: changed comment for fbset-* from "test" to "FIX", because it currently
  just crashes the kernel



Modified: trunk/src/target/kernel/patches/fbset-gta02-core.patch
===================================================================
--- trunk/src/target/kernel/patches/fbset-gta02-core.patch      2008-01-08 
13:57:10 UTC (rev 3787)
+++ trunk/src/target/kernel/patches/fbset-gta02-core.patch      2008-01-08 
15:53:30 UTC (rev 3788)
@@ -8,7 +8,7 @@
 ===================================================================
 --- linux-2.6.22.5.orig/arch/arm/mach-s3c2440/mach-gta02.c
 +++ linux-2.6.22.5/arch/arm/mach-s3c2440/mach-gta02.c
-@@ -514,8 +514,15 @@
+@@ -514,11 +514,18 @@
  /* Smedia Glamo 3362 */
  
  static struct glamofb_platform_data gta02_glamo_pdata = {
@@ -25,4 +25,8 @@
 +      .vsync_len      = 2,
        .xres           = {
                .min    = 240,
-               .max    = 480,
+-              .max    = 480,
++              .max    = 640,
+               .defval = 480,
+       },
+       .yres           = {

Modified: trunk/src/target/kernel/patches/fbset-smedia-glamo.patch
===================================================================
--- trunk/src/target/kernel/patches/fbset-smedia-glamo.patch    2008-01-08 
13:57:10 UTC (rev 3787)
+++ trunk/src/target/kernel/patches/fbset-smedia-glamo.patch    2008-01-08 
15:53:30 UTC (rev 3788)
@@ -32,7 +32,25 @@
 ===================================================================
 --- linux-2.6.22.5.orig/drivers/video/glamo/glamo-fb.c
 +++ linux-2.6.22.5/drivers/video/glamo/glamo-fb.c
-@@ -99,25 +99,12 @@
+@@ -52,6 +52,17 @@
+ #include "glamo-regs.h"
+ #include "glamo-core.h"
+ 
++#ifdef DEBUG
++#define GLAMO_LOG(...)
++#else
++#define GLAMO_LOG(...) \
++do { \
++      printk(KERN_DEBUG "in %s:%s:%d", __FILE__, __func__, __LINE__); \
++      printk(KERN_DEBUG __VA_ARGS__); \
++} while (0);
++#endif
++
++
+ #define RESSIZE(ressource) (((ressource)->end - (ressource)->start)+1)
+ 
+ #define GLAMO_FB_ALLOC        (640*480*2)
+@@ -99,25 +110,12 @@
        { GLAMO_REG_LCD_MODE3, 0x0b40 },
          /* src data rgb565, res, 18bit rgb666
           * 000 01 011 0100 0000 */
@@ -58,53 +76,215 @@
  };
  
  static int glamofb_run_script(struct glamofb_handle *glamo,
-@@ -207,24 +194,69 @@
+@@ -207,24 +205,231 @@
        return 0;
  }
  
-+static void glamofb_activate_var(struct glamofb_handle *glamo,
-+                              struct fb_var_screeninfo *var)
++static void reg_set_bit_mask(struct glamofb_handle *glamo,
++                           u_int16_t reg, u_int16_t mask,
++                           u_int16_t val)
 +{
-+      int sync, bp, disp, fp, total;
++      u_int16_t tmp;
 +
++      val &= mask;
++
++      tmp = reg_read(glamo, reg);
++      tmp &= ~mask;
++      tmp |= val;
++      reg_write(glamo, reg, tmp);
++}
++
++#define GLAMO_LCD_WIDTH_MASK 0x03FF
++#define GLAMO_LCD_HEIGHT_MASK 0x03FF
++#define GLAMO_LCD_PITCH_MASK 0x07FE
++#define GLAMO_LCD_HV_TOTAL_MASK 0x03FF
++#define GLAMO_LCD_HV_RETR_START_MASK 0x03FF
++#define GLAMO_LCD_HV_RETR_END_MASK 0x03FF
++#define GLAMO_LCD_HV_RETR_DISP_START_MASK 0x03FF
++#define GLAMO_LCD_HV_RETR_DISP_END_MASK 0x03FF
++
++enum orientation {
++    ORIENTATION_PORTRAIT,
++    ORIENTATION_LANDSCAPE
++};
++
++
++static void rotate_lcd(struct glamofb_handle *glamo,
++                       __u32 rotation)
++{
++      int glamo_rot;
++
++      switch (rotation) {
++              case FB_ROTATE_UR:
++                      glamo_rot = GLAMO_LCD_ROT_MODE_0;
++                      break;
++              case FB_ROTATE_CW:
++                      glamo_rot = GLAMO_LCD_ROT_MODE_90;
++                      break;
++              case FB_ROTATE_UD:
++                      glamo_rot = GLAMO_LCD_ROT_MODE_180;
++                      break;
++              case FB_ROTATE_CCW:
++                      glamo_rot = GLAMO_LCD_ROT_MODE_270;
++                      break;
++              default:
++                      glamo_rot = GLAMO_LCD_ROT_MODE_0;
++                      break;
++      }
 +      glamofb_cmd_mode(glamo, 1);
++      reg_set_bit_mask(glamo,
++                       GLAMO_REG_LCD_WIDTH,
++                       GLAMO_LCD_ROT_MODE_MASK,
++                       glamo_rot);
++      reg_set_bit_mask(glamo,
++                       GLAMO_REG_LCD_MODE1,
++                       GLAMO_LCD_MODE1_ROTATE_EN,
++                       (glamo_rot != GLAMO_LCD_ROT_MODE_0)?
++                               GLAMO_LCD_MODE1_ROTATE_EN : 0);
++      glamofb_cmd_mode(glamo, 0);
++}
 +
++static enum orientation get_orientation(struct fb_var_screeninfo *var)
++{
++      GLAMO_LOG("mark\n")
++      if (var->xres <= var->yres) {
++              GLAMO_LOG("portrait\n")
++              return ORIENTATION_PORTRAIT;
++      }
++      GLAMO_LOG("landscape\n")
++      return ORIENTATION_LANDSCAPE;
++}
++
++static int will_orientation_change(struct fb_var_screeninfo *var)
++{
++      enum  orientation orient = get_orientation(var);
++      switch (orient) {
++              case ORIENTATION_LANDSCAPE:
++                      if (var->rotate == FB_ROTATE_UR || var->rotate == 
FB_ROTATE_UD)
++                              return 1;
++                      break;
++              case ORIENTATION_PORTRAIT:
++                      if (var->rotate == FB_ROTATE_CW || var->rotate == 
FB_ROTATE_CCW)
++                              return 1;
++                      break;
++      }
++      return 0;
++}
++
++static void glamofb_update_lcd_controller(struct glamofb_handle *glamo,
++                                        struct fb_var_screeninfo *var)
++{
++      int sync, bp, disp, fp, total, xres, yres, pitch, orientation_changing;
++
++      GLAMO_LOG("enter: glamo:%#x, var:%#x\n", (unsigned)glamo, 
(unsigned)var);
++      if (!glamo || !var)
++              return;
++
++      glamofb_cmd_mode(glamo, 1);
++
 +      if (var->pixclock)
 +              glamo_engine_reclock(glamo->mach_info->glamo,
 +                                   GLAMO_ENGINE_LCD,
 +                                   var->pixclock);
 +
-+      /* XXX highest bits of the following two regs have other meanings */
-+      reg_write(glamo, GLAMO_REG_LCD_WIDTH, var->xres);
-+      reg_write(glamo, GLAMO_REG_LCD_HEIGHT, var->yres);
-+      reg_write(glamo, GLAMO_REG_LCD_PITCH,
-+                      (var->xres * var->bits_per_pixel) / 8);
++      xres = var->xres;
++      yres = var->yres;
++      GLAMO_LOG("xres:%d, yres:%d, rotate:%d\n", xres, yres, var->rotate);
 +
++      /*
++       * figure out if orientation is going to change
++       */
++      orientation_changing = will_orientation_change(var);
++      GLAMO_LOG("orientation_changing:%d\n", orientation_changing);
++
++        /*
++         * adjust the pitch according to new orientation to come
++         */
++        if (orientation_changing) {
++              pitch = var->yres * var->bits_per_pixel / 8;
++        } else {
++              pitch = var->xres * var->bits_per_pixel / 8;
++        }
++      GLAMO_LOG("pitch:%d\n", pitch);
++
++      /*
++       * set the awaiten LCD geometry
++       */
++      reg_set_bit_mask(glamo,
++                       GLAMO_REG_LCD_WIDTH,
++                       GLAMO_LCD_WIDTH_MASK,
++                       xres);
++      reg_set_bit_mask(glamo,
++                       GLAMO_REG_LCD_HEIGHT,
++                       GLAMO_LCD_HEIGHT_MASK,
++                       yres);
++      reg_set_bit_mask(glamo,
++                       GLAMO_REG_LCD_PITCH,
++                       GLAMO_LCD_PITCH_MASK,
++                       pitch);
++
++      GLAMO_LOG("mark:\n");
++      /*
++       * honour the rotation request
++       */
++      rotate_lcd(glamo, var->rotate);
++
++      /*
++       * update the reported geometry
++       * of the framebuffer.
++       */
++      if (orientation_changing) {
++              var->xres_virtual = var->xres = yres;
++              var->yres_virtual = var->yres = xres;
++      } else {
++              var->xres_virtual = var->xres = xres;
++              var->yres_virtual = var->yres = yres;
++      }
++
++      GLAMO_LOG("reported res:(%d,%d)\n", var->xres, var->yres);
++      /*
++       * update scannout timings
++       */
 +      sync = 0;
 +      bp = sync + var->hsync_len;
 +      disp = bp + var->left_margin;
-+      fp = disp + var->xres;
++      fp = disp + xres;
 +      total = fp + var->right_margin;
 +
-+      reg_write(glamo, GLAMO_REG_LCD_HORIZ_TOTAL, total);
-+      reg_write(glamo, GLAMO_REG_LCD_HORIZ_RETR_START, sync);
-+      reg_write(glamo, GLAMO_REG_LCD_HORIZ_RETR_END, bp);
-+      reg_write(glamo, GLAMO_REG_LCD_HORIZ_DISP_START, disp);
-+      reg_write(glamo, GLAMO_REG_LCD_HORIZ_DISP_END, fp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_HORIZ_TOTAL,
++                       GLAMO_LCD_HV_TOTAL_MASK, total);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_HORIZ_RETR_START,
++                       GLAMO_LCD_HV_RETR_START_MASK, sync);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_HORIZ_RETR_END,
++                       GLAMO_LCD_HV_RETR_END_MASK, bp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_HORIZ_DISP_START,
++                        GLAMO_LCD_HV_RETR_DISP_START_MASK, disp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_HORIZ_DISP_END,
++                       GLAMO_LCD_HV_RETR_DISP_END_MASK, fp);
 +
++      GLAMO_LOG("mark:\n");
++
 +      sync = 0;
 +      bp = sync + var->vsync_len;
 +      disp = bp + var->upper_margin;
-+      fp = disp + var->yres;
++      fp = disp + yres;
 +      total = fp + var->lower_margin;
 +
-+      reg_write(glamo, GLAMO_REG_LCD_VERT_TOTAL, total);
-+      reg_write(glamo, GLAMO_REG_LCD_VERT_RETR_START, sync);
-+      reg_write(glamo, GLAMO_REG_LCD_VERT_RETR_END, bp);
-+      reg_write(glamo, GLAMO_REG_LCD_VERT_DISP_START, disp);
-+      reg_write(glamo, GLAMO_REG_LCD_VERT_DISP_END, fp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_VERT_TOTAL,
++                       GLAMO_LCD_HV_TOTAL_MASK, total);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_VERT_RETR_START,
++                        GLAMO_LCD_HV_RETR_START_MASK, sync);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_VERT_RETR_END,
++                       GLAMO_LCD_HV_RETR_END_MASK, bp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_VERT_DISP_START,
++                       GLAMO_LCD_HV_RETR_DISP_START_MASK, disp);
++      reg_set_bit_mask(glamo, GLAMO_REG_LCD_VERT_DISP_END,
++                       GLAMO_LCD_HV_RETR_DISP_END_MASK, fp);
 +
++      GLAMO_LOG("mark:\n");
 +      glamofb_cmd_mode(glamo, 0);
++
++      GLAMO_LOG("leave:\n");
 +}
 +
  static int glamofb_set_par(struct fb_info *info)
@@ -129,11 +309,11 @@
 +      info->fix.line_length = (var->xres * var->bits_per_pixel) / 8;
 +      info->fix.smem_len = info->fix.line_length * var->yres_virtual;
 +
-+      glamofb_activate_var(glamo, var);
++      glamofb_update_lcd_controller(glamo, var);
  
        return 0;
  }
-@@ -368,6 +400,8 @@
+@@ -368,6 +573,8 @@
                while (!reg_read(gfb, GLAMO_REG_LCD_STATUS2) & (1 << 12))
                        yield();
                dev_dbg(gfb->dev, "idle!\n");
@@ -142,7 +322,7 @@
        } else {
                /* RGB interface needs vsync/hsync */
                if (reg_read(gfb, GLAMO_REG_LCD_MODE3) & GLAMO_LCD_MODE3_RGB)
-@@ -384,7 +418,6 @@
+@@ -384,7 +591,6 @@
  
  int glamofb_cmd_write(struct glamofb_handle *gfb, u_int16_t val)
  {
@@ -150,7 +330,7 @@
        dev_dbg(gfb->dev, "%s: waiting for cmdq empty\n",
                __FUNCTION__);
        while (!glamofb_cmdq_empty(gfb))
-@@ -409,6 +442,18 @@
+@@ -409,6 +615,18 @@
        .fb_imageblit   = cfb_imageblit,
  };
  
@@ -169,7 +349,7 @@
  static int __init glamofb_probe(struct platform_device *pdev)
  {
        int rc = -EIO;
-@@ -504,24 +549,14 @@
+@@ -504,24 +722,14 @@
        fbinfo->var.yres_virtual = mach_info->yres.defval;
        fbinfo->var.bits_per_pixel = mach_info->bpp.defval;
  
@@ -201,7 +381,7 @@
        fbinfo->fix.smem_len = mach_info->xres.max *
                               mach_info->yres.max *
                               mach_info->bpp.max / 8;
-@@ -530,8 +565,7 @@
+@@ -530,8 +738,7 @@
  
        glamo_engine_enable(mach_info->glamo, GLAMO_ENGINE_LCD);
        glamo_engine_reset(mach_info->glamo, GLAMO_ENGINE_LCD);
@@ -337,3 +517,24 @@
  enum glamo_power {
        GLAMO_POWER_ON,
        GLAMO_POWER_STANDBY,
+Index: linux-2.6.22.5/drivers/video/glamo/glamo-regs.h
+===================================================================
+--- linux-2.6.22.5.orig/drivers/video/glamo/glamo-regs.h
++++ linux-2.6.22.5/drivers/video/glamo/glamo-regs.h
+@@ -431,6 +431,16 @@
+       GLAMO_LCD_MODE3_18BITS          = 0x0040,
+ };
+ 
++enum glamo_lcd_rot_mode {
++        GLAMO_LCD_ROT_MODE_0            = 0x0000,
++        GLAMO_LCD_ROT_MODE_180          = 0x2000,
++        GLAMO_LCD_ROT_MODE_MIRROR       = 0x4000,
++        GLAMO_LCD_ROT_MODE_FLIP         = 0x6000,
++        GLAMO_LCD_ROT_MODE_90           = 0x8000,
++        GLAMO_LCD_ROT_MODE_270          = 0xa000,
++};
++#define GLAMO_LCD_ROT_MODE_MASK         0xe000
++
+ enum glamo_lcd_cmd_type {
+       GLAMO_LCD_CMD_TYPE_DISP         = 0x0000,
+       GLAMO_LCD_CMD_TYPE_PARALLEL     = 0x4000,

Modified: trunk/src/target/kernel/patches/series
===================================================================
--- trunk/src/target/kernel/patches/series      2008-01-08 13:57:10 UTC (rev 
3787)
+++ trunk/src/target/kernel/patches/series      2008-01-08 15:53:30 UTC (rev 
3788)
@@ -45,12 +45,12 @@
 hxd8-tsl256x.patch
 pcf50633.patch
 smedia-glamo.patch
-# test, then merge
+# FIX, then merge
 #fbset-smedia-glamo.patch
 s3c24xx-nand-largepage.patch
 s3c2442b-cpuid.patch
 gta02-core.patch
-# test, then merge
+# FIX, then merge
 #fbset-gta02-core.patch
 # merge into gta02-core as soon as compatibility issues are resolved
 gta02-nor.patch




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2008-01-08 17:02:11 +0100 (Tue, 08 Jan 2008)
New Revision: 3789

Modified:
   trunk/src/target/kernel/scripts/build
   trunk/src/target/u-boot/scripts/build
Log:
- u-boot/scripts/build, kernel/scripts/build: removed "don't use" header
- u-boot/scripts/build: fixed space typo, breaking git version selection
- kernel/scripts/build: also update defconfig's SVN revision



Modified: trunk/src/target/kernel/scripts/build
===================================================================
--- trunk/src/target/kernel/scripts/build       2008-01-08 15:53:30 UTC (rev 
3788)
+++ trunk/src/target/kernel/scripts/build       2008-01-08 16:02:11 UTC (rev 
3789)
@@ -1,5 +1,3 @@
-UNDER DEVELOPMENT - DON'T USE YET
-
 #!/bin/sh -e
 #
 # This script illustrates how to build a specific version of the Linux kernel
@@ -42,10 +40,11 @@
 
 ln -sf $SVN/trunk/src/target/kernel/patches
 
+defconfig=$SVN/trunk/src/target/kernel/config/defconfig-$KERNEL
 [ -z "$SVN_REV" ] ||
-  ( cd patches && svn update -r$SVN_REV; )
+  ( cd patches && svn update -r$SVN_REV . $defconfig; )
 
 quilt push -a
-cp $SVN/trunk/src/target/kernel/config/defconfig-$KERNEL .config
+cp $defconfig .config
 make ARCH=arm CROSS_COMPILE=arm-angstrom-linux-gnueabi- oldconfig
 make ARCH=arm CROSS_COMPILE=arm-angstrom-linux-gnueabi- uImage

Modified: trunk/src/target/u-boot/scripts/build
===================================================================
--- trunk/src/target/u-boot/scripts/build       2008-01-08 15:53:30 UTC (rev 
3788)
+++ trunk/src/target/u-boot/scripts/build       2008-01-08 16:02:11 UTC (rev 
3789)
@@ -1,5 +1,3 @@
-UNDER DEVELOPMENT - DON'T USE YET
-
 #!/bin/sh -e
 #
 # This script illustrates how to build a specific version of u-boot from
@@ -31,7 +29,7 @@
 git clone git://www.denx.de/git/u-boot.git
 cd u-boot
 
-[ -z "$GIT_HEAD"] ||
+[ -z "$GIT_HEAD" ] ||
   git reset --hard $GIT_HEAD
 
 ln -sf $SVN/trunk/src/target/u-boot/patches




--- End Message ---
--- Begin Message ---
Author: werner
Date: 2008-01-08 21:53:27 +0100 (Tue, 08 Jan 2008)
New Revision: 3790

Modified:
   trunk/src/target/kernel/patches/fbset-gta02-core.patch
   trunk/src/target/kernel/patches/fbset-smedia-glamo.patch
   trunk/src/target/kernel/patches/series
Log:
Fixed the crash on initialization, which was a disagreement between allocated
and cleared memory. It's this patch, with trivial editing:
http://folks.o-hand.com/dodji/omoko/kernel/fix-glamo-fb-init-crash.patch.txt

fbset-gta02-core.patch:
- arch/arm/mach-s3c2440/mach-gta02.c (gta02_glamo_pdata): initialize
  fb_mem_size to 4MB (half of the SRAM available on the chip)

fbset-smedia-glamo.patch:
- include/linux/glamofb.h (struct glamofb_platform_data): new field fb_mem_size
  for the allocated size of the frame buffer memory
- drivers/video/glamo/glamo-fb.c (GLAMO_FB_ALLOC, glamofb_probe): removed
  GLAMO_FB_ALLOC. Allocation now comes from machine information.
- drivers/video/glamo/glamo-fb.c (glamofb_probe): set smem_len to available
  memory, not maximum visible frame buffer

series: enabled fbset-*



Modified: trunk/src/target/kernel/patches/fbset-gta02-core.patch
===================================================================
--- trunk/src/target/kernel/patches/fbset-gta02-core.patch      2008-01-08 
16:02:11 UTC (rev 3789)
+++ trunk/src/target/kernel/patches/fbset-gta02-core.patch      2008-01-08 
20:53:27 UTC (rev 3790)
@@ -8,7 +8,7 @@
 ===================================================================
 --- linux-2.6.22.5.orig/arch/arm/mach-s3c2440/mach-gta02.c
 +++ linux-2.6.22.5/arch/arm/mach-s3c2440/mach-gta02.c
-@@ -514,11 +514,18 @@
+@@ -514,11 +514,19 @@
  /* Smedia Glamo 3362 */
  
  static struct glamofb_platform_data gta02_glamo_pdata = {
@@ -23,6 +23,7 @@
 +      .lower_margin   = 16,
 +      .hsync_len      = 8,
 +      .vsync_len      = 2,
++      .fb_mem_size    = 0x400000, /* we have 8MB of SRAM, use half for fb */
        .xres           = {
                .min    = 240,
 -              .max    = 480,

Modified: trunk/src/target/kernel/patches/fbset-smedia-glamo.patch
===================================================================
--- trunk/src/target/kernel/patches/fbset-smedia-glamo.patch    2008-01-08 
16:02:11 UTC (rev 3789)
+++ trunk/src/target/kernel/patches/fbset-smedia-glamo.patch    2008-01-08 
20:53:27 UTC (rev 3790)
@@ -17,7 +17,7 @@
 ===================================================================
 --- linux-2.6.22.5.orig/include/linux/glamofb.h
 +++ linux-2.6.22.5/include/linux/glamofb.h
-@@ -13,6 +13,10 @@
+@@ -13,6 +13,11 @@
  
  struct glamofb_platform_data {
        int width, height;
@@ -25,6 +25,7 @@
 +      int left_margin, right_margin;
 +      int upper_margin, lower_margin;
 +      int hsync_len, vsync_len;
++      int fb_mem_size;
  
        struct glamofb_val xres;
        struct glamofb_val yres;
@@ -32,10 +33,11 @@
 ===================================================================
 --- linux-2.6.22.5.orig/drivers/video/glamo/glamo-fb.c
 +++ linux-2.6.22.5/drivers/video/glamo/glamo-fb.c
-@@ -52,6 +52,17 @@
+@@ -52,9 +52,18 @@
  #include "glamo-regs.h"
  #include "glamo-core.h"
  
+-#define RESSIZE(ressource) (((ressource)->end - (ressource)->start)+1)
 +#ifdef DEBUG
 +#define GLAMO_LOG(...)
 +#else
@@ -45,12 +47,14 @@
 +      printk(KERN_DEBUG __VA_ARGS__); \
 +} while (0);
 +#endif
+ 
+-#define GLAMO_FB_ALLOC        (640*480*2)
 +
-+
- #define RESSIZE(ressource) (((ressource)->end - (ressource)->start)+1)
++#define RESSIZE(ressource) (((ressource)->end - (ressource)->start)+1)
  
- #define GLAMO_FB_ALLOC        (640*480*2)
-@@ -99,25 +110,12 @@
+ struct glamofb_handle {
+       struct fb_info *fb;
+@@ -99,25 +108,12 @@
        { GLAMO_REG_LCD_MODE3, 0x0b40 },
          /* src data rgb565, res, 18bit rgb666
           * 000 01 011 0100 0000 */
@@ -76,7 +80,7 @@
  };
  
  static int glamofb_run_script(struct glamofb_handle *glamo,
-@@ -207,24 +205,231 @@
+@@ -207,24 +203,231 @@
        return 0;
  }
  
@@ -313,7 +317,7 @@
  
        return 0;
  }
-@@ -368,6 +573,8 @@
+@@ -368,6 +571,8 @@
                while (!reg_read(gfb, GLAMO_REG_LCD_STATUS2) & (1 << 12))
                        yield();
                dev_dbg(gfb->dev, "idle!\n");
@@ -322,7 +326,7 @@
        } else {
                /* RGB interface needs vsync/hsync */
                if (reg_read(gfb, GLAMO_REG_LCD_MODE3) & GLAMO_LCD_MODE3_RGB)
-@@ -384,7 +591,6 @@
+@@ -384,7 +589,6 @@
  
  int glamofb_cmd_write(struct glamofb_handle *gfb, u_int16_t val)
  {
@@ -330,7 +334,7 @@
        dev_dbg(gfb->dev, "%s: waiting for cmdq empty\n",
                __FUNCTION__);
        while (!glamofb_cmdq_empty(gfb))
-@@ -409,6 +615,18 @@
+@@ -409,6 +613,18 @@
        .fb_imageblit   = cfb_imageblit,
  };
  
@@ -349,7 +353,17 @@
  static int __init glamofb_probe(struct platform_device *pdev)
  {
        int rc = -EIO;
-@@ -504,24 +722,14 @@
+@@ -453,7 +669,8 @@
+       }
+ 
+       glamofb->fb_res = request_mem_region(glamofb->fb_res->start,
+-                                           GLAMO_FB_ALLOC, pdev->name);
++                                           mach_info->fb_mem_size,
++                                           pdev->name);
+       if (!glamofb->fb_res) {
+               dev_err(&pdev->dev, "failed to request vram region\n");
+               goto out_release_reg;
+@@ -504,34 +721,21 @@
        fbinfo->var.yres_virtual = mach_info->yres.defval;
        fbinfo->var.bits_per_pixel = mach_info->bpp.defval;
  
@@ -378,11 +392,13 @@
 -      fbinfo->var.green.length = 6;
 -      fbinfo->var.blue.length = 5;
 -      fbinfo->var.transp.length = 0;
-       fbinfo->fix.smem_len = mach_info->xres.max *
-                              mach_info->yres.max *
-                              mach_info->bpp.max / 8;
-@@ -530,8 +738,7 @@
+-      fbinfo->fix.smem_len = mach_info->xres.max *
+-                             mach_info->yres.max *
+-                             mach_info->bpp.max / 8;
++      fbinfo->fix.smem_len = mach_info->fb_mem_size;
  
+       memset(fbinfo->screen_base, 0, fbinfo->fix.smem_len);
+ 
        glamo_engine_enable(mach_info->glamo, GLAMO_ENGINE_LCD);
        glamo_engine_reset(mach_info->glamo, GLAMO_ENGINE_LCD);
 -      glamofb_run_script(glamofb, glamo_regs, ARRAY_SIZE(glamo_regs));

Modified: trunk/src/target/kernel/patches/series
===================================================================
--- trunk/src/target/kernel/patches/series      2008-01-08 16:02:11 UTC (rev 
3789)
+++ trunk/src/target/kernel/patches/series      2008-01-08 20:53:27 UTC (rev 
3790)
@@ -45,13 +45,13 @@
 hxd8-tsl256x.patch
 pcf50633.patch
 smedia-glamo.patch
-# FIX, then merge
-#fbset-smedia-glamo.patch
+# test, then merge into above patch
+fbset-smedia-glamo.patch
 s3c24xx-nand-largepage.patch
 s3c2442b-cpuid.patch
 gta02-core.patch
-# FIX, then merge
-#fbset-gta02-core.patch
+# test, then merge into above patch
+fbset-gta02-core.patch
 # merge into gta02-core as soon as compatibility issues are resolved
 gta02-nor.patch
 lis302dl.patch




--- End Message ---
_______________________________________________
commitlog mailing list
[email protected]
http://lists.openmoko.org/mailman/listinfo/commitlog

Reply via email to