From: Toni Wilen Date: Tue, 6 Mar 2007 18:34:57 +0000 (+0200) Subject: imported winuaesrc1410b1.zip X-Git-Tag: 2100~239 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=ce234b82c47dbed3ee26fb69003dfe7407a66176;p=francis%2Fwinuae.git imported winuaesrc1410b1.zip --- diff --git a/blkdev.c b/blkdev.c index 307e9817..8f8aa028 100755 --- a/blkdev.c +++ b/blkdev.c @@ -27,9 +27,10 @@ extern struct device_functions devicefunc_win32_ioctl; static void install_driver (int flags) { int installed = 0; + device_func[DF_SCSI] = &devicefunc_win32_aspi; #ifdef WINDDK - if (os_winnt && os_winnt_admin) { + if (os_winnt) { device_func[DF_IOCTL] = &devicefunc_win32_ioctl; device_func[DF_SCSI] = &devicefunc_win32_spti; installed = 1; diff --git a/drawing.c b/drawing.c index e6f4559b..c5c28b0d 100755 --- a/drawing.c +++ b/drawing.c @@ -1394,13 +1394,14 @@ STATIC_INLINE void do_color_changes (line_draw_func worker_border, line_draw_fun } } -/* move color changes in horizontal cycles 0 to HBLANK_OFFSET to previous line - * cycles 0 to HBLANK_OFFSET must be visible in right border +/* Move color changes in horizontal cycles 0 to HBLANK_OFFSET - 1 to previous line. + * Cycles 0 to HBLANK_OFFSET are visible in right border on real Amigas. */ -static void mungedip(int lineno) +static void mungedip(int lineno, int next) { int i = dip_for_drawing->last_color_change; - struct draw_info *dip_for_drawing_next = curr_drawinfo + (lineno + 1); + struct draw_info *dip_for_drawing_next = curr_drawinfo + (lineno + next); + if (dip_for_drawing_next->first_color_change == 0) dip_for_drawing_next = curr_drawinfo + (lineno + 2); while (i < dip_for_drawing_next->last_color_change) { @@ -1434,7 +1435,7 @@ static void pfield_draw_line (int lineno, int gfx_ypos, int follow_ypos) dp_for_drawing = line_decisions + lineno; dip_for_drawing = curr_drawinfo + lineno; - mungedip(lineno); + mungedip(lineno, (dp_for_drawing->bplcon0 & 4) ? 2 : 1); switch (linestate[lineno]) { case LINE_REMEMBERED_AS_PREVIOUS: if (!warned) diff --git a/include/drawing.h b/include/drawing.h index 08c6cc24..1ee845e7 100755 --- a/include/drawing.h +++ b/include/drawing.h @@ -265,7 +265,6 @@ enum nln_how { extern void hsync_record_line_state (int lineno, enum nln_how, int changed); extern void vsync_handle_redraw (int long_frame, int lof_changed); extern void init_hardware_for_drawing_frame (void); -extern void finish_drawing_frame (void); extern void reset_drawing (void); extern void drawing_init (void); extern void notice_interlace_seen (void); diff --git a/include/options.h b/include/options.h index f7579338..714bc402 100755 --- a/include/options.h +++ b/include/options.h @@ -9,7 +9,7 @@ #define UAEMAJOR 1 #define UAEMINOR 4 -#define UAESUBREV 0 +#define UAESUBREV 1 typedef enum { KBD_LANG_US, KBD_LANG_DK, KBD_LANG_DE, KBD_LANG_SE, KBD_LANG_FR, KBD_LANG_IT, KBD_LANG_ES } KbdLang; diff --git a/include/scsidev.h b/include/scsidev.h index dafaa14c..fe5fc450 100755 --- a/include/scsidev.h +++ b/include/scsidev.h @@ -17,9 +17,10 @@ void scsi_do_disk_change (int device_id, int insert); extern int log_scsi; #ifdef _WIN32 -#define UAESCSI_SPTI 0 -#define UAESCSI_SPTISCAN 1 -#define UAESCSI_ADAPTECASPI 2 -#define UAESCSI_NEROASPI 3 -#define UAESCSI_FROGASPI 4 +#define UAESCSI_SPTI 1 +#define UAESCSI_SPTISCAN 2 +#define UAESCSI_ASPI_FIRST 3 +#define UAESCSI_ADAPTECASPI 3 +#define UAESCSI_NEROASPI 4 +#define UAESCSI_FROGASPI 5 #endif \ No newline at end of file diff --git a/memory.c b/memory.c index 8acf47ea..504bacb0 100755 --- a/memory.c +++ b/memory.c @@ -1672,7 +1672,7 @@ static int read_kickstart (struct zfile *f, uae_u8 *mem, int size, int dochecksu if (kickdisk && i > 262144) i = 262144; - if (i != 8192 && i != 65536 && i != 131072 && i != 262144 && i != 524288 && i != 524288 * 2) { + if (i != 8192 && i != 65536 && i != 131072 && i != 262144 && i != 524288 && i != 524288 * 2 && i != 524288 * 4) { notify_user (NUMSG_KSROMREADERROR); return 0; } diff --git a/od-win32/mman.c b/od-win32/mman.c index fc652d10..03e1419f 100755 --- a/od-win32/mman.c +++ b/od-win32/mman.c @@ -231,6 +231,10 @@ void *shmat(int shmid, void *shmaddr, int shmflg) got = TRUE; size+=32; } + if(!strcmp(shmids[shmid].name,"rom_a8")) { + shmaddr=natmem_offset+0xa80000; + got = TRUE; + } if(!strcmp(shmids[shmid].name,"rom_e0")) { shmaddr=natmem_offset+0xe00000; got = TRUE; diff --git a/od-win32/parser.c b/od-win32/parser.c index c93a21ba..a840c498 100755 --- a/od-win32/parser.c +++ b/od-win32/parser.c @@ -1201,34 +1201,17 @@ int enumserialports(void) break; } if (j == cnt) { + if (cnt >= MAX_SERIAL_PORTS) + break; comports[j].dev = xmalloc(100); sprintf(comports[cnt].dev, "\\.\\\\%s", name); comports[j].cfgname = my_strdup (name); comports[j].name = my_strdup (name); - write_log("SERPORT: '%s' = '%s' (%s)\n", comports[j].name, comports[j].dev, devname); + write_log("SERPORT: %d:'%s' = '%s' (%s)\n", cnt, comports[j].name, comports[j].dev, devname); cnt++; } } } -#if 0 - { - cnt = 0; - for(port = 0; port < MAX_SERIAL_PORTS; port++) { - COMMCONFIG cc; - sprintf(name, "COM%d", port); - if(GetDefaultCommConfig(name, &cc, &size)) { - if (cnt < MAX_SERIAL_PORTS) { - comports[cnt].dev = xmalloc(100); - sprintf(comports[cnt].dev, "\\.\\\\%s", name); - comports[cnt].cfgname = my_strdup (name); - comports[cnt].name = my_strdup (name); - write_log("SERPORT: '%s' = '%s'\n", comports[cnt].name, comports[cnt].dev); - cnt++; - } - } - } - } -#endif write_log("Serial port enumeration end\n"); return cnt; } diff --git a/od-win32/parser.h b/od-win32/parser.h index 5c801f4d..f5b0b380 100755 --- a/od-win32/parser.h +++ b/od-win32/parser.h @@ -33,7 +33,7 @@ void serialuartbreak (int); extern void unload_ghostscript (void); extern int load_ghostscript (void); -#define MAX_SERIAL_PORTS 8 +#define MAX_SERIAL_PORTS 32 struct serialportinfo { char *dev; diff --git a/od-win32/resources/winuae.rc b/od-win32/resources/winuae.rc index a36fbccf..d0c0981e 100755 --- a/od-win32/resources/winuae.rc +++ b/od-win32/resources/winuae.rc @@ -812,8 +812,8 @@ IDI_PATHS ICON "paths.ico" // VS_VERSION_INFO VERSIONINFO - FILEVERSION 1,4,0,0 - PRODUCTVERSION 1,4,0,0 + FILEVERSION 1,4,1,0 + PRODUCTVERSION 1,4,1,0 FILEFLAGSMASK 0x3fL #ifdef _DEBUG FILEFLAGS 0x1L @@ -829,12 +829,12 @@ BEGIN BLOCK "040904b0" BEGIN VALUE "FileDescription", "WinUAE" - VALUE "FileVersion", "1.4.0" + VALUE "FileVersion", "1.4.1" VALUE "InternalName", "WinUAE" VALUE "LegalCopyright", "© 1996-2007 under the GNU Public License (GPL)" VALUE "OriginalFilename", "WinUAE.exe" VALUE "ProductName", "WinUAE" - VALUE "ProductVersion", "1.4.0" + VALUE "ProductVersion", "1.4.1" END END BLOCK "VarFileInfo" diff --git a/od-win32/serial_win32.c b/od-win32/serial_win32.c index 9fe74e28..f226872f 100755 --- a/od-win32/serial_win32.c +++ b/od-win32/serial_win32.c @@ -235,9 +235,9 @@ void SERDAT (uae_u16 w) if (serper == 372) { extern int enforcermode; if (enforcermode & 2) { - write_log ("%c", dochar (w)); + console_out ("%c", dochar (w)); if (w == 266) - write_log("\n"); + console_out("\n"); } } diff --git a/od-win32/win32.c b/od-win32/win32.c index 6080f13b..8da22a67 100755 --- a/od-win32/win32.c +++ b/od-win32/win32.c @@ -1706,6 +1706,29 @@ uae_u8 *target_load_keyfile (struct uae_prefs *p, char *path, int *sizep, char * extern char *get_aspi_path(int); +static get_aspi(int old) +{ + if ((old == UAESCSI_SPTI || old == UAESCSI_SPTISCAN) && os_winnt && os_winnt_admin) + return old; + if (old == UAESCSI_NEROASPI && get_aspi_path(1)) + return old; + if (old == UAESCSI_FROGASPI && get_aspi_path(2)) + return old; + if (old == UAESCSI_ADAPTECASPI && get_aspi_path(0)) + return old; + if (os_winnt && os_winnt_admin) + return UAESCSI_SPTI; + else if (get_aspi_path(1)) + return UAESCSI_NEROASPI; + else if (get_aspi_path(2)) + return UAESCSI_FROGASPI; + else if (get_aspi_path(0)) + return UAESCSI_ADAPTECASPI; + else if (os_winnt) + return UAESCSI_SPTI; + return UAESCSI_ADAPTECASPI; +} + void target_default_options (struct uae_prefs *p, int type) { if (type == 2 || type == 0) { @@ -1727,18 +1750,19 @@ void target_default_options (struct uae_prefs *p, int type) p->win32_automount_drives = 0; p->win32_automount_netdrives = 0; p->win32_kbledmode = 0; - p->win32_uaescsimode = get_aspi_path(1) ? 2 : ((os_winnt && os_winnt_admin) ? 0 : 1); + p->win32_uaescsimode = get_aspi(p->win32_uaescsimode); p->win32_borderless = 0; p->win32_powersavedisabled = 1; p->win32_outsidemouse = 0; } if (type == 1 || type == 0) { + p->win32_uaescsimode = get_aspi(p->win32_uaescsimode); p->win32_midioutdev = -2; p->win32_midiindev = 0; } } -static const char *scsimode[] = { "SPTI", "SPTI+SCSISCAN", "AdaptecASPI", "NeroASPI", 0 }; +static const char *scsimode[] = { "none", "SPTI", "SPTI+SCSISCAN", "AdaptecASPI", "NeroASPI", "FrogASPI", 0 }; void target_save_options (struct zfile *f, struct uae_prefs *p) { @@ -1827,7 +1851,9 @@ int target_parse_option (struct uae_prefs *p, char *option, char *value) if (cfgfile_yesno (option, value, "aspi", &v)) { p->win32_uaescsimode = 0; if (v) - p->win32_uaescsimode = get_aspi_path(1) ? 2 : 1; + p->win32_uaescsimode = get_aspi(0); + if (p->win32_uaescsimode < UAESCSI_ASPI_FIRST) + p->win32_uaescsimode = UAESCSI_ADAPTECASPI; return 1; } diff --git a/od-win32/win32.h b/od-win32/win32.h index ae44c72b..245f3061 100755 --- a/od-win32/win32.h +++ b/od-win32/win32.h @@ -15,9 +15,9 @@ #define GETBDM(x) (((x) - ((x / 10000) * 10000)) / 100) #define GETBDD(x) ((x) % 100) -#define WINUAEBETA 0 -#define WINUAEPUBLICBETA 0 -#define WINUAEDATE MAKEBD(2007, 3, 3) +#define WINUAEBETA 1 +#define WINUAEPUBLICBETA 1 +#define WINUAEDATE MAKEBD(2007, 3, 6) #define IHF_WINDOWHIDDEN 6 #define NORMAL_WINDOW_STYLE (WS_VISIBLE | WS_BORDER | WS_CAPTION | WS_MINIMIZEBOX | WS_SYSMENU) diff --git a/od-win32/win32gfx.c b/od-win32/win32gfx.c index 8daed516..234e7050 100755 --- a/od-win32/win32gfx.c +++ b/od-win32/win32gfx.c @@ -1002,7 +1002,9 @@ uae_u8 *gfx_lock_picasso (void) #if DX_INV == 0 /* For the DX_Invalidate() and gfx_unlock_picasso() functions */ -static int p96_double_buffer_first, p96_double_buffer_last, p96_double_buffer_needs_flushing = 0; +static int p96_double_buffer_firstx, p96_double_buffer_lastx; +static int p96_double_buffer_first, p96_double_buffer_last; +static int p96_double_buffer_needs_flushing = 0; void gfx_unlock_picasso (void) { @@ -1015,9 +1017,10 @@ void gfx_unlock_picasso (void) relock = TRUE; unlockscr(); } - DX_Blit (0, p96_double_buffer_first, - 0, p96_double_buffer_first, - currentmode->current_width, p96_double_buffer_last - p96_double_buffer_first + 1, + DX_Blit (p96_double_buffer_firstx, p96_double_buffer_first, + p96_double_buffer_firstx, p96_double_buffer_first, + p96_double_buffer_lastx - p96_double_buffer_firstx + 1, + p96_double_buffer_last - p96_double_buffer_first + 1, BLIT_SRC); if (relock) { lockscr(); @@ -1453,15 +1456,20 @@ void DX_SetPalette (int start, int count) void DX_Invalidate (int x, int y, int width, int height) { - int last; + int last, lastx; if (y < 0 || height < 0) { y = 0; height = picasso_vidinfo.height; + x = 0; + width = picasso_vidinfo.width; } last = y + height - 1; + lastx = x + width - 1; p96_double_buffer_first = y; p96_double_buffer_last = last; + p96_double_buffer_firstx = x; + p96_double_buffer_lastx = lastx; p96_double_buffer_needs_flushing = 1; } diff --git a/od-win32/win32gui.c b/od-win32/win32gui.c index b9a92c05..24c9c454 100755 --- a/od-win32/win32gui.c +++ b/od-win32/win32gui.c @@ -4778,12 +4778,12 @@ extern char *get_aspi_path(int); static void misc_scsi(HWND hDlg) { SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_RESETCONTENT, 0, 0); - SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)((os_winnt && os_winnt_admin) ? "SPTI" : "(SPTI)")); - SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)((os_winnt && os_winnt_admin) ? "SPTI + SCSI SCAN" : "(SPTI + SCSI SCAN)")); + SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)(os_winnt ? "SPTI" : "(SPTI)")); + SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)(os_winnt ? "SPTI + SCSI SCAN" : "(SPTI + SCSI SCAN)")); SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)((get_aspi_path(0)) ? "AdaptecASPI" : "(AdaptecASPI)")); SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)((get_aspi_path(1)) ? "NeroASPI" : "(NeroASPI)")); SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_ADDSTRING, 0, (LPARAM)((get_aspi_path(2)) ? "FrogASPI" : "(FrogASPI)")); - SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_SETCURSEL, workprefs.win32_uaescsimode, 0); + SendDlgItemMessage (hDlg, IDC_SCSIMODE, CB_SETCURSEL, workprefs.win32_uaescsimode - 1, 0); } static void misc_lang(HWND hDlg) @@ -4955,7 +4955,7 @@ static INT_PTR MiscDlgProc (HWND hDlg, UINT msg, WPARAM wParam, LPARAM lParam) case IDC_SCSIMODE: v = SendDlgItemMessage(hDlg, IDC_SCSIMODE, CB_GETCURSEL, 0, 0L); if (v != CB_ERR) - workprefs.win32_uaescsimode = v; + workprefs.win32_uaescsimode = v + 1; break; case IDC_LANGUAGE: if (HIWORD (wParam) == CBN_SELENDOK) { diff --git a/od-win32/winuaechangelog.txt b/od-win32/winuaechangelog.txt index 01df1322..74522113 100755 --- a/od-win32/winuaechangelog.txt +++ b/od-win32/winuaechangelog.txt @@ -1,5 +1,17 @@ +Beta 1: + +- default ASPI detection selected (possibly non-existing) AdaptecASPI +- Quickstart automatically selects working SCSI mode (uses setting from + default.uae if available, if not, selects "best" available) +- 120b1 right border update fixed to work in interlaced modes (Unreal) +- serial port "compatibility mode" enumeration added in 140b6 didn't + check if serial port buffer was already full (>=8 devices detected) + Added check and increased size of buffer. + +1.4.0 + Beta 10 (pre-final): - in some cases dskready signal was set active even if floppy drive