What position do cellular communcation (1G, 2G, 3G, 4G or other function only implemented in phone) play in Android operating system archtecture? I am entirely new to Android, but have a little knowledge on Linux.

I have view the architecture graph of android on official site:


The Problem:

Not all android device support cellar network. As a result, it isn't shown in graph. But which layer is actually cellular networking (and other function related to SIM card) drivers in? 

Analysis:

If it is in kernel layer, it means that there should be an independent kernel repository or patch specific for cell phone other that tab computer, smart television and music player. It would not be a good design of architecture and will be difficult to maintain.

If it is in HAL, it means that wrong driver won't affect the booting process, instead, it will only make cell phone unable to connect to cellar network. While the other application and GUI should be run properly, because the init system will skip the error units. However, it is actually not true. 

What I have done:

I have a Samsung Galaxy Note II GT N7108 (China Mobile) (Use TD-SCDMA) which I bought from China. I download and flash two firmware package (Official Samsung ROM for AT&amp;T device and Lineage OS 14.1 for NOTE II LTE). But the result is the same, the device is unable to boot and keeping no change on startup screen.

Update 1:

According to the wikipedia link provide by '@Morrison Chang', it is said that NOTE II for China Mobile use Snapdragon SoC. However, it should be noticed that, the model use Snapdragon SoC is GT-N7108D instead of GT-N7108. GT-N7108 use Samsung Exynos 4412 as its SoC.
If it is in kernel layer, it means that there should be an independent kernel repository or patch specific for cell phone other that tab computer, smart television and music player. It would not be a good design of architecture and will be difficult to maintain.


Bingo. Lots of device specific stuff are in binary blob drivers which only work for specific devices. Android has no common platform like a PC. Those drivers are held by the device manufacturers or system-on-a-chip vendors.

See: Why is it that Android still can't be installed as regular OS?, and Why are there not generic phone OS installers?

Based on this article from LWN.net: An update on the Android problem is seems like the Android kernel problem is improving, but architectural changes like Project Treble would only benefit devices already integrated with those changes.

And so posts like Is there a technical reason Android update story is so bad? will remain valid for some time.

If you wish to go down deeper, at least be aware of the content in the AOSP Architecture documentation

Yes, but what about cellular radio

Mobile telephony radio is managed via a baseband processor which will have its own CPU/RAM/Firmware. Control communication appears to be done by serial AT commands. Realize that baseband processors may differ based on device model.

For more detail see:
How mobile OS talks to baseband OS and How does Modem code talk to Android code

But why doesn't it boot?

Flashing software that isn't specifically designed for the hardware could/would result in bricking. A quick check of the specs for a Samsung Galaxy Note II shows two different CPUs - Exynos and Qualcomm. While both may run ARM code, the internal architecture is different: i.e. number of cores, GPU driver, camera driver, memory layout etc. Putting a US AT&amp;T firmware, designed for Exynos, on hardware for China Mobile, containing Qualcomm, is guaranteed won't work.

Response to Update 1

While the CPU chipset may be the same, GT-N7108 radio band support for the USA is poor with no 3G bands, which means that the physical baseband processor would be different for Galaxy Note II models marketed and sold in the USA. As part of the boot process, the baseband processor is checked (further details in prior links), that could easily result in a non-operational state.