community.general/lib/ansible
Zhangfei Gao ce4ada93f9 facts: fix arm64 ansible_processor_vcpus = 0
On arm64, /proc/cpuinfo has no 'model name', 'Processor', 'vendor_id', 'cpu', 'Vendor',
as a resul "ansible_processor_count": 0 & "ansible_processor_vcpus": 0
Add checking element "processor" to fix the issue.

$ ansible -i ~/all-in-one  -m setup all | grep proc
	"ansible_processor": [],
	"ansible_processor_cores": 1,
	"ansible_processor_count": 0,
	"ansible_processor_threads_per_core": 1,
	"ansible_processor_vcpus": 0,

$ cat /proc/cpuinfo
processor	: 0
BogoMIPS	: 100.00
Features	: fp asimd evtstrm aes pmull sha1 sha2 crc32
CPU implementer	: 0x41
CPU architecture: 8
CPU variant	: 0x1
CPU part	: 0xd07
CPU revision	: 1

$ ansible --version
ansible 2.3.1.0
config file =
configured module search path = Default w/o overrides
python version = 2.7.9 (default, Aug 13 2016, 16:27:01) [GCC 4.9.2]

With fix, checking processor as well:
$ ansible -i ~/all-in-one  -m setup all | grep proc
	"ansible_processor": [
	"ansible_processor_cores": 1,
	"ansible_processor_count": 16,
	"ansible_processor_threads_per_core": 1,
	"ansible_processor_vcpus": 16,

Signed-off-by: Zhangfei Gao <zhangfei.gao@linaro.org>
2017-08-07 12:39:14 -04:00
..
cli Fix bug that diff.always = yes in ansible.cfg won't be respected (#27746) 2017-08-04 10:42:38 -04:00
compat Remove wildcard imports 2017-07-28 22:10:17 -07:00
config Add back support for vault_password_file config var (#27597) 2017-08-01 18:07:33 -04:00
errors correct, cleanup & simplify dwim stack (#25956) 2017-07-03 15:27:53 -04:00
executor Fix for ansiballz filenames conflicting with python stdlib modules 2017-08-01 15:20:35 -07:00
galaxy Removes container-enabled warning (#27578) 2017-08-01 12:51:03 -04:00
inventory ensure all groups inherit from 'all' 2017-07-13 18:38:39 -04:00
module_utils facts: fix arm64 ansible_processor_vcpus = 0 2017-08-07 12:39:14 -04:00
modules Refactor E-Series VolumeCopy to use module_utils (#20902) 2017-08-07 09:18:26 -06:00
parsing Handle win style CRLF newlines in vault text (#27590) 2017-08-01 18:53:22 -04:00
playbook Remove _diff from play_context default 2017-08-04 15:25:40 -04:00
plugins Fixes #21536: Allowing the ability to pass aws session paramters to credstash lookup (#23077) 2017-08-07 11:33:59 -04:00
template Try to show original exception info for yaml (and other) errors (#24468) 2017-06-09 13:13:15 -04:00
utils aci.py: Add use_proxy support (#27735) 2017-08-07 16:08:20 +02:00
vars Remove wildcard imports 2017-07-28 22:10:17 -07:00
__init__.py Fix ziploader for the cornercase of ansible invoking ansible. 2016-04-29 08:47:49 -07:00
constants.py Fix undefined variables, basestring usage, and some associated python3 issues 2017-07-25 15:58:23 -07:00
release.py Collated PEP8 fixes (#25293) 2017-06-02 12:14:11 +01:00