[Galaxy Note II, Galaxy S III Developer Discussion ] garyd9:
Okay...

First, the mmc*boot? device nodes are for the boot loaders - please ignore those device nodes. Act like they don't exist. Don't mess with them. Ever. If there's one way to brick a samsung phone, it's by messing up the bootloaders. (Thanks to people like Adam Outler, you might still be able to recover, but only via hardware tinkering.)

So, let's back up and not be concerned about what the device nodes are named, but more concerned about what the device nodes are USED FOR (in relation to dual booting.) If I'm correct, you really aren't concerned about those device node names, but are more concerned about getting the dual boot working.

Is that init script in the OP unmolested? The reason I'm asking is that parts of it aren't making sense to me. For example, it's mounting the /system directory either via an image file OR from mmcblk0p13. However, you've stated that the SGS3 has the SYSTEM partition on mmcblk0p9. It almost appears as if you (or someone else) might have started editing the init script to make it work with a device that has the system partition on p13 (such as the note2.) That would also match with the fact that p16 on the Note2 is the data (userdata) partition...

Actually, that might be exactly what's going on here. The mknod parameters are creating device nodes to the existing p9/p12 partitions, but giving them different names that just happen to match the names used on the Note2...

You could, in theory, do something similar to what you suggested in your OP, but you'd need to do it a bit differently.... Instead of making device nodes with unused names and minors of 9/12, you'd want to use unused names and minors of 13 and 16. Let me explain...

Here is the code you said was in the sgs3 init script (along with comments followed by "//")

mknod /dev/block/mmcblk0p13 b 179 9 // creates a device node called p13 but is identical to p9
mknod /dev/block/mmcblk0p16 b 179 12 // creates a device node called p16 but is identical to p12

So, in your init script, /dev/block/mmcblk0p13 is referencing the EXACT SAME DEVICE as /dev/block/mmcblk0p9 (and the same for the created p16 device and the already existing p12 device.)

Wow, I really hope that not only am I making sense, but also that you are following me. I'm going to start rambling even more.

You kind of have to understand how device nodes work, etc. The NAME of the device node doesn't matter. What matters is if it's a block or character device, the MAJOR number and the MINOR number. For block types of MAJOR 179, it's referring to a MMC device. For block/MMC (b 179). the minor number specifies the partition of the device. (I'm simplifying here - it's actually a masked value that includes a partition and device - and gets more interesting with > 16 partitions that require different majors)

So, you could (in theory) go into that script that works fine on the sgs3 and rename every occurrence of "mmcblk0p16" with "i_like_sex" and it'll still work on the sgs3 (even if you didn't like sex.)

Okay... so back to the script. Keep in mind that I'm basing EVERYTHING on that one script and haven't seen anything else related to this multi-boot thing. It'd probably help if someone gave me a link (I'm too lazy to search) to something that installs this multi-boot stuff.

Anyway, that script. I'm going to do something here for clarity. Instead of referencing the misleading "mmcblk0p13" and "mmcblk0p16" device node nodes, I'm just going to call them "extra13" and "extra16" (because they are NOT referencing partitions 13/16.)

So, in that script, extra13 is actually pointing to partition9 which (based on your information) is the SYSTEM partition (mmcblk0p9) and extra16 is actually pointing to partition12 which (again based on your info) is the USERDATA partition.

In other words, extra13 is pointing to what is normally mounted as "/system" and extra16 is pointing to what is normally mounted as "/data". However, at least for getting the dual boot stuff kick started, it's mounting extra16 in "/.secondrom" instead of "/data".

THAT should be enough information to get you going towards solving your issue.

Personally, I think that whoever decided to use mmcblk0p13 and mmcblk0p16 as fictional device node names on the sgs3 should be thumped in the head for either intentionally or unintentionally creating confusion. It might be due to one of the other dependencies of the dual booting system (what is "/sbin/choose_rom"?) that they were unwilling (or unable) to fix. It might also just be a way to try and make the stuff a pain to port. I don't know their intentions/motives.

I will offer this: If my explanation didn't make sense, you might want to take a few steps back and learn what all of it means before you keep going with the porting effort. Some of the concepts here are important to know, and some basic understanding of device nodes is important when mounting file systems.

Take care

Gary