kernelloader-cvs Mailing List for Kernelloader (Page 47)
Run Linux on the Playstation 2
Brought to you by:
kloader
You can subscribe to this list here.
2012 |
Jan
|
Feb
(34) |
Mar
(6) |
Apr
(2) |
May
(20) |
Jun
(33) |
Jul
(12) |
Aug
(14) |
Sep
(48) |
Oct
(37) |
Nov
(19) |
Dec
(30) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2013 |
Jan
(24) |
Feb
(8) |
Mar
|
Apr
(2) |
May
(8) |
Jun
(57) |
Jul
(43) |
Aug
(20) |
Sep
(6) |
Oct
(7) |
Nov
|
Dec
(3) |
2014 |
Jan
(7) |
Feb
|
Mar
(2) |
Apr
(35) |
May
(36) |
Jun
(6) |
Jul
(651) |
Aug
(11) |
Sep
(2) |
Oct
(1) |
Nov
|
Dec
|
From: Mega M. <kl...@us...> - 2012-02-28 23:19:28
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv21872/loader Modified Files: loader.c loader.h loadermenu.cpp main.cpp modules.c nvram.c Log Message: The IOP reset automatically loaded the new version of CDVDMAN which is not able to read NVRAM on SCPH-70000. This has been fixed. Index: main.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/main.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** main.cpp 19 Feb 2012 14:02:54 -0000 1.18 --- main.cpp 28 Feb 2012 23:19:25 -0000 1.19 *************** *** 87,92 **** initMenu(menu); - nvram_init(); - loadLoaderModules(debug_mode); --- 87,90 ---- Index: loadermenu.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loadermenu.cpp,v retrieving revision 1.33 retrieving revision 1.34 diff -C2 -d -r1.33 -r1.34 *** loadermenu.cpp 27 Feb 2012 23:58:39 -0000 1.33 --- loadermenu.cpp 28 Feb 2012 23:19:25 -0000 1.34 *************** *** 852,859 **** --- 852,863 ---- /* New modules seems to be more stable on slim on heavy USB use. */ loaderConfig.newModulesInTGE = 1; + /* Load newer CDVDMAN module on IOP reset. */ + strcpy(iop_reset_param, "rom0:UDNL rom0:EELOADCNF"); } else { /* Value for fat PS2. */ slim = -1; loaderConfig.newModulesInTGE = 0; + /* Load old CDVDMAN module on IOP reset. */ + strcpy(iop_reset_param, "rom0:UDNL"); } *************** *** 944,947 **** --- 948,952 ---- addConfigTextItem("ps2linkGatewayIP", gatewayIP, MAX_INPUT_LEN); addConfigTextItem("ps2DNSIP", dnsIP, MAX_INPUT_LEN); + addConfigTextItem("IOPResetParameter", iop_reset_param, MAX_INPUT_LEN); menu->setTitle("Boot Menu"); *************** *** 1179,1182 **** --- 1184,1188 ---- &loaderConfig.patchLibsd); configMenu->addCheckItem("Enable IOP debug output", &loaderConfig.enableEEDebug); + configMenu->addItem("IOP Reset Param", editString, iop_reset_param); /* SBIOS Calls Menu */ Index: modules.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.c,v retrieving revision 1.22 retrieving revision 1.23 diff -C2 -d -r1.22 -r1.23 *** modules.c 27 Feb 2012 23:58:39 -0000 1.22 --- modules.c 28 Feb 2012 23:19:25 -0000 1.23 *************** *** 225,229 **** --- 225,236 ---- /** Parameter for IOP reset. */ + #ifdef NEW_ROM_MODULES + /* XXX: This will load the newer CDVDMAN module which doesn't support reading of NVRAM. */ static char s_pUDNL [] __attribute__( ( section( ".data" ), aligned( 1 ) ) ) = "rom0:UDNL rom0:EELOADCNF"; + #endif + #ifdef OLD_ROM_MODULES + /* This will load the old CDVDMAN module which supports reading of NVRAM. */ + static char s_pUDNL [] __attribute__( ( section( ".data" ), aligned( 1 ) ) ) = "rom0:UDNL"; + #endif char ps2_rom_version[256] = "unknown"; *************** *** 361,364 **** --- 368,375 ---- #endif + /* CDVDMAN is loaded by IopReset and NVRAM can be read. */ + graphic_setStatusMessage("Read NVRAM from CDVD"); + nvram_init(); + eromdrvSupport = 0; Index: nvram.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/nvram.c,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** nvram.c 27 Feb 2012 23:58:39 -0000 1.3 --- nvram.c 28 Feb 2012 23:19:25 -0000 1.4 *************** *** 34,38 **** char ps2_console_type[32] = "CDVD error"; char ps2_region_type[32] = "CDVD error"; ! int nvm_errors; void nvram_init(void) --- 34,38 ---- char ps2_console_type[32] = "CDVD error"; char ps2_region_type[32] = "CDVD error"; ! int nvm_errors = -1; void nvram_init(void) *************** *** 46,49 **** --- 46,54 ---- nvm_offsets_t *off = &nvmOff[0]; + if (nvm_errors >= 0) { + /* NVRAM was already loaded. */ + return; + } + version = getBiosVersion(); for (type = 0; type < (sizeof(nvmOff)/sizeof(nvmOff[0])); type++) { Index: loader.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.c,v retrieving revision 1.43 retrieving revision 1.44 diff -C2 -d -r1.43 -r1.44 *** loader.c 27 Feb 2012 23:58:39 -0000 1.43 --- loader.c 28 Feb 2012 23:19:25 -0000 1.44 *************** *** 92,96 **** /** Parameter for IOP reset. */ ! static char s_pUDNL [] __attribute__( ( section( ".data" ), aligned( 1 ) ) ) = "rom0:UDNL rom0:EELOADCNF"; /** Modules that should be loaded. */ --- 92,96 ---- /** Parameter for IOP reset. */ ! char iop_reset_param[MAX_INPUT_LEN] = "rom0:UDNL rom0:EELOADCNF"; /** Modules that should be loaded. */ *************** *** 2102,2106 **** SifStopDma(); ! SifIopReset(s_pUDNL, 0); while (SifIopSync()); --- 2102,2106 ---- SifStopDma(); ! SifIopReset(iop_reset_param, 0); while (SifIopSync()); Index: loader.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.h,v retrieving revision 1.28 retrieving revision 1.29 diff -C2 -d -r1.28 -r1.29 *** loader.h 27 Feb 2012 23:58:39 -0000 1.28 --- loader.h 28 Feb 2012 23:19:25 -0000 1.29 *************** *** 73,76 **** --- 73,78 ---- void DelayThread(int delay); const char *getPcicType(void); + + extern char iop_reset_param[]; #ifdef __cplusplus } |
From: Mega M. <kl...@us...> - 2012-02-28 00:00:15
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv23829 Modified Files: history.txt Log Message: Added menu entry for changing path to EROMDRV. Index: history.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/history.txt,v retrieving revision 1.18 retrieving revision 1.19 diff -C2 -d -r1.18 -r1.19 *** history.txt 27 Feb 2012 23:58:38 -0000 1.18 --- history.txt 28 Feb 2012 00:00:13 -0000 1.19 *************** *** 4,7 **** --- 4,10 ---- - Fixed detection of DVD region. Version 2.5 was only working on european slim PSTwo or fat PS2 (all regions). + - Add entry in Versions menu for changing path to EROMDRV. + The modules need to be reloaded in the menu Configuration-> + Net Options. 2.5 |
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv23615/loader Modified Files: getelf.h getrte.c getsbios.c loader.c loader.h loadermenu.cpp modules.c nvram.c nvram.h Log Message: Fixed problems with region detection which was introduced by kernelloader 2.5. Added possibilty to change name of EROM driver. Index: loadermenu.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loadermenu.cpp,v retrieving revision 1.32 retrieving revision 1.33 diff -C2 -d -r1.32 -r1.33 *** loadermenu.cpp 17 Feb 2012 22:59:25 -0000 1.32 --- loadermenu.cpp 27 Feb 2012 23:58:39 -0000 1.33 *************** *** 25,29 **** #define MAX_ENTRIES 256 #define MAX_FILE_LEN 256 ! #define MAX_PATH_LEN 1024 #define EXAMPLE_KERNEL "host:kernel.elf" --- 25,29 ---- #define MAX_ENTRIES 256 #define MAX_FILE_LEN 256 ! #define MAX_PATH_LEN MAX_INPUT_LEN #define EXAMPLE_KERNEL "host:kernel.elf" *************** *** 762,766 **** default: ! strcpy(text, commandline_pal); break; } --- 762,770 ---- default: ! if (ps2_rom_version[4] != 'E') { ! strcpy(text, commandline_ntsc); ! } else { ! strcpy(text, commandline_pal); ! } break; } *************** *** 1264,1267 **** --- 1268,1272 ---- versionMenu->addItem("LIBSD Version", showText, (void *) libsd_version); versionMenu->addItem("Hardware Information", showText, (void *) hardware_information); + versionMenu->addItem("EROMDRV Path", editString, (void *) get_eromdrvpath()); } Index: modules.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.c,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** modules.c 17 Feb 2012 22:59:25 -0000 1.21 --- modules.c 27 Feb 2012 23:58:39 -0000 1.22 *************** *** 60,64 **** ! static char eromdrvpath[] = "rom1:EROMDRVE"; static moduleLoaderEntry_t moduleList[] = { --- 60,64 ---- ! static char eromdrvpath[MAX_INPUT_LEN] = "rom1:EROMDRVE"; static moduleLoaderEntry_t moduleList[] = { *************** *** 361,364 **** --- 361,366 ---- #endif + eromdrvSupport = 0; + graphic_setStatusMessage("Add eedebug handler"); addEEDebugHandler(); *************** *** 413,417 **** if (rv < 0) { if ((moduleList[i].sms_mod == 0) || (isDVDVSupported())) { ! if (moduleList[i].eromdrv != 0) { rv = open("rom1:EROMDRV", O_RDONLY); if (rv >=0 ) { --- 415,422 ---- if (rv < 0) { if ((moduleList[i].sms_mod == 0) || (isDVDVSupported())) { ! if (moduleList[i].eromdrv < 0) { ! /* Try to detect EROM driver only the first time. */ ! moduleList[i].eromdrv = 1; ! rv = open("rom1:EROMDRV", O_RDONLY); if (rv >=0 ) { *************** *** 424,428 **** nvm = get_nvram(); ! if (nvm[NVM_FAKE_REGION] == version[4]) { /* NVM layout seems to be correct. */ eromdrvpath[12] = nvm[NVM_REAL_REGION]; --- 429,433 ---- nvm = get_nvram(); ! if (nvm[NVM_FAKE_REGION] == ps2_rom_version[4]) { /* NVM layout seems to be correct. */ eromdrvpath[12] = nvm[NVM_REAL_REGION]; *************** *** 435,440 **** --- 440,458 ---- continue; } + } else { + if (nvm_errors > 0) { + error_printf("%d errors when reading NVRAM. Please set path " + "to EROMDRV and reload modules.", nvm_errors); + } else { + error_printf("The region code stored in the NVRAM 0x%02x " + "doesn't match 0x%02x from the PS2 version string.", + nvm[NVM_FAKE_REGION], + ps2_rom_version[4]); + } + continue; } } + } + if (moduleList[i].eromdrv != 0) { moduleList[i].args = get_eromdrvpath(); moduleList[i].argLen = strlen(moduleList[i].args) + 1; Index: getrte.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/getrte.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** getrte.c 17 Oct 2009 22:29:41 -0000 1.2 --- getrte.c 27 Feb 2012 23:58:39 -0000 1.3 *************** *** 11,15 **** static char copybuffer[1024]; ! char rtePath[1024] = "cdfs:modules/mod203"; const char *moduleList[] = { "iopintr.irx", --- 11,15 ---- static char copybuffer[1024]; ! char rtePath[MAX_INPUT_LEN] = "cdfs:modules/mod203"; const char *moduleList[] = { "iopintr.irx", Index: nvram.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/nvram.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** nvram.c 9 Feb 2012 22:54:40 -0000 1.2 --- nvram.c 27 Feb 2012 23:58:39 -0000 1.3 *************** *** 34,41 **** char ps2_console_type[32] = "CDVD error"; char ps2_region_type[32] = "CDVD error"; void nvram_init(void) { - int errors; int rv; u32 addr; --- 34,41 ---- char ps2_console_type[32] = "CDVD error"; char ps2_region_type[32] = "CDVD error"; + int nvm_errors; void nvram_init(void) { int rv; u32 addr; *************** *** 59,63 **** } ! errors = 0; memset(nvm, 0, sizeof(nvm)); for (addr = 0; addr < sizeof(nvm)/2; addr++) { --- 59,63 ---- } ! nvm_errors = 0; memset(nvm, 0, sizeof(nvm)); for (addr = 0; addr < sizeof(nvm)/2; addr++) { *************** *** 65,69 **** if (rv != 1) { printf("sceCdReadNVM Error: rv = %d, addr = 0x%04x data = 0x%04x, stat = 0x%02x\n", rv, 2 * addr, data, stat); ! errors++; } else { nvm[addr * 2] = data & 0xFF; --- 65,69 ---- if (rv != 1) { printf("sceCdReadNVM Error: rv = %d, addr = 0x%04x data = 0x%04x, stat = 0x%02x\n", rv, 2 * addr, data, stat); ! nvm_errors++; } else { nvm[addr * 2] = data & 0xFF; *************** *** 79,83 **** ps2_console_type[sizeof(ps2_console_type) - 1] = 0; printf("PS2 Console type: %s\n", ps2_console_type); ! snprintf(ps2_region_type, sizeof(ps2_region_type), "0x%02x 0x%02x (%d NVM errors)", nvm[off->fake_region], nvm[off->real_region], errors); } --- 79,83 ---- ps2_console_type[sizeof(ps2_console_type) - 1] = 0; printf("PS2 Console type: %s\n", ps2_console_type); ! snprintf(ps2_region_type, sizeof(ps2_region_type), "0x%02x 0x%02x (%d NVM errors)", nvm[off->fake_region], nvm[off->real_region], nvm_errors); } Index: loader.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.c,v retrieving revision 1.42 retrieving revision 1.43 diff -C2 -d -r1.42 -r1.43 *** loader.c 17 Feb 2012 22:59:25 -0000 1.42 --- loader.c 27 Feb 2012 23:58:39 -0000 1.43 *************** *** 1450,1454 **** } if (rv < 0) { ! error_printf("Failed to start module \"%s\" (rv = %d).", modules[i].path, rv); } } --- 1450,1458 ---- } if (rv < 0) { ! if (modules[i].eromdrv) { ! error_printf("Failed to start module \"%s\" (rv = %d).", modules[i].args, rv); ! } else { ! error_printf("Failed to start module \"%s\" (rv = %d).", modules[i].path, rv); ! } } } Index: getelf.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/getelf.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** getelf.h 2 Aug 2008 22:19:27 -0000 1.1 --- getelf.h 27 Feb 2012 23:58:39 -0000 1.2 *************** *** 3,8 **** typedef struct { ! char elfNumber[1024]; ! char outputFilename[1024]; } copyRTEELF_param_t; --- 3,8 ---- typedef struct { ! char elfNumber[MAX_INPUT_LEN]; ! char outputFilename[MAX_INPUT_LEN]; } copyRTEELF_param_t; *************** *** 11,15 **** #endif ! extern char rteELF[1024]; int copyRTEELF(void *arg); --- 11,15 ---- #endif ! extern char rteELF[MAX_INPUT_LEN]; int copyRTEELF(void *arg); Index: getsbios.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/getsbios.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** getsbios.c 17 Oct 2009 22:29:41 -0000 1.2 --- getsbios.c 27 Feb 2012 23:58:39 -0000 1.3 *************** *** 15,20 **** #include "modules.h" ! char rteElf[1024] = "cdfs:pbpx_955.09"; ! char rteElfOffset[1024] = "16773120"; static char magic_string[] __attribute__((aligned(4))) = "PS2b"; --- 15,20 ---- #include "modules.h" ! char rteElf[MAX_INPUT_LEN] = "cdfs:pbpx_955.09"; ! char rteElfOffset[MAX_INPUT_LEN] = "16773120"; static char magic_string[] __attribute__((aligned(4))) = "PS2b"; Index: nvram.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/nvram.h,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** nvram.h 9 Feb 2012 22:54:40 -0000 1.2 --- nvram.h 27 Feb 2012 23:58:39 -0000 1.3 *************** *** 14,17 **** --- 14,18 ---- void nvram_init(void); u8 *get_nvram(void); + extern int nvm_errors; #ifdef __cplusplus Index: loader.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.h,v retrieving revision 1.27 retrieving revision 1.28 diff -C2 -d -r1.27 -r1.28 *** loader.h 9 Feb 2012 22:54:39 -0000 1.27 --- loader.h 27 Feb 2012 23:58:39 -0000 1.28 *************** *** 5,9 **** #include "stdint.h" ! #define LOADER_VERSION "2.5" #ifdef __cplusplus --- 5,9 ---- #include "stdint.h" ! #define LOADER_VERSION "2.6" #ifdef __cplusplus |
From: Mega M. <kl...@us...> - 2012-02-23 20:51:47
|
Update of /cvsroot/kernelloader/kernelloader/patches In directory vz-cvs-3.sog:/tmp/cvs-serv20447/patches Modified Files: linux-2.2.1-ps2-all_fat_and_slim.patch Log Message: Fix cross-compiling. Index: linux-2.2.1-ps2-all_fat_and_slim.patch =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/patches/linux-2.2.1-ps2-all_fat_and_slim.patch,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** linux-2.2.1-ps2-all_fat_and_slim.patch 19 Sep 2011 22:52:53 -0000 1.5 --- linux-2.2.1-ps2-all_fat_and_slim.patch 23 Feb 2012 20:51:45 -0000 1.6 *************** *** 751,752 **** --- 751,789 ---- /*--------------------------------------------------------------------------*/ + --- linux-2.2.1/arch/mips/Makefile 2001-03-28 09:47:20.000000000 +0200 + +++ linux-2.2.1_ps2/arch/mips/Makefile 2011-04-22 14:20:50.777984998 +0200 + @@ -54,12 +54,12 @@ MODFLAGS += -mlong-calls + # machines may also. + # + ifdef CONFIG_ELF_KERNEL + -CFLAGS += -G 0 -mno-abicalls -fno-pic + +CFLAGS += -G 0 -mno-abicalls + LINKFLAGS += -G 0 + LD_RFLAG += -G 0 + endif + ifdef CONFIG_ECOFF_KERNEL + -CFLAGS += -G 0 -mno-abicalls -fno-pic + +CFLAGS += -G 0 -mno-abicalls + LINKFLAGS += -G 0 -oformat ecoff-littlemips + LD_RFLAG += -G 0 + endif + @@ -187,7 +187,7 @@ endif + # The pipe options is bad for my low-mem machine + # Uncomment this if you want this. + # + -CFLAGS += -pipe + +#CFLAGS += -pipe + + HEAD := arch/mips/kernel/head.o arch/mips/kernel/init_task.o + + --- linux-2.2.1/arch/mips/Makefile.orig 2012-02-19 17:36:25.638421232 +0100 + +++ linux-2.2.1_ps2/arch/mips/Makefile 2012-02-19 17:36:41.090293352 +0100 + @@ -18,7 +18,7 @@ + # + ifdef CONFIG_CPU_LITTLE_ENDIAN + ifdef CONFIG_CPU_R5900 + -tool-prefix = mipsEEel-linux- + +tool-prefix = /usr/local/ps2/bin/ee- + else + tool-prefix = mipsel-linux- + endif |
From: Mega M. <kl...@us...> - 2012-02-23 20:51:05
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv20133 Modified Files: install.txt Log Message: loadkeys is needed to compile linux 2.4.17. Index: install.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/install.txt,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** install.txt 19 Feb 2012 17:54:20 -0000 1.9 --- install.txt 23 Feb 2012 20:51:02 -0000 1.10 *************** *** 195,198 **** --- 195,199 ---- locale-gen de_DE.UTF-8 apt-get install sudo + apt-get install kbd exit |
From: Mega M. <kl...@us...> - 2012-02-19 17:54:22
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv30113 Modified Files: install.txt Log Message: Karmic was moved to old releases in Ubuntu. Index: install.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/install.txt,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** install.txt 22 Oct 2011 22:27:04 -0000 1.8 --- install.txt 19 Feb 2012 17:54:20 -0000 1.9 *************** *** 174,178 **** Note: You need to replace $USER by your user name. ! sudo debootstrap --variant=buildd --arch i386 karmic /chroot/ http://archive.ubuntu.com/ubuntu/ Add the following to /etc/fstab /home /chroot/home none bind 0 0 --- 174,178 ---- Note: You need to replace $USER by your user name. ! sudo debootstrap --variant=buildd --arch i386 karmic /chroot/ http://old-releases.ubuntu.com/ubuntu/ Add the following to /etc/fstab /home /chroot/home none bind 0 0 |
From: Mega M. <kl...@us...> - 2012-02-19 15:12:06
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv14228 Modified Files: history.txt Log Message: - Fixed screen drawing problem in VGA mode (flickering penguin when loading data with http). Index: history.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/history.txt,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** history.txt 19 Feb 2012 14:02:54 -0000 1.16 --- history.txt 19 Feb 2012 15:12:02 -0000 1.17 *************** *** 39,42 **** --- 39,44 ---- The start button jumps to the beginning and the select button to the end of the string. + - Fixed screen drawing problem in VGA mode (flickering penguin when + loading data with http). 2.4 |
From: Mega M. <kl...@us...> - 2012-02-19 14:02:57
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv9395 Modified Files: history.txt readme.txt Log Message: Added support for virtual keyboard via game pad. Added support to move cusor in input fields. Index: history.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/history.txt,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** history.txt 18 Feb 2012 00:42:49 -0000 1.15 --- history.txt 19 Feb 2012 14:02:54 -0000 1.16 *************** *** 29,34 **** - Add parameter "-d" for kernelloader. This enables loading of ps2link for debugging purpose. ! - Show blinking cursor in input fields. - Set scroll position to 0 when input field is opened. 2.4 --- 29,42 ---- - Add parameter "-d" for kernelloader. This enables loading of ps2link for debugging purpose. ! - Show blinking cursor in input fields. Add possibilty to navigate ! the cursor with the cursor keys. - Set scroll position to 0 when input field is opened. + - Changed screenshot button to R3. + - Added virtual keyboard. The key is selected with R1 and L1. + The triangle button inserts the key. Left and right moves the + cursor left and right. The square button deletes a character + and the circle button is for fast jumping in key selection. + The start button jumps to the beginning and the select button + to the end of the string. 2.4 Index: readme.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/readme.txt,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** readme.txt 17 Feb 2012 21:01:40 -0000 1.4 --- readme.txt 19 Feb 2012 14:02:54 -0000 1.5 *************** *** 22,25 **** --- 22,45 ---- menu ("Select Kernel" -> vmlinux, "Select RAM disc" -> initrd). + Virtual Keyboard + ################ + The input fields in kernelloader supports a virtual keyboard. The virtual + keyboard is controlled by the game pad. This allows to enter kernel + parameter with the game pad without an USB keyboard. + The cursor is blinking. When it blinks it shows for a short time an + underline sign and for the remaining time the character which will + be inserted when pressing triangle. The default is the invisible + space character. The buttons have the following functions: + - The character is selected with R1 and L1. + - The triangle button inserts the character. It can be inserted multiple + times. + - Left and right moves the cursor left and right. + - The square button deletes the character which is left to the cursor. + - The circle button is for fast jumping in the character selection. This + is the same as pressing R1 for 16 times. You get from a capital letter + to lower case by pressing circle 2 times. + - The start button jumps to the beginning of the text. + - The select button jumps to the end of the string. + Video Mode ########## |
From: Mega M. <kl...@us...> - 2012-02-18 00:47:05
|
Update of /cvsroot/kernelloader/linux/simple-toolchain In directory vz-cvs-3.sog:/tmp/cvs-serv11437 Modified Files: build.sh Log Message: Install required packages for building when "apt-get" is available. Index: build.sh =================================================================== RCS file: /cvsroot/kernelloader/linux/simple-toolchain/build.sh,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** build.sh 29 Dec 2011 01:14:46 -0000 1.5 --- build.sh 18 Feb 2012 00:47:03 -0000 1.6 *************** *** 62,65 **** --- 62,73 ---- INSTALLPATH="$PREFIX/mipsel-linux-gnu" + which apt-get >/dev/null + if [ $? -eq 0 ]; then + INSTALLER="y" + + sudo apt-get install gcc make automake autoconf perl e2fsprogs gzip tar libmpfr-dev libgmp-dev libncurses-dev || exit -1 + sudo apt-get build-dep binutils gcc || exit -1 + fi + if [ "$EXTRACT_BIN" = "y" ]; then # Build binutils: |
From: Mega M. <kl...@us...> - 2012-02-18 00:42:51
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv11286/loader Modified Files: graphic.cpp Log Message: - Show blinking cursor in input fields. - Set scroll position to 0 when input field is opened. Index: graphic.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/graphic.cpp,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** graphic.cpp 17 Feb 2012 22:59:25 -0000 1.21 --- graphic.cpp 18 Feb 2012 00:42:49 -0000 1.22 *************** *** 247,254 **** static char *inputBuffer = NULL; static int writeable = 0; ! int printTextBlock(int x, int y, int z, int maxCharsPerLine, int maxY, const char *msg, int scrollPos) { ! char lineBuffer[maxCharsPerLine]; int i; int pos; --- 247,255 ---- static char *inputBuffer = NULL; static int writeable = 0; + static int cursor_counter = 0; ! int printTextBlock(int x, int y, int z, int maxCharsPerLine, int maxY, const char *msg, int scrollPos, int cursor) { ! char lineBuffer[maxCharsPerLine + 1]; /* + 1 for cursor */ int i; int pos; *************** *** 261,265 **** do { i = 0; ! lastSpace = 0; lastSpacePos = 0; while (i < maxCharsPerLine) { --- 262,266 ---- do { i = 0; ! lastSpace = -1; lastSpacePos = 0; while (i < maxCharsPerLine) { *************** *** 268,280 **** lastSpace = i; lastSpacePos = pos; - i++; break; - } - if (msg[pos] == ' ') { - lastSpace = i; - lastSpacePos = pos + 1; - if (i != 0) { - i++; - } } else if (msg[pos] == '\r') { lineBuffer[i] = 0; --- 269,273 ---- *************** *** 287,290 **** --- 280,299 ---- pos++; break; + } + if (i >= (maxCharsPerLine - 1)) { + if (msg[pos] == ' ') { + /* Last character is a space, show it at the beginning of the next line. */ + lastSpace = i; + lastSpacePos = pos; + } + break; + } + if (msg[pos] == ' ') { + /* Current character is a space. */ + lastSpace = i; + lastSpacePos = pos + 1; + i++; + } else if (msg[pos] == '\r') { + /* ignore */ } else { i++; *************** *** 292,301 **** pos++; } ! if (lastSpace != 0) { pos = lastSpacePos; } else { lastSpace = i; } lineBuffer[lastSpace] = 0; if (lineNo >= scrollPos) { --- 301,317 ---- pos++; } ! if (lastSpace >= 0) { pos = lastSpacePos; } else { + /* No whitespace in current line, cut off at last character in line. */ lastSpace = i; } lineBuffer[lastSpace] = 0; + if (msg[pos] == 0) { + if (cursor) { + lineBuffer[lastSpace] = '_'; + lineBuffer[lastSpace + 1] = 0; + } + } if (lineNo >= scrollPos) { *************** *** 407,417 **** gsKit_fontm_print_scaled(gsGlobal, gsFont, 50, 170, 3, scale, TexRed, "Error Message:"); ! printTextBlock(50, 230, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, msg, 0); } else { if (!isInfoBufferEmpty()) { ! scrollPos = printTextBlock(50, 170, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, infoBuffer, scrollPos); } else { if (inputBuffer != NULL) { ! inputScrollPos = printTextBlock(50, 170, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, inputBuffer, inputScrollPos); } else if (menu != NULL) { menu->paint(); --- 423,433 ---- gsKit_fontm_print_scaled(gsGlobal, gsFont, 50, 170, 3, scale, TexRed, "Error Message:"); ! printTextBlock(50, 230, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, msg, 0, 0); } else { if (!isInfoBufferEmpty()) { ! scrollPos = printTextBlock(50, 170, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, infoBuffer, scrollPos, 0); } else { if (inputBuffer != NULL) { ! inputScrollPos = printTextBlock(50, 170, 3, 26, gsGlobal->Height - reservedEndOfDisplayY, inputBuffer, inputScrollPos, writeable && (cursor_counter < (getModeFrequenzy()/2))); } else if (menu != NULL) { menu->paint(); *************** *** 461,464 **** --- 477,485 ---- gsKit_queue_exec(gsGlobal); gsKit_sync_flip(gsGlobal); + + cursor_counter++; + if (cursor_counter >= getModeFrequenzy()) { + cursor_counter = 0; + } } *************** *** 929,932 **** --- 950,955 ---- void setInputBuffer(char *buffer, int w) { + scrollPos = 0; + inputScrollPos = 0; inputBuffer = buffer; writeable = w; |
From: Mega M. <kl...@us...> - 2012-02-17 23:00:50
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv30558 Modified Files: config.mk Log Message: Not starting ps2link should be default (for real world tests). Index: config.mk =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/config.mk,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** config.mk 17 Feb 2012 22:59:25 -0000 1.16 --- config.mk 17 Feb 2012 23:00:46 -0000 1.17 *************** *** 15,19 **** # Activate ps2link debug modules in kernelloader (has only effect when IOP # reset is done): ! LOAD_PS2LINK = yes # Use new ROM modules in loader. --- 15,19 ---- # Activate ps2link debug modules in kernelloader (has only effect when IOP # reset is done): ! LOAD_PS2LINK = no # Use new ROM modules in loader. |
From: Mega M. <kl...@us...> - 2012-02-17 22:59:27
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv30469/loader Modified Files: Makefile graphic.cpp loader.c loadermenu.cpp main.cpp modules.c modules.h Log Message: - Add parameter "-d" for kernelloader. This enables loading of ps2link for debugging purpose. - Removed NAPLINK stuff from source code. This was never tested? Index: main.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/main.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -C2 -d -r1.16 -r1.17 *** main.cpp 17 Feb 2012 21:01:40 -0000 1.16 --- main.cpp 17 Feb 2012 22:59:25 -0000 1.17 *************** *** 16,19 **** --- 16,21 ---- #include "nvram.h" + int debug_mode; + /** * Entry point for loader. *************** *** 33,38 **** int refreshesPerSecond; ! argc = argc; ! argv = argv; /* Disable debug output at startup. */ --- 35,45 ---- int refreshesPerSecond; ! debug_mode = -1; ! for (i = 0; i < argc; i++) { ! if (strcmp(argv[i], "-d") == 0) { ! /* Enter debug mode, activate ps2link. */ ! debug_mode = 1; ! } ! } /* Disable debug output at startup. */ *************** *** 56,60 **** nvram_init(); ! loadLoaderModules(); setEnableDisc(false); --- 63,67 ---- nvram_init(); ! loadLoaderModules(debug_mode); setEnableDisc(false); *************** *** 70,73 **** --- 77,84 ---- refreshesPerSecond = getModeFrequenzy(); + printf("argc %d\n", argc); + for (i = 0; i < argc; i++) { + printf("argv[%d] = %s\n", i, argv[i]); + } if (loaderConfig.autoBootTime > 0) { Index: loadermenu.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loadermenu.cpp,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** loadermenu.cpp 17 Feb 2012 21:00:44 -0000 1.31 --- loadermenu.cpp 17 Feb 2012 22:59:25 -0000 1.32 *************** *** 899,902 **** --- 899,904 ---- int reloadModules(void *arg) { + extern int debug_mode; + (void) arg; *************** *** 915,919 **** setEnableDisc(true); ! loadLoaderModules(); setEnableDisc(false); --- 917,921 ---- setEnableDisc(true); ! loadLoaderModules(debug_mode); setEnableDisc(false); *************** *** 984,988 **** }; configFileMenu->addItem(cmc1Param.menuName, fsroot, (void *) &cmc1Param); ! #if !defined(RESET_IOP) || defined(PS2LINK) || defined(NAPLINK) static fsRootParam_t chostParam = { configfile, --- 986,990 ---- }; configFileMenu->addItem(cmc1Param.menuName, fsroot, (void *) &cmc1Param); ! #if !defined(RESET_IOP) static fsRootParam_t chostParam = { configfile, *************** *** 1048,1052 **** }; linuxMenu->addItem(kmc1Param.menuName, fsroot, (void *) &kmc1Param); ! #if !defined(RESET_IOP) || defined(PS2LINK) || defined(NAPLINK) static fsRootParam_t khostParam = { kernelFilename, --- 1050,1054 ---- }; linuxMenu->addItem(kmc1Param.menuName, fsroot, (void *) &kmc1Param); ! #if !defined(RESET_IOP) static fsRootParam_t khostParam = { kernelFilename, *************** *** 1112,1116 **** }; initrdMenu->addItem(mc1Param.menuName, fsroot, (void *) &mc1Param); ! #if !defined(RESET_IOP) || defined(PS2LINK) static fsRootParam_t hostParam = { initrdFilename, --- 1114,1118 ---- }; initrdMenu->addItem(mc1Param.menuName, fsroot, (void *) &mc1Param); ! #if !defined(RESET_IOP) static fsRootParam_t hostParam = { initrdFilename, *************** *** 1231,1240 **** " RESET_IOP" #endif - #ifdef PS2LINK - " PS2LINK" - #endif - #ifdef NAPLINK - " NAPLINK" - #endif #ifdef SCREENSHOT " SCREENSHOT" --- 1233,1236 ---- Index: graphic.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/graphic.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** graphic.cpp 17 Feb 2012 21:01:40 -0000 1.20 --- graphic.cpp 17 Feb 2012 22:59:25 -0000 1.21 *************** *** 334,343 **** "R" #endif - #ifdef PS2LINK - "P" - #endif - #ifdef NAPLINK - "N" - #endif #ifdef SCREENSHOT "S" --- 334,337 ---- Index: modules.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.c,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** modules.c 9 Feb 2012 22:54:39 -0000 1.20 --- modules.c 17 Feb 2012 22:59:25 -0000 1.21 *************** *** 55,58 **** --- 55,60 ---- /** True, if module needs network. */ int network; + /** 1, if debug mode. 0, load always. -1, no debug mode */ + int debug_mode; } moduleLoaderEntry_t; *************** *** 61,69 **** static moduleLoaderEntry_t moduleList[] = { ! #if defined(IOP_RESET) && !defined(PS2LINK) { .path = "eedebug.irx", .argLen = 0, ! .args = NULL }, #endif --- 63,72 ---- static moduleLoaderEntry_t moduleList[] = { ! #if defined(IOP_RESET) { .path = "eedebug.irx", .argLen = 0, ! .args = NULL, ! .debug_mode = -1, }, #endif *************** *** 169,173 **** .network = -1, }, - #ifdef PS2LINK { .path = "ps2link.irx", --- 172,175 ---- *************** *** 176,182 **** .checkMc = -1, .network = -1, }, #endif - #endif { .path = "dns.irx", --- 178,184 ---- .checkMc = -1, .network = -1, + .debug_mode = 1, }, #endif { .path = "dns.irx", *************** *** 194,211 **** .network = -1, }, - #ifdef NAPLINK - { - .path = "npm-usbd.irx", - .argLen = 0, - .args = NULL, - .checkMc = -1 - }, - { - .path = "npm-2301.irx", - .argLen = 0, - .args = NULL, - .checkMc = -1 - }, - #else { .path = "usbd.irx", --- 196,199 ---- *************** *** 214,218 **** .checkMc = -1 }, - #endif { .path = "usb_mass.irx", --- 202,205 ---- *************** *** 343,347 **** } ! int loadLoaderModules(void) { static int load_dvd_config = -1; --- 330,334 ---- } ! int loadLoaderModules(int debug_mode) { static int load_dvd_config = -1; *************** *** 381,384 **** --- 368,377 ---- rom_entry_t *romfile; + if (moduleList[i].debug_mode != 0) { + if (moduleList[i].debug_mode != debug_mode) { + continue; + } + } + /* Load configuration when necessary modules are loaded. */ if (moduleList[i].loadCfg) { Index: Makefile =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/Makefile,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** Makefile 9 Feb 2012 22:48:25 -0000 1.26 --- Makefile 17 Feb 2012 22:59:25 -0000 1.27 *************** *** 20,30 **** EE_OBJS += iopmem.o endif - ifeq ($(LOAD_PS2LINK),yes) - EE_FLAGS += -DPS2LINK - endif - ifeq ($(LOAD_NAPLINK),yes) - EE_FLAGS += -DNAPLINK - ROM_FILES += $(NAPLINK_MODULES) - endif ifeq ($(RESET_IOP),yes) EE_FLAGS += -DRESET_IOP --- 20,23 ---- *************** *** 87,94 **** dev9init.irx - NAPLINK_MODULES += \ - npm-usbd.irx \ - npm-2301.irx - ROM_FILES += $(MODULES) \ SMSUTILS.irx \ --- 80,83 ---- *************** *** 143,154 **** for file in $@; do install -m 644 $(PS2SDK)/iop/irx/$$file $$file; done - $(NAPLINK_MODULES): - for file in $(NAPLINK_MODULES); do cp $(NAPLINK_PATH)/$$file .; done - rom.o: rom.c romfilelist.h romdefinitions.h rominitialize.h test: all ! #ps2client -h $(TARGET_IP) execee host:$(PROGRAM).elf ps2client -h $(TARGET_IP) execee host:$(PACKEDFILE) reset: $(PROGRAM).elf --- 132,143 ---- for file in $@; do install -m 644 $(PS2SDK)/iop/irx/$$file $$file; done rom.o: rom.c romfilelist.h romdefinitions.h rominitialize.h test: all ! ifeq ($(LOAD_PS2LINK),yes) ! ps2client -h $(TARGET_IP) execee host:$(PACKEDFILE) -d ! else ps2client -h $(TARGET_IP) execee host:$(PACKEDFILE) + endif reset: $(PROGRAM).elf Index: modules.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.h,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** modules.h 9 Feb 2012 22:54:39 -0000 1.7 --- modules.h 17 Feb 2012 22:59:25 -0000 1.8 *************** *** 6,10 **** extern "C" { #endif ! int loadLoaderModules(void); int isSlimPSTwo(void); int isDVDVSupported(void); --- 6,10 ---- extern "C" { #endif ! int loadLoaderModules(int debug_mode); int isSlimPSTwo(void); int isDVDVSupported(void); Index: loader.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.c,v retrieving revision 1.41 retrieving revision 1.42 diff -C2 -d -r1.41 -r1.42 *** loader.c 9 Feb 2012 22:54:39 -0000 1.41 --- loader.c 17 Feb 2012 22:59:25 -0000 1.42 *************** *** 380,397 **** .network = -1, }, - #ifdef NAPLINK - { - .path = "host:npm-usbd.irx", - .buffered = -1, - .argLen = 0, - .args = NULL, - }, - { - .path = "host:npm-2301.irx", - .buffered = -1, - .argLen = 0, - .args = NULL, - }, - #endif { .path = "host:sharedmem.irx", --- 380,383 ---- |
From: Mega M. <kl...@us...> - 2012-02-17 22:31:21
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv28426/loader Modified Files: pad.c Log Message: - The screen was scrolling away in loader when there was no game pad connected to port 0. Fixed detecting of game pads. Index: pad.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/pad.c,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** pad.c 9 Feb 2012 22:48:25 -0000 1.4 --- pad.c 17 Feb 2012 22:31:17 -0000 1.5 *************** *** 132,137 **** if (modes == 0) { printf("This is a digital controller?\n"); ! padInitialized[port] = -1; ! return 1; } // Verify that the controller has a DUAL SHOCK mode --- 132,136 ---- if (modes == 0) { printf("This is a digital controller?\n"); ! return 0; } // Verify that the controller has a DUAL SHOCK mode |
From: Mega M. <kl...@us...> - 2012-02-17 21:01:46
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv19847 Modified Files: readme.txt history.txt Log Message: - Added mode setting by function keys: F1: Auto detect F2: VGA 640x480 60Hz F3: VGA 640x480 72Hz F4: VGA 640x480 75Hz F5: VGA 640x480 85Hz F6: DTV 480P F7: NTSC F8: PAL - Disabled switching of screen mode with keys "+" and "-" in input fields, because the keys can be used as kernel parameters and switching can confuse the user. Index: history.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/history.txt,v retrieving revision 1.11 retrieving revision 1.12 diff -C2 -d -r1.11 -r1.12 *** history.txt 9 Feb 2012 22:54:39 -0000 1.11 --- history.txt 17 Feb 2012 21:01:40 -0000 1.12 *************** *** 13,16 **** --- 13,28 ---- should fix DVD video support on these consoles. This is needed to get the Live DVD working. + - Added mode setting by function keys: + F1: Auto detect + F2: VGA 640x480 60Hz + F3: VGA 640x480 72Hz + F4: VGA 640x480 75Hz + F5: VGA 640x480 85Hz + F6: DTV 480P + F7: NTSC + F8: PAL + - Disabled switching of screen mode with keys "+" and "-" in + input fields, because the keys can be used as kernel parameters + and switching can confuse the user. 2.4 Index: readme.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/readme.txt,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** readme.txt 22 Oct 2011 21:03:31 -0000 1.3 --- readme.txt 17 Feb 2012 21:01:40 -0000 1.4 *************** *** 32,35 **** --- 32,46 ---- and restore defaults, because this will automatically set the kernel parameter accordingly. + The "+" and "-" keys on the keyboard also switch the video mode when + the focus is not in a input field. + The following function keys switch the screen mode: + F1: Auto detect + F2: VGA 640x480 60Hz + F3: VGA 640x480 72Hz + F4: VGA 640x480 75Hz + F5: VGA 640x480 85Hz + F6: DTV 480P + F7: NTSC + F8: PAL Auto-Boot |
From: Mega M. <kl...@us...> - 2012-02-17 21:01:45
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv19847/loader Modified Files: graphic.cpp graphic.h main.cpp Log Message: - Added mode setting by function keys: F1: Auto detect F2: VGA 640x480 60Hz F3: VGA 640x480 72Hz F4: VGA 640x480 75Hz F5: VGA 640x480 85Hz F6: DTV 480P F7: NTSC F8: PAL - Disabled switching of screen mode with keys "+" and "-" in input fields, because the keys can be used as kernel parameters and switching can confuse the user. Index: main.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/main.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -C2 -d -r1.15 -r1.16 *** main.cpp 1 May 2010 21:53:14 -0000 1.15 --- main.cpp 17 Feb 2012 21:01:40 -0000 1.16 *************** *** 116,119 **** --- 116,120 ---- do { char key; + int written; graphic_paint(); *************** *** 121,124 **** --- 122,126 ---- new_pad = paddata & ~old_pad; old_pad = paddata; + written = 0; if (PS2KbdRead(&key) > 0) { *************** *** 127,130 **** --- 129,144 ---- if (PS2KbdRead(&key) > 0) { switch(key) { + case 1: + case 2: + case 3: + case 4: + case 5: + case 6: + case 7: + case 8: + setMode(key - 1); + changeMode(); + refreshesPerSecond = getModeFrequenzy(); + break; case 41: new_pad |= PAD_RIGHT; *************** *** 149,158 **** new_pad |= PAD_CROSS; break; - case '+': - new_pad |= PAD_R2; - break; - case '-': - new_pad |= PAD_L2; - break; default: //info_printf("Key %d \"%c\"\n", key, key); --- 163,166 ---- *************** *** 209,212 **** --- 217,222 ---- if (isWriteable()) { int pos; + + written = 1; pos = strlen(buffer); if (key == 7) { *************** *** 262,265 **** --- 272,287 ---- } } + if (!written) { + if (key == '+') { + incrementMode(); + changeMode(); + refreshesPerSecond = getModeFrequenzy(); + } else if (key == '-') { + decrementMode(); + changeMode(); + refreshesPerSecond = getModeFrequenzy(); + } + } + } while (1); Index: graphic.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/graphic.cpp,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** graphic.cpp 6 Feb 2012 18:18:59 -0000 1.19 --- graphic.cpp 17 Feb 2012 21:01:40 -0000 1.20 *************** *** 700,703 **** --- 700,710 ---- } + void setMode(int mode) + { + if (mode < (sizeof(modeList)/sizeof(modeList[0]))) { + currentMode = mode; + } + } + int getModeFrequenzy(void) { Index: graphic.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/graphic.h,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** graphic.h 27 Apr 2010 23:23:22 -0000 1.9 --- graphic.h 17 Feb 2012 21:01:40 -0000 1.10 *************** *** 12,15 **** --- 12,16 ---- void incrementMode(void); void decrementMode(void); + void setMode(int mode); int getModeFrequenzy(void); void graphic_paint(void); |
From: Mega M. <kl...@us...> - 2012-02-17 21:00:46
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv19652/loader Modified Files: loadermenu.cpp Log Message: Reduced memory consumption by reducing colors. Make default resolution fit into default maxmimum framebuffer memory. Index: loadermenu.cpp =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loadermenu.cpp,v retrieving revision 1.30 retrieving revision 1.31 diff -C2 -d -r1.30 -r1.31 *** loadermenu.cpp 6 Feb 2012 18:18:59 -0000 1.30 --- loadermenu.cpp 17 Feb 2012 21:00:44 -0000 1.31 *************** *** 286,293 **** const char commandline_ntsc[] = "crtmode=ntsc xmode=NTSC video=ps2fb:ntsc,640x448-32"; /** Default Linux parameter for VGA mode. */ ! const char commandline_vga60[] = "crtmode=vesa0,60 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-32@60"; ! const char commandline_vga72[] = "crtmode=vesa0 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-32@72"; ! const char commandline_vga75[] = "crtmode=vesa0,75 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-32@75"; ! const char commandline_vga85[] = "crtmode=vesa0,75 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-32@85"; /** Default Linux parameter for HDTV mode. */ const char commandline_dtv[] = "crtmode=dtv0 xmode=dtv,480p video=ps2fb:dtv,720x480-32"; --- 286,293 ---- const char commandline_ntsc[] = "crtmode=ntsc xmode=NTSC video=ps2fb:ntsc,640x448-32"; /** Default Linux parameter for VGA mode. */ ! const char commandline_vga60[] = "crtmode=vesa0,60 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-16@60"; ! const char commandline_vga72[] = "crtmode=vesa0 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-16@72"; ! const char commandline_vga75[] = "crtmode=vesa0,75 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-16@75"; ! const char commandline_vga85[] = "crtmode=vesa0,75 xmode=VESA,1024x768x24 video=ps2fb:vesa,1024x768-16@85"; /** Default Linux parameter for HDTV mode. */ const char commandline_dtv[] = "crtmode=dtv0 xmode=dtv,480p video=ps2fb:dtv,720x480-32"; |
From: Mega M. <kl...@us...> - 2012-02-13 18:28:52
|
Update of /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video In directory vz-cvs-3.sog:/tmp/cvs-serv32726/linux-2.6.35.4-mipsel-ps2/drivers/video Modified Files: Kconfig Log Message: Configure framebuffer driver as default. Index: Kconfig =================================================================== RCS file: /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video/Kconfig,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** Kconfig 15 Jan 2012 16:14:24 -0000 1.3 --- Kconfig 13 Feb 2012 18:28:50 -0000 1.4 *************** *** 2233,2237 **** tristate "Frame buffer driver for Sony Playstation 2" depends on FB && SONY_PS2 ! default n help This driver implements support for framebuffer of the Sony --- 2233,2237 ---- tristate "Frame buffer driver for Sony Playstation 2" depends on FB && SONY_PS2 ! default y help This driver implements support for framebuffer of the Sony |
From: Mega M. <kl...@us...> - 2012-02-12 23:27:51
|
Update of /cvsroot/kernelloader/linux/configuration In directory vz-cvs-3.sog:/tmp/cvs-serv25888 Modified Files: readme.txt Log Message: Updated documentation for new ps2fb driver. Index: readme.txt =================================================================== RCS file: /cvsroot/kernelloader/linux/configuration/readme.txt,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** readme.txt 12 Feb 2012 14:34:29 -0000 1.5 --- readme.txt 12 Feb 2012 23:27:49 -0000 1.6 *************** *** 66,71 **** The mplayer can directly use the framebuffer. You can ! start it with the command: mplayer -nosound -vo fbdev -vf rgb2bgr=swap -fs video.mpg --- 66,72 ---- The mplayer can directly use the framebuffer. You can ! start it with the commands: + fbset -xres 800 -yres 600 -depth 32 mplayer -nosound -vo fbdev -vf rgb2bgr=swap -fs video.mpg *************** *** 75,76 **** --- 76,87 ---- leads to an acceptable speed: MPEG1 320x240 (aspect 1) 29.970 fps 990.8 kbps (123.8 kbyte/s) + + The color is correct when mode is 32 bit and the filter rgb2bgr + swaps the byte order. + + Note: The mplayer crashs if the videomemsize is too small. + This can be avoided by a smaller resolution or by increasing + the videomemsize. + + In X11 the mplayer doesn't work, because BGR is not supported + (inverted order of color bytes). |
From: Mega M. <kl...@us...> - 2012-02-12 23:13:25
|
Update of /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video In directory vz-cvs-3.sog:/tmp/cvs-serv24534/drivers/video Modified Files: ps2fb.c Log Message: Implemented ps2fb_copyarea() used by fbcon. Fixed color in ps2fb_fillrect(). This caused incorrect colors in aptitude. Clean up code. Index: ps2fb.c =================================================================== RCS file: /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video/ps2fb.c,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** ps2fb.c 12 Feb 2012 13:29:57 -0000 1.10 --- ps2fb.c 12 Feb 2012 23:13:22 -0000 1.11 *************** *** 23,29 **** #include <asm/mach-ps2/ps2con.h> - /* TBD: Seems not to be needed, because this is not used by xorg. */ - #define PIXMAP_SIZE (4 * 2048 * 32/8) - /** Bigger 1 bit color images will be devided into smaller images with the following maximum width. */ #define PATTERN_MAX_X 16 --- 23,26 ---- *************** *** 88,92 **** } ! // TBD: Add code to support old parameter style. return 0; --- 85,89 ---- } ! /* TBD: Add code to support old parameter style. */ return 0; *************** *** 204,208 **** b <<= 8 - var->blue.length; t = (col >> var->transp.offset) & (0xFFFFFFFF >> (32 - var->transp.length)); ! b <<= 8 - var->transp.length; rv = (r << 0) | (g << 8) | (b << 16) | (t << 24); --- 201,205 ---- b <<= 8 - var->blue.length; t = (col >> var->transp.offset) & (0xFFFFFFFF >> (32 - var->transp.length)); ! t <<= 8 - var->transp.length; rv = (r << 0) | (g << 8) | (b << 16) | (t << 24); *************** *** 218,235 **** * the framebuffer. * - * This function is the first function called in the framebuffer api. - * Usually you don't need to provide this function. The case where it - * is used is to change from a text mode hardware state to a graphics - * mode state. - * * Returns negative errno on error, or zero on success. */ static int ps2fb_open(struct fb_info *info, int user) { ! struct ps2fb_par *par; DPRINTK("ps2fb_open: user %d\n", user); - par = info->par; if (user) { par->opencnt++; --- 215,226 ---- * the framebuffer. * * Returns negative errno on error, or zero on success. */ static int ps2fb_open(struct fb_info *info, int user) { ! struct ps2fb_par *par = info->par; DPRINTK("ps2fb_open: user %d\n", user); if (user) { par->opencnt++; *************** *** 245,264 **** * the framebuffer. * - * Thus function is called when we close /dev/fb or the framebuffer - * console system is released. Usually you don't need this function. - * The case where it is usually used is to go from a graphics state - * to a text mode state. - * * Returns negative errno on error, or zero on success. */ static int ps2fb_release(struct fb_info *info, int user) { ! struct ps2fb_par *par; DPRINTK("ps2fb_release: user %d\n", user); - par = info->par; if (user) { - /* TBD: Check if mmap is also removed. */ par->opencnt--; if (par->opencnt == 0) { --- 236,248 ---- * the framebuffer. * * Returns negative errno on error, or zero on success. */ static int ps2fb_release(struct fb_info *info, int user) { ! struct ps2fb_par *par = info->par; DPRINTK("ps2fb_release: user %d\n", user); if (user) { par->opencnt--; if (par->opencnt == 0) { *************** *** 575,579 **** } offset = start & (PAGE_SIZE - 1); ! // TBD: vmalloc_to_pfn is only working with redraw handler. cur_start = phys_to_virt(PFN_PHYS(vmalloc_to_pfn((void *) start))) + offset; cur_size = ALIGN16(s); --- 559,563 ---- } offset = start & (PAGE_SIZE - 1); ! /* vmalloc_to_pfn is only working with redraw handler. */ cur_start = phys_to_virt(PFN_PHYS(vmalloc_to_pfn((void *) start))) + offset; cur_size = ALIGN16(s); *************** *** 619,622 **** --- 603,616 ---- } + /** + * Copy data to framebuffer on GS side. + * + * @param info PS2 screeninfo (16 bit and 32 bit PSM is supported) + * @param sx Destination X coordinate in framebuffer + * @param sy Destination Y coordinate in framebuffer + * @param width Width of frame + * @param height Height of frame + * @param data Source pointer which was allocated with rvmalloc() + */ static void ps2fb_copyframe(struct ps2_screeninfo *info, int sx, int sy, int width, int height, const uint32_t *data) { *************** *** 770,774 **** int res; - /* TBD: Support 16 and 32 bit color. */ if (var->bits_per_pixel <= 16) { var->bits_per_pixel = 16; --- 764,767 ---- *************** *** 805,808 **** --- 798,803 ---- var->transp.length = 1; } else { + /* TBD: Add support for 8bpp, because directfb doesn't support BGR, but 8bpp. */ + /* TBD: Simulate 8bpp, convert on GS side. */ printk("ps2fb: %d bits per pixel are not supported.\n", var->bits_per_pixel); return -EINVAL; *************** *** 873,877 **** par->screeninfo.h = info->var.yres; par->redraw_yres = info->var.yres; ! par->screeninfo.res = ps2con_get_resolution(crtmode, info->var.xres, info->var.yres, 60 /* TBD: calculate rate. */); if (info->var.bits_per_pixel == 16) { par->screeninfo.psm = PS2_GS_PSMCT16; --- 868,873 ---- par->screeninfo.h = info->var.yres; par->redraw_yres = info->var.yres; ! par->screeninfo.res = ps2con_get_resolution(crtmode, ! info->var.xres, info->var.yres, 60 /* TBD: calculate rate. */); if (info->var.bits_per_pixel == 16) { par->screeninfo.psm = PS2_GS_PSMCT16; *************** *** 1094,1123 **** region->height, region->color); return; } if (p->fix.visual == FB_VISUAL_TRUECOLOR || ! p->fix.visual == FB_VISUAL_DIRECTCOLOR ) color = ((u32*)(p->pseudo_palette))[region->color]; ! else color = region->color; ! /* TBD: handle region->rop ROP_COPY or ROP_XOR */ ! ps2_paintrect(region->dx, region->dy, region->width, region->height, colto32(&p->var, color)); ! /* Meaning of struct fb_fillrect ! * ! * @dx: The x and y corrdinates of the upper left hand corner of the ! * @dy: area we want to draw to. ! * @width: How wide the rectangle is we want to draw. ! * @height: How tall the rectangle is we want to draw. ! * @color: The color to fill in the rectangle with. ! * @rop: The raster operation. We can draw the rectangle with a COPY ! * of XOR which provides erasing effect. ! */ } /** ! * ps2fb_copyarea - REQUIRED function. Can use generic routines if ! * non acclerated hardware and packed pixel based. ! * Copies one area of the screen to another area. * * @info: frame buffer structure that represents a single frame buffer --- 1090,1109 ---- region->height, region->color); + /* TBD: handle region->rop ROP_COPY or ROP_XOR */ return; } if (p->fix.visual == FB_VISUAL_TRUECOLOR || ! p->fix.visual == FB_VISUAL_DIRECTCOLOR ) { color = ((u32*)(p->pseudo_palette))[region->color]; ! } else { color = region->color; ! } ! ps2_paintrect(region->dx, region->dy, ! region->width, region->height, colto32(&p->var, color)); } /** ! * ps2fb_copyarea - REQUIRED function. * * @info: frame buffer structure that represents a single frame buffer *************** *** 1126,1172 **** * * This drawing operation copies a rectangular area from one area of the ! * screen to another area. */ ! void ps2fb_copyarea(struct fb_info *p, const struct fb_copyarea *area) { DPRINTK("ps2fb: %d %s()\n", __LINE__, __FUNCTION__); ! /* ! * @dx: The x and y coordinates of the upper left hand corner of the ! * @dy: destination area on the screen. ! * @width: How wide the rectangle is we want to copy. ! * @height: How tall the rectangle is we want to copy. ! * @sx: The x and y coordinates of the upper left hand corner of the ! * @sy: source area on the screen. ! */ ! /* TBD: Function ps2fb_copyarea() needs to be implemented, used by fbcon. */ } /** ! * ps2fb_imageblit - REQUIRED function. Can use generic routines if ! * non acclerated hardware and packed pixel based. ! * Copies a image from system memory to the screen. * ! * @info: frame buffer structure that represents a single frame buffer ! * @image: structure defining the image. * * This drawing operation draws a image on the screen. It can be a ! * mono image (needed for font handling) or a color image (needed for ! * tux). */ void ps2fb_imageblit(struct fb_info *info, const struct fb_image *image) { struct ps2fb_par *par = info->par; - uint32_t fgcolor; - uint32_t bgcolor; - - if ((image->depth != 1) && (image->depth != 8)) { - printk("ps2fb: blit depth %d dx %d dy %d w %d h %d 0x%08x\n", - image->depth, - image->dx, - image->dy, - image->width, - image->height, - (unsigned int)image->data); - } if (image->depth == 1) { --- 1112,1172 ---- * * This drawing operation copies a rectangular area from one area of the ! * screen to another area. */ ! void ps2fb_copyarea(struct fb_info *info, const struct fb_copyarea *area) { + struct ps2fb_par *par = info->par; + u64 *gsp; + int fbw = (par->screeninfo.w + 63) / 64; + DPRINTK("ps2fb: %d %s()\n", __LINE__, __FUNCTION__); ! ! if ((gsp = ps2con_gsp_alloc(ALIGN16(10 * 8), NULL)) == NULL) { ! printk("ps2fb: ps2con_gsp_alloc() failed in ps2con_bmove().\n"); ! return; ! } ! ! *gsp++ = PS2_GIFTAG_SET_TOPHALF(4, 1, 0, 0, PS2_GIFTAG_FLG_PACKED, 1); ! /* A+D */ ! *gsp++ = 0x0e; ! *gsp++ = (u64)par->screeninfo.fbp | ! ((u64)fbw << 16) | ((u64)par->screeninfo.psm << 24) | ! ((u64)par->screeninfo.fbp << 32) | ! ((u64)fbw << 48) | ((u64)par->screeninfo.psm << 56); ! *gsp++ = PS2_GS_BITBLTBUF; ! ! if (area->sy > area->dy || (area->sy == area->dy && area->sx > area->dx)) { ! /* copy region LT -> RB */ ! *gsp++ = PACK64(PACK32(area->sx, area->sy), ! PACK32(area->dx, area->dy) + (0 << 27)); ! } else { ! /* copy region RB -> LT */ ! *gsp++ = PACK64(PACK32(area->sx, area->sy), ! PACK32(area->dx, area->dy) + (3 << 27)); ! } ! ! *gsp++ = PS2_GS_TRXPOS; ! *gsp++ = PACK64(area->width, area->height); ! *gsp++ = PS2_GS_TRXREG; ! /* local to local */ ! *gsp++ = 2; ! *gsp++ = PS2_GS_TRXDIR; ! ! ps2con_gsp_send(ALIGN16(10 * 8), 0); } /** ! * ps2fb_imageblit - REQUIRED function. * ! * @info: frame buffer structure that represents a single frame buffer ! * @image: structure defining the image. * * This drawing operation draws a image on the screen. It can be a ! * mono image (needed for font handling) or a color image (needed for ! * tux). */ void ps2fb_imageblit(struct fb_info *info, const struct fb_image *image) { struct ps2fb_par *par = info->par; if (image->depth == 1) { *************** *** 1174,1177 **** --- 1174,1179 ---- int y; int offset; + uint32_t fgcolor; + uint32_t bgcolor; fgcolor = ((u32*)(info->pseudo_palette))[image->fg_color]; *************** *** 1242,1245 **** --- 1244,1256 ---- } } + } else { + printk("ps2fb: blit depth %d dx %d dy %d w %d h %d 0x%08x\n", + image->depth, + image->dx, + image->dy, + image->width, + image->height, + (unsigned int)image->data); + /* TBD: Implement other color depths in ps2fb_imageblit()? */ } } *************** *** 1252,1256 **** unsigned long offset = vma->vm_pgoff << PAGE_SHIFT; unsigned long page, pos; ! struct ps2fb_par *par; if (offset + size > info->fix.smem_len) { --- 1263,1267 ---- unsigned long offset = vma->vm_pgoff << PAGE_SHIFT; unsigned long page, pos; ! struct ps2fb_par *par = info->par; if (offset + size > info->fix.smem_len) { *************** *** 1259,1262 **** --- 1270,1275 ---- if ((info->fix.smem_start == 0) && (info->fix.smem_len > 0)) { + /* Memory is allocated on first call to mmap. */ + /* This will save memory until framebuffer is used. */ info->fix.smem_start = (unsigned long) rvmalloc(info->fix.smem_len); } *************** *** 1267,1272 **** } - par = info->par; - pos = (unsigned long)info->fix.smem_start + offset; /* Framebuffer can't be mapped. Map normal memory instead --- 1280,1283 ---- *************** *** 1349,1353 **** if (!info) { - /* TBD: goto error path */ return -ENOMEM; } --- 1360,1363 ---- *************** *** 1405,1465 **** | FBINFO_HWACCEL_FILLRECT | FBINFO_HWACCEL_IMAGEBLIT; ! ! #if 1 // TBD: Check ! /********************* This stage is optional ******************************/ ! /* ! * The struct pixmap is a scratch pad for the drawing functions. This ! * is where the monochrome bitmap is constructed by the higher layers ! * and then passed to the accelerator. For drivers that uses ! * cfb_imageblit, you can skip this part. For those that have a more ! * rigorous requirement, this stage is needed ! */ ! ! /* PIXMAP_SIZE should be small enough to optimize drawing, but not ! * large enough that memory is wasted. A safe size is ! * (max_xres * max_font_height/8). max_xres is driver dependent, ! * max_font_height is 32. ! */ ! info->pixmap.addr = kmalloc(PIXMAP_SIZE, GFP_KERNEL); ! if (!info->pixmap.addr) { ! /* TBD: goto error handler */ ! return -ENOMEM; ! } ! ! info->pixmap.size = PIXMAP_SIZE; ! ! /* ! * FB_PIXMAP_SYSTEM - memory is in system ram ! * FB_PIXMAP_IO - memory is iomapped ! * FB_PIXMAP_SYNC - if set, will call fb_sync() per access to pixmap, ! * usually if FB_PIXMAP_IO is set. ! * ! * Currently, FB_PIXMAP_IO is unimplemented. ! */ ! /* TBD: Set FB_PIXMAP_SYNC for DMA? */ ! info->pixmap.flags = FB_PIXMAP_SYSTEM; ! ! /* ! * scan_align is the number of padding for each scanline. It is in bytes. ! * Thus for accelerators that need padding to the next u32, put 4 here. ! */ ! info->pixmap.scan_align = 1; ! ! /* ! * buf_align is the amount to be padded for the buffer. For example, ! * the i810fb needs a scan_align of 2 but expects it to be fed with ! * dwords, so a buf_align = 4 is required. ! */ ! info->pixmap.buf_align = 16; ! ! /* access_align is how many bits can be accessed from the framebuffer ! * ie. some epson cards allow 16-bit access only. Most drivers will ! * be safe with u32 here. ! * ! * NOTE: This field is currently unused. ! */ ! info->pixmap.access_align = 8; ! /***************************** End optional stage ***************************/ ! #endif /* --- 1415,1419 ---- | FBINFO_HWACCEL_FILLRECT | FBINFO_HWACCEL_IMAGEBLIT; ! /* TBD: Support FBINFO_HWACCEL_YPAN or FBINFO_HWACCEL_YWRAP some applications need this. */ /* |
From: Mega M. <kl...@us...> - 2012-02-12 14:34:32
|
Update of /cvsroot/kernelloader/linux/configuration In directory vz-cvs-3.sog:/tmp/cvs-serv17822 Modified Files: readme.txt Log Message: Updated description for new driver version. Index: readme.txt =================================================================== RCS file: /cvsroot/kernelloader/linux/configuration/readme.txt,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** readme.txt 5 Feb 2012 23:01:09 -0000 1.4 --- readme.txt 12 Feb 2012 14:34:29 -0000 1.5 *************** *** 19,31 **** video=ps2fb:vesa,800x600 video=ps2fb:vesa,1024x768 ! video=ps2fb:vesa,1280x1024 video=ps2fb:dtv video=ps2fb:dtv,720x480 ! video=ps2fb:dtv,1280x720 ! video=ps2fb:dtv,1920x1080 The resolutions 1280x1024 and 1920x1080 support 16 bit color. Lower resolutions support 32 bit color. ! At the moment only 32 bit color is working correctly. xorg configuration --- 19,45 ---- video=ps2fb:vesa,800x600 video=ps2fb:vesa,1024x768 ! video=ps2fb:vesa,1280x1024,videomemsize=4194304 video=ps2fb:dtv video=ps2fb:dtv,720x480 ! video=ps2fb:dtv,1280x720,videomemsize=4194304 ! video=ps2fb:dtv,1920x1080,videomemsize=4194304 The resolutions 1280x1024 and 1920x1080 support 16 bit color. Lower resolutions support 32 bit color. ! 32 bit and 16 bit color are working correctly. ! The color format is BGR and not RGB (inverted order of colors ! in memory). Some programs and libraries can't handle this ! (e.g. vice in X11, ROLF in 16 bit format, directfb in 16 and ! 32 bit color). ! The default video memory size is 2MiB. You can always set the ! higher modes, but only use them in text mode. Mapping of full ! framebuffer will not work (only 2MiB). ! The video memory is not allocated until the first application ! mmaps the memory. It can't be swapped so it can decrease the ! system performance. ! ! The resolution can be changed with the command: ! fbset -xres 800 -yres 600 -depth 32 ! fbset -xres 800 -yres 600 -depth 16 xorg configuration *************** *** 36,49 **** apt-get install xorg apt-get install xfce4 The file xorg.conf need to be copied to /etc/X11/xorg.conf ! This file is configured to 640x480. This was only working when ! the following kernel parameter was specified: ! video=ps2fb:vesa,640x480 ! It is also possible to change the mode with the command: ! fbset -xres 640 -yres 480 ! The system will crash if the mode configured in the file ! /etc/X11/xorg.conf is not already set by the kernel parameter ! or by fbset. It can be started as root user with the command: startx --- 50,60 ---- apt-get install xorg apt-get install xfce4 + apt-get install fluxbox + Fluxbox runs faster. The file xorg.conf need to be copied to /etc/X11/xorg.conf ! This file is configured to 640x480 and 32 bit color. ! The color depth need to be configured to 24 or 15 bit. ! X11 will automatically switch the resolution and color format. It can be started as root user with the command: startx |
From: Mega M. <kl...@us...> - 2012-02-12 14:17:45
|
Update of /cvsroot/kernelloader/linux/simpleinitrd In directory vz-cvs-3.sog:/tmp/cvs-serv16289 Modified Files: createinitrd.sh readme.txt Log Message: Added support for cpio format. This allows to build smaller and larger initial ramdisks. Use cpio as default. Index: createinitrd.sh =================================================================== RCS file: /cvsroot/kernelloader/linux/simpleinitrd/createinitrd.sh,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** createinitrd.sh 8 Jan 2012 17:37:28 -0000 1.5 --- createinitrd.sh 12 Feb 2012 14:17:42 -0000 1.6 *************** *** 5,11 **** --- 5,13 ---- PROGRAM=${1:-simpleprog} + INITRDTYPE=${2:-cpio} error_exit() { + sudo umount root echo >&2 "Error occured" exit -1 *************** *** 14,23 **** cd "`dirname $0`" BASEDIR="`pwd`" ! if [ "$PROGRAM" != "" ]; then ! cd ../testprograms || error_exit ! SIZE=16384 ! else cd ../minimalistic || error_exit SIZE=512 fi make clean || error_exit --- 16,25 ---- cd "`dirname $0`" BASEDIR="`pwd`" ! if [ "$PROGRAM" = "simpleprog" ]; then cd ../minimalistic || error_exit SIZE=512 + else + cd ../testprograms || error_exit + SIZE=16384 fi make clean || error_exit *************** *** 25,55 **** cd "$BASEDIR" || error_exit ! mkdir -p root/sbin || error_exit if [ "$PROGRAM" != "simpleprog" ]; then cp ../testprograms/*/$PROGRAM root/sbin/init || error_exit else cp ../minimalistic/simpleprog root/sbin/init || error_exit fi ! dd if=/dev/zero of=initrd bs=1024 count="$SIZE" || error_exit ! mkfs.ext2 -F -t ext2 -I 128 initrd || error_exit ! mkdir -p mnt || error_exit ! sudo mount -o loop initrd mnt || error_exit ! sudo mkdir mnt/dev || error_exit ! sudo mknod mnt/dev/console c 5 1 || error_exit ! sudo mknod mnt/dev/ttyS0 c 4 64 || error_exit ! sudo cp -r root/. mnt || error_exit ! if [ "$PROGRAM" != "simpleprog" ]; then ! sudo mkdir mnt/lib || error_exit ! sudo cp -a /usr/local/mipsel-linux-gnu/lib/libc.so* mnt/lib/ || error_exit ! sudo cp -a /usr/local/mipsel-linux-gnu/lib/libc-* mnt/lib/ || error_exit ! sudo cp -a /usr/local/mipsel-linux-gnu/lib/ld.so.1 mnt/lib/ || error_exit ! sudo cp -a /usr/local/mipsel-linux-gnu/lib/ld-2.7.so mnt/lib/ || error_exit ! sudo cp -a /usr/local/mipsel-linux-gnu/lib/libgcc* mnt/lib/ || error_exit ! sudo mkdir -p mnt/usr/local/mipsel-linux-gnu || error_exit ! sudo ln -s /lib mnt/usr/local/mipsel-linux-gnu/lib || error_exit fi - sudo chown -R root:root mnt/ || error_exit - sudo chmod +x mnt/sbin/init || error_exit - sudo umount mnt || error_exit rm -f initrd.gz || error_exit gzip initrd || error_exit --- 27,68 ---- cd "$BASEDIR" || error_exit ! if [ -d root ]; then ! sudo rm -rf root || error_exit ! fi ! mkdir root || error_exit ! if [ "$INITRDTYPE" != "cpio" ]; then ! dd if=/dev/zero of=initrd bs=1024 count="$SIZE" || error_exit ! mkfs.ext2 -F -t ext2 -I 128 initrd || error_exit ! sudo mount -o loop initrd root || error_exit ! fi ! mkdir root/sbin || error_exit ! sudo mkdir root/dev || error_exit ! sudo mknod root/dev/console c 5 1 || error_exit ! sudo mknod root/dev/ttyS0 c 4 64 || error_exit if [ "$PROGRAM" != "simpleprog" ]; then + sudo mknod root/dev/fb0 c 29 0 || error_exit cp ../testprograms/*/$PROGRAM root/sbin/init || error_exit + sudo mkdir root/lib || error_exit + sudo cp -a /usr/local/mipsel-linux-gnu/lib/libc.so* root/lib/ || error_exit + sudo cp -a /usr/local/mipsel-linux-gnu/lib/libc-* root/lib/ || error_exit + sudo cp -a /usr/local/mipsel-linux-gnu/lib/ld.so.1 root/lib/ || error_exit + sudo cp -a /usr/local/mipsel-linux-gnu/lib/ld-2.7.so root/lib/ || error_exit + sudo cp -a /usr/local/mipsel-linux-gnu/lib/libgcc* root/lib/ || error_exit + sudo mkdir -p root/usr/local/mipsel-linux-gnu || error_exit + sudo ln -sf /lib root/usr/local/mipsel-linux-gnu/lib || error_exit else cp ../minimalistic/simpleprog root/sbin/init || error_exit fi ! sudo ln -sf /sbin/init root/init ! sudo chown -R root:root root/ || error_exit ! sudo chmod +x root/sbin/init || error_exit ! find root | xargs ls -ld ! if [ "$INITRDTYPE" = "cpio" ]; then ! cd root || error_exit ! sudo bash -c "find . | cpio --create --format='newc' >../initrd" || error_exit ! cd .. || error_exit ! else ! sudo umount root || error_exit fi rm -f initrd.gz || error_exit gzip initrd || error_exit Index: readme.txt =================================================================== RCS file: /cvsroot/kernelloader/linux/simpleinitrd/readme.txt,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** readme.txt 8 Jan 2012 17:37:29 -0000 1.1 --- readme.txt 12 Feb 2012 14:17:42 -0000 1.2 *************** *** 6,15 **** Usage: ! createinitrd.sh [program] Possible parameters for [program] is simpleprog or ! an program from ../testprograms/*/, e.g.: ! ./createinitrd.sh simpleprog # Test without libc ! ./createinitrd.sh helloworld # Test with libc ! ./createinitrd.sh testframebuffer # Test framebuffer --- 6,17 ---- Usage: ! createinitrd.sh [program] [format] Possible parameters for [program] is simpleprog or ! an program from ../testprograms/*/. ! Format is either cpio or initrd. ! ./createinitrd.sh simpleprog # Test without libc in cpio container ! ./createinitrd.sh helloworld # Test with libc in cpio container ! ./createinitrd.sh helloworld initrd # Test with libc in ext2 container ! ./createinitrd.sh testframebuffer # Test framebuffer in cpio container |
From: Mega M. <kl...@us...> - 2012-02-12 13:31:46
|
Update of /cvsroot/kernelloader/linux/testprograms/framebuffer In directory vz-cvs-3.sog:/tmp/cvs-serv13550/framebuffer Modified Files: testframebuffer.c Log Message: Fixed error handling. Support 16 bit color mode. Only mmap framebuffer memory which is available. Index: testframebuffer.c =================================================================== RCS file: /cvsroot/kernelloader/linux/testprograms/framebuffer/testframebuffer.c,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** testframebuffer.c 5 Feb 2012 22:36:35 -0000 1.2 --- testframebuffer.c 12 Feb 2012 13:31:43 -0000 1.3 *************** *** 18,26 **** long int location = 0; unsigned int max = 400; /* Open the file for reading and writing */ fbfd = open("/dev/fb0", O_RDWR); ! if (!fbfd) { ! printf("Error: cannot open framebuffer device.\n"); exit(1); } --- 18,27 ---- long int location = 0; unsigned int max = 400; + unsigned int maxline; /* Open the file for reading and writing */ fbfd = open("/dev/fb0", O_RDWR); ! if (fbfd < 0) { ! perror("Error: cannot open framebuffer device."); exit(1); } *************** *** 29,33 **** /* Get fixed screen information */ if (ioctl(fbfd, FBIOGET_FSCREENINFO, &finfo)) { ! printf("Error reading fixed information.\n"); exit(2); } --- 30,34 ---- /* Get fixed screen information */ if (ioctl(fbfd, FBIOGET_FSCREENINFO, &finfo)) { ! perror("Error reading fixed information"); exit(2); } *************** *** 38,42 **** /* Get variable screen information */ if (ioctl(fbfd, FBIOGET_VSCREENINFO, &vinfo)) { ! printf("Error reading variable information.\n"); exit(3); } --- 39,43 ---- /* Get variable screen information */ if (ioctl(fbfd, FBIOGET_VSCREENINFO, &vinfo)) { ! perror("Error reading variable information"); exit(3); } *************** *** 53,57 **** /* Map the device to memory */ ! fbp = (char *) mmap(0, screensize, PROT_READ | PROT_WRITE, MAP_SHARED, fbfd, 0); if ((long) fbp == -1) { --- 54,58 ---- /* Map the device to memory */ ! fbp = (char *) mmap(0, finfo.smem_len, PROT_READ | PROT_WRITE, MAP_SHARED, fbfd, 0); if ((long) fbp == -1) { *************** *** 61,64 **** --- 62,70 ---- printf("The framebuffer device was mapped to memory successfully.\n"); + maxline = finfo.smem_len / finfo.line_length; + if (max > maxline) { + max = maxline; + } + if (max > vinfo.xres) { max = vinfo.xres; *************** *** 88,92 **** color |= (transp >> (8 - vinfo.transp.length)) << vinfo.transp.offset; //printf("0x%08lx color 0x%08x\n", (long) (fbp + location), color); ! *((uint32_t *) (fbp + location)) = color; } --- 94,116 ---- color |= (transp >> (8 - vinfo.transp.length)) << vinfo.transp.offset; //printf("0x%08lx color 0x%08x\n", (long) (fbp + location), color); ! switch (vinfo.bits_per_pixel) { ! case 32: ! *((uint32_t *) (fbp + location)) = color; ! break; ! ! case 16: ! *((uint16_t *) (fbp + location)) = color; ! break; ! ! case 8: ! *((uint8_t *) (fbp + location)) = color; ! break; ! ! default: ! printf("Unsupported pixel format %d bpp.\n", vinfo.bits_per_pixel); ! munmap(fbp, screensize); ! close(fbfd); ! return -1; ! } } |
From: Mega M. <kl...@us...> - 2012-02-12 13:29:59
|
Update of /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video In directory vz-cvs-3.sog:/tmp/cvs-serv13442/drivers/video Modified Files: ps2fb.c Log Message: Add support for 15 bit color mode (16bpp). Add parameter videomemsize for configuring framebuffer size. Index: ps2fb.c =================================================================== RCS file: /cvsroot/kernelloader/linux/linux-2.6.35.4-mipsel-ps2/drivers/video/ps2fb.c,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** ps2fb.c 7 Feb 2012 23:53:55 -0000 1.9 --- ps2fb.c 12 Feb 2012 13:29:57 -0000 1.10 *************** *** 31,34 **** --- 31,51 ---- #define PATTERN_MAX_Y 8 + /** Alignment for width in Bytes. */ + #define PS2_FBMEM_ALIGN 8 + + /** Number of colors in palette. */ + #define PAL_COLORS 256 + + /** Usable memory in GS. */ [...1054 lines suppressed...] ! } else if (strnicmp(this_opt, "pal", 3) == 0) { crtmode = PS2_GS_PAL; ! // TBD: maxres = 2; } else if (this_opt[0] >= '0' && this_opt[0] <= '9') { mode_option = this_opt; --- 1561,1574 ---- if (!*this_opt) continue; ! if (strnicmp(this_opt, VESA, sizeof(VESA) - 1) == 0) { crtmode = PS2_GS_VESA; ! } else if (strnicmp(this_opt, DTV, sizeof(DTV) - 1) == 0) { crtmode = PS2_GS_DTV; ! } else if (strnicmp(this_opt, NTSC, sizeof(NTSC) - 1) == 0) { crtmode = PS2_GS_NTSC; ! } else if (strnicmp(this_opt, PAL, sizeof(PAL) - 1) == 0) { crtmode = PS2_GS_PAL; ! } else if (strnicmp(this_opt, VIDEOMEMEMORYSIZE, sizeof(VIDEOMEMEMORYSIZE) - 1) == 0) { ! videomemsize = simple_strtoul(this_opt + sizeof(VIDEOMEMEMORYSIZE) - 1, NULL, 10); } else if (this_opt[0] >= '0' && this_opt[0] <= '9') { mode_option = this_opt; |
From: Mega M. <kl...@us...> - 2012-02-09 22:54:42
|
Update of /cvsroot/kernelloader/kernelloader/loader In directory vz-cvs-3.sog:/tmp/cvs-serv24438/loader Modified Files: loader.c loader.h modules.c modules.h nvram.c nvram.h Log Message: Fix detecting of console region on v12/v13 SCPH-7000x. This should fix DVD video support on these consoles. This is needed to get the Live DVD working. Index: modules.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.c,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** modules.c 1 May 2010 21:53:14 -0000 1.19 --- modules.c 9 Feb 2012 22:54:39 -0000 1.20 *************** *** 20,23 **** --- 20,24 ---- #include "graphic.h" #include "loadermenu.h" + #include "nvram.h" #ifdef NEW_ROM_MODULES *************** *** 57,60 **** --- 58,63 ---- + static char eromdrvpath[] = "rom1:EROMDRVE"; + static moduleLoaderEntry_t moduleList[] = { #if defined(IOP_RESET) && !defined(PS2LINK) *************** *** 417,420 **** --- 420,450 ---- if (rv < 0) { if ((moduleList[i].sms_mod == 0) || (isDVDVSupported())) { + if (moduleList[i].eromdrv != 0) { + rv = open("rom1:EROMDRV", O_RDONLY); + if (rv >=0 ) { + eromdrvpath[12] = 0; + + /* This is an old fat PS2 (working with SCPH-50004 and SCPH-39004). */ + close(rv); + } else { + const u8 *nvm; + + nvm = get_nvram(); + if (nvm[NVM_FAKE_REGION] == version[4]) { + /* NVM layout seems to be correct. */ + eromdrvpath[12] = nvm[NVM_REAL_REGION]; + rv = open(eromdrvpath, O_RDONLY); + if (rv >=0 ) { + /* Region code seems to be correct. */ + close(rv); + } else { + error_printf("Can't find driver for DVD video: \"%s\".", eromdrvpath); + continue; + } + } + } + moduleList[i].args = get_eromdrvpath(); + moduleList[i].argLen = strlen(moduleList[i].args) + 1; + } romfile = rom_getFile(moduleList[i].path); if (romfile != NULL) { *************** *** 429,437 **** } if (rv < 0) { ! printf("Failed to load module \"%s\".", moduleList[i].path); if (moduleList[i].ps2smap && !isSlimPSTwo()) { network_support = 0; } else { ! error_printf("Failed to load module \"%s\".", moduleList[i].path); } } else { --- 459,475 ---- } if (rv < 0) { ! if (moduleList[i].eromdrv != 0) { ! printf("Failed to load module \"%s\".\n", get_eromdrvpath()); ! } else { ! printf("Failed to load module \"%s\".\n", moduleList[i].path); ! } if (moduleList[i].ps2smap && !isSlimPSTwo()) { network_support = 0; } else { ! if (moduleList[i].eromdrv != 0) { ! error_printf("Failed to load module \"%s\".", get_eromdrvpath()); ! } else { ! error_printf("Failed to load module \"%s\".", moduleList[i].path); ! } } } else { *************** *** 493,494 **** --- 531,538 ---- return 0; } + + const char *get_eromdrvpath(void) + { + return eromdrvpath; + } + Index: modules.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/modules.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** modules.h 1 May 2010 21:53:14 -0000 1.6 --- modules.h 9 Feb 2012 22:54:39 -0000 1.7 *************** *** 14,17 **** --- 14,18 ---- int getBiosVersion(void); int hasNetworkSupport(void); + const char *get_eromdrvpath(void); extern char hardware_information[]; Index: nvram.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/nvram.c,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** nvram.c 1 May 2010 21:53:14 -0000 1.1 --- nvram.c 9 Feb 2012 22:54:40 -0000 1.2 *************** *** 81,82 **** --- 81,87 ---- snprintf(ps2_region_type, sizeof(ps2_region_type), "0x%02x 0x%02x (%d NVM errors)", nvm[off->fake_region], nvm[off->real_region], errors); } + + u8 *get_nvram(void) + { + return nvm; + } Index: loader.c =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.c,v retrieving revision 1.40 retrieving revision 1.41 diff -C2 -d -r1.40 -r1.41 *** loader.c 6 Feb 2012 18:18:59 -0000 1.40 --- loader.c 9 Feb 2012 22:54:39 -0000 1.41 *************** *** 121,124 **** --- 121,125 ---- .args = NULL, .defaultmod = 1, + .eromdrv = 1, }, { *************** *** 1414,1417 **** --- 1415,1422 ---- { if (modules[i].load) { + if (modules[i].eromdrv) { + modules[i].args = get_eromdrvpath(); + modules[i].argLen = strlen(modules[i].args) + 1; + } if (modules[i].network) { if (!hasNetworkSupport()) { Index: nvram.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/nvram.h,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** nvram.h 1 May 2010 21:53:14 -0000 1.1 --- nvram.h 9 Feb 2012 22:54:40 -0000 1.2 *************** *** 2,5 **** --- 2,8 ---- #define _NVRAM_H_ + #define NVM_FAKE_REGION 0x185 + #define NVM_REAL_REGION 0x186 + #ifdef __cplusplus extern "C" { *************** *** 10,13 **** --- 13,17 ---- void nvram_init(void); + u8 *get_nvram(void); #ifdef __cplusplus Index: loader.h =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/loader/loader.h,v retrieving revision 1.26 retrieving revision 1.27 diff -C2 -d -r1.26 -r1.27 *** loader.h 5 Apr 2011 21:50:06 -0000 1.26 --- loader.h 9 Feb 2012 22:54:39 -0000 1.27 *************** *** 44,47 **** --- 44,49 ---- /** -1, if module needs network, 0 otherwise. */ int network; + /** True, if module is responsible eromdrv. */ + int eromdrv; } moduleEntry_t; |
From: Mega M. <kl...@us...> - 2012-02-09 22:54:41
|
Update of /cvsroot/kernelloader/kernelloader In directory vz-cvs-3.sog:/tmp/cvs-serv24438 Modified Files: history.txt Log Message: Fix detecting of console region on v12/v13 SCPH-7000x. This should fix DVD video support on these consoles. This is needed to get the Live DVD working. Index: history.txt =================================================================== RCS file: /cvsroot/kernelloader/kernelloader/history.txt,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** history.txt 6 Feb 2012 18:18:59 -0000 1.10 --- history.txt 9 Feb 2012 22:54:39 -0000 1.11 *************** *** 10,13 **** --- 10,16 ---- kernel parameters in menu. - Support video parameters for framebuffer driver of Linux2.6 + - Fix detecting of console region on v12/v13 SCPH-7000x. This + should fix DVD video support on these consoles. This is + needed to get the Live DVD working. 2.4 |