- Simplify the implementation of the 'DiskGetBootPath' function;
- Cache the retrived freeldr boot path (corresponding to a given 'FrldrBootDrive' number);
- Introduce a 'DiskIsCdRomDrive' function to attempt to fix CORE-12692 .
svn path=/trunk/; revision=73621
- Do not push memory stores onto the operation stack since they can't be acted upon. Based on a patch by Katayama Hirofumi MZ.
CORE-12325 #resolve
svn path=/trunk/; revision=73620
- Remove the DiskVtbl functions (machxbox.c) of the XBOX and share them instead with those of the PC, since they are basically the same.
They just however differ by which 'DiskGetPartitionEntry' function they use. To cope with this, 'DiskGetPartitionEntry' becomes a pointer
to either the default function 'DiskGetMbrPartitionEntry' (which indeed assumes a MBR-layout, see partition.c), or the special function
'XboxDiskGetPartitionEntry' in the case of partitionless XBOX disks.
Note that, by the way, partition.c should in the future support GPT-layout disks as well...
- The boot devices pre-initialization code can also be shared as well, thus getting rid of 'XboxInitializeBootDevices', because we note that
this is exactly what the (old) XBOX version of 'DetectBiosDisks' did at its beginning.
- But then, we can also share 'DetectBiosDisks' XBOX code with its PC version, and also *fix* the PC code version as well!
'DetectSystem' and 'DetectBiosDisks' are therefore merged *as they should be*. Thanks to the boot devices pre-initialization code that has
run before the hardware detection, 'DetectBiosDisks' can just use the cached information.
- Now we correctly initialize the PC root HW system configuration key: we first create it, then, after the bios disks (floppies + HDDs) are enumerated
we set the BIOS INT13h disk data to the system key's configuration data.
svn path=/trunk/; revision=73618
- Move the HW detection code specific to the PC architecture from hardware.c to machpc.c, keeping in hardware.c the code that is shared between PC and XBOX.
- Move what remained of i386disk.c into pcdisk.c (specific to PC architecture) + code formatting.
- Move what remained of xboxhw.c into machxbox.c (specific to XBOX architecture); we discover that some code related to disk management is actually shared with PC architecture (in hwdisk.c): hwdisk.c therefore contains disk-management routines common to both PC & XBOX.
- xboxdisk.c: Code formatting only.
- Cleanup in disk.c/disk.h
svn path=/trunk/; revision=73616
* Recreated the start menu banner as a SVG file in Inkscape.
* Deleted old PSD (Photoshop) files.
* Replaced the explorer banner BMP with one exported by Inkscape from the SVG file.
The end result is slightly sharper text, but otherwise identical.
svn path=/trunk/; revision=73612
- Add missing checks for allocation failure in DetectSerialPointerPeripheral and DetectPS2Mouse. Patch by Serge Gautherie.
CORE-12623
svn path=/trunk/; revision=73608
- Use 'DiskReadBufferSize' instead of hardcoded values in hwdisk.c
- Transform reactos_arc_disk_info into a ARC_DISK_SIGNATURE_EX structure, so that its conversion into a ARC list in winldr.c becomes a bit simpler.
- In winldr.c:
* In case we fail to either open the SYSTEM hive or scan it, bail out with an error message, instead of trying to continue loading ROS.
* Fix an old comment related to ACPI;
- In memory.c/h: Do some cleanup (in particular, just use the MachXXX macros instead of also defining functions with the same names as the macros, and which just redirect into the virtual table).
svn path=/trunk/; revision=73606
Import the isohybrid tool from http://repo.or.cz/syslinux.git/tree/138e850fab106b5235178848b3e0d33e25f4d3a2:/utils
I had to add a lot of glue code (getopt, err/errx/warn/warnx) to get it to compile under all our build platforms Windows, Linux and macOS.
GPT/Mac partition support is disabled at the moment (look for REACTOS_ISOHYBRID_EFI_MAC_SUPPORT), that would need a portable libuuid.
A fix for correctly opening ISOs as binary and not text-mode has been implemented and already sent upstream.
ISOs are not being patched automatically yet due to CORE-12692
CORE-12648
svn path=/trunk/; revision=73595
Overhaul our ISO boot sector:
- Add another entry point for hybrid booting (called by isombr) and the hybrid signature needed for isohybrid.
- Import latest isolinux.asm "API" from http://repo.or.cz/syslinux.git/blob/8bbb10b70905339b7ca6b58d6833b6a95ab03dae:/core/isolinux.asm (latest version to date) and http://repo.or.cz/syslinux.git/blob/9141c603930ef23da1e08e487a0c26750fbb4fbe:/core/isolinux.asm (latest version that came with all functions in ASM).
Among other things, this brings us getlinsec_ebios (for reading setupldr.sys in hybrid/MBR mode) and BrokenAwardHack (for working around broken Award BIOSes)
- Fix upstream getlinsec_ebios to load files >64K.
- Load the HDD boot sector directly to 0x7C00 instead of trackbuf. This way, we don't have to load it again when the user decides to boot from HDD.
- Check for the 0xAA55 signature to decide if the HDD contains a valid MBR. This was done differently and inconsistently for isoboot and isobtrt.
- Adapt the file and comment style to ReactOS guidelines. Add meaningful comments to our main code. Remove stuff that was just taken from isolinux.asm, but makes no sense for our version.
- Remove DEBUG_MESSAGES ifdef. There is no chance they can ever fit into the 2K sector with all the added features. Debugging can still happen using Bochs or adding specific messages.
Tested with Bochs, QEMU, VMware, VirtualBox and four real computers.
Many thanks to Hermès for all the helpful suggestions and additional investigations! :)
CORE-12648
svn path=/trunk/; revision=73594
- CDefaultContextMenu: Fix the implementation of the QueryContextMenu to respect how IContextMenu should function. Don't ignore idCmdFirst and idCmdLast parameters. Return a correct HRESULT. For now I'm not sure how 0 cmd ids should be handled and if the standard menu items should also be affected by these parameters.
svn path=/trunk/; revision=73591
- Start implementing the possibility of customizing the Welcome.exe utility using configuration INI files (e.g. what we would do for FOSDEM, CLT, etc...)
- Resources cleanup.
svn path=/trunk/; revision=73590
- Reduce stack usage by manipulating UNICODE_STRINGS we are given instead of copying it a gazillion times
- Do not assume said strings are null-terminated
svn path=/trunk/; revision=73586
- Now that we correctly handle the shell link data block list with APIs, no need to hack an extra zeroed DWORD at the end of shortcut files!
- Fix the display of the shortcut target location: this typically displays the (last) directory where the target resides. Addendum for r53624, r54957 and CORE-5730 CORE-6104
svn path=/trunk/; revision=73578
- Make more shortcuts start from the user directory;
- The desktop shortcut of the ReadMe file should not use an icon location, so that the shell correctly retrieves the icon to display from the type of the file (in our case, .txt).
- Make the necessary adjustments in syssetup/install.c :
* opt-out setting the icon location;
* in addition, since we now support shell link targets containing environment variables, don't always expand the target path before setting up the shortcut, but do it just in the case we have to compute a suitable working directory.
svn path=/trunk/; revision=73577