[Galaxy Note 10.1 (2014 Edition) Android Developmen] ghembuls:
Bootloader Check Command

For those who wish to try to flash this ROM on other devices than SM-P601 or any recovery system which intended for other than SM-P601, there are 3 things you have to understand. These 3 things are written on 2 items, 1st is on updater-script inside META-INF and 2nd on build.prop inside system. Open those 2 files using Notepad++ and pay attention on these lines below;

A. Updater-Script (META-INF)

1. Target Device

assert(getprop("ro.product.device") == "lt033g" || getprop("ro.build.product") == "lt033g" || getprop("ro.product.device") == "lt03wifi" || getprop("ro.build.product") == "lt03wifi" || getprop("ro.product.device") == "lt03wifiue" || getprop("ro.build.product") == "lt03wifiue" || getprop("ro.product.device") == "n1awifi" || getprop("ro.build.product") == "n1awifi" || getprop("ro.product.device") == "n1a3g" || getprop("ro.build.product") == "n1a3g" || abort("E3004: This package is for device: lt033g,lt03wifi,lt03wifiue,n1awifi,n1a3g; this device is " + getprop("ro.product.device") + "."););

This line, will tell the ROM package to check destination device. This line will also check your recovery system, even if your device is SM-P601 in actual but your are using custom recovery for SM-P602, it will fail and give error during flashing then send error signal. If not mistaken, the error signal is Error 7.

2. Bootloader

assert(sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601XXUDQA1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601XXUDPL1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601UBSDQA1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601XXSDPK1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601UBUDPF1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601XXSDPL1")) == "" || sha1_check(read_file("EMMC:/dev/block/platform/msm_sdcc.1/by-name/aboot:1048576:P601XXUDPF4")) == "" || abort("Invalid checksum for partition /dev/block/platform/msm_sdcc.1/by-name/aboot"));

This line is specific to inquire your installed bootloader, this line will execute command to check if the bootloader actually match its requirement. If the bootloader fail to match its requirement, it will tell the script to abort.

B. Build.Prop (System)

1. Booting Check

ro.build.expect.bootloader=P601XXUDQA1|P601XXUDPL1|P601UBSDQA1|P601XXSDPK1|P601UBUDPF1|P601XXSDPL1|P601XXUDPF4

This line, will be executed during device booting. As you notice, the line is read, "expect bootloader". It means, during booting, it will need to call the stated bootloaders. Any bootloaders other than stated above, it will likely to fail and give you looping or black screen.

These 3 commands, are required to prevent users to implement incompatible bootloader which may cause possible flaws generated from bootloaders. I dont know about installing bootloaders from other device into SM-P601, but as far as I know, before flashing, you need to make sure your actual device match custom recovery. As I have mentioned above, even if your actual device is P601 but you have installed TWRP for P602, the script will read your device as P602.

If I have given incorrect information, please be kind to correct it accordingly.

Hope it help.