sunxi: disambiguate sw_get_ic_ver()'s enum

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: soc-detect: move sw_get_ic_ver() to a separated module

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: move sunxi_chip_id() out of core.c

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: don't assume SUNXI_VER_A10A == 0

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: extend sw_get_ic_ver() to detect sun5i chips

based on Allwinner's mach-sun5i code to "magically" detect the chip

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: fix sw_get_ic_ver/sun5i bug

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: print detected SoC the first time
sunxi: add sunxi_is_${soc_name}() macros

supporting all known sun4i and sun5i SoCs.
- sunxi_is_a10()
- sunxi_is_a13()
- sunxi_is_a12()
- sunxi_is_a10s()

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: implement sw_get_chip_id()

from latest sun[45]i SDK

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: mark sw_get_ic_ver() as pure

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: bring sunxi_pr_chip_id() back, but using the ic_ver

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: rename sunxi_chip_id() to sunxi_brom_chip_id()

because there are other methods

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: export sunxi_brom_chip_id()

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi: introduce SUNXI_MACH_SUNnI defines using Allwinner's chipid values
sunxi:soc-detect: introduce sunxi_sramc_chip_id()

Thanks to hno's discovery

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: add cached/pure sunxi_chip_id() and sunxi_is_sunNi() macros

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: add extra debugging to sw_get_ic_ver() errors
sunxi:soc-detect: remove CONFIG_ARCH_SUNnI optimization

Signed-off-by: Alejandro Mery <amery@geeks.cl>
sunxi:soc-detect: dump SSE_IO_REG0 when failed to detect SoC too
sunxi:soc-detect: clean register dumping code

Signed-off-by: Alejandro Mery <amery@geeks.cl>