Changes between Version 9 and Version 10 of Android:SGX

Show
Ignore:
Timestamp:
09/10/10 10:32:06 (3 years ago)
Author:
alsutton
Comment:

Updated as SGX modules are now in the build

Legend:

Unmodified
Added
Removed
Modified
  • Android:SGX

    v9 v10  
    22== Getting SGX acceleration to work == 
    33  
    4 '''Everything should work as in androreas image with the instructions''' 
    5  
    6 NOTE: as of 2010-09-01, if you build the image yourself like described in the wiki, '''you only have to follow steps 1-5 and 13''' all other steps are already done. 
     4NOTE: You now *must* do this because the build is set up to expect the SGX drivers to be installed 
    75 
    86 1. Get and install the omap android sdk as mentioned [http://code.google.com/p/rowboat/wiki/ConfigureAndBuild#Install_the_Android_Graphics_SGX_SDK_on_Host_Machine here]. 
    9  1. Get the ARM tool chain from [http://www.codesourcery.com/sgpp/lite/arm/portal/release830 CodeSourcery]. 
    107 1. Change in the gfx_rel_es3.x_android folder (others wont work) 
    118 1. Mount your froyo image with -o loop 
    129 1. Run DISCIMAGE=/mountpoint ./install.sh 
    13  1. Apply the following patch to your init.rc (root of your froyo image) 
    14  
    15 {{{ 
    16  
    17 --- init.rc~ 2010-08-21 18:39:14.000000000 +0200 
    18 +++ init.rc 2010-08-24 12:07:31.000000000 +0200 
    19 @@ -268,6 +268,11 @@ on boot 
    20  service console /system/bin/sh 
    21      console 
    22   
    23 +# Start of SGX driver 
    24 +service pvrsrv /system/bin/sh /system/bin/sgx/rc.pvr start 
    25 +   user root 
    26 +   oneshot   
    27 + 
    28  # adbd is controlled by the persist.service.adb.enable system property 
    29  service adbd /sbin/adbd 
    30      disabled 
    31  
    32  
    33 }}} 
    34  
    35  6. Apply the following dirty patch to disable thigs that do not compile in  OMAP35x_Android_Graphics_SDK_3_01_00_03/GFX_Linux_KM/services4/system/omap3/  
    36  
    37  
    38 {{{ 
    39 --- sysutils_linux.c~   2010-06-01 17:01:09.000000000 +0200 
    40 +++ sysutils_linux.c    2010-08-25 01:19:34.248830000 +0200 
    41 @@ -36,10 +36,8 @@ 
    42   
    43  #if (LINUX_VERSION_CODE > KERNEL_VERSION(2,6,29)) 
    44  #include <plat/resource.h> 
    45 -#include <plat/omap-pm.h> 
    46  #else 
    47  #include <mach/resource.h> 
    48 -#include <mach/omap-pm.h> 
    49  #endif 
    50   
    51  #include "sgxdefs.h" 
    52 @@ -63,15 +61,6 @@ extern struct platform_device *gpsPVRLDM 
    53   
    54  static PVRSRV_ERROR ForceMaxSGXClocks(SYS_SPECIFIC_DATA *psSysSpecData) 
    55  { 
    56 -       PVR_UNREFERENCED_PARAMETER(psSysSpecData); 
    57 - 
    58 -       /* Pin the memory bus bw to the highest value according to CORE_REV */ 
    59 -#if defined(SGX530) && (SGX_CORE_REV == 125) 
    60 -       if(cpu_is_omap3630()) 
    61 -               omap_pm_set_min_bus_tput(&gpsPVRLDMDev->dev, OCP_INITIATOR_AGENT, 800000); 
    62 -#else 
    63 -       omap_pm_set_min_bus_tput(&gpsPVRLDMDev->dev, OCP_INITIATOR_AGENT, 664000); 
    64 -#endif 
    65         return PVRSRV_OK; 
    66  } 
    67   
    68 @@ -291,7 +280,6 @@ IMG_VOID DisableSGXClocks(SYS_DATA *psSy 
    69                 clk_disable(psSysSpecData->psSGX_FCK); 
    70         } 
    71   
    72 -       omap_pm_set_min_bus_tput(&gpsPVRLDMDev->dev, OCP_INITIATOR_AGENT, 0); 
    73   
    74         atomic_set(&psSysSpecData->sSGXClocksEnabled, 0); 
    75  
    76  
    77 }}} 
    78  
    79  7. Change to the directory OMAP35x_Android_Graphics_SDK_3_01_00_03/GFX_Linux_KM/eurasiacon/build/linux/omap3430_android/kbuild 
    80  1. Edit the file build_gfx_kernelmodules 
    81   a. Change DISCIMAGE= to where your froyo image is 
    82   a. Change KERNELDIR= to the kernel directory (from archos gpl source package, you need to have the kernel compiled before) 
    83   a. Change ANDROID_ROOT= to the location where you checked out the openaos froyo source 
    84   a. Change CROSS_COMPILE= to arm-none-eabi- 
    85  1. Add the bin subdirectory of the arm tool chain to your path. 
    86  1. Run ./build_gfx_kernelmodules, compilation of pvrsrvkm.ko will work, afterwards omapfb will fail, but we dont care. 
    87  1. Copy the resulting file OMAP35x_Android_Graphics_SDK_3_01_00_03/GFX_Linux_KM/services4/srvkm/env/linux/kbuild/pvrsrvkm.ko in  /system/bin/sgx/ in your froyo image 
    88  1. Copy omaplfb.ko from the extracted archos 2.0.28 firmware to /system/bin/sgx/ in your image. (Version compiled from the archos gpl code should also work) 
    89  1. Unmount your image, copy to archos and test. 
    90  
    91 == Optional: backlight support == 
    92  * copy system/lib/hw/lights.archos.so from the extracted archos 2.0.28 firmware to /system/lib/hw/ in your froyo image.