MantisBT

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000098Kolibri OS (trunk)[All Projects] Kernelpublic2015-06-16 20:322017-01-22 23:53
ReporterCameron 
Assigned Todunkaist 
PrioritynormalSeveritymajorReproducibilityalways
StatusclosedResolutionfixed 
PlatformAny x86 / Любой x86OSKolibriOSOS VersionSVN autobuilds
Product VersionSVN build / автосборка SVN 
Target VersionFixed in VersionSVN build / автосборка SVN 
Summary0000098: File system error on FAT16 formatted hard disk (qemu)
DescriptionAttached hard disks that were formatted by MS-DOS cannot be accessed by KolibriOS in Qemu.
Steps To ReproduceHere is a detailed description of the exact steps I performed.

1.) Download the latest KolibriOS from http://builds.kolibrios.org/eng/latest-distr.7z [^] and extract all the files into a directory called KolibriOS.
2.) Download the latest Qemu build for Windows and place it in a subdirectory of KolibriOS called qemu.
3.) Open a command-line and CD into the KolibriOS directory.
4.) Create a 512 MB hard disk image with the following command:
    qemu\qemu-img.exe create -f raw harddisk.img 512M
5.) Download a MS-DOS 6.22 boot disk from here http://www.allbootdisks.com/download/dos.html [^] and place it in the KolibriOS directory.
6.) Start up the DOS boot disk, which will be used to format the hard disk image.
    qemu\qemu-system-i386.exe -fda Dos6.22.img -hda harddisk.img -boot a
7.) Once DOS has booted up, run 'fdisk', choose "Create DOS Partition or Logical DOS drive", "Create Primary DOS Partition", choose "Y" to use the maximum size, and it should create a partition. Press a key to reboot the VM. After it has rebooted, run 'format c:' to create a FAT16 filesystem. Run 'echo Hello > C:\foo.txt' to create a simple test file on the new partition. Close the VM.
8.) Boot up KolibriOS using the following command:
    qemu\qemu-system-i386.exe -fda kolibri.img -hda harddisk.img -boot a
9.) The hard disk image should be mapped to /hd0/1, however KFM gives a "File system error" instead of showing the actual contents. Trying to cd into /hd0/1 from the shell also throws an error.
Additional InformationIssue also happens with a floppy image. I cannot access /fd2/1

Also happens when booting the live CD (kolibri.iso).

I am sure the created disk images are valid since I am able to access them from both Windows XP and Lubuntu in a Qemu VM, but trying to access them from KolibriOS gives an error.
Tagsfloppy, pci, qemu
SVN revision / ревизия SVN
Type of distribution / Тип дистрибутиваany / любой
Attached Filesdiff file icon qemu_pci_bus_master.diff [^] (2,493 bytes) 2016-12-24 20:02 [Show Content]
diff file icon fd_fd2.diff [^] (1,016 bytes) 2016-12-26 01:01 [Show Content]

- Relationships
has duplicate 0000103closeddunkaist /fd2/1 это дупликат (is a duplicate of) /fd/1 & Eolite crashes on /hd{0|1}/1 under QEMU 

-  Notes
(0000188)
dunkaist (administrator)
2016-12-24 20:18
edited on: 2016-12-24 20:45

The issue with IDE disks is that
 - Active bit in Bus_Master_ATA_Status register is set;
 - however Bus_Master bit in Command PCI register is not set.

Qemu honors PCI_COMMAND_MASTER starting with 1c380f946052.

I attached a patch that sets Bus_Master bit when a device enables DMA. However, I never touched this part of kernel and ask somebody to review it.

The issue with floppy stays open.

(0000189)
dunkaist (administrator)
2016-12-26 01:05

Fix for floppies: r6814. Tested in qemu and bochs.

Drive number wasn't specified for recalibrate/read/write commands, always 0.

- Issue History
Date Modified Username Field Change
2015-06-16 20:32 Cameron New Issue
2016-12-24 19:58 dunkaist Relationship added has duplicate 0000103
2016-12-24 19:59 dunkaist Status new => confirmed
2016-12-24 20:01 dunkaist Tag Attached: pci
2016-12-24 20:01 dunkaist Tag Attached: qemu
2016-12-24 20:02 dunkaist File Added: qemu_pci_bus_master.diff
2016-12-24 20:18 dunkaist Note Added: 0000188
2016-12-24 20:45 dunkaist Note Edited: 0000188 View Revisions
2016-12-26 01:01 dunkaist File Added: fd_fd2.diff
2016-12-26 01:05 dunkaist Note Added: 0000189
2016-12-26 01:24 dunkaist Tag Attached: floppy
2016-12-26 21:57 dunkaist Relationship replaced duplicate of 0000103
2016-12-26 21:57 dunkaist Status confirmed => resolved
2016-12-26 21:57 dunkaist Fixed in Version => SVN build / автосборка SVN
2016-12-26 21:57 dunkaist Resolution open => fixed
2016-12-26 21:57 dunkaist Assigned To => dunkaist
2016-12-26 21:58 dunkaist Relationship replaced has duplicate 0000103
2017-01-22 23:53 dunkaist Status resolved => closed


Copyright © 2000 - 2021 MantisBT Team
Powered by Mantis Bugtracker