Re: Disk icon for mounted file system in the Finder
Hi Garth, thanks for the response. Our kext isn't an IOKit driver - currently its only interaction with the IOKit is to iterate over the IOMedia objects to find the disks it needs. Is this going to be a problem when we try to publish our logical volumes as IOMedia objects? Presumably if I fill out the details in the IOMedia objects like mount path and major/minor numbers, apps like the Finder will be able to interact with the logical volumes without any further handholding from us. i.e. no registered callbacks or other additional interfaces required. If this is the case, we should be home and hosed. I flicked through the IOKit headers and found IORegistryEntry::attachToParent(), which looks like the call I'll need. I then went into the IORegistryExplorer to have a look around and work out where we should add our IOMedia objects. Since I had an NFS mount on my desktop, I expected to find an IOMedia entry for it somewhere, but it was nowhere to be found. Indeed unmounting it and remounting it didn't result in any of the usual "IORegistry has changed" messages from IORegistryExplorer. Is NFS a special case? I grepped through other file system code in xnu but couldn't see any use of IORegistryEntry or attachToParent. Can anyone suggest a suitable parent in the Registry for our logical volumes? Should they go in the IOService plane or the IODeviceTree plane? I'll try a few variations in the meantime and see if we have any success. Thanks again for your helpful suggestions, Sam On Tuesday, Oct 14, 2003, at 01:55 Australia/Melbourne, Garth Cummings wrote: Once you've got your file system to the point where it mounts and you can do basic operations including I/O, how do you get the Finder to give you an icon on the Desktop that can be browsed? When Disk Arbitration works its way through the disks we're using, we put our hand up to say they're ours but we decline to mount them since they're not meant to be accessed directly. We then make the logical volumes we do want to expose visible by adding them to the devfs tree and mounting them in e.g. /mnt/mydisk. Do you publish IOMedia objects for your logical volumes? That would trigger mounting via DiskArb. This will eventually cause your fsck utility to run and, if it succeeds, the volume will be mounted. Ultimately, DiskArb has to be involved in mounts that you want Finder to see. Is there a call we can make that's something along the lines of "here's our mount point, here's a volume name and here's an icon, please add a volume to the Finder for us"? No. BTW, the filesystem folks hang out on the darwin-kernel list. _______________________________________________ darwin-kernel mailing list | darwin-kernel@lists.apple.com Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/darwin-kernel Do not post admin requests to the list. They will be ignored.
participants (1)
-
Sam Vaughan