Hi
I'm trying to use the TANITA Bodyvision software (http://www.tanita.co.uk/index.php?id=158) under wine. The software is supposed to read its data from an SD-Card. But under wine it cannot find the SD card.
I managed to find out what it takes so that the software finds the SD card. Please see the attached small sample to see how the software iterates the drive letters, and how it determines a eligibile media using (data.MediaType == RemovableMedia).
The reasons why this does not work are manyfold. Here are some events which happen when inserting the card. * The drive is reported using udisks. This creates a symlink in dosdevices to the raw block device /dev/sdf * The partition /dev/sdf1 is mounted automatically in /media/XXXX-YYYY * /dev/sdf and /dev/sdf1 are not user read/writable. * wine creates a drive letter symlink for /dev/sdf * no symlink is created for /media/XXXX-YYYY * When you open wine explorer, the drive does not show up in the drive list
This means that the drive letter assigned for the sd card will not be returned in GetLogicalDrives(). When the symlink to the mountpoint is added manually, following output is produced:
DbgPrint says: Drive f fixme:ntdll:server_ioctl_file Unsupported ioctl 70000 (device=7 access=0 func=0 method=0) DbgPrint says: DeviceIoControl failed
When get_dos_device is made to unconditionally return STATUS_BAD_DEVICE_TYPE, the ioctl is properly delivered to harddisk_ioctl DeviceIoControl succeeds:
DbgPrint says: Drive f DbgPrint says: Removable: 0
But still, the device is reported as non-removable. The reason for this is probably that udisks reports /dev/sdf as removable, but not its partition /dev/sdf1.
Is it worth for working on patches for these issues, or is this completely impossible with the current architecture?
Eduard
On 07/14/2012 09:14 PM, Eduard Hasenleithner wrote:
[...] This means that the drive letter assigned for the sd card will not be returned in GetLogicalDrives(). When the symlink to the mountpoint is added manually, following output is produced:
Does http://source.winehq.org/patches/data/88280 solve your GetLogicalDrives issue ?
Am 2012-07-15 22:04, schrieb GOUJON Alexandre:
On 07/14/2012 09:14 PM, Eduard Hasenleithner wrote:
[...] This means that the drive letter assigned for the sd card will not be returned in GetLogicalDrives(). When the symlink to the mountpoint is added manually, following output is produced:
Does http://source.winehq.org/patches/data/88280 solve your GetLogicalDrives issue ?
Well yes, with the patch all the drive letters are reported by GetLogicalDrives (although there are quite a lot due to the multi-slot card reader).
This means that the drive letters are also visible in explorer.exe. But in explorer I still cannot have a look at the drive contents because there is no symlink in dosdevices which points to the mount point.
Eduard
On Mon, Jul 16, 2012 at 07:12:59AM +0200, Eduard Hasenleithner wrote:
Am 2012-07-15 22:04, schrieb GOUJON Alexandre:
On 07/14/2012 09:14 PM, Eduard Hasenleithner wrote:
[...] This means that the drive letter assigned for the sd card will not be returned in GetLogicalDrives(). When the symlink to the mountpoint is added manually, following output is produced:
Does http://source.winehq.org/patches/data/88280 solve your GetLogicalDrives issue ?
Well yes, with the patch all the drive letters are reported by GetLogicalDrives (although there are quite a lot due to the multi-slot card reader).
This means that the drive letters are also visible in explorer.exe. But in explorer I still cannot have a look at the drive contents because there is no symlink in dosdevices which points to the mount point.
Perhaps an issue here is that by default the card/drive is not mounted in the current udisks/udisks2 setups
The mount process need to be initiated by the desktop client (either KDE, GNOME or perhaps Wine) on demand.
Ciao, marcus
On 2012-07-16 09:39, Marcus Meissner wrote:
On Mon, Jul 16, 2012 at 07:12:59AM +0200, Eduard Hasenleithner wrote:
Am 2012-07-15 22:04, schrieb GOUJON Alexandre:
Does http://source.winehq.org/patches/data/88280 solve your GetLogicalDrives issue ?
Well yes, with the patch all the drive letters are reported by GetLogicalDrives (although there are quite a lot due to the multi-slot card reader).
This means that the drive letters are also visible in explorer.exe. But in explorer I still cannot have a look at the drive contents because there is no symlink in dosdevices which points to the mount point.
Perhaps an issue here is that by default the card/drive is not mounted in the current udisks/udisks2 setups
The mount process need to be initiated by the desktop client (either KDE, GNOME or perhaps Wine) on demand.
Maybe I should have mentioned it, but I'm using Ubuntu 12.04 and the SD card is mounted automatically as soon as I put it into the slot. My current hypothesis why the symlink in dosdevices is missing is that the partition is added using 'add_volume' instead of 'add_dos_device'.
On 07/16/2012 09:44 AM, Eduard Hasenleithner wrote:
[...] Maybe I should have mentioned it, but I'm using Ubuntu 12.04 and the SD card is mounted automatically as soon as I put it into the slot. My current hypothesis why the symlink in dosdevices is missing is that the partition is added using 'add_volume' instead of 'add_dos_device'.
As you may have read, my patch to fix the GetLogicalDrives issue is wrong so I'll need more time to investigate. The best thing you can do is fill a bug with all those details and tell me its bug number. But you'll have to wait a bit .. my spare time is limited.
Am 2012-07-16 19:57, schrieb GOUJON Alexandre:
On 07/16/2012 09:44 AM, Eduard Hasenleithner wrote:
[...] Maybe I should have mentioned it, but I'm using Ubuntu 12.04 and the SD card is mounted automatically as soon as I put it into the slot. My current hypothesis why the symlink in dosdevices is missing is that the partition is added using 'add_volume' instead of 'add_dos_device'.
As you may have read, my patch to fix the GetLogicalDrives issue is wrong so I'll need more time to investigate. The best thing you can do is fill a bug with all those details and tell me its bug number. But you'll have to wait a bit .. my spare time is limited.
All the code in dlls/kernel32/volume.c seems to be build around evaluating the symlinks present in .wine/dosdevices. Is there already a design document which describes how the interaction with mountmgr should look like in future? Will the dosdevices directory be removed?
Eduard
On 07/21/2012 12:34 PM, Eduard Hasenleithner wrote:
All the code in dlls/kernel32/volume.c seems to be build around evaluating the symlinks present in .wine/dosdevices. Is there already a design document which describes how the interaction with mountmgr should look like in future? Will the dosdevices directory be removed?
Eduard
According to AJ, using symlink to check if a volume exists, is not a good idea as it's not reliable. So we have to get the info from the mountmgr. As its name implies, its job is to manage devices, so it's fairly logical to ask it.
I don't think a design document exists but if I missed it. And clearly, making documentation is not funniest part of a project. But if you want to know what are the plans, ask AJ, he's the only one that can decide what to do.
If you look at mountmgr.c in dlls/mountmgr.sys/, there are calls to IoCreateSymbolicLink and IoDeleteSymbolicLink so symbolic links are used internally. If you remove dosdevices (can be a good idea considering some filesystems don't support symbolic links), you have to store the info elsewhere, in the registry ? in a file ?
AJ ? Any thoughts ?