Patches for 2.6.24

2010-07-06 Thread Angelo
Here i paste some patches to OpenEZX old 2.6.24 kernel...But makes the 
rootfs images builded for A780 with graphicals parts runs on 
A1200anybody can port it to news kernels.
Its named android-*.patch because is projected to run Android on 
A1200,but works in anothers rootfs.


I will paste one-by-one in my emails

--- offical/linux-2.6.24/drivers/input/touchscreen/pcap_ts.c2008-08-03 
14:10:24.582740912 +0800
+++ android/linux-2.6.24/drivers/input/touchscreen/pcap_ts.c2008-08-03 
14:23:32.384976768 +0800
@@ -156,8 +156,8 @@
enable_irq(pcap_ts-irq_touch);
} else {
DEBUGP(DOWN\n);
-   input_report_abs(pcap_ts-input, ABS_X, pcap_ts-x);
-   input_report_abs(pcap_ts-input, ABS_Y, pcap_ts-y);
+   input_report_abs(pcap_ts-input, ABS_X, X_AXIS_MAX - 
X_AXIS_MIN - pcap_ts-x);
+   input_report_abs(pcap_ts-input, ABS_Y, Y_AXIS_MAX - 
Y_AXIS_MIN - pcap_ts-y);
 
/* switch back to pressure read mode */
pcap_ts_mode(pcap_ts, PRESSURE_MEASUREMENT);


Patches for 2.6.24

2010-07-06 Thread Angelo
Here i paste some patches to OpenEZX old 2.6.24 kernel...But makes the 
rootfs images builded for A780 with graphicals parts runs on 
A1200anybody can port it to news kernels.
Its named android-*.patch because is projected to run Android on 
A1200,but works in anothers rootfs.


I will paste one-by-one in my emails


--- offical/linux-2.6.24/arch/arm/mach-pxa/ezx-a1200.c  2008-08-03 
14:10:26.981376264 +0800
+++ android/linux-2.6.24/arch/arm/mach-pxa/ezx-a1200.c  2008-08-03 
14:15:44.606089968 +0800
@@ -126,8 +126,8 @@
.pixclock = 192308,
.xres = 240,
.yres = 320,
-   .bpp = 18,
-   .nonstd = 32,
+   .bpp = 16,
+   .nonstd = 0,
.hsync_len = 10,
.left_margin = 20,
.right_margin = 10,
@@ -140,8 +140,8 @@
 static struct pxafb_mach_info a1200_fb_info = {
.modes = mode_a1200,
.num_modes = 1,
-   .lccr0 = 0x022008B8,
-   .lccr3 = 0xC130FF13,
+   .lccr0 = 0x042008B8,
+   .lccr3 = 0xC430FF13,
.pxafb_backlight_power = ezx_backlight_power,
.pxafb_lcd_power = ezx_lcd_power,
 };


Some patches for 2.6.24

2010-07-06 Thread Angelo
Here i paste some patches to OpenEZX old 2.6.24 kernel...But makes the 
rootfs images builded for A780 with graphicals parts runs on 
A1200anybody can port it to news kernels.
Its named android-*.patch because is projected to run Android on 
A1200,but works in anothers rootfs.


I will paste one-by-one in my emails
--- offical/linux-2.6.24/arch/arm/mach-pxa/ezx-a1200.c  2008-08-03 
14:10:26.981376264 +0800
+++ android/linux-2.6.24/arch/arm/mach-pxa/ezx-a1200.c  2008-08-03 
14:19:50.586695232 +0800
@@ -149,20 +149,29 @@
 /* PCAP */
 static int a1200_pcap_init(void)
 {
-   /* FIXME */
-   ezx_pcap_write(PCAP_REG_INT_SEL, 0x0); /* wrong */
-   ezx_pcap_write(PCAP_REG_SWCTRL, 0x2ee6); /* partially wrong */
-   ezx_pcap_write(PCAP_REG_VREG1, 0x15778e3); /* wrong */
-   ezx_pcap_write(PCAP_REG_VREG2, 0x810234); /* partially wrong */
-   ezx_pcap_write(PCAP_REG_AUXVREG, 0x1024bec); /* wrong */
-   ezx_pcap_write(PCAP_REG_PWR, 0x94108); /* partially wrong */
-   ezx_pcap_write(PCAP_REG_AUXVREG_MASK, 0x214d48); /* wrong */
-   ezx_pcap_write(PCAP_REG_BUSCTRL, 0x2a0); /* wrong */
-   ezx_pcap_write(PCAP_REG_LOWPWR, 0x1d9610c);
-   ezx_pcap_write(PCAP_REG_PERIPH, 0x0); /* wrong */
-   ezx_pcap_write(PCAP_REG_GP, 0x107); /* probably unnecessary */
-
-   return 0;
+   ezx_pcap_write(PCAP_REG_MSR, 0x007BEF7C);
+   ezx_pcap_write(PCAP_REG_INT_SEL,0x);
+   ezx_pcap_write(PCAP_REG_SWCTRL,0x2EE6);
+   ezx_pcap_write(PCAP_REG_VREG1,0x2EE6);
+   ezx_pcap_write(PCAP_REG_VREG2,0x00810234);
+
+   ezx_pcap_write(PCAP_REG_AUXVREG,0x01024BEC);
+   ezx_pcap_write(PCAP_REG_BATT,0x00228E00);
+   ezx_pcap_write(PCAP_REG_ADC1,0x001A00E4);
+   ezx_pcap_write(PCAP_REG_CODEC,0x0800);
+   ezx_pcap_write(PCAP_REG_RX_AMPS,0x0003);
+
+   ezx_pcap_write(PCAP_REG_ST_DAC,0x00099700);
+   ezx_pcap_write(PCAP_REG_PWR,0x00094108);
+   ezx_pcap_write(PCAP_REG_BUSCTRL,0x02A0);
+   ezx_pcap_write(PCAP_REG_AUXVREG_MASK,0x00214D48);
+   ezx_pcap_write(PCAP_REG_LOWPWR,0x01D9610C);
+
+   ezx_pcap_write(PCAP_REG_PERIPH_MASK,0x);
+   ezx_pcap_write(PCAP_REG_TX_AMPS,0xE000);
+   ezx_pcap_write(PCAP_REG_GP,0x0107);
+   
+return 0;
 }
 
 static struct pcap_platform_data a1200_pcap_platform_data = {