Page 1 of 1
ps2hd system file module for linux
Posted: Sun Apr 03, 2005 2:38 am
by Marduk
Hi:
First, i'm newbie around here and i'm not usual in this "world", but we are making a free-open linux distro (a fork of guadalinex, debian based) and our users suggested that our distro could write/read ps2 hd's.
So we need a module (or kernel patch) that allow us to format/read/write/... from ps2 hd's.
Is there a ps2hd system file module for linux?
I have found the libhdd, but my skills are not enough to make a module from this.
Any one can guide me?
Thanks.
Posted: Sun Apr 03, 2005 2:55 am
by mrbrown
I doubt anyone would guide you, but you can grab an implementation of APA and PFS from
Andrew Church's PS2 Linux page. Without much modification you should be able to partition an drive with APA. You can also read PFS from existing APA-parititoned drives, but there's no format utility there, IIRC.
Posted: Sun Apr 03, 2005 4:27 am
by Marduk
ups, it's a little in japanish....
I'have downloaded the ps2fs.tar.gz but the readme are in japanish too :P
But i realized one interesting line in "english":
mount -t ps2fs -o ro,partition=__common /dev/hda /mnt/common
So maybe, this is what i'm looking for... but difficult to say without speaking that language.
Mac mini
Posted: Sun Apr 03, 2005 5:12 am
by mharris
Part of the difficulty in supporting the PS2 file system under Linux comes from the fact that the PS2 partitioning system (APA) is different than on standard PC hard disks, so you'll need to add stuff to linux/fs/partitions/ as well as supporting the filesystem itself in linux/fs/pfs. There are weird interrelationship between APA and PFS that will challenge you, you may need some way to 'wrap' the multiple partitions into a single filesystem so that the kernel can understand it, maybe something like the md system would work (see linux/drivers/md/). This part might be a little more challenging that you're comfortable with, I'd focus on getting a single partition working first, in read-only mode. 'mount -o loop,ro' is your friend here, see if you can get a decent disk image (via dd or similar). The alternative would be to treat the entire HDD as a single filesystem, and let your driver deal with the partitions internally.
This is assuming you're putting a physical PS2 HDD in your existing Linux system. If you're talking about the tweaking the PS2 Linux Kit, good luck. I thought that BlackRhino might have supported apa/pfs, but I'm not sure about that.
I started this once, and made some progress -- let me know if you'd like any of my crappy code (so you know what not to do). All of my work was on the 2.4 kernel, so it may not be any help if you're targetting 2.6.