frno7 / linux

Linux 2.2, 2.6, 3.x, 4.x and 5.x kernels for the PlayStation 2.
Other
84 stars 5 forks source link

Enable the memory card accessory #21

Open frno7 opened 5 years ago

frno7 commented 5 years ago

Implement a readable and writable block device driver for the PlayStation 2 memory card (SCPH-10020) accessory. Also implement a corresponding filesystem?

See also #4 and #11.

uyjulian commented 1 year ago

As for how SCE did this, they wrote a shim driver that just communicates to the MCMAN filesystem driver running on the IOP. Sort of how virtio-fs does it.

See: https://github.com/rickgaiser/linux-2.4.17-ps2/blob/69d1691010e92b14133758864c1433042de028cf/drivers/ps2/mcfs/mcfs.c

frno7 commented 1 year ago

Thanks, @uyjulian! @jur made some minor updates to it in drivers/ps2/mcfs/mcfs.c on the ps2-v2.6.35.14 branch. It’s available up to and including the ps2-v4.11 branch, actually.

bignaux commented 1 year ago

for the record https://github.com/FranciscoDA/ps2mcfs . I like the idea we use FUSE for pfs and mcfs, since it has great advantage about maintenance and portability.

frno7 commented 1 year ago

@bignaux, we could have both FUSE and kernel filesystems. I’ll need to figure out how to multiplex gamepad and memory card data via the SIO2. :-)