~brian-murray/checkbox/brian

« back to all changes in this revision

Viewing changes to registries/cpuinfo.py

  • Committer: Marc Tardif
  • Date: 2009-09-28 18:19:11 UTC
  • Revision ID: marc.tardif@canonical.com-20090928181911-36ysfu3o30iw6rrh
Removed replacement of spaces with underscores in /proc/cpuinfo keys.

Show diffs side-by-side

added added

removed removed

Lines of Context:
45
45
    platform_to_conversion = {
46
46
        ("i386", "i486", "i586", "i686", "x86_64",): {
47
47
            "type": "vendor_id",
48
 
            "model": "model_name",
49
 
            "model_number": "cpu_family",
 
48
            "model": "model name",
 
49
            "model_number": "cpu family",
50
50
            "model_version": "model",
51
51
            "model_revision": "stepping",
52
 
            "cache": "cache_size",
 
52
            "cache": "cache size",
53
53
            "other": "flags",
54
 
            "speed": "cpu_mhz"},
 
54
            "speed": "cpu mhz"},
55
55
        ("alpha", "alphaev6",): {
56
 
            "count": "cpus_detected",
 
56
            "count": "cpus detected",
57
57
            "type": "cpu",
58
 
            "model": "cpu_model",
59
 
            "model_number": "cpu_variation",
60
 
            "model_version": ("system_type", "system_variation",),
61
 
            "model_revision": "cpu_revision",
62
 
            "other": "platform_string",
63
 
            "speed": "cycle_frequency_[Hz]"},
 
58
            "model": "cpu model",
 
59
            "model_number": "cpu variation",
 
60
            "model_version": ("system type", "system variation",),
 
61
            "model_revision": "cpu revision",
 
62
            "other": "platform string",
 
63
            "speed": "cycle frequency [Hz]"},
64
64
        ("ia64",): {
65
65
            "type": "vendor",
66
66
            "model": "family",
67
67
            "model_version": "archrev",
68
68
            "model_revision": "revision",
69
69
            "other": "features",
70
 
            "speed": "cpu_mhz"},
 
70
            "speed": "cpu mhz"},
71
71
        ("ppc64", "ppc",): {
72
72
            "type": "platform",
73
73
            "model": "cpu",
75
75
            "vendor": "machine",
76
76
            "speed": "clock"},
77
77
        ("sparc64", "sparc",): {
78
 
            "count": "ncpus_probed",
 
78
            "count": "ncpus probed",
79
79
            "type": "type",
80
80
            "model": "cpu",
81
81
            "model_version": "type",
163
163
                    continue
164
164
 
165
165
                key, value = line.split(":")
166
 
 
167
 
                # Sanitize key and value
168
 
                key = key.strip()
169
 
                key = key.replace(" ", "_")
170
 
                value = value.strip()
 
166
                key, value = key.strip(), value.strip()
171
167
 
172
168
                # Handle bogomips on sparc
173
169
                if key.endswith("Bogo"):