HFS/HFS+ Driver for OpenSolaris
This project exists to port the HFS filesystem driver code present in Apple’s XNU kernel to the Nevada/ON consolidation in the OpenSolaris project.
- The HFS fstyp module (/usr/lib/fs/hfs/fstyp.so.1) compiles and can print out basic HFS+ Volume Header information via fstyp -v [rawdev].
- mkfs_hfs compiles and mostly works, but it still cannot make a fs that’s readable by MacOS. Work is progressing to fix this as well as to bring the command and its options more inline with other Solaris mkfs_* commands.
- Work still needs to start on mount_hfs and fsck_hfs.
- The hfs kernel driver code porting has been started. Items currently being worked on are typedef conversion and vfs ops and vnode ops conversion.
- Apple Technote 1150 describes the HFS+ on-disk format and internal structures.
- Chapter 14 of Solaris Internals. Buy this book!
- Other Solaris FS code.
The code can be retrieved via anonymous Subversion at:
$ svn co https://elemental.org/svn/solaris-hfs/
$ cd solaris-hfs
This project is being developed on Solaris Express Community Edition (SXCE) build 80 and onward.
I’m not considering making this compatible with Solaris 10 because the VOP and VFS interfaces have changed a bit between that and what’s in current Nevada builds, primarily because of PSARC 2007/632.
Also, Nevada has PSARC 2007/227 and PSARC 2007/244 which are particularly useful to this project in that they introduce support for case-insensitive filesystems, which is the variant of HFS+ most commonly encountered.
As for the XNU code itself, I started with the rev of code that was included in Apple’s MacOS X 10.5.2 (Darwin 9.2) update. This is available here.
Call For Help
If you’d like to help out with this project, please feel free to grab the source and hack away. Please send any patches to email@example.com. If you have any questions, please email me directly at firstname.lastname@example.org.