ReactOS.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
List overview
Download
Ros-diffs
April 2009
----- 2025 -----
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
ros-diffs@reactos.org
25 participants
476 discussions
Start a n
N
ew thread
[dgorbachev] 40678: Update log2lines tool. Patch by Jan Roeloffzen, with some changes. Bug #4342.
by dgorbachev@svn.reactos.org
Author: dgorbachev Date: Fri Apr 24 16:26:25 2009 New Revision: 40678 URL:
http://svn.reactos.org/svn/reactos?rev=40678&view=rev
Log: Update log2lines tool. Patch by Jan Roeloffzen, with some changes. Bug #4342. Modified: trunk/reactos/tools/log2lines.c Modified: trunk/reactos/tools/log2lines.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/log2lines.c?rev=4067…
============================================================================== --- trunk/reactos/tools/log2lines.c [iso-8859-1] (original) +++ trunk/reactos/tools/log2lines.c [iso-8859-1] Fri Apr 24 16:26:25 2009 @@ -18,7 +18,7 @@ #include "rsym.h" -#define LOG2LINES_VERSION "0.5" +#define LOG2LINES_VERSION "0.6" #define INVALID_BASE 0xFFFFFFFFL @@ -31,6 +31,8 @@ #define PATH_CHAR '\\' #define PATH_STR "\\" #define PATHCMP strcasecmp +#define CP_CMD "copy /Y " +#define DIR_FMT "dir /a:-d /s /b %s > %s" #else /* not defined (__DJGPP__) || defined (__WIN32__) */ @@ -43,12 +45,17 @@ #define PATH_CHAR '/' #define PATH_STR "/" #define PATHCMP strcmp +#define CP_CMD "cp -f " +#define DIR_FMT "find %s -type f > %s" #endif /* not defined (__DJGPP__) || defined (__WIN32__) */ -#define UNZIP_FMT "7z x -y -r %s -o%s > " DEV_NULL +#define CP_FMT CP_CMD "%s %s > " DEV_NULL + +#define CMD_7Z "7z" +#define UNZIP_FMT "%s x -y -r %s -o%s > " DEV_NULL #define UNZIP_FMT_CAB \ -"7z x -y -r %s" PATH_STR "reactos" PATH_STR "reactos.cab -o%s" PATH_STR "reactos" PATH_STR "reactos > " DEV_NULL +"%s x -y -r %s" PATH_STR "reactos" PATH_STR "reactos.cab -o%s" PATH_STR "reactos" PATH_STR "reactos > " DEV_NULL #define LINESIZE 1024 @@ -74,7 +81,7 @@ static CACHE cache; -static char *optchars = "cd:fFhl:mMrv"; +static char *optchars = "cd:fFhl:mMrvz:"; static int opt_help = 0; // -h static int opt_force = 0; // -f static int opt_exit = 0; // -e @@ -85,6 +92,7 @@ static int opt_raw = 0; // -r static char opt_dir[MAX_PATH]; // -d static char opt_logFile[MAX_PATH]; // -l +static char opt_7z[MAX_PATH]; // -z static FILE *logFile = NULL; static char *cache_name; @@ -565,7 +573,7 @@ remove(tmp_name); fprintf(stderr, "Scanning %s ...\n", opt_dir); - snprintf(Line, LINESIZE, "dir /a:-d /s /b %s > %s", opt_dir, tmp_name); + snprintf(Line, LINESIZE, DIR_FMT, opt_dir, tmp_name); system(Line); fprintf(stderr, "Creating cache ..."); @@ -616,14 +624,14 @@ size_t base = 0; CACHE_ENTRY *pentry = NULL; int res = 0; - char *path; + char *path, *dpath; /* First get the ImageBase of the File. If its smaller than the given * Parameter, everything is ok, because it was already added onto the * adress and can be given directly to process_file. If not, add it and * give the result to process_file. */ - path = convert_path(cpath); + dpath = path = convert_path(cpath); if (!path) { return 1; @@ -658,7 +666,7 @@ res = process_file(path, offset, toString); } - free(path); + free(dpath); return res; } @@ -834,7 +842,7 @@ " - The image will be unpacked to a directory with the same name.\n" " - The embedded reactos.cab file will also be unpacked.\n" " - Combined with -f the file will be re-unpacked.\n" -" - NOTE: this ISO unpack feature needs 7z to be in the current PATH.\n" +" - NOTE: this ISO unpack feature needs 7z to be in the PATH.\n" " Default: " DEF_OPT_DIR "\n\n" " -f Force creating new cache.\n\n" " -F As -f but exits immediately after creating cache.\n\n" @@ -849,6 +857,10 @@ " -v Show detailed errors and tracing.\n" " Repeating this option adds more verbosity.\n" " Default: only (major) errors\n" "\n" +" -z <path to 7z>\n" +" Specify path to 7z.\n" +" Default: '7z'\n" +"\n" "Examples:\n" " Setup is a VMware machine with its serial port set to: '\\\\.\\pipe\\kdbg'.\n\n" " Just recreate cache after a svn update or a new module has been added:\n" @@ -882,11 +894,33 @@ { char Line[LINESIZE]; int res = 0; - - sprintf(Line, UNZIP_FMT, iso, dir); + char iso_tmp[MAX_PATH]; + int iso_copied = 0; + FILE *fiso; + + strcpy(iso_tmp, iso); + if ((fiso = fopen(iso, "a")) == NULL) + { + if (opt_verbose) + fprintf(stderr, "Open of %s failed (locked), trying to copy first\n", iso); + + strcat(iso_tmp,"~"); + remove(iso_tmp); + sprintf(Line, CP_FMT, iso, iso_tmp); + if (opt_verbose > 1) + fprintf(stderr, "Executing: %s\n", Line); + system(Line); + iso_copied = 1; + } + else + { + fclose(fiso); + } + + sprintf(Line, UNZIP_FMT, opt_7z, iso_tmp, dir); if (system(Line) < 0) { - fprintf(stderr, "Cannot unpack %s (check 7z path!)\n", iso); + fprintf(stderr, "\nCannot unpack %s (check 7z path!)\n", iso_tmp); if (opt_verbose) fprintf(stderr, "Failed to execute: '%s'\n", Line); res = 1; @@ -894,20 +928,24 @@ else { if (opt_verbose > 1) - fprintf(stderr, "Unpacking reactos.cab in %s\n", dir); - sprintf(Line, UNZIP_FMT_CAB, dir, dir); + fprintf(stderr, "\nUnpacking reactos.cab in %s\n", dir); + sprintf(Line, UNZIP_FMT_CAB, opt_7z, dir, dir); if (system(Line) < 0) { - fprintf(stderr, "Cannot unpack reactos.cab in %s\n", dir); + fprintf(stderr, "\nCannot unpack reactos.cab in %s\n", dir); if (opt_verbose) fprintf(stderr, "Failed to execute: '%s'\n", Line); res = 2; } } + if (iso_copied) + { + remove(iso_tmp); + } return res; } -static void +static int check_directory(int force) { char freeldr_path[MAX_PATH]; @@ -938,6 +976,11 @@ fprintf(stderr, "%s already unpacked in: %s\n", iso_path, opt_dir); } } + else + { + fprintf(stderr, "ISO image not found: %s\n", opt_dir); + return 1; + } } cache_name = malloc(MAX_PATH); tmp_name = malloc(MAX_PATH); @@ -945,6 +988,7 @@ strcat(cache_name, PATH_STR "log2lines.cache"); strcpy(tmp_name, cache_name); strcat(tmp_name, "~"); + return 0; } int @@ -956,6 +1000,7 @@ strcpy(opt_dir, DEF_OPT_DIR); strcpy(opt_logFile, ""); + strcpy(opt_7z, CMD_7Z); while (-1 != (opt = getopt(argc, (char **const)argv, optchars))) { switch (opt) @@ -995,6 +1040,10 @@ case 'v': opt_verbose++; break; + case 'z': + optCount++; + strcpy(opt_7z, optarg); + break; default: usage(0); exit(2); @@ -1010,7 +1059,9 @@ exit(1); } - check_directory(opt_force); + if (check_directory(opt_force)) + exit(3); + create_cache(opt_force, 0); if (opt_exit) exit(0); @@ -1018,7 +1069,20 @@ read_cache(); if (*opt_logFile) + { logFile = fopen(opt_logFile, "a"); + if (logFile) + { + // disable buffering so fflush is not needed + setbuf(logFile,NULL); + } + else + { + fprintf(stderr, "Could not open logfile %s (%s)\n", opt_logFile, strerror(errno)); + exit(2); + + } + } if (argc == 3) { // translate <exefile> <offset> translate_file(argv[optCount + 1], my_atoi(argv[optCount + 2]), NULL);
15 years, 9 months
1
0
0
0
[mjmartin] 40677: - Improved fix for edit control context menu. Send appropriate message based on return value of TrackPopupMenu and remove handling of WM_MENUSELECT as its no longer needed. Patch sent to wine-patches@winehq.org.
by mjmartin@svn.reactos.org
Author: mjmartin Date: Fri Apr 24 16:13:07 2009 New Revision: 40677 URL:
http://svn.reactos.org/svn/reactos?rev=40677&view=rev
Log: - Improved fix for edit control context menu. Send appropriate message based on return value of TrackPopupMenu and remove handling of WM_MENUSELECT as its no longer needed. Patch sent to wine-patches(a)winehq.org. Modified: trunk/reactos/dll/win32/user32/controls/edit.c Modified: trunk/reactos/dll/win32/user32/controls/edit.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/user32/controls/…
============================================================================== --- trunk/reactos/dll/win32/user32/controls/edit.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/user32/controls/edit.c [iso-8859-1] Fri Apr 24 16:13:07 2009 @@ -255,7 +255,6 @@ * WM_XXX message handlers */ static LRESULT EDIT_WM_Char(EDITSTATE *es, WCHAR c); -static void EDIT_WM_MenuSelect(EDITSTATE *es, INT code, INT id, HWND conrtol); static void EDIT_WM_ContextMenu(EDITSTATE *es, INT x, INT y); static void EDIT_WM_Copy(EDITSTATE *es); static LRESULT EDIT_WM_Create(EDITSTATE *es, LPCWSTR name); @@ -945,10 +944,6 @@ case WM_CLEAR: EDIT_WM_Clear(es); - break; - - case WM_MENUSELECT: - EDIT_WM_MenuSelect(es, HIWORD(wParam), LOWORD(wParam), (HWND)lParam); break; case WM_CONTEXTMENU: @@ -4221,48 +4216,6 @@ /********************************************************************* * - * WM_COMMAND - * - */ -static void EDIT_WM_MenuSelect(EDITSTATE *es, INT code, INT id, HWND control) -{ - - static INT MenuSelected; - - if (id != 0) { - MenuSelected = id; - return; - } - - switch (MenuSelected) { - case EM_UNDO: - SendMessageW(es->hwndSelf, WM_UNDO, 0, 0); - break; - case WM_CUT: - SendMessageW(es->hwndSelf, WM_CUT, 0, 0); - break; - case WM_COPY: - SendMessageW(es->hwndSelf, WM_COPY, 0, 0); - break; - case WM_PASTE: - SendMessageW(es->hwndSelf, WM_PASTE, 0, 0); - break; - case WM_CLEAR: - SendMessageW(es->hwndSelf, WM_CLEAR, 0, 0); - break; - case EM_SETSEL: - EDIT_EM_SetSel(es, 0, (UINT)-1, FALSE); - EDIT_EM_ScrollCaret(es); - break; - default: - ERR("unknown menu item, please report\n"); - break; - } -} - - -/********************************************************************* - * * WM_CONTEXTMENU * * Note: the resource files resource/sysres_??.rc cannot define a @@ -4287,6 +4240,8 @@ HMENU popup = GetSubMenu(menu, 0); UINT start = es->selection_start; UINT end = es->selection_end; + + BOOL selectedItem; ORDER_UINT(start, end); @@ -4313,7 +4268,35 @@ y = rc.top + (rc.bottom - rc.top) / 2; } - TrackPopupMenu(popup, TPM_LEFTALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD, x, y, 0, es->hwndSelf, NULL); + selectedItem = TrackPopupMenu(popup, TPM_LEFTALIGN | TPM_RIGHTBUTTON | TPM_RETURNCMD, x, y, 0, es->hwndSelf, NULL); + + switch (selectedItem) { + case EM_UNDO: + SendMessageW(es->hwndSelf, WM_UNDO, 0, 0); + break; + case WM_CUT: + SendMessageW(es->hwndSelf, WM_CUT, 0, 0); + break; + case WM_COPY: + SendMessageW(es->hwndSelf, WM_COPY, 0, 0); + break; + case WM_PASTE: + SendMessageW(es->hwndSelf, WM_PASTE, 0, 0); + break; + case WM_CLEAR: + SendMessageW(es->hwndSelf, WM_CLEAR, 0, 0); + break; + case EM_SETSEL: + EDIT_EM_SetSel(es, 0, (UINT)-1, FALSE); + EDIT_EM_ScrollCaret(es); + break; + case 0: + break; + default: + ERR("unknown menu item, please report\n"); + break; + } + DestroyMenu(menu); }
15 years, 9 months
1
0
0
0
[fireball] 40676: - Fix CDROM device registration: don't hardcode it to 0xE0, but register whatever device FreeLdr starts and which is not reported by BIOS as a hardisk. Fixes setupldr2.
by fireball@svn.reactos.org
Author: fireball Date: Fri Apr 24 16:08:56 2009 New Revision: 40676 URL:
http://svn.reactos.org/svn/reactos?rev=40676&view=rev
Log: - Fix CDROM device registration: don't hardcode it to 0xE0, but register whatever device FreeLdr starts and which is not reported by BIOS as a hardisk. Fixes setupldr2. Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c Modified: trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/freeldr/freeldr/arch/…
============================================================================== --- trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c [iso-8859-1] (original) +++ trunk/reactos/boot/freeldr/freeldr/arch/i386/hardware.c [iso-8859-1] Fri Apr 24 16:08:56 2009 @@ -772,7 +772,8 @@ ULONG DiskCount; ULONG Size; ULONG i; - BOOLEAN Changed; + BOOLEAN Changed, BootDriveReported = FALSE; + CHAR BootPath[512]; /* Count the number of visible drives */ DiskReportError(FALSE); @@ -846,6 +847,9 @@ Int13Drives = (PVOID)(((ULONG_PTR)PartialResourceList) + sizeof(CM_PARTIAL_RESOURCE_LIST)); for (i = 0; i < DiskCount; i++) { + if (BootDrive == 0x80 + i) + BootDriveReported = TRUE; + if (MachDiskGetDriveGeometry(0x80 + i, &Geometry)) { Int13Drives[i].DriveSelect = 0x80 + i; @@ -890,8 +894,16 @@ SetHarddiskIdentifier(DiskKey, 0x80 + i); } - /* Also add one cdrom drive */ - FsRegisterDevice("multi(0)disk(0)cdrom(224)", &DiskVtbl); + /* Get the drive we're booting from */ + MachDiskGetBootPath(BootPath, sizeof(BootPath)); + + /* Add it, if it's a floppy or cdrom */ + if ((BootDrive >= 0x80 && !BootDriveReported) || + DiskIsDriveRemovable(BootDrive)) + { + /* TODO: Check if it's really a cdrom drive */ + FsRegisterDevice(BootPath, &DiskVtbl); + } } static VOID
15 years, 9 months
1
0
0
0
[janderwald] 40675: - Implement VideoPortPutDmaAdapter, VideoPortStartDma, VideoPortCompleteDma, VideoPortLockBuffer, VideoPortUnlockBuffer,
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 24 06:18:30 2009 New Revision: 40675 URL:
http://svn.reactos.org/svn/reactos?rev=40675&view=rev
Log: - Implement VideoPortPutDmaAdapter, VideoPortStartDma, VideoPortCompleteDma, VideoPortLockBuffer, VideoPortUnlockBuffer, Modified: trunk/reactos/drivers/video/videoprt/dma.c trunk/reactos/drivers/video/videoprt/resource.c Modified: trunk/reactos/drivers/video/videoprt/dma.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/videoprt/dma…
============================================================================== --- trunk/reactos/drivers/video/videoprt/dma.c [iso-8859-1] (original) +++ trunk/reactos/drivers/video/videoprt/dma.c [iso-8859-1] Fri Apr 24 06:18:30 2009 @@ -11,6 +11,24 @@ #include <videoprt.h> #define NDEBUG #include <debug.h> + +typedef struct +{ + PDMA_ADAPTER Adapter; + ULONG MapRegisters; + +}VIP_DMA_ADAPTER, *PVIP_DMA_ADAPTER; + +typedef struct +{ + PVOID HwDeviceExtension; + PSCATTER_GATHER_LIST ScatterGatherList; + PEXECUTE_DMA ExecuteDmaRoutine; + PVOID Context; + PVP_DMA_ADAPTER VpDmaAdapter; + +}DMA_START_CONTEXT, *PDMA_START_CONTEXT; + /* PUBLIC FUNCTIONS ***********************************************************/ @@ -26,11 +44,10 @@ IN BOOLEAN CacheEnabled, PVOID Reserved) { - /* Forward to HAL */ - return HalAllocateCommonBuffer((PADAPTER_OBJECT)VpDmaAdapter, - DesiredLength, - LogicalAddress, - CacheEnabled); + PVIP_DMA_ADAPTER Adapter = (PVIP_DMA_ADAPTER)VpDmaAdapter; + + + return Adapter->Adapter->DmaOperations->AllocateCommonBuffer(Adapter->Adapter, DesiredLength, LogicalAddress, CacheEnabled); } /* @@ -45,23 +62,23 @@ IN PVOID VirtualAddress, IN BOOLEAN CacheEnabled) { - /* Forward to HAL */ - HalFreeCommonBuffer((PADAPTER_OBJECT)VpDmaAdapter, - Length, - LogicalAddress, - VirtualAddress, - CacheEnabled); -} - -/* - * @unimplemented + PVIP_DMA_ADAPTER Adapter = (PVIP_DMA_ADAPTER)VpDmaAdapter; + + Adapter->Adapter->DmaOperations->FreeCommonBuffer(Adapter->Adapter, Length, LogicalAddress, VirtualAddress, CacheEnabled); +} + +/* + * @implemented */ VOID NTAPI VideoPortPutDmaAdapter(IN PVOID HwDeviceExtension, IN PVP_DMA_ADAPTER VpDmaAdapter) { - UNIMPLEMENTED; + PVIP_DMA_ADAPTER Adapter = (PVIP_DMA_ADAPTER)VpDmaAdapter; + + Adapter->Adapter->DmaOperations->PutDmaAdapter(Adapter->Adapter); + ExFreePool(Adapter); } /* @@ -75,29 +92,45 @@ DEVICE_DESCRIPTION DeviceDescription; PVIDEO_PORT_DEVICE_EXTENSION DeviceExtension = VIDEO_PORT_GET_DEVICE_EXTENSION(HwDeviceExtension); ULONG NumberOfMapRegisters; - - /* Zero the structure */ + PVIP_DMA_ADAPTER Adapter; + PDMA_ADAPTER DmaAdapter; + + /* Zero the structure */ RtlZeroMemory(&DeviceDescription, - sizeof(DEVICE_DESCRIPTION)); + sizeof(DEVICE_DESCRIPTION)); /* Initialize the structure */ DeviceDescription.Version = DEVICE_DESCRIPTION_VERSION; DeviceDescription.Master = TRUE /* ?? */; - DeviceDescription.DmaWidth = Width8Bits; + DeviceDescription.DmaWidth = Width8Bits; DeviceDescription.DmaSpeed = Compatible; - /* Copy data from caller's device extension */ + /* Copy data from caller's device extension */ DeviceDescription.ScatterGather = VpDeviceExtension->ScatterGather; - DeviceDescription.Dma32BitAddresses = VpDeviceExtension->Dma32BitAddresses; - DeviceDescription.Dma64BitAddresses = VpDeviceExtension->Dma64BitAddresses; - DeviceDescription.MaximumLength = VpDeviceExtension->MaximumLength; + DeviceDescription.Dma32BitAddresses = VpDeviceExtension->Dma32BitAddresses; + DeviceDescription.Dma64BitAddresses = VpDeviceExtension->Dma64BitAddresses; + DeviceDescription.MaximumLength = VpDeviceExtension->MaximumLength; /* Copy data from the internal device extension */ DeviceDescription.BusNumber = DeviceExtension->SystemIoBusNumber; DeviceDescription.InterfaceType = DeviceExtension->AdapterInterfaceType; - return (PVP_DMA_ADAPTER)HalGetAdapter(&DeviceDescription, - &NumberOfMapRegisters); + Adapter = ExAllocatePool(NonPagedPool, sizeof(VIP_DMA_ADAPTER)); + if (!Adapter) + return NULL; + + + DmaAdapter = IoGetDmaAdapter(DeviceExtension->PhysicalDeviceObject, &DeviceDescription, &NumberOfMapRegisters); + if (!DmaAdapter) + { + ExFreePool(Adapter); + return NULL; + } + + Adapter->Adapter = DmaAdapter; + Adapter->MapRegisters = NumberOfMapRegisters; + + return (PVP_DMA_ADAPTER)Adapter; } /* @@ -198,24 +231,91 @@ return FALSE; } -/* - * @unimplemented + +BOOLEAN +NTAPI +SyncScatterRoutine( + IN PVOID Context) +{ + PDMA_START_CONTEXT StartContext = (PDMA_START_CONTEXT)Context; + + StartContext->ExecuteDmaRoutine(StartContext->HwDeviceExtension, StartContext->VpDmaAdapter, (PVP_SCATTER_GATHER_LIST)StartContext->ScatterGatherList, StartContext->Context); + return TRUE; +} + +VOID +NTAPI +ScatterAdapterControl( + IN PDEVICE_OBJECT *DeviceObject, + IN PIRP *Irp, + IN PSCATTER_GATHER_LIST ScatterGather, + IN PVOID Context) +{ + PDMA_START_CONTEXT StartContext = (PDMA_START_CONTEXT)Context; + + StartContext->ScatterGatherList = ScatterGather; + + VideoPortSynchronizeExecution(StartContext->HwDeviceExtension, VpMediumPriority, SyncScatterRoutine, StartContext); + ExFreePool(StartContext); +} + +/* + * @implemented */ VP_STATUS NTAPI VideoPortStartDma(IN PVOID HwDeviceExtension, IN PVP_DMA_ADAPTER VpDmaAdapter, - IN PVOID Mdl, - IN ULONG Offset, - IN OUT PULONG pLength, - IN PEXECUTE_DMA ExecuteDmaRoutine, - IN PVOID Context, - IN BOOLEAN WriteToDevice) -{ - UNIMPLEMENTED; - - /* Lie and return success */ - return NO_ERROR; + IN PVOID Mdl, + IN ULONG Offset, + IN OUT PULONG pLength, + IN PEXECUTE_DMA ExecuteDmaRoutine, + IN PVOID Context, + IN BOOLEAN WriteToDevice) +{ + NTSTATUS Status; + KIRQL OldIrql; + PDMA_START_CONTEXT StartContext; + PVIDEO_PORT_DEVICE_EXTENSION DeviceExtension = VIDEO_PORT_GET_DEVICE_EXTENSION(HwDeviceExtension); + PVIP_DMA_ADAPTER Adapter = (PVIP_DMA_ADAPTER)VpDmaAdapter; + + StartContext = ExAllocatePool(NonPagedPool, sizeof(DMA_START_CONTEXT)); + if (!StartContext) + { + return ERROR_NOT_ENOUGH_MEMORY; + } + + StartContext->Context = Context; + StartContext->ExecuteDmaRoutine = ExecuteDmaRoutine; + StartContext->HwDeviceExtension = HwDeviceExtension; + StartContext->VpDmaAdapter = VpDmaAdapter; + + KeRaiseIrql(DISPATCH_LEVEL, &OldIrql); + + Status = Adapter->Adapter->DmaOperations->GetScatterGatherList(Adapter->Adapter, + DeviceExtension->PhysicalDeviceObject, + Mdl, + MmGetSystemAddressForMdl((PMDL)Mdl), + MmGetMdlByteCount((PMDL)Mdl), + (PDRIVER_LIST_CONTROL)ScatterAdapterControl, + StartContext, + WriteToDevice); + + KeLowerIrql(OldIrql); + + if (!NT_SUCCESS(Status)) + { + *pLength = 0; + ExFreePool(StartContext); + Status = ERROR_NOT_ENOUGH_MEMORY; + } + else + { + Status = NO_ERROR; + } + + /* Return status */ + return Status; } /* @@ -240,7 +340,7 @@ IN DMA_FLAGS DmaFlags) { /* Deprecated */ - return NULL; + return NULL; } /* @@ -258,7 +358,7 @@ } /* - * @unimplemented + * @implemented */ VP_STATUS NTAPI @@ -267,8 +367,12 @@ IN PVP_SCATTER_GATHER_LIST VpScatterGather, IN BOOLEAN WriteToDevice) { - UNIMPLEMENTED; - - /* Lie and return success */ - return NO_ERROR; -} + KIRQL OldIrql; + PVIP_DMA_ADAPTER Adapter = (PVIP_DMA_ADAPTER)VpDmaAdapter; + + KeRaiseIrql(DISPATCH_LEVEL, &OldIrql); + Adapter->Adapter->DmaOperations->PutScatterGatherList(Adapter->Adapter, (PSCATTER_GATHER_LIST)VpScatterGather, WriteToDevice); + KeLowerIrql(OldIrql); + + return NO_ERROR; +} Modified: trunk/reactos/drivers/video/videoprt/resource.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/video/videoprt/res…
============================================================================== --- trunk/reactos/drivers/video/videoprt/resource.c [iso-8859-1] (original) +++ trunk/reactos/drivers/video/videoprt/resource.c [iso-8859-1] Fri Apr 24 06:18:30 2009 @@ -735,7 +735,7 @@ } /* - * @unimplemented + * @implemented */ PVOID NTAPI @@ -745,8 +745,16 @@ IN ULONG Length, IN VP_LOCK_OPERATION Operation) { - UNIMPLEMENTED; - return NULL; + PMDL Mdl; + + Mdl = IoAllocateMdl(BaseAddress, Length, FALSE, FALSE, NULL); + if (!Mdl) + { + return NULL; + } + /* FIXME use seh */ + MmProbeAndLockPages(Mdl, KernelMode,Operation); + return Mdl; } /* @@ -758,7 +766,11 @@ IN PVOID HwDeviceExtension, IN PVOID Mdl) { - UNIMPLEMENTED; + if (Mdl) + { + MmUnlockPages((PMDL)Mdl); + IoFreeMdl(Mdl); + } } /*
15 years, 9 months
1
0
0
0
[janderwald] 40674: - Remove unused file - Fix Es1370mp / Es1371mp driver installation. However, no sound yet. Needs more investigation
by janderwald@svn.reactos.org
Author: janderwald Date: Fri Apr 24 00:33:27 2009 New Revision: 40674 URL:
http://svn.reactos.org/svn/reactos?rev=40674&view=rev
Log: - Remove unused file - Fix Es1370mp / Es1371mp driver installation. However, no sound yet. Needs more investigation Removed: trunk/reactos/drivers/wdm/audio/backpln/portcls/PortWavePci.cpp Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/dma_slave.c trunk/reactos/drivers/wdm/audio/backpln/portcls/interfaces.h Removed: trunk/reactos/drivers/wdm/audio/backpln/portcls/PortWavePci.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/PortWavePci.cpp [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/PortWavePci.cpp (removed) @@ -1,31 +1,0 @@ -/* - ReactOS Operating System - Port Class API / IPort Implementation - - by Andrew Greenwood -*/ - -#include "private.h" - -NTSTATUS -IPortWavePci::NewMasterDmaChannel( - OUT PDMACHANNEL* DmaChannel, - IN PUNKNOWN OuterUnknown, - IN POOL_TYPE PoolType, - IN PRESOURCELIST ResourceList OPTIONAL, - IN BOOL ScatterGather, - IN BOOL Dma32BitAddresses, - IN BOOL Dma64BitAddresses, - IN DMA_WIDTH DmaWidth, - IN DMA_SPEED DmaSpeed, - IN ULONG MaximumLength, - IN ULONG DmaPort) -{ - return STATUS_UNSUCCESSFUL; -} - -VOID -IPortWavePci::Notify( - IN PSERVICEGROUP ServiceGroup) -{ -} Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/dma_slave.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/dma_slave.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/dma_slave.c [iso-8859-1] Fri Apr 24 00:33:27 2009 @@ -1,7 +1,7 @@ /* * COPYRIGHT: See COPYING in the top level directory * PROJECT: ReactOS Kernel Streaming - * FILE: drivers/wdm/audio/backpln/portcls/dma_slave.c + * FILE: drivers/wdm/audio/backpln/portcls/dma_Init.c * PURPOSE: portcls dma support object * PROGRAMMER: Johannes Anderwald */ @@ -11,7 +11,7 @@ typedef struct { - IDmaChannelSlaveVtbl *lpVtbl; + IDmaChannelInitVtbl *lpVtbl; LONG ref; @@ -36,10 +36,7 @@ PMDL Mdl; BOOLEAN WriteToDevice; -}IDmaChannelSlaveImpl; - -const GUID IID_IDmaChannel; - +}IDmaChannelInitImpl; //--------------------------------------------------------------- // IUnknown methods @@ -48,12 +45,12 @@ NTSTATUS NTAPI -IDmaChannelSlave_fnQueryInterface( - IDmaChannelSlave * iface, +IDmaChannelInit_fnQueryInterface( + IDmaChannelInit * iface, IN REFIID refiid, OUT PVOID* Output) { - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; if (IsEqualGUIDAligned(refiid, &IID_IUnknown) || IsEqualGUIDAligned(refiid, &IID_IDmaChannel) || @@ -63,32 +60,32 @@ InterlockedIncrement(&This->ref); return STATUS_SUCCESS; } - + DPRINT1("No interface!!!\n"); return STATUS_UNSUCCESSFUL; } ULONG -STDMETHODCALLTYPE -IDmaChannelSlave_fnAddRef( - IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_AddRef: This %p\n", This); +NTAPI +IDmaChannelInit_fnAddRef( + IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_AddRef: This %p\n", This); return InterlockedIncrement(&This->ref); } ULONG -STDMETHODCALLTYPE -IDmaChannelSlave_fnRelease( - IDmaChannelSlave* iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; +NTAPI +IDmaChannelInit_fnRelease( + IDmaChannelInit* iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; InterlockedDecrement(&This->ref); - DPRINT("IDmaChannelSlave_Release: This %p new ref %u\n", This, This->ref); + DPRINT("IDmaChannelInit_Release: This %p new ref %u\n", This, This->ref); if (This->ref == 0) { @@ -104,91 +101,94 @@ // IDmaChannel methods // - NTSTATUS NTAPI -IDmaChannelSlave_fnAllocateBuffer( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnAllocateBuffer( + IN IDmaChannelInit * iface, IN ULONG BufferSize, IN PPHYSICAL_ADDRESS PhysicalAddressConstraint OPTIONAL) { - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); /* Did the caller already allocate a buffer ?*/ if (This->Buffer) { - DPRINT1("IDmaChannelSlave_AllocateBuffer free common buffer first \n"); + DPRINT1("IDmaChannelInit_AllocateBuffer free common buffer first \n"); return STATUS_UNSUCCESSFUL; } This->Buffer = This->pAdapter->DmaOperations->AllocateCommonBuffer(This->pAdapter, BufferSize, &This->Address, FALSE); if (!This->Buffer) { - DPRINT1("IDmaChannelSlave_AllocateBuffer fAllocateCommonBuffer failed \n"); + DPRINT1("IDmaChannelInit_AllocateBuffer fAllocateCommonBuffer failed \n"); return STATUS_UNSUCCESSFUL; } This->BufferSize = BufferSize; This->AllocatedBufferSize = BufferSize; - DPRINT1("IDmaChannelSlave_fnAllocateBuffer Success Buffer %p BufferSize %u Address %x\n", This->Buffer, BufferSize, This->Address); + DPRINT1("IDmaChannelInit_fnAllocateBuffer Success Buffer %p BufferSize %u Address %x\n", This->Buffer, BufferSize, This->Address); return STATUS_SUCCESS; } ULONG NTAPI -IDmaChannelSlave_fnAllocatedBufferSize( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_AllocatedBufferSize: This %p BufferSize %u\n", This, This->BufferSize); +IDmaChannelInit_fnAllocatedBufferSize( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_AllocatedBufferSize: This %p BufferSize %u\n", This, This->BufferSize); return This->AllocatedBufferSize; } VOID NTAPI -IDmaChannelSlave_fnCopyFrom( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnCopyFrom( + IN IDmaChannelInit * iface, IN PVOID Destination, IN PVOID Source, IN ULONG ByteCount ) { - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_CopyFrom: This %p Destination %p Source %p ByteCount %u\n", This, Destination, Source, ByteCount); + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_CopyFrom: This %p Destination %p Source %p ByteCount %u\n", This, Destination, Source, ByteCount); iface->lpVtbl->CopyTo(iface, Destination, Source, ByteCount); } VOID NTAPI -IDmaChannelSlave_fnCopyTo( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnCopyTo( + IN IDmaChannelInit * iface, IN PVOID Destination, IN PVOID Source, IN ULONG ByteCount ) { - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_CopyTo: This %p Destination %p Source %p ByteCount %u\n", This, Destination, Source, ByteCount); + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_CopyTo: This %p Destination %p Source %p ByteCount %u\n", This, Destination, Source, ByteCount); RtlCopyMemory(Destination, Source, ByteCount); } VOID NTAPI -IDmaChannelSlave_fnFreeBuffer( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_FreeBuffer: This %p\n", This); +IDmaChannelInit_fnFreeBuffer( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_FreeBuffer: This %p\n", This); + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->Buffer) { - DPRINT1("IDmaChannelSlave_FreeBuffer allocate common buffer first \n"); + DPRINT1("IDmaChannelInit_FreeBuffer allocate common buffer first \n"); return; } @@ -206,59 +206,60 @@ PADAPTER_OBJECT NTAPI -IDmaChannelSlave_fnGetAdapterObject( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_GetAdapterObject: This %p\n", This); +IDmaChannelInit_fnGetAdapterObject( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_GetAdapterObject: This %p\n", This); return (PADAPTER_OBJECT)This->pAdapter; } ULONG NTAPI -IDmaChannelSlave_fnMaximumBufferSize( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_MaximumBufferSize: This %p\n", This); +IDmaChannelInit_fnMaximumBufferSize( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_MaximumBufferSize: This %p\n", This); return This->MaximumBufferSize; } PHYSICAL_ADDRESS NTAPI -IDmaChannelSlave_fnPhysicalAdress( - IN IDmaChannelSlave * iface) -{ - PHYSICAL_ADDRESS Address; - - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - DPRINT("IDmaChannelSlave_PhysicalAdress: This %p Virtuell %p Physical High %x Low %x%\n", This, This->Buffer, This->Address.HighPart, This->Address.LowPart); - - Address = This->Address; - return Address; +IDmaChannelInit_fnPhysicalAdress( + IN IDmaChannelInit * iface, + PPHYSICAL_ADDRESS Address) +{ + PHYSICAL_ADDRESS Result; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + DPRINT("IDmaChannelInit_PhysicalAdress: This %p Virtuell %p Physical High %x Low %x%\n", This, This->Buffer, This->Address.HighPart, This->Address.LowPart); + + Address->QuadPart = This->Address.QuadPart; + Result.QuadPart = (PtrToUlong(Address)); + return Result; } VOID NTAPI -IDmaChannelSlave_fnSetBufferSize( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnSetBufferSize( + IN IDmaChannelInit * iface, IN ULONG BufferSize) { - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_SetBufferSize: This %p\n", This); + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_SetBufferSize: This %p\n", This); This->BufferSize = BufferSize; } ULONG NTAPI -IDmaChannelSlave_fnBufferSize( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; +IDmaChannelInit_fnBufferSize( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; return This->BufferSize; } @@ -266,33 +267,35 @@ PVOID NTAPI -IDmaChannelSlave_fnSystemAddress( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_SystemAddress: This %p\n", This); +IDmaChannelInit_fnSystemAddress( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_SystemAddress: This %p\n", This); return This->Buffer; } ULONG NTAPI -IDmaChannelSlave_fnTransferCount( - IN IDmaChannelSlave * iface) -{ - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_TransferCount: This %p\n", This); +IDmaChannelInit_fnTransferCount( + IN IDmaChannelInit * iface) +{ + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_TransferCount: This %p\n", This); return This->LastTransferCount; } ULONG NTAPI -IDmaChannelSlave_fnReadCounter( - IN IDmaChannelSlave * iface) +IDmaChannelInit_fnReadCounter( + IN IDmaChannelInit * iface) { ULONG Counter; - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + ASSERT_IRQL(DISPATCH_LEVEL); Counter = This->pAdapter->DmaOperations->ReadDmaCounter(This->pAdapter); @@ -311,7 +314,7 @@ IN PVOID Context) { ULONG Length; - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)Context; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)Context; Length = This->MapSize; This->MapRegisterBase = MapRegisterBase; @@ -333,17 +336,19 @@ NTSTATUS NTAPI -IDmaChannelSlave_fnStart( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnStart( + IN IDmaChannelInit * iface, ULONG MapSize, BOOLEAN WriteToDevice) { NTSTATUS Status; ULONG MapRegisters; KIRQL OldIrql; - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_Start: This %p\n", This); + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_Start: This %p\n", This); + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->DmaStarted) return STATUS_UNSUCCESSFUL; @@ -379,13 +384,14 @@ NTSTATUS NTAPI -IDmaChannelSlave_fnStop( - IN IDmaChannelSlave * iface) +IDmaChannelInit_fnStop( + IN IDmaChannelInit * iface) { KIRQL OldIrql; - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; - - DPRINT("IDmaChannelSlave_fnStop: This %p\n", This); + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + DPRINT("IDmaChannelInit_fnStop: This %p\n", This); + ASSERT_IRQL(DISPATCH_LEVEL); if (!This->DmaStarted) return STATUS_SUCCESS; @@ -413,15 +419,17 @@ NTSTATUS NTAPI -IDmaChannelSlave_fnWaitForTC( - IN IDmaChannelSlave * iface, +IDmaChannelInit_fnWaitForTC( + IN IDmaChannelInit * iface, ULONG Timeout) { ULONG RetryCount; ULONG BytesRemaining; ULONG PrevBytesRemaining; - IDmaChannelSlaveImpl * This = (IDmaChannelSlaveImpl*)iface; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); BytesRemaining = This->pAdapter->DmaOperations->ReadDmaCounter(This->pAdapter); if (!BytesRemaining) @@ -454,30 +462,73 @@ } -IDmaChannelSlaveVtbl vt_IDmaChannelSlaveVtbl = +NTSTATUS +NTAPI +IDmaChannelInit_fnInit( + IN IDmaChannelInit * iface, + IN PDEVICE_DESCRIPTION DeviceDescription, + IN PDEVICE_OBJECT DeviceObject) +{ + INTERFACE_TYPE BusType; + NTSTATUS Status; + PDMA_ADAPTER Adapter; + PPCLASS_DEVICE_EXTENSION DeviceExt; + ULONG MapRegisters; + ULONG ResultLength; + IDmaChannelInitImpl * This = (IDmaChannelInitImpl*)iface; + + /* Get bus type */ + Status = IoGetDeviceProperty(DeviceObject, DevicePropertyLegacyBusType, sizeof(BusType), (PVOID)&BusType, &ResultLength); + if (NT_SUCCESS(Status)) + { + DeviceDescription->InterfaceType = BusType; + } + /* Fetch device extension */ + DeviceExt = (PPCLASS_DEVICE_EXTENSION) DeviceObject->DeviceExtension; + /* Acquire dma adapter */ + Adapter = IoGetDmaAdapter(DeviceExt->PhysicalDeviceObject, DeviceDescription, &MapRegisters); + if (!Adapter) + { + FreeItem(This, TAG_PORTCLASS); + return STATUS_DEVICE_CONFIGURATION_ERROR; + } + + /* initialize object */ + This->ref = 1; + This->pAdapter = Adapter; + This->pDeviceObject = DeviceObject; + This->MaximumBufferSize = DeviceDescription->MaximumLength; + This->MaxMapRegisters = MapRegisters; + + return STATUS_SUCCESS; +} + + +IDmaChannelInitVtbl vt_IDmaChannelInitVtbl = { /* IUnknown methods */ - IDmaChannelSlave_fnQueryInterface, - IDmaChannelSlave_fnAddRef, - IDmaChannelSlave_fnRelease, + IDmaChannelInit_fnQueryInterface, + IDmaChannelInit_fnAddRef, + IDmaChannelInit_fnRelease, /* IDmaChannel methods */ - IDmaChannelSlave_fnAllocateBuffer, - IDmaChannelSlave_fnFreeBuffer, - IDmaChannelSlave_fnTransferCount, - IDmaChannelSlave_fnMaximumBufferSize, - IDmaChannelSlave_fnAllocatedBufferSize, - IDmaChannelSlave_fnBufferSize, - IDmaChannelSlave_fnSetBufferSize, - IDmaChannelSlave_fnSystemAddress, - IDmaChannelSlave_fnPhysicalAdress, - IDmaChannelSlave_fnGetAdapterObject, - IDmaChannelSlave_fnCopyTo, - IDmaChannelSlave_fnCopyFrom, - /* IDmaChannelSlave methods */ - IDmaChannelSlave_fnStart, - IDmaChannelSlave_fnStop, - IDmaChannelSlave_fnReadCounter, - IDmaChannelSlave_fnWaitForTC + IDmaChannelInit_fnAllocateBuffer, + IDmaChannelInit_fnFreeBuffer, + IDmaChannelInit_fnTransferCount, + IDmaChannelInit_fnMaximumBufferSize, + IDmaChannelInit_fnAllocatedBufferSize, + IDmaChannelInit_fnBufferSize, + IDmaChannelInit_fnSetBufferSize, + IDmaChannelInit_fnSystemAddress, + IDmaChannelInit_fnPhysicalAdress, + IDmaChannelInit_fnGetAdapterObject, + IDmaChannelInit_fnCopyTo, + IDmaChannelInit_fnCopyFrom, + /* IDmaChannelInit methods */ + IDmaChannelInit_fnStart, + IDmaChannelInit_fnStop, + IDmaChannelInit_fnReadCounter, + IDmaChannelInit_fnWaitForTC, + IDmaChannelInit_fnInit }; @@ -493,48 +544,26 @@ IN PDEVICE_OBJECT DeviceObject) { NTSTATUS Status; - PDMA_ADAPTER Adapter; - ULONG MapRegisters; - INTERFACE_TYPE BusType; - ULONG ResultLength; - PPCLASS_DEVICE_EXTENSION DeviceExt; - - IDmaChannelSlaveImpl * This; + IDmaChannelInitImpl * This; DPRINT("OutDmaChannel %p OuterUnknown %p PoolType %p DeviceDescription %p DeviceObject %p\n", OutDmaChannel, OuterUnknown, PoolType, DeviceDescription, DeviceObject); - This = AllocateItem(PoolType, sizeof(IDmaChannelSlaveImpl), TAG_PORTCLASS); + This = AllocateItem(PoolType, sizeof(IDmaChannelInitImpl), TAG_PORTCLASS); if (!This) { return STATUS_INSUFFICIENT_RESOURCES; } - DeviceExt = (PPCLASS_DEVICE_EXTENSION) DeviceObject->DeviceExtension; - - Status = IoGetDeviceProperty(DeviceObject, DevicePropertyLegacyBusType, sizeof(BusType), (PVOID)&BusType, &ResultLength); + /* initialize object */ + Status = IDmaChannelInit_fnInit((IDmaChannelInit*)This, DeviceDescription, DeviceObject); if (NT_SUCCESS(Status)) { - DeviceDescription->InterfaceType = BusType; - } - - Adapter = IoGetDmaAdapter(DeviceExt->PhysicalDeviceObject, DeviceDescription, &MapRegisters); - if (!Adapter) - { - FreeItem(This, TAG_PORTCLASS); - return STATUS_DEVICE_CONFIGURATION_ERROR; - } - - /* initialize object */ - This->ref = 1; - This->lpVtbl = &vt_IDmaChannelSlaveVtbl; - This->pAdapter = Adapter; - This->pDeviceObject = DeviceObject; - This->MaximumBufferSize = DeviceDescription->MaximumLength; - This->MaxMapRegisters = MapRegisters; - - *OutDmaChannel = (PVOID)(&This->lpVtbl); - DPRINT("PcNewDmaChannel result %p\n", *OutDmaChannel); - return STATUS_SUCCESS; - -} + /* store result */ + This->lpVtbl = &vt_IDmaChannelInitVtbl; + *OutDmaChannel = (PVOID)(&This->lpVtbl); + } + + return Status; + +} Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/interfaces.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/interfaces.h [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/interfaces.h [iso-8859-1] Fri Apr 24 00:33:27 2009 @@ -520,4 +520,60 @@ STDMETHOD_(PMINIPORT, GetMiniport)(THIS); }; +/***************************************************************************** + * IDmaChannelInit + ***************************************************************************** + */ + +#undef INTERFACE +#define INTERFACE IDmaChannelInit + +DECLARE_INTERFACE_(IDmaChannelInit, IUnknown) +{ + DEFINE_ABSTRACT_UNKNOWN() + + STDMETHOD_(NTSTATUS,AllocateBuffer)(THIS_ + IN ULONG BufferSize, + IN PPHYSICAL_ADDRESS PhysicalAddressConstraint OPTIONAL); + + STDMETHOD_(VOID, FreeBuffer)(THIS); + STDMETHOD_(ULONG, TransferCount)(THIS); + STDMETHOD_(ULONG, MaximumBufferSize)(THIS); + STDMETHOD_(ULONG, AllocatedBufferSize)(THIS); + STDMETHOD_(ULONG, BufferSize)(THIS); + + STDMETHOD_(VOID, SetBufferSize)(THIS_ + IN ULONG BufferSize); + + STDMETHOD_(PVOID, SystemAddress)(THIS); + STDMETHOD_(PHYSICAL_ADDRESS, PhysicalAddress)(THIS_ + IN PPHYSICAL_ADDRESS Address); + + STDMETHOD_(PADAPTER_OBJECT, GetAdapterObject)(THIS); + + STDMETHOD_(VOID, CopyTo)(THIS_ + IN PVOID Destination, + IN PVOID Source, + IN ULONG ByteCount); + + STDMETHOD_(VOID, CopyFrom)(THIS_ + IN PVOID Destination, + IN PVOID Source, + IN ULONG ByteCount); + + STDMETHOD_(NTSTATUS, Start)( THIS_ + IN ULONG MapSize, + IN BOOLEAN WriteToDevice) PURE; + + STDMETHOD_(NTSTATUS, Stop)( THIS ) PURE; + STDMETHOD_(ULONG, ReadCounter)( THIS ) PURE; + + STDMETHOD_(NTSTATUS, WaitForTC)( THIS_ + ULONG Timeout) PURE; + + STDMETHOD_(NTSTATUS, Init)( THIS_ + IN PDEVICE_DESCRIPTION DeviceDescription, + IN PDEVICE_OBJECT DeviceObject) PURE; +}; + #endif
15 years, 9 months
1
0
0
0
[cgutman] 40673: - Allocate memory for the OOB area also - Set the NdisPacketOobOffset in each packet - Fixes the mysterious packet corruption - Fixes Realtek 8139 and Intel PRO/1000
by cgutman@svn.reactos.org
Author: cgutman Date: Fri Apr 24 00:00:36 2009 New Revision: 40673 URL:
http://svn.reactos.org/svn/reactos?rev=40673&view=rev
Log: - Allocate memory for the OOB area also - Set the NdisPacketOobOffset in each packet - Fixes the mysterious packet corruption - Fixes Realtek 8139 and Intel PRO/1000 Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/ndis/ndis/…
============================================================================== --- trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] Fri Apr 24 00:00:36 2009 @@ -428,6 +428,7 @@ Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS; + Temp->Private.NdisPacketOobOffset = Pool->PacketLength - sizeof(NDIS_PACKET_OOB_DATA); *Packet = Temp; *Status = NDIS_STATUS_SUCCESS; @@ -506,7 +507,7 @@ NumberOfDescriptors = 0xffff; } - Length = sizeof(NDIS_PACKET) + ProtocolReservedLength; + Length = sizeof(NDIS_PACKET) + sizeof(NDIS_PACKET_OOB_DATA) + ProtocolReservedLength; Size = sizeof(NDISI_PACKET_POOL) + Length * NumberOfDescriptors; Pool = ExAllocatePool(NonPagedPool, Size); @@ -711,6 +712,7 @@ Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS; + Temp->Private.NdisPacketOobOffset = Pool->PacketLength - sizeof(NDIS_PACKET_OOB_DATA); *Packet = Temp; *Status = NDIS_STATUS_SUCCESS; @@ -760,6 +762,7 @@ Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS; + Temp->Private.NdisPacketOobOffset = Pool->PacketLength - sizeof(NDIS_PACKET_OOB_DATA); *Packet = Temp; *Status = NDIS_STATUS_SUCCESS;
15 years, 9 months
1
0
0
0
[janderwald] 40672: - Add tons of ASSERT_IRQL / ASSERT_IRQL_EQUAL - Queue a dpc when IServiceGroup::RequestService is called above dispatch level - As a result writing to common buffer and completing irps can be done at the same time - Start the stream at PASSIVE_LEVEL - Check if key has been deleted in IRegistryKey object function - Implement IRegistryKey::QueryRegistryValues
by janderwald@svn.reactos.org
Author: janderwald Date: Thu Apr 23 23:06:36 2009 New Revision: 40672 URL:
http://svn.reactos.org/svn/reactos?rev=40672&view=rev
Log: - Add tons of ASSERT_IRQL / ASSERT_IRQL_EQUAL - Queue a dpc when IServiceGroup::RequestService is called above dispatch level - As a result writing to common buffer and completing irps can be done at the same time - Start the stream at PASSIVE_LEVEL - Check if key has been deleted in IRegistryKey object function - Implement IRegistryKey::QueryRegistryValues Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/adapter.c trunk/reactos/drivers/wdm/audio/backpln/portcls/api.c trunk/reactos/drivers/wdm/audio/backpln/portcls/connection.c trunk/reactos/drivers/wdm/audio/backpln/portcls/drm.c trunk/reactos/drivers/wdm/audio/backpln/portcls/drm_port.c trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c trunk/reactos/drivers/wdm/audio/backpln/portcls/irp.c trunk/reactos/drivers/wdm/audio/backpln/portcls/irpstream.c trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport.c trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport_dmus.c trunk/reactos/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_dmus.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_midi.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_topology.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavecyclic.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepci.c trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepcistream.c trunk/reactos/drivers/wdm/audio/backpln/portcls/power.c trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h trunk/reactos/drivers/wdm/audio/backpln/portcls/registry.c trunk/reactos/drivers/wdm/audio/backpln/portcls/resource.c trunk/reactos/drivers/wdm/audio/backpln/portcls/service_group.c Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/adapter.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/adapter.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/adapter.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -46,6 +46,7 @@ //ULONG i; DPRINT1("PcInitializeAdapterDriver\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); /* Our IRP handlers */ DPRINT1("Setting IRP handlers\n"); @@ -94,6 +95,7 @@ PPCLASS_DEVICE_EXTENSION portcls_ext = NULL; DPRINT1("PcAddAdapterDevice called\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!DriverObject || !PhysicalDeviceObject || !StartDevice) { @@ -223,6 +225,7 @@ ULONG Index; DPRINT1("PcRegisterSubdevice DeviceObject %p Name %S Unknown %p\n", DeviceObject, Name, Unknown); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); /* check if all parameters are valid */ if (!DeviceObject || !Name || !Unknown) Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/api.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/api.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/api.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -20,6 +20,7 @@ OUT PVOID PropertyBuffer, OUT PULONG ResultLength) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return IoGetDeviceProperty(DeviceObject, DeviceProperty, BufferLength, PropertyBuffer, ResultLength); } @@ -49,6 +50,7 @@ { NTSTATUS Status; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); /* FIXME * check if timer is already used @@ -74,6 +76,8 @@ IN PIO_TIMER_ROUTINE pTimerRoutine, IN PVOID pContext) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + /* FIXME * check if timer is already used */ @@ -93,6 +97,7 @@ IN NTSTATUS NtStatus) { /* sanity checks */ + ASSERT_IRQL(DISPATCH_LEVEL); if (!PropertyRequest) return STATUS_INVALID_PARAMETER; Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/connection.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/connection.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/connection.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -114,8 +114,8 @@ IN PUNKNOWN ToUnknown, IN ULONG ToPin) { - DPRINT("PcRegisterPhysicalConnection\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!DeviceObject || !FromUnknown || !ToUnknown) return STATUS_INVALID_PARAMETER; @@ -134,6 +134,8 @@ IN PUNKNOWN ToUnknown, IN ULONG ToPin) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!DeviceObject || !FromString || !ToUnknown) return STATUS_INVALID_PARAMETER; @@ -151,6 +153,8 @@ IN PUNICODE_STRING ToString, IN ULONG ToPin) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!DeviceObject || !FromUnknown || !ToString) return STATUS_INVALID_PARAMETER; Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/drm.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/drm.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/drm.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -18,6 +18,7 @@ IN PVOID *paHandlers, IN ULONG NumHandlers) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmAddContentHandlers(ContentId, paHandlers, NumHandlers); } @@ -31,6 +32,7 @@ IN ULONG cContentId, OUT PULONG pMixedContentId) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmCreateContentMixed(paContentId, cContentId, pMixedContentId); } @@ -42,6 +44,7 @@ PcDestroyContent( IN ULONG ContentId) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmDestroyContent(ContentId); } @@ -55,6 +58,7 @@ IN PVOID Reserved, IN PCDRMFORWARD DrmForward) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmForwardContentToDeviceObject(ContentId, Reserved, DrmForward); } @@ -67,6 +71,7 @@ IN ULONG ContentId, IN PFILE_OBJECT FileObject) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmForwardContentToFileObject(ContentId, FileObject); } @@ -92,5 +97,6 @@ IN ULONG ContentId, OUT PDRMRIGHTS DrmRights) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmGetContentRights(ContentId, DrmRights); } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/drm_port.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/drm_port.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/drm_port.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -79,6 +79,7 @@ IN ULONG cContentId, OUT PULONG pMixedContentId) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmCreateContentMixed(paContentId, cContentId, pMixedContentId); } @@ -88,6 +89,7 @@ IN IDrmPort2 * iface, IN ULONG ContentId) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmDestroyContent(ContentId); } @@ -109,6 +111,7 @@ IN PUNKNOWN pUnknown, IN ULONG NumMethods) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmForwardContentToInterface(ContentId, pUnknown, NumMethods); } @@ -119,6 +122,7 @@ IN ULONG ContentId, OUT PDRMRIGHTS DrmRights) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmGetContentRights(ContentId, DrmRights); } @@ -130,6 +134,7 @@ IN PVOID * paHandlers, IN ULONG NumHandlers) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmAddContentHandlers(ContentId, paHandlers, NumHandlers); } @@ -141,6 +146,7 @@ IN PVOID Reserved, IN PCDRMFORWARD DrmForward) { + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return DrmForwardContentToDeviceObject(ContentId, Reserved, DrmForward); } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/interrupt.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -242,6 +242,7 @@ PCM_PARTIAL_RESOURCE_DESCRIPTOR Descriptor; DPRINT("IInterruptSync_fnConnect\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); Descriptor = This->ResourceList->lpVtbl->FindTranslatedEntry(This->ResourceList, CmResourceTypeInterrupt, This->ResourceIndex); if (!Descriptor) @@ -273,7 +274,9 @@ IN IInterruptSync * iface) { IInterruptSyncImpl * This = (IInterruptSyncImpl*)iface; + DPRINT("IInterruptSync_fnDisconnect\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->Interrupt) { @@ -297,6 +300,7 @@ IInterruptSyncImpl * This = (IInterruptSyncImpl*)iface; DPRINT("IInterruptSync_fnRegisterServiceRoutine\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); NewEntry = AllocateItem(NonPagedPool, sizeof(SYNC_ENTRY), TAG_PORTCLASS); if (!NewEntry) Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/irp.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/irp.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/irp.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -291,6 +291,8 @@ PPCLASS_DEVICE_EXTENSION DeviceExt; NTSTATUS Status; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + DeviceExt = (PPCLASS_DEVICE_EXTENSION)DeviceObject->DeviceExtension; /* initialize the notification event */ Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/irpstream.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/irpstream.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/irpstream.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -13,7 +13,6 @@ LIST_ENTRY Entry; KSSTREAM_HEADER *Header; PIRP Irp; - KDPC Dpc; ULONG NumTags; PVOID * Tag; @@ -48,15 +47,9 @@ VOID NTAPI -DpcRoutine( - IN struct _KDPC *Dpc, - IN PVOID DeferredContext, - IN PVOID SystemArgument1, - IN PVOID SystemArgument2) -{ - PIRP_MAPPING CurMapping; - - CurMapping = (PIRP_MAPPING)SystemArgument1; +FreeMappingRoutine( + PIRP_MAPPING CurMapping) +{ ASSERT(CurMapping); if (CurMapping->Irp) @@ -159,8 +152,6 @@ Mapping->Header = (KSSTREAM_HEADER*)Buffer; Mapping->Irp = Irp; - KeInitializeDpc(&Mapping->Dpc, DpcRoutine, (PVOID)Mapping); - KeSetImportanceDpc(&Mapping->Dpc, HighImportance); if (This->MaxFrameSize) { @@ -215,7 +206,7 @@ IN ULONG BytesWritten) { IIrpQueueImpl * This = (IIrpQueueImpl*)iface; - PIRP_MAPPING Mapping; + PIRP_MAPPING Mapping, CurMapping; This->CurrentOffset += BytesWritten; This->NumDataAvailable -= BytesWritten; @@ -224,11 +215,12 @@ { This->CurrentOffset = 0; Mapping = (PIRP_MAPPING)ExInterlockedRemoveHeadList(&This->ListHead, &This->Lock); - + CurMapping = This->FirstMap; + + (void)InterlockedExchangePointer((PVOID volatile*)&This->FirstMap, (PVOID)Mapping); InterlockedDecrement(&This->NumMappings); - KeInsertQueueDpc(&This->FirstMap->Dpc, (PVOID)This->FirstMap, NULL); - (void)InterlockedExchangePointer((PVOID volatile*)&This->FirstMap, (PVOID)Mapping); + FreeMappingRoutine(CurMapping); } } @@ -279,6 +271,9 @@ IIrpQueue_fnCancelBuffers( IN IIrpQueue *iface) { + IIrpQueueImpl * This = (IIrpQueueImpl*)iface; + + This->StartStream = FALSE; return TRUE; } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -19,6 +19,7 @@ NTSTATUS Status = STATUS_INVALID_PARAMETER; DPRINT("PcNewMiniport entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!OutMiniport) { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport_dmus.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport_dmus.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/miniport_dmus.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -21,7 +21,7 @@ /* IUnknown methods */ NTSTATUS -STDMETHODCALLTYPE +NTAPI IMiniportDMus_fnQueryInterface( IMiniportDMus* iface, IN REFIID refiid, @@ -39,7 +39,7 @@ } ULONG -STDMETHODCALLTYPE +NTAPI IMiniportDMus_fnAddRef( IMiniportDMus* iface) { @@ -49,7 +49,7 @@ } ULONG -STDMETHODCALLTYPE +NTAPI IMiniportDMust_fnRelease( IMiniportDMus* iface) { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/pin_wavecyclic.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -24,7 +24,6 @@ KSSTATE State; PKSDATAFORMAT Format; KSPIN_CONNECT * ConnectDetails; - KDPC Dpc; PVOID CommonBuffer; ULONG CommonBufferSize; @@ -35,11 +34,18 @@ PUCHAR ActiveIrpBuffer; ULONG ActiveIrpBufferSize; ULONG ActiveIrpOffset; - ULONG DelayedRequestInProgress; ULONG FrameSize; BOOL Capture; }IPortPinWaveCyclicImpl; + + +typedef struct +{ + IPortPinWaveCyclicImpl *Pin; + PIO_WORKITEM WorkItem; + KSSTATE State; +}SETSTREAM_CONTEXT, *PSETSTREAM_CONTEXT; NTSTATUS NTAPI @@ -194,57 +200,64 @@ VOID NTAPI -StopStreamWorkerRoutine( +SetStreamWorkerRoutine( IN PDEVICE_OBJECT DeviceObject, IN PVOID Context) { IPortPinWaveCyclicImpl * This; - PSTOPSTREAM_CONTEXT Ctx = (PSTOPSTREAM_CONTEXT)Context; - - This = (IPortPinWaveCyclicImpl*)Ctx->Pin; + PSETSTREAM_CONTEXT Ctx = (PSETSTREAM_CONTEXT)Context; + KSSTATE State; + + This = Ctx->Pin; + State = Ctx->State; IoFreeWorkItem(Ctx->WorkItem); FreeItem(Ctx, TAG_PORTCLASS); - if (This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue)) + /* Has the audio stream resumed? */ + if (This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue) && State == KSSTATE_STOP) return; - /* Set the state to stop */ - This->Stream->lpVtbl->SetState(This->Stream, KSSTATE_STOP); - /* Set internal state to stop */ - This->State = KSSTATE_STOP; - - DPRINT1("Stopping %p %u Irql %u\n", This, This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue), KeGetCurrentIrql()); + /* Set the state */ + if (NT_SUCCESS(This->Stream->lpVtbl->SetState(This->Stream, State))) + { + /* Set internal state to stop */ + This->State = State; + + if (This->State == KSSTATE_STOP) + { + /* reset start stream */ + This->IrpQueue->lpVtbl->CancelBuffers(This->IrpQueue); //FIX function name + DPRINT1("Stopping %u Irql %u\n", This, This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue), KeGetCurrentIrql()); + } + } } VOID NTAPI -StopStreamRoutine( - IN PKDPC Dpc, - IN PVOID DeferredContext, - IN PVOID SystemArgument1, - IN PVOID SystemArgument2) -{ - PDEVICE_OBJECT DeviceObject; - IPortPinWaveCyclicImpl * This = (IPortPinWaveCyclicImpl*)DeferredContext; - PIO_WORKITEM WorkItem; - PSTOPSTREAM_CONTEXT Context; +SetStreamState( + IN IPortPinWaveCyclicImpl * This, + IN KSSTATE State) +{ + PDEVICE_OBJECT DeviceObject; + PIO_WORKITEM WorkItem; + PSETSTREAM_CONTEXT Context; ASSERT(KeGetCurrentIrql() <= DISPATCH_LEVEL); /* Has the audio stream resumed? */ - if (This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue)) + if (This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue) && State == KSSTATE_STOP) return; - /* Has the audio stream already stopped */ - if (This->State == KSSTATE_STOP) + /* Has the audio state already been set? */ + if (This->State == State) return; /* Get device object */ DeviceObject = GetDeviceObject(This->Port); - /* allocate stop context */ - Context = AllocateItem(NonPagedPool, sizeof(STOPSTREAM_CONTEXT), TAG_PORTCLASS); + /* allocate set state context */ + Context = AllocateItem(NonPagedPool, sizeof(SETSTREAM_CONTEXT), TAG_PORTCLASS); if (!Context) return; @@ -260,9 +273,10 @@ Context->Pin = (PVOID)This; Context->WorkItem = WorkItem; + Context->State = State; /* queue the work item */ - IoQueueWorkItem(WorkItem, StopStreamWorkerRoutine, DelayedWorkQueue, (PVOID)Context); + IoQueueWorkItem(WorkItem, SetStreamWorkerRoutine, DelayedWorkQueue, (PVOID)Context); } static @@ -277,10 +291,12 @@ ULONG BufferSize; IPortPinWaveCyclicImpl * This = (IPortPinWaveCyclicImpl*)CONTAINING_RECORD(iface, IPortPinWaveCyclicImpl, lpVtblServiceSink); + ASSERT_IRQL(DISPATCH_LEVEL); + Status = This->IrpQueue->lpVtbl->GetMapping(This->IrpQueue, &Buffer, &BufferSize); if (!NT_SUCCESS(Status)) { - KeInsertQueueDpc(&This->Dpc, NULL, NULL); + SetStreamState(This, KSSTATE_STOP); return; } @@ -481,9 +497,7 @@ ASSERT(IsEqualGUIDAligned(&((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->DataFormat.SubFormat, &KSDATAFORMAT_SUBTYPE_PCM)); ASSERT(IsEqualGUIDAligned(&((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->DataFormat.Specifier, &KSDATAFORMAT_SPECIFIER_WAVEFORMATEX)); - Status = This->Stream->lpVtbl->SetState(This->Stream, KSSTATE_STOP); - ASSERT(Status == STATUS_SUCCESS); - This->State = KSSTATE_STOP; + ASSERT(This->State == KSSTATE_STOP); DPRINT1("NewDataFormat: Channels %u Bits %u Samples %u\n", ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.nChannels, ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.wBitsPerSample, ((PKSDATAFORMAT_WAVEFORMATEX)NewDataFormat)->WaveFormatEx.nSamplesPerSec); @@ -501,7 +515,6 @@ IoCompleteRequest(Irp, IO_NO_INCREMENT); return STATUS_SUCCESS; } - } DPRINT1("Failed to set format\n"); Irp->IoStatus.Information = 0; @@ -921,11 +934,9 @@ if (This->IrpQueue->lpVtbl->MinimumDataAvailable(This->IrpQueue) == TRUE && This->State != KSSTATE_RUN) { + SetStreamState(This, KSSTATE_RUN); /* some should initiate a state request but didnt do it */ - DPRINT1("Starting stream with %lu\n", This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue)); - - This->Stream->lpVtbl->SetState(This->Stream, KSSTATE_RUN); - This->State = KSSTATE_RUN; + DPRINT1("Starting stream with %lu mappings Status %x\n", This->IrpQueue->lpVtbl->NumMappings(This->IrpQueue), Status); } return TRUE; @@ -958,7 +969,6 @@ This->KsPinDescriptor = KsPinDescriptor; This->ConnectDetails = ConnectDetails; This->Miniport = GetWaveCyclicMiniport(Port); - KeInitializeDpc(&This->Dpc, StopStreamRoutine, (PVOID)This); DeviceObject = GetDeviceObject(Port); Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -21,6 +21,8 @@ UNICODE_STRING GuidString; DPRINT("PcNewPort entered\n"); + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!OutPort) { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_dmus.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_dmus.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_dmus.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -97,6 +97,8 @@ { IPortDMusImpl * This = (IPortDMusImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortDMus_fnNewRegistryKey called w/o initiazed\n"); @@ -119,6 +121,8 @@ IMiniportDMus * Miniport; NTSTATUS Status; IPortDMusImpl * This = (IPortDMusImpl*)iface; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->bInitialized) { @@ -166,6 +170,8 @@ { IPortDMusImpl * This = (IPortDMusImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortDMus_fnNewRegistryKey called w/o initialized\n"); @@ -173,13 +179,6 @@ } return STATUS_UNSUCCESSFUL; } - - - - - - - NTSTATUS NewPortDMus( Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_midi.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_midi.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_midi.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -134,6 +134,8 @@ { IPortMidiImpl * This = (IPortMidiImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortMidi_fnNewRegistryKey called w/o initiazed\n"); @@ -160,6 +162,7 @@ DPRINT("IPortMidi_fnInit entered This %p DeviceObject %p Irp %p UnknownMiniport %p UnknownAdapter %p ResourceList %p\n", This, DeviceObject, Irp, UnknownMiniport, UnknownAdapter, ResourceList); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->bInitialized) { @@ -239,6 +242,8 @@ { IPortMidiImpl * This = (IPortMidiImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortMidi_fnNewRegistryKey called w/o initialized\n"); @@ -272,6 +277,7 @@ IN PSERVICEGROUP ServiceGroup) { UNIMPLEMENTED + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return STATUS_SUCCESS; } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_topology.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_topology.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_topology.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -153,6 +153,7 @@ OUT PULONG ReturnLength) { IPortTopologyImpl * This = (IPortTopologyImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { @@ -179,6 +180,7 @@ DPRINT("IPortTopology_fnInit entered This %p DeviceObject %p Irp %p UnknownMiniport %p UnknownAdapter %p ResourceList %p\n", This, DeviceObject, Irp, UnknownMiniport, UnknownAdapter, ResourceList); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->bInitialized) { @@ -255,6 +257,7 @@ OUT PULONG Disposition OPTIONAL) { IPortTopologyImpl * This = (IPortTopologyImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { @@ -506,7 +509,7 @@ PKSOBJECT_CREATE_ITEM CreateItem; PPIN_WORKER_CONTEXT Context; - DPRINT("PcCreateItemDispatch called DeviceObject %p\n", DeviceObject); + DPRINT1("PcCreateItemDispatch called DeviceObject %p\n", DeviceObject); /* access the create item */ CreateItem = KSCREATE_ITEM_IRP_STORAGE(Irp); @@ -570,7 +573,7 @@ NULL); if (!NT_SUCCESS(Status)) { - DPRINT("Failed to get filter object\n"); + DPRINT1("Failed to get filter object\n"); return Status; } @@ -580,7 +583,7 @@ /* create the dispatch object */ Status = NewDispatchObject(Irp, Filter); - DPRINT("Filter %p\n", Filter); + DPRINT1("Filter %p\n", Filter); } else { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavecyclic.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavecyclic.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavecyclic.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -287,6 +287,7 @@ OUT PULONG ReturnLength) { IPortWaveCyclicImpl * This = (IPortWaveCyclicImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { @@ -314,6 +315,7 @@ IPortWaveCyclicImpl * This = (IPortWaveCyclicImpl*)iface; DPRINT("IPortWaveCyclic_Init entered %p\n", This); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->bInitialized) { @@ -420,6 +422,8 @@ { IPortWaveCyclicImpl * This = (IPortWaveCyclicImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortWaveCyclic_fnNewRegistryKey called w/o initialized\n"); @@ -450,6 +454,8 @@ DEVICE_DESCRIPTION DeviceDescription; IPortWaveCyclicImpl * This = (IPortWaveCyclicImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!This->bInitialized) { DPRINT("IPortWaveCyclic_fnNewSlaveDmaChannel called w/o initialized\n"); @@ -480,8 +486,9 @@ DEVICE_DESCRIPTION DeviceDescription; PDMACHANNEL DmaChannel; NTSTATUS Status; - IPortWaveCyclicImpl * This = (IPortWaveCyclicImpl*)iface; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepci.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepci.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepci.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -114,6 +114,7 @@ IN PKSEVENT_ENTRY EventEntry) { UNIMPLEMENTED + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); } @@ -348,6 +349,7 @@ DPRINT("IPortWavePci_fnInit entered with This %p, DeviceObject %p Irp %p UnknownMiniport %p, UnknownAdapter %p ResourceList %p\n", This, DeviceObject, Irp, UnknownMiniport, UnknownAdapter, ResourceList); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (This->bInitialized) { @@ -471,6 +473,7 @@ IPortWavePciImpl * This = (IPortWavePciImpl*)iface; DPRINT("IPortWavePci_fnNewRegistryKey entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { @@ -501,6 +504,7 @@ IPortWavePciImpl * This = (IPortWavePciImpl*)iface; DPRINT("IPortWavePci_fnGetDeviceProperty entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!This->bInitialized) { @@ -533,6 +537,7 @@ IPortWavePciImpl * This = (IPortWavePciImpl*)iface; DPRINT("IPortWavePci_fnNewMasterDmaChannel This %p entered\n", This); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); Status = PcDmaMasterDescription(ResourceList, ScatterGather, Dma32BitAddresses, IgnoreCount, Dma64BitAddresses, DmaWidth, DmaSpeed, MaximumLength, DmaPort, &DeviceDescription); if (NT_SUCCESS(Status)) Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepcistream.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepcistream.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/port_wavepcistream.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -86,6 +86,8 @@ { IPortWavePciStreamImpl * This = (IPortWavePciStreamImpl*)iface; + ASSERT_IRQL(DISPATCH_LEVEL); + return This->Queue->lpVtbl->GetMappingWithTag(This->Queue, Tag, PhysicalAddress, VirtualAddress, ByteCount, Flags); } @@ -97,6 +99,9 @@ IN PVOID Tag) { IPortWavePciStreamImpl * This = (IPortWavePciStreamImpl*)iface; + + ASSERT_IRQL(DISPATCH_LEVEL); + This->Queue->lpVtbl->ReleaseMappingWithTag(This->Queue, Tag); return STATUS_SUCCESS; } @@ -108,6 +113,7 @@ IN IPortWavePciStream *iface) { UNIMPLEMENTED + ASSERT_IRQL(DISPATCH_LEVEL); return STATUS_SUCCESS; } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/power.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/power.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/power.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -24,6 +24,7 @@ IAdapterPowerManagement * pPower; DPRINT("PcRegisterAdapterPowerManagement pUnknown %p pvContext %p\n", pUnknown, pvContext); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); if (!pUnknown || !pvContext) return STATUS_INVALID_PARAMETER; @@ -72,6 +73,8 @@ POWER_STATE PowerState; PPCLASS_DEVICE_EXTENSION DeviceExt; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + if (!DeviceObject || !RequestedNewState) return STATUS_INVALID_PARAMETER; Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/private.h [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -28,6 +28,8 @@ #define STDCALL #define DDKAPI #endif + +#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x)) NTSTATUS NTAPI @@ -181,12 +183,6 @@ KSSTREAM_HEADER Header; PIRP Irp; }CONTEXT_WRITE, *PCONTEXT_WRITE; - -typedef struct -{ - PVOID Pin; - PIO_WORKITEM WorkItem; -}STOPSTREAM_CONTEXT, *PSTOPSTREAM_CONTEXT; typedef struct { Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/registry.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/registry.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/registry.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -14,6 +14,7 @@ LONG ref; HANDLE hKey; + BOOL Deleted; }IRegistryKeyImpl; @@ -22,7 +23,7 @@ ULONG -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnAddRef( IN IRegistryKey* iface) { @@ -34,7 +35,7 @@ } ULONG -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnRelease( IN IRegistryKey* iface) { @@ -56,7 +57,7 @@ } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnQueryInterface( IN IRegistryKey* iface, IN REFIID refiid, @@ -77,17 +78,29 @@ } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnDeleteKey( IN IRegistryKey* iface) { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; - DPRINT("IRegistryKey_fnDeleteKey entered\n"); - return ZwDeleteKey(This->hKey); -} - -NTSTATUS -STDMETHODCALLTYPE + NTSTATUS Status; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + + Status = ZwDeleteKey(This->hKey); + if (NT_SUCCESS(Status)) + { + This->Deleted = TRUE; + } + return Status; +} + +NTSTATUS +NTAPI IRegistryKey_fnEnumerateKey( IN IRegistryKey* iface, IN ULONG Index, @@ -97,12 +110,18 @@ OUT PULONG ResultLength) { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; - DPRINT("IRegistryKey_fnEnumerateKey entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + return ZwEnumerateKey(This->hKey, Index, KeyInformationClass, KeyInformation, Length, ResultLength); } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnEnumerateKeyValue( IN IRegistryKey* iface, IN ULONG Index, @@ -112,12 +131,18 @@ OUT PULONG ResultLength) { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; - DPRINT("IRegistryKey_fnEnumerateKeyValue entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + return ZwEnumerateValueKey(This->hKey, Index, KeyValueInformationClass, KeyValueInformation, Length, ResultLength); } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnNewSubKey( IN IRegistryKey* iface, OUT PREGISTRYKEY *RegistrySubKey, @@ -132,7 +157,14 @@ HANDLE hKey; IRegistryKeyImpl * NewThis, *This = (IRegistryKeyImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + DPRINT("IRegistryKey_fnNewSubKey entered %S\n", SubKeyName); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } InitializeObjectAttributes(&Attributes, SubKeyName, 0, This->hKey, NULL); Status = ZwCreateKey(&hKey, KEY_READ | KEY_WRITE, &Attributes, 0, NULL, 0, Disposition); @@ -164,7 +196,7 @@ } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnQueryKey( IN IRegistryKey* iface, IN KEY_INFORMATION_CLASS KeyInformationClass, @@ -173,25 +205,36 @@ OUT PULONG ResultLength) { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; - DPRINT("IRegistryKey_fnQueryKey entered\n"); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + return ZwQueryKey(This->hKey, KeyInformationClass, KeyInformation, Length, ResultLength); } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnQueryRegistryValues( IN IRegistryKey* iface, IN PRTL_QUERY_REGISTRY_TABLE QueryTable, IN PVOID Context OPTIONAL) { - //IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; - UNIMPLEMENTED - DbgBreakPoint(); - return STATUS_UNSUCCESSFUL; -} - -NTSTATUS -STDMETHODCALLTYPE + IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + + return RtlQueryRegistryValues(RTL_REGISTRY_HANDLE, (PCWSTR)This->hKey, QueryTable, Context, NULL); +} + +NTSTATUS +NTAPI IRegistryKey_fnQueryValueKey( IN IRegistryKey* iface, IN PUNICODE_STRING ValueName, @@ -201,12 +244,20 @@ OUT PULONG ResultLength) { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; + DPRINT("IRegistryKey_fnQueryValueKey entered %p value %wZ\n", This, ValueName); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + return ZwQueryValueKey(This->hKey, ValueName, KeyValueInformationClass, KeyValueInformation, Length, ResultLength); } NTSTATUS -STDMETHODCALLTYPE +NTAPI IRegistryKey_fnSetValueKey( IN IRegistryKey* iface, IN PUNICODE_STRING ValueName OPTIONAL, @@ -217,6 +268,13 @@ { IRegistryKeyImpl * This = (IRegistryKeyImpl*)iface; DPRINT("IRegistryKey_fnSetValueKey entered %S\n", ValueName->Buffer); + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + if (This->Deleted) + { + return STATUS_INVALID_HANDLE; + } + return ZwSetValueKey(This->hKey, ValueName, 0, Type, Data, DataSize); } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/resource.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/resource.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/resource.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -98,6 +98,8 @@ { IResourceListImpl * This = (IResourceListImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + return This->TranslatedResourceList->List[0].PartialResourceList.Count; } @@ -107,12 +109,13 @@ IResourceList* iface, IN CM_RESOURCE_TYPE Type) { - /* I guess the translated and untranslated lists will be same length? */ - IResourceListImpl * This = (IResourceListImpl*)iface; ULONG Index, Count = 0; PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptor; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + + /* I guess the translated and untranslated lists will be same length? */ for (Index = 0; Index < This->TranslatedResourceList->List[0].PartialResourceList.Count; Index ++ ) { PartialDescriptor = &This->TranslatedResourceList->List[0].PartialResourceList.PartialDescriptors[Index]; @@ -138,6 +141,8 @@ IResourceListImpl * This = (IResourceListImpl*)iface; ULONG DescIndex, Count = 0; PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptor; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); for (DescIndex = 0; DescIndex < This->TranslatedResourceList->List[0].PartialResourceList.Count; DescIndex ++ ) { @@ -168,6 +173,8 @@ ULONG DescIndex, Count = 0; PCM_PARTIAL_RESOURCE_DESCRIPTOR PartialDescriptor; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + for (DescIndex = 0; DescIndex < This->UntranslatedResourceList->List[0].PartialResourceList.Count; DescIndex ++ ) { PartialDescriptor = &This->UntranslatedResourceList->List[0].PartialResourceList.PartialDescriptors[DescIndex]; @@ -196,6 +203,8 @@ ULONG NewTranslatedSize, NewUntranslatedSize; IResourceListImpl * This = (IResourceListImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + NewTranslatedSize = sizeof(CM_RESOURCE_LIST) + This->TranslatedResourceList[0].List->PartialResourceList.Count * sizeof(CM_PARTIAL_RESOURCE_DESCRIPTOR); NewTranslatedResources = AllocateItem(This->PoolType, NewTranslatedSize, TAG_PORTCLASS); if (!NewTranslatedResources) @@ -254,6 +263,8 @@ ULONG NewTranslatedSize; IResourceListImpl * This = (IResourceListImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + Translated = Parent->lpVtbl->FindTranslatedEntry(Parent, Type, Index); if (!Translated) return STATUS_INVALID_PARAMETER; @@ -287,6 +298,8 @@ { IResourceListImpl * This = (IResourceListImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + return This->TranslatedResourceList; } @@ -296,6 +309,8 @@ IResourceList* iface) { IResourceListImpl * This = (IResourceListImpl*)iface; + + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); return This->UntranslatedResourceList; } Modified: trunk/reactos/drivers/wdm/audio/backpln/portcls/service_group.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/backpln/…
============================================================================== --- trunk/reactos/drivers/wdm/audio/backpln/portcls/service_group.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/backpln/portcls/service_group.c [iso-8859-1] Thu Apr 23 23:06:36 2009 @@ -25,9 +25,7 @@ BOOL Initialized; BOOL TimerActive; KTIMER Timer; - KEVENT DpcEvent; KDPC Dpc; - }IServiceGroupImpl; @@ -38,7 +36,7 @@ NTSTATUS -STDMETHODCALLTYPE +NTAPI IServiceGroup_fnQueryInterface( IServiceGroup* iface, IN REFIID refiid, @@ -66,7 +64,7 @@ } ULONG -STDMETHODCALLTYPE +NTAPI IServiceGroup_fnAddRef( IServiceGroup* iface) { @@ -76,7 +74,7 @@ } ULONG -STDMETHODCALLTYPE +NTAPI IServiceGroup_fnRelease( IServiceGroup* iface) { @@ -95,7 +93,6 @@ Entry->pServiceSink->lpVtbl->Release(Entry->pServiceSink); FreeItem(Entry, TAG_PORTCLASS); } - KeWaitForSingleObject(&This->DpcEvent, Executive, KernelMode, FALSE, NULL); KeCancelTimer(&This->Timer); FreeItem(This, TAG_PORTCLASS); return 0; @@ -115,17 +112,18 @@ IServiceGroup_fnRequestService( IN IServiceGroup * iface) { - PLIST_ENTRY CurEntry; - PGROUP_ENTRY Entry; - IServiceGroupImpl * This = (IServiceGroupImpl*)iface; - - CurEntry = This->ServiceSinkHead.Flink; - while (CurEntry != &This->ServiceSinkHead) - { - Entry = CONTAINING_RECORD(CurEntry, GROUP_ENTRY, Entry); - Entry->pServiceSink->lpVtbl->RequestService(Entry->pServiceSink); - CurEntry = CurEntry->Flink; - } + KIRQL OldIrql; + IServiceGroupImpl * This = (IServiceGroupImpl*)iface; + + if (KeGetCurrentIrql() > DISPATCH_LEVEL) + { + KeInsertQueueDpc(&This->Dpc, NULL, NULL); + return; + } + + KeRaiseIrql(DISPATCH_LEVEL, &OldIrql); + KeInsertQueueDpc(&This->Dpc, NULL, NULL); + KeLowerIrql(OldIrql); } //--------------------------------------------------------------- @@ -141,6 +139,8 @@ PGROUP_ENTRY Entry; IServiceGroupImpl * This = (IServiceGroupImpl*)iface; + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); + Entry = AllocateItem(NonPagedPool, sizeof(GROUP_ENTRY), TAG_PORTCLASS); if (!Entry) return STATUS_INSUFFICIENT_RESOURCES; @@ -148,8 +148,6 @@ Entry->pServiceSink = pServiceSink; pServiceSink->lpVtbl->AddRef(pServiceSink); - //FIXME - //check if Dpc is active InsertTailList(&This->ServiceSinkHead, &Entry->Entry); return STATUS_SUCCESS; @@ -165,9 +163,7 @@ PGROUP_ENTRY Entry; IServiceGroupImpl * This = (IServiceGroupImpl*)iface; - //FIXME - //check if Dpc is active - // + ASSERT_IRQL_EQUAL(PASSIVE_LEVEL); CurEntry = This->ServiceSinkHead.Flink; while (CurEntry != &This->ServiceSinkHead) @@ -194,11 +190,18 @@ IN PVOID SystemArgument2 ) { + PLIST_ENTRY CurEntry; + PGROUP_ENTRY Entry; IServiceGroupImpl * This = (IServiceGroupImpl*)DeferredContext; - IServiceGroup_fnRequestService((IServiceGroup*)DeferredContext); - KeSetEvent(&This->DpcEvent, IO_SOUND_INCREMENT, FALSE); -} - + + CurEntry = This->ServiceSinkHead.Flink; + while (CurEntry != &This->ServiceSinkHead) + { + Entry = CONTAINING_RECORD(CurEntry, GROUP_ENTRY, Entry); + Entry->pServiceSink->lpVtbl->RequestService(Entry->pServiceSink); + CurEntry = CurEntry->Flink; + } +} VOID NTAPI @@ -207,11 +210,11 @@ { IServiceGroupImpl * This = (IServiceGroupImpl*)iface; + ASSERT_IRQL(DISPATCH_LEVEL); + if (!This->Initialized) { - KeInitializeEvent(&This->DpcEvent, SynchronizationEvent, FALSE); KeInitializeTimerEx(&This->Timer, NotificationTimer); - KeInitializeDpc(&This->Dpc, IServiceGroupDpc, (PVOID)This); This->Initialized = TRUE; } } @@ -224,6 +227,8 @@ { LARGE_INTEGER DueTime; IServiceGroupImpl * This = (IServiceGroupImpl*)iface; + + ASSERT_IRQL(DISPATCH_LEVEL); DueTime.QuadPart = ullDelay; @@ -233,8 +238,6 @@ KeSetTimer(&This->Timer, DueTime, &This->Dpc); else KeInsertQueueDpc(&This->Dpc, NULL, NULL); - - KeClearEvent(&This->DpcEvent); } } @@ -244,6 +247,8 @@ IN IServiceGroup * iface) { IServiceGroupImpl * This = (IServiceGroupImpl*)iface; + + ASSERT_IRQL(DISPATCH_LEVEL); if (This->Initialized) { @@ -283,6 +288,8 @@ This->lpVtbl = &vt_IServiceGroup; This->ref = 1; + KeInitializeDpc(&This->Dpc, IServiceGroupDpc, (PVOID)This); + KeSetImportanceDpc(&This->Dpc, HighImportance); InitializeListHead(&This->ServiceSinkHead); *OutServiceGroup = (PSERVICEGROUP)&This->lpVtbl;
15 years, 9 months
1
0
0
0
[cgutman] 40671: - Fix the size passed to RtlZeroMemory so it also zeros the protocol reserved memory
by cgutman@svn.reactos.org
Author: cgutman Date: Thu Apr 23 22:56:37 2009 New Revision: 40671 URL:
http://svn.reactos.org/svn/reactos?rev=40671&view=rev
Log: - Fix the size passed to RtlZeroMemory so it also zeros the protocol reserved memory Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/ndis/ndis/…
============================================================================== --- trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] Thu Apr 23 22:56:37 2009 @@ -424,7 +424,7 @@ KeReleaseSpinLock(&Pool->SpinLock.SpinLock, OldIrql); - RtlZeroMemory(Temp, sizeof(NDIS_PACKET)); + RtlZeroMemory(Temp, Pool->PacketLength); Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS; @@ -707,7 +707,7 @@ KeReleaseSpinLockFromDpcLevel(&Pool->SpinLock.SpinLock); - RtlZeroMemory(Temp, sizeof(NDIS_PACKET)); + RtlZeroMemory(Temp, Pool->PacketLength); Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS; @@ -756,7 +756,7 @@ Temp = Pool->FreeList; Pool->FreeList = (PNDIS_PACKET)Temp->Reserved[0]; - RtlZeroMemory(Temp, sizeof(NDIS_PACKET)); + RtlZeroMemory(Temp, Pool->PacketLength); Temp->Private.Pool = Pool; Temp->Private.ValidCounts = TRUE; Temp->Private.NdisPacketFlags = fPACKET_ALLOCATED_BY_NDIS;
15 years, 9 months
1
0
0
0
[tkreuzer] 40670: fix build
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Thu Apr 23 18:39:12 2009 New Revision: 40670 URL:
http://svn.reactos.org/svn/reactos?rev=40670&view=rev
Log: fix build Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c Modified: trunk/reactos/drivers/network/ndis/ndis/buffer.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/ndis/ndis/…
============================================================================== --- trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/ndis/ndis/buffer.c [iso-8859-1] Thu Apr 23 18:39:12 2009 @@ -1108,4 +1108,4 @@ *Buffer = NdisBuffer; } -/* EOF */ +/* EOF */
15 years, 9 months
1
0
0
0
[tkreuzer] 40669: Fix broken RosBE Windows
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Thu Apr 23 16:56:40 2009 New Revision: 40669 URL:
http://svn.reactos.org/svn/reactos?rev=40669&view=rev
Log: Fix broken RosBE Windows Modified: trunk/tools/RosBE/RosBE-Windows/Root/Build.cmd trunk/tools/RosBE/RosBE-Windows/Root/rosbe-gcc-env.cmd Modified: trunk/tools/RosBE/RosBE-Windows/Root/Build.cmd URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE/RosBE-Windows/Root/Bui…
============================================================================== --- trunk/tools/RosBE/RosBE-Windows/Root/Build.cmd [iso-8859-1] (original) +++ trunk/tools/RosBE/RosBE-Windows/Root/Build.cmd [iso-8859-1] Thu Apr 23 16:56:40 2009 @@ -71,8 +71,8 @@ set TARGET_CPP=%_ROSBE_CCACHE%g++ if not "%ROS_ARCH%" == "" ( - set TARGET_CC=%_ROSBE_CCACHE%%ROS_ARCH%-pc-mingw32-gcc - set TARGET_CPP=%_ROSBE_CCACHE%%ROS_ARCH%-pc-mingw32-g++ + set TARGET_CC=%_ROSBE_CCACHE%%ROS_PREFIX%-gcc + set TARGET_CPP=%_ROSBE_CCACHE%%ROS_PREFIX%-g++ ) :: Modified: trunk/tools/RosBE/RosBE-Windows/Root/rosbe-gcc-env.cmd URL:
http://svn.reactos.org/svn/reactos/trunk/tools/RosBE/RosBE-Windows/Root/ros…
============================================================================== --- trunk/tools/RosBE/RosBE-Windows/Root/rosbe-gcc-env.cmd [iso-8859-1] (original) +++ trunk/tools/RosBE/RosBE-Windows/Root/rosbe-gcc-env.cmd [iso-8859-1] Thu Apr 23 16:56:40 2009 @@ -113,3 +113,9 @@ set ROSBE_TARGET_CFLAGS= set ROSBE_TARGET_CXXFLAGS= ) + +:: HAX !!!! +set HOST_CFLAGS=%ROSBE_HOST_CFLAGS% +set HOST_CPPFLAGS=%ROSBE_HOST_CXXFLAGS% +set TARGET_CFLAGS=%ROSBE_TARGET_CFLAGS% +set TARGET_CPPFLAGS=%ROSBE_TARGET_CXXFLAGS%
15 years, 9 months
1
0
0
0
← Newer
1
...
6
7
8
9
10
11
12
...
48
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
Results per page:
10
25
50
100
200