Merge ~jocave/checkbox-support:fix-lp1850972 into checkbox-support:master

Proposed by Jonathan Cave
Status: Merged
Approved by: Jonathan Cave
Approved revision: c70003975ef17ebaac80e906b9ffb56f3780c77a
Merged at revision: 00510d9e198105828abedff5a36444766277894c
Proposed branch: ~jocave/checkbox-support:fix-lp1850972
Merge into: checkbox-support:master
Diff against target: 1279 lines (+1225/-2)
3 files modified
checkbox_support/parsers/dmidecode.py (+2/-2)
checkbox_support/parsers/tests/dmidecode_data/LENOVO_SYSTEMX.txt (+1192/-0)
checkbox_support/parsers/tests/test_dmidecode.py (+31/-0)
Reviewer Review Type Date Requested Status
Sylvain Pineau (community) Approve
Sheila Miguez (community) Approve
Review via email: mp+375165@code.launchpad.net

Description of the change

Regex modification and tests to check the output against the source of bug 1850972

To post a comment you must log in.
Revision history for this message
Sheila Miguez (codersquid) wrote :

lgtm

review: Approve
Revision history for this message
Sylvain Pineau (sylvain-pineau) wrote :

+1

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
diff --git a/checkbox_support/parsers/dmidecode.py b/checkbox_support/parsers/dmidecode.py
index b056683..4581968 100644
--- a/checkbox_support/parsers/dmidecode.py
+++ b/checkbox_support/parsers/dmidecode.py
@@ -36,7 +36,7 @@ HANDLE_RE = re.compile(
36 r"(?P<size>\d+) bytes$"36 r"(?P<size>\d+) bytes$"
37 % hexdigits)37 % hexdigits)
38KEY_VALUE_RE = re.compile(38KEY_VALUE_RE = re.compile(
39 r"^\t(?P<key>[%s].+):( (?P<value>.+))?$"39 r"^\t(?P<key>[%s][^:]+):( (?P<value>.+))?$"
40 % ascii_uppercase)40 % ascii_uppercase)
4141
4242
@@ -64,7 +64,7 @@ class DmidecodeParser(object):
64 "Type": "type",64 "Type": "type",
65 "Vendor": "vendor",65 "Vendor": "vendor",
66 "Version": "version",66 "Version": "version",
67 }67 }
6868
69 def __init__(self, stream):69 def __init__(self, stream):
70 self.stream = stream70 self.stream = stream
diff --git a/checkbox_support/parsers/tests/dmidecode_data/LENOVO_SYSTEMX.txt b/checkbox_support/parsers/tests/dmidecode_data/LENOVO_SYSTEMX.txt
71new file mode 10064471new file mode 100644
index 0000000..7f07c88
--- /dev/null
+++ b/checkbox_support/parsers/tests/dmidecode_data/LENOVO_SYSTEMX.txt
@@ -0,0 +1,1192 @@
1# dmidecode 3.2
2Getting SMBIOS data from sysfs.
3SMBIOS 3.0 present.
483 structures occupying 4246 bytes.
5Table at 0x78A02000.
6
7Handle 0x0000, DMI type 7, 19 bytes
8Cache Information
9 Socket Designation: L1-Cache
10 Configuration: Enabled, Not Socketed, Level 1
11 Operational Mode: Write Back
12 Location: Internal
13 Installed Size: 64 kB
14 Maximum Size: 64 kB
15 Supported SRAM Types:
16 Synchronous
17 Installed SRAM Type: Synchronous
18 Speed: Unknown
19 Error Correction Type: Single-bit ECC
20 System Type: Instruction
21 Associativity: 8-way Set-associative
22
23Handle 0x0001, DMI type 7, 19 bytes
24Cache Information
25 Socket Designation: L2-Cache
26 Configuration: Enabled, Not Socketed, Level 2
27 Operational Mode: Varies With Memory Address
28 Location: Internal
29 Installed Size: 256 kB
30 Maximum Size: 256 kB
31 Supported SRAM Types:
32 Synchronous
33 Installed SRAM Type: Synchronous
34 Speed: Unknown
35 Error Correction Type: Single-bit ECC
36 System Type: Unified
37 Associativity: 8-way Set-associative
38
39Handle 0x0002, DMI type 7, 19 bytes
40Cache Information
41 Socket Designation: L3-Cache
42 Configuration: Enabled, Not Socketed, Level 3
43 Operational Mode: Varies With Memory Address
44 Location: Internal
45 Installed Size: 25600 kB
46 Maximum Size: 25600 kB
47 Supported SRAM Types:
48 Synchronous
49 Installed SRAM Type: Synchronous
50 Speed: Unknown
51 Error Correction Type: Single-bit ECC
52 System Type: Unified
53 Associativity: Fully Associative
54
55Handle 0x0003, DMI type 4, 48 bytes
56Processor Information
57 Socket Designation: Socket 1
58 Type: Central Processor
59 Family: Xeon
60 Manufacturer: Intel(R) Corporation
61 ID: F1 06 04 00 FF FB EB BF
62 Signature: Type 0, Family 6, Model 79, Stepping 1
63 Flags:
64 FPU (Floating-point unit on-chip)
65 VME (Virtual mode extension)
66 DE (Debugging extension)
67 PSE (Page size extension)
68 TSC (Time stamp counter)
69 MSR (Model specific registers)
70 PAE (Physical address extension)
71 MCE (Machine check exception)
72 CX8 (CMPXCHG8 instruction supported)
73 APIC (On-chip APIC hardware supported)
74 SEP (Fast system call)
75 MTRR (Memory type range registers)
76 PGE (Page global enable)
77 MCA (Machine check architecture)
78 CMOV (Conditional move instruction supported)
79 PAT (Page attribute table)
80 PSE-36 (36-bit page size extension)
81 CLFSH (CLFLUSH instruction supported)
82 DS (Debug store)
83 ACPI (ACPI supported)
84 MMX (MMX technology supported)
85 FXSR (FXSAVE and FXSTOR instructions supported)
86 SSE (Streaming SIMD extensions)
87 SSE2 (Streaming SIMD extensions 2)
88 SS (Self-snoop)
89 HTT (Multi-threading)
90 TM (Thermal monitor supported)
91 PBE (Pending break enabled)
92 Version: Intel(R) Xeon(R) CPU E5-2689 v4 @ 3.10GHz
93 Voltage: 1.8 V
94 External Clock: 100 MHz
95 Max Speed: 4000 MHz
96 Current Speed: 3100 MHz
97 Status: Populated, Enabled
98 Upgrade: Socket LGA2011-3
99 L1 Cache Handle: 0x0000
100 L2 Cache Handle: 0x0001
101 L3 Cache Handle: 0x0002
102 Serial Number: Not Specified
103 Asset Tag: Unknown
104 Part Number: Not Specified
105 Core Count: 10
106 Core Enabled: 10
107 Thread Count: 20
108 Characteristics:
109 64-bit capable
110 Multi-Core
111 Hardware Thread
112 Execute Protection
113 Enhanced Virtualization
114 Power/Performance Control
115
116Handle 0x0004, DMI type 7, 19 bytes
117Cache Information
118 Socket Designation: L1-Cache
119 Configuration: Enabled, Not Socketed, Level 1
120 Operational Mode: Write Back
121 Location: Internal
122 Installed Size: 64 kB
123 Maximum Size: 64 kB
124 Supported SRAM Types:
125 Synchronous
126 Installed SRAM Type: Synchronous
127 Speed: Unknown
128 Error Correction Type: Single-bit ECC
129 System Type: Instruction
130 Associativity: 8-way Set-associative
131
132Handle 0x0005, DMI type 7, 19 bytes
133Cache Information
134 Socket Designation: L2-Cache
135 Configuration: Enabled, Not Socketed, Level 2
136 Operational Mode: Varies With Memory Address
137 Location: Internal
138 Installed Size: 256 kB
139 Maximum Size: 256 kB
140 Supported SRAM Types:
141 Synchronous
142 Installed SRAM Type: Synchronous
143 Speed: Unknown
144 Error Correction Type: Single-bit ECC
145 System Type: Unified
146 Associativity: 8-way Set-associative
147
148Handle 0x0006, DMI type 7, 19 bytes
149Cache Information
150 Socket Designation: L3-Cache
151 Configuration: Enabled, Not Socketed, Level 3
152 Operational Mode: Varies With Memory Address
153 Location: Internal
154 Installed Size: 25600 kB
155 Maximum Size: 25600 kB
156 Supported SRAM Types:
157 Synchronous
158 Installed SRAM Type: Synchronous
159 Speed: Unknown
160 Error Correction Type: Single-bit ECC
161 System Type: Unified
162 Associativity: Fully Associative
163
164Handle 0x0007, DMI type 4, 48 bytes
165Processor Information
166 Socket Designation: Socket 2
167 Type: Central Processor
168 Family: Xeon
169 Manufacturer: Intel(R) Corporation
170 ID: F1 06 04 00 FF FB EB BF
171 Signature: Type 0, Family 6, Model 79, Stepping 1
172 Flags:
173 FPU (Floating-point unit on-chip)
174 VME (Virtual mode extension)
175 DE (Debugging extension)
176 PSE (Page size extension)
177 TSC (Time stamp counter)
178 MSR (Model specific registers)
179 PAE (Physical address extension)
180 MCE (Machine check exception)
181 CX8 (CMPXCHG8 instruction supported)
182 APIC (On-chip APIC hardware supported)
183 SEP (Fast system call)
184 MTRR (Memory type range registers)
185 PGE (Page global enable)
186 MCA (Machine check architecture)
187 CMOV (Conditional move instruction supported)
188 PAT (Page attribute table)
189 PSE-36 (36-bit page size extension)
190 CLFSH (CLFLUSH instruction supported)
191 DS (Debug store)
192 ACPI (ACPI supported)
193 MMX (MMX technology supported)
194 FXSR (FXSAVE and FXSTOR instructions supported)
195 SSE (Streaming SIMD extensions)
196 SSE2 (Streaming SIMD extensions 2)
197 SS (Self-snoop)
198 HTT (Multi-threading)
199 TM (Thermal monitor supported)
200 PBE (Pending break enabled)
201 Version: Intel(R) Xeon(R) CPU E5-2689 v4 @ 3.10GHz
202 Voltage: 1.8 V
203 External Clock: 100 MHz
204 Max Speed: 4000 MHz
205 Current Speed: 3100 MHz
206 Status: Populated, Enabled
207 Upgrade: Socket LGA2011-3
208 L1 Cache Handle: 0x0004
209 L2 Cache Handle: 0x0005
210 L3 Cache Handle: 0x0006
211 Serial Number: Not Specified
212 Asset Tag: Unknown
213 Part Number: Not Specified
214 Core Count: 10
215 Core Enabled: 10
216 Thread Count: 20
217 Characteristics:
218 64-bit capable
219 Multi-Core
220 Hardware Thread
221 Execute Protection
222 Enhanced Virtualization
223 Power/Performance Control
224
225Handle 0x0008, DMI type 16, 23 bytes
226Physical Memory Array
227 Location: System Board Or Motherboard
228 Use: System Memory
229 Error Correction Type: Multi-bit ECC
230 Maximum Capacity: 1536 GB
231 Error Information Handle: Not Provided
232 Number Of Devices: 24
233
234Handle 0x0009, DMI type 19, 31 bytes
235Memory Array Mapped Address
236 Starting Address: 0x00000000000
237 Ending Address: 0x00FFFFFFFFF
238 Range Size: 64 GB
239 Physical Array Handle: 0x0008
240 Partition Width: 24
241
242Handle 0x000A, DMI type 17, 40 bytes
243Memory Device
244 Array Handle: 0x0008
245 Error Information Handle: Not Provided
246 Total Width: 72 bits
247 Data Width: 64 bits
248 Size: 16384 MB
249 Form Factor: DIMM
250 Set: None
251 Locator: Dimm 1
252 Bank Locator: CPU 1
253 Type: DDR4
254 Type Detail: Synchronous
255 Speed: 2133 MT/s
256 Manufacturer: Hynix
257 Serial Number: 108DEFAD
258 Asset Tag: Unknown
259 Part Number: HMA42GR7MFR4N-TF
260 Rank: 2
261 Configured Memory Speed: 2133 MT/s
262 Minimum Voltage: 1.2 V
263 Maximum Voltage: 1.2 V
264 Configured Voltage: 1.2 V
265
266Handle 0x000B, DMI type 17, 40 bytes
267Memory Device
268 Array Handle: 0x0008
269 Error Information Handle: Not Provided
270 Total Width: Unknown
271 Data Width: Unknown
272 Size: No Module Installed
273 Form Factor: DIMM
274 Set: None
275 Locator: Dimm 2
276 Bank Locator: CPU 1
277 Type: DDR4
278 Type Detail: Synchronous
279 Speed: Unknown
280 Manufacturer: NO DIMM
281 Serial Number: Unknown
282 Asset Tag: Unknown
283 Part Number: Unknown
284 Rank: Unknown
285 Configured Memory Speed: Unknown
286 Minimum Voltage: Unknown
287 Maximum Voltage: Unknown
288 Configured Voltage: Unknown
289
290Handle 0x000C, DMI type 17, 40 bytes
291Memory Device
292 Array Handle: 0x0008
293 Error Information Handle: Not Provided
294 Total Width: Unknown
295 Data Width: Unknown
296 Size: No Module Installed
297 Form Factor: DIMM
298 Set: None
299 Locator: Dimm 3
300 Bank Locator: CPU 1
301 Type: DDR4
302 Type Detail: Synchronous
303 Speed: Unknown
304 Manufacturer: NO DIMM
305 Serial Number: Unknown
306 Asset Tag: Unknown
307 Part Number: Unknown
308 Rank: Unknown
309 Configured Memory Speed: Unknown
310 Minimum Voltage: Unknown
311 Maximum Voltage: Unknown
312 Configured Voltage: Unknown
313
314Handle 0x000D, DMI type 17, 40 bytes
315Memory Device
316 Array Handle: 0x0008
317 Error Information Handle: Not Provided
318 Total Width: 72 bits
319 Data Width: 64 bits
320 Size: 16384 MB
321 Form Factor: DIMM
322 Set: None
323 Locator: Dimm 4
324 Bank Locator: CPU 1
325 Type: DDR4
326 Type Detail: Synchronous
327 Speed: 2133 MT/s
328 Manufacturer: Hynix
329 Serial Number: 108DEFB5
330 Asset Tag: Unknown
331 Part Number: HMA42GR7MFR4N-TF
332 Rank: 2
333 Configured Memory Speed: 2133 MT/s
334 Minimum Voltage: 1.2 V
335 Maximum Voltage: 1.2 V
336 Configured Voltage: 1.2 V
337
338Handle 0x000E, DMI type 17, 40 bytes
339Memory Device
340 Array Handle: 0x0008
341 Error Information Handle: Not Provided
342 Total Width: Unknown
343 Data Width: Unknown
344 Size: No Module Installed
345 Form Factor: DIMM
346 Set: None
347 Locator: Dimm 5
348 Bank Locator: CPU 1
349 Type: DDR4
350 Type Detail: Synchronous
351 Speed: Unknown
352 Manufacturer: NO DIMM
353 Serial Number: Unknown
354 Asset Tag: Unknown
355 Part Number: Unknown
356 Rank: Unknown
357 Configured Memory Speed: Unknown
358 Minimum Voltage: Unknown
359 Maximum Voltage: Unknown
360 Configured Voltage: Unknown
361
362Handle 0x000F, DMI type 17, 40 bytes
363Memory Device
364 Array Handle: 0x0008
365 Error Information Handle: Not Provided
366 Total Width: Unknown
367 Data Width: Unknown
368 Size: No Module Installed
369 Form Factor: DIMM
370 Set: None
371 Locator: Dimm 6
372 Bank Locator: CPU 1
373 Type: DDR4
374 Type Detail: Synchronous
375 Speed: Unknown
376 Manufacturer: NO DIMM
377 Serial Number: Unknown
378 Asset Tag: Unknown
379 Part Number: Unknown
380 Rank: Unknown
381 Configured Memory Speed: Unknown
382 Minimum Voltage: Unknown
383 Maximum Voltage: Unknown
384 Configured Voltage: Unknown
385
386Handle 0x0010, DMI type 17, 40 bytes
387Memory Device
388 Array Handle: 0x0008
389 Error Information Handle: Not Provided
390 Total Width: Unknown
391 Data Width: Unknown
392 Size: No Module Installed
393 Form Factor: DIMM
394 Set: None
395 Locator: Dimm 7
396 Bank Locator: CPU 1
397 Type: DDR4
398 Type Detail: Synchronous
399 Speed: Unknown
400 Manufacturer: NO DIMM
401 Serial Number: Unknown
402 Asset Tag: Unknown
403 Part Number: Unknown
404 Rank: Unknown
405 Configured Memory Speed: Unknown
406 Minimum Voltage: Unknown
407 Maximum Voltage: Unknown
408 Configured Voltage: Unknown
409
410Handle 0x0011, DMI type 17, 40 bytes
411Memory Device
412 Array Handle: 0x0008
413 Error Information Handle: Not Provided
414 Total Width: Unknown
415 Data Width: Unknown
416 Size: No Module Installed
417 Form Factor: DIMM
418 Set: None
419 Locator: Dimm 8
420 Bank Locator: CPU 1
421 Type: DDR4
422 Type Detail: Synchronous
423 Speed: Unknown
424 Manufacturer: NO DIMM
425 Serial Number: Unknown
426 Asset Tag: Unknown
427 Part Number: Unknown
428 Rank: Unknown
429 Configured Memory Speed: Unknown
430 Minimum Voltage: Unknown
431 Maximum Voltage: Unknown
432 Configured Voltage: Unknown
433
434Handle 0x0012, DMI type 17, 40 bytes
435Memory Device
436 Array Handle: 0x0008
437 Error Information Handle: Not Provided
438 Total Width: Unknown
439 Data Width: Unknown
440 Size: No Module Installed
441 Form Factor: DIMM
442 Set: None
443 Locator: Dimm 9
444 Bank Locator: CPU 1
445 Type: DDR4
446 Type Detail: Synchronous
447 Speed: Unknown
448 Manufacturer: NO DIMM
449 Serial Number: Unknown
450 Asset Tag: Unknown
451 Part Number: Unknown
452 Rank: Unknown
453 Configured Memory Speed: Unknown
454 Minimum Voltage: Unknown
455 Maximum Voltage: Unknown
456 Configured Voltage: Unknown
457
458Handle 0x0013, DMI type 17, 40 bytes
459Memory Device
460 Array Handle: 0x0008
461 Error Information Handle: Not Provided
462 Total Width: Unknown
463 Data Width: Unknown
464 Size: No Module Installed
465 Form Factor: DIMM
466 Set: None
467 Locator: Dimm 10
468 Bank Locator: CPU 1
469 Type: DDR4
470 Type Detail: Synchronous
471 Speed: Unknown
472 Manufacturer: NO DIMM
473 Serial Number: Unknown
474 Asset Tag: Unknown
475 Part Number: Unknown
476 Rank: Unknown
477 Configured Memory Speed: Unknown
478 Minimum Voltage: Unknown
479 Maximum Voltage: Unknown
480 Configured Voltage: Unknown
481
482Handle 0x0014, DMI type 17, 40 bytes
483Memory Device
484 Array Handle: 0x0008
485 Error Information Handle: Not Provided
486 Total Width: Unknown
487 Data Width: Unknown
488 Size: No Module Installed
489 Form Factor: DIMM
490 Set: None
491 Locator: Dimm 11
492 Bank Locator: CPU 1
493 Type: DDR4
494 Type Detail: Synchronous
495 Speed: Unknown
496 Manufacturer: NO DIMM
497 Serial Number: Unknown
498 Asset Tag: Unknown
499 Part Number: Unknown
500 Rank: Unknown
501 Configured Memory Speed: Unknown
502 Minimum Voltage: Unknown
503 Maximum Voltage: Unknown
504 Configured Voltage: Unknown
505
506Handle 0x0015, DMI type 17, 40 bytes
507Memory Device
508 Array Handle: 0x0008
509 Error Information Handle: Not Provided
510 Total Width: Unknown
511 Data Width: Unknown
512 Size: No Module Installed
513 Form Factor: DIMM
514 Set: None
515 Locator: Dimm 12
516 Bank Locator: CPU 1
517 Type: DDR4
518 Type Detail: Synchronous
519 Speed: Unknown
520 Manufacturer: NO DIMM
521 Serial Number: Unknown
522 Asset Tag: Unknown
523 Part Number: Unknown
524 Rank: Unknown
525 Configured Memory Speed: Unknown
526 Minimum Voltage: Unknown
527 Maximum Voltage: Unknown
528 Configured Voltage: Unknown
529
530Handle 0x0016, DMI type 17, 40 bytes
531Memory Device
532 Array Handle: 0x0008
533 Error Information Handle: Not Provided
534 Total Width: 72 bits
535 Data Width: 64 bits
536 Size: 16384 MB
537 Form Factor: DIMM
538 Set: None
539 Locator: Dimm 13
540 Bank Locator: CPU 2
541 Type: DDR4
542 Type Detail: Synchronous
543 Speed: 2133 MT/s
544 Manufacturer: Hynix
545 Serial Number: 108DF039
546 Asset Tag: Unknown
547 Part Number: HMA42GR7MFR4N-TF
548 Rank: 2
549 Configured Memory Speed: 2133 MT/s
550 Minimum Voltage: 1.2 V
551 Maximum Voltage: 1.2 V
552 Configured Voltage: 1.2 V
553
554Handle 0x0017, DMI type 17, 40 bytes
555Memory Device
556 Array Handle: 0x0008
557 Error Information Handle: Not Provided
558 Total Width: Unknown
559 Data Width: Unknown
560 Size: No Module Installed
561 Form Factor: DIMM
562 Set: None
563 Locator: Dimm 14
564 Bank Locator: CPU 2
565 Type: DDR4
566 Type Detail: Synchronous
567 Speed: Unknown
568 Manufacturer: NO DIMM
569 Serial Number: Unknown
570 Asset Tag: Unknown
571 Part Number: Unknown
572 Rank: Unknown
573 Configured Memory Speed: Unknown
574 Minimum Voltage: Unknown
575 Maximum Voltage: Unknown
576 Configured Voltage: Unknown
577
578Handle 0x0018, DMI type 17, 40 bytes
579Memory Device
580 Array Handle: 0x0008
581 Error Information Handle: Not Provided
582 Total Width: Unknown
583 Data Width: Unknown
584 Size: No Module Installed
585 Form Factor: DIMM
586 Set: None
587 Locator: Dimm 15
588 Bank Locator: CPU 2
589 Type: DDR4
590 Type Detail: Synchronous
591 Speed: Unknown
592 Manufacturer: NO DIMM
593 Serial Number: Unknown
594 Asset Tag: Unknown
595 Part Number: Unknown
596 Rank: Unknown
597 Configured Memory Speed: Unknown
598 Minimum Voltage: Unknown
599 Maximum Voltage: Unknown
600 Configured Voltage: Unknown
601
602Handle 0x0019, DMI type 17, 40 bytes
603Memory Device
604 Array Handle: 0x0008
605 Error Information Handle: Not Provided
606 Total Width: 72 bits
607 Data Width: 64 bits
608 Size: 16384 MB
609 Form Factor: DIMM
610 Set: None
611 Locator: Dimm 16
612 Bank Locator: CPU 2
613 Type: DDR4
614 Type Detail: Synchronous
615 Speed: 2133 MT/s
616 Manufacturer: Hynix
617 Serial Number: 108DEFB8
618 Asset Tag: Unknown
619 Part Number: HMA42GR7MFR4N-TF
620 Rank: 2
621 Configured Memory Speed: 2133 MT/s
622 Minimum Voltage: 1.2 V
623 Maximum Voltage: 1.2 V
624 Configured Voltage: 1.2 V
625
626Handle 0x001A, DMI type 17, 40 bytes
627Memory Device
628 Array Handle: 0x0008
629 Error Information Handle: Not Provided
630 Total Width: Unknown
631 Data Width: Unknown
632 Size: No Module Installed
633 Form Factor: DIMM
634 Set: None
635 Locator: Dimm 17
636 Bank Locator: CPU 2
637 Type: DDR4
638 Type Detail: Synchronous
639 Speed: Unknown
640 Manufacturer: NO DIMM
641 Serial Number: Unknown
642 Asset Tag: Unknown
643 Part Number: Unknown
644 Rank: Unknown
645 Configured Memory Speed: Unknown
646 Minimum Voltage: Unknown
647 Maximum Voltage: Unknown
648 Configured Voltage: Unknown
649
650Handle 0x001B, DMI type 17, 40 bytes
651Memory Device
652 Array Handle: 0x0008
653 Error Information Handle: Not Provided
654 Total Width: Unknown
655 Data Width: Unknown
656 Size: No Module Installed
657 Form Factor: DIMM
658 Set: None
659 Locator: Dimm 18
660 Bank Locator: CPU 2
661 Type: DDR4
662 Type Detail: Synchronous
663 Speed: Unknown
664 Manufacturer: NO DIMM
665 Serial Number: Unknown
666 Asset Tag: Unknown
667 Part Number: Unknown
668 Rank: Unknown
669 Configured Memory Speed: Unknown
670 Minimum Voltage: Unknown
671 Maximum Voltage: Unknown
672 Configured Voltage: Unknown
673
674Handle 0x001C, DMI type 17, 40 bytes
675Memory Device
676 Array Handle: 0x0008
677 Error Information Handle: Not Provided
678 Total Width: Unknown
679 Data Width: Unknown
680 Size: No Module Installed
681 Form Factor: DIMM
682 Set: None
683 Locator: Dimm 19
684 Bank Locator: CPU 2
685 Type: DDR4
686 Type Detail: Synchronous
687 Speed: Unknown
688 Manufacturer: NO DIMM
689 Serial Number: Unknown
690 Asset Tag: Unknown
691 Part Number: Unknown
692 Rank: Unknown
693 Configured Memory Speed: Unknown
694 Minimum Voltage: Unknown
695 Maximum Voltage: Unknown
696 Configured Voltage: Unknown
697
698Handle 0x001D, DMI type 17, 40 bytes
699Memory Device
700 Array Handle: 0x0008
701 Error Information Handle: Not Provided
702 Total Width: Unknown
703 Data Width: Unknown
704 Size: No Module Installed
705 Form Factor: DIMM
706 Set: None
707 Locator: Dimm 20
708 Bank Locator: CPU 2
709 Type: DDR4
710 Type Detail: Synchronous
711 Speed: Unknown
712 Manufacturer: NO DIMM
713 Serial Number: Unknown
714 Asset Tag: Unknown
715 Part Number: Unknown
716 Rank: Unknown
717 Configured Memory Speed: Unknown
718 Minimum Voltage: Unknown
719 Maximum Voltage: Unknown
720 Configured Voltage: Unknown
721
722Handle 0x001E, DMI type 17, 40 bytes
723Memory Device
724 Array Handle: 0x0008
725 Error Information Handle: Not Provided
726 Total Width: Unknown
727 Data Width: Unknown
728 Size: No Module Installed
729 Form Factor: DIMM
730 Set: None
731 Locator: Dimm 21
732 Bank Locator: CPU 2
733 Type: DDR4
734 Type Detail: Synchronous
735 Speed: Unknown
736 Manufacturer: NO DIMM
737 Serial Number: Unknown
738 Asset Tag: Unknown
739 Part Number: Unknown
740 Rank: Unknown
741 Configured Memory Speed: Unknown
742 Minimum Voltage: Unknown
743 Maximum Voltage: Unknown
744 Configured Voltage: Unknown
745
746Handle 0x001F, DMI type 17, 40 bytes
747Memory Device
748 Array Handle: 0x0008
749 Error Information Handle: Not Provided
750 Total Width: Unknown
751 Data Width: Unknown
752 Size: No Module Installed
753 Form Factor: DIMM
754 Set: None
755 Locator: Dimm 22
756 Bank Locator: CPU 2
757 Type: DDR4
758 Type Detail: Synchronous
759 Speed: Unknown
760 Manufacturer: NO DIMM
761 Serial Number: Unknown
762 Asset Tag: Unknown
763 Part Number: Unknown
764 Rank: Unknown
765 Configured Memory Speed: Unknown
766 Minimum Voltage: Unknown
767 Maximum Voltage: Unknown
768 Configured Voltage: Unknown
769
770Handle 0x0020, DMI type 17, 40 bytes
771Memory Device
772 Array Handle: 0x0008
773 Error Information Handle: Not Provided
774 Total Width: Unknown
775 Data Width: Unknown
776 Size: No Module Installed
777 Form Factor: DIMM
778 Set: None
779 Locator: Dimm 23
780 Bank Locator: CPU 2
781 Type: DDR4
782 Type Detail: Synchronous
783 Speed: Unknown
784 Manufacturer: NO DIMM
785 Serial Number: Unknown
786 Asset Tag: Unknown
787 Part Number: Unknown
788 Rank: Unknown
789 Configured Memory Speed: Unknown
790 Minimum Voltage: Unknown
791 Maximum Voltage: Unknown
792 Configured Voltage: Unknown
793
794Handle 0x0021, DMI type 17, 40 bytes
795Memory Device
796 Array Handle: 0x0008
797 Error Information Handle: Not Provided
798 Total Width: Unknown
799 Data Width: Unknown
800 Size: No Module Installed
801 Form Factor: DIMM
802 Set: None
803 Locator: Dimm 24
804 Bank Locator: CPU 2
805 Type: DDR4
806 Type Detail: Synchronous
807 Speed: Unknown
808 Manufacturer: NO DIMM
809 Serial Number: Unknown
810 Asset Tag: Unknown
811 Part Number: Unknown
812 Rank: Unknown
813 Configured Memory Speed: Unknown
814 Minimum Voltage: Unknown
815 Maximum Voltage: Unknown
816 Configured Voltage: Unknown
817
818Handle 0x0022, DMI type 0, 24 bytes
819BIOS Information
820 Vendor: LENOVO
821 Version: -[TBE132I-2.50]-
822 Release Date: 10/11/2017
823 Address: 0xF0000
824 Runtime Size: 64 kB
825 ROM Size: 16 MB
826 Characteristics:
827 PCI is supported
828 PNP is supported
829 BIOS is upgradeable
830 BIOS shadowing is allowed
831 Boot from CD is supported
832 Selectable boot is supported
833 EDD is supported
834 5.25"/1.2 MB floppy services are supported (int 13h)
835 3.5"/720 kB floppy services are supported (int 13h)
836 3.5"/2.88 MB floppy services are supported (int 13h)
837 Print screen service is supported (int 5h)
838 8042 keyboard services are supported (int 9h)
839 Serial services are supported (int 14h)
840 Printer services are supported (int 17h)
841 CGA/mono video services are supported (int 10h)
842 ACPI is supported
843 USB legacy is supported
844 LS-120 boot is supported
845 ATAPI Zip drive boot is supported
846 Function key-initiated network boot is supported
847 Targeted content distribution is supported
848 UEFI is supported
849 BIOS Revision: 2.50
850 Firmware Revision: 2.50
851
852Handle 0x0023, DMI type 1, 27 bytes
853System Information
854 Manufacturer: LENOVO
855 Product Name: System x3550 M5: -[5463AC1]-
856 Version: 07
857 Serial Number: 06EEEAR
858 UUID: 7b75005c-d029-11e4-9aa6-40f2e9b938a0
859 Wake-up Type: Power Switch
860 SKU Number: (none)
861 Family: System X
862
863Handle 0x0024, DMI type 2, 17 bytes
864Base Board Information
865 Manufacturer: LENOVO
866 Product Name: 00MU647
867 Version: SVT
868 Serial Number: 51W03H
869 Asset Tag: (none)
870 Features:
871 Board is a hosting board
872 Board is replaceable
873 Location In Chassis: Rack Mount
874 Chassis Handle: 0x0000
875 Type: Motherboard
876 Contained Object Handles: 0
877
878Handle 0x0025, DMI type 3, 24 bytes
879Chassis Information
880 Manufacturer: LENOVO
881 Type: Rack Mount Chassis
882 Lock: Not Present
883 Version: none
884 Serial Number: none
885 Asset Tag: none
886 Boot-up State: Unknown
887 Power Supply State: Safe
888 Thermal State: Unknown
889 Security Status: Unknown
890 OEM Information: 0x00000000
891 Height: 1 U
892 Number Of Power Cords: 2
893 Contained Elements: 0
894 SKU Number: Not Specified
895
896Handle 0x0026, DMI type 8, 9 bytes
897Port Connector Information
898 Internal Reference Designator: SATA Port 0
899 Internal Connector Type: SAS/SATA Plug Receptacle
900 External Reference Designator: None
901 External Connector Type: None
902 Port Type: SATA
903
904Handle 0x0027, DMI type 8, 9 bytes
905Port Connector Information
906 Internal Reference Designator: SATA Port 1
907 Internal Connector Type: SAS/SATA Plug Receptacle
908 External Reference Designator: None
909 External Connector Type: None
910 Port Type: SATA
911
912Handle 0x0028, DMI type 8, 9 bytes
913Port Connector Information
914 Internal Reference Designator: SATA ODD
915 Internal Connector Type: SAS/SATA Plug Receptacle
916 External Reference Designator: None
917 External Connector Type: None
918 Port Type: SATA
919
920Handle 0x0029, DMI type 8, 9 bytes
921Port Connector Information
922 Internal Reference Designator: None
923 Internal Connector Type: None
924 External Reference Designator: Video 1
925 External Connector Type: DB-15 female
926 Port Type: Video Port
927
928Handle 0x002A, DMI type 8, 9 bytes
929Port Connector Information
930 Internal Reference Designator: Video 2
931 Internal Connector Type: DB-15 female
932 External Reference Designator: None
933 External Connector Type: None
934 Port Type: Video Port
935
936Handle 0x002B, DMI type 8, 9 bytes
937Port Connector Information
938 Internal Reference Designator: COM
939 Internal Connector Type: Other
940 External Reference Designator: None
941 External Connector Type: None
942 Port Type: Serial Port 16550A Compatible
943
944Handle 0x002C, DMI type 8, 9 bytes
945Port Connector Information
946 Internal Reference Designator: USB Port Front
947 Internal Connector Type: Access Bus (USB)
948 External Reference Designator: None
949 External Connector Type: None
950 Port Type: USB
951
952Handle 0x002D, DMI type 8, 9 bytes
953Port Connector Information
954 Internal Reference Designator: USB Port Front
955 Internal Connector Type: Access Bus (USB)
956 External Reference Designator: None
957 External Connector Type: None
958 Port Type: USB
959
960Handle 0x002E, DMI type 8, 9 bytes
961Port Connector Information
962 Internal Reference Designator: USB Port Front
963 Internal Connector Type: Access Bus (USB)
964 External Reference Designator: None
965 External Connector Type: None
966 Port Type: USB
967
968Handle 0x002F, DMI type 8, 9 bytes
969Port Connector Information
970 Internal Reference Designator: USB Port Clippy
971 Internal Connector Type: Access Bus (USB)
972 External Reference Designator: None
973 External Connector Type: None
974 Port Type: USB
975
976Handle 0x0030, DMI type 8, 9 bytes
977Port Connector Information
978 Internal Reference Designator: USB Port Hypervisor
979 Internal Connector Type: Access Bus (USB)
980 External Reference Designator: None
981 External Connector Type: None
982 Port Type: USB
983
984Handle 0x0031, DMI type 8, 9 bytes
985Port Connector Information
986 Internal Reference Designator: None
987 Internal Connector Type: None
988 External Reference Designator: USB Port 1 Rear
989 External Connector Type: Access Bus (USB)
990 Port Type: USB
991
992Handle 0x0032, DMI type 8, 9 bytes
993Port Connector Information
994 Internal Reference Designator: None
995 Internal Connector Type: None
996 External Reference Designator: USB Port 2 Rear
997 External Connector Type: Access Bus (USB)
998 Port Type: USB
999
1000Handle 0x0033, DMI type 8, 9 bytes
1001Port Connector Information
1002 Internal Reference Designator: None
1003 Internal Connector Type: None
1004 External Reference Designator: USB Port 3 Rear
1005 External Connector Type: Access Bus (USB)
1006 Port Type: USB
1007
1008Handle 0x0034, DMI type 8, 9 bytes
1009Port Connector Information
1010 Internal Reference Designator: None
1011 Internal Connector Type: None
1012 External Reference Designator: Ethernet 1
1013 External Connector Type: RJ-45
1014 Port Type: Network Port
1015
1016Handle 0x0035, DMI type 8, 9 bytes
1017Port Connector Information
1018 Internal Reference Designator: None
1019 Internal Connector Type: None
1020 External Reference Designator: Ethernet 2
1021 External Connector Type: RJ-45
1022 Port Type: Network Port
1023
1024Handle 0x0036, DMI type 8, 9 bytes
1025Port Connector Information
1026 Internal Reference Designator: None
1027 Internal Connector Type: None
1028 External Reference Designator: Ethernet 3
1029 External Connector Type: RJ-45
1030 Port Type: Network Port
1031
1032Handle 0x0037, DMI type 8, 9 bytes
1033Port Connector Information
1034 Internal Reference Designator: None
1035 Internal Connector Type: None
1036 External Reference Designator: Ethernet 4
1037 External Connector Type: RJ-45
1038 Port Type: Network Port
1039
1040Handle 0x0038, DMI type 8, 9 bytes
1041Port Connector Information
1042 Internal Reference Designator: None
1043 Internal Connector Type: None
1044 External Reference Designator: Dedicated
1045 External Connector Type: RJ-45
1046 Port Type: Network Port
1047
1048Handle 0x0039, DMI type 9, 17 bytes
1049System Slot Information
1050 Designation: Slot 1
1051 Type: x16 PCI Express 3 x16
1052 Current Usage: In Use
1053 Length: <OUT OF SPEC>
1054 ID: 1
1055 Characteristics:
1056 3.3 V is provided
1057 Bus Address: 0000:06:00.0
1058
1059Handle 0x003A, DMI type 9, 17 bytes
1060System Slot Information
1061 Designation: Slot 4
1062 Type: x8 PCI Express 3 x8
1063 Current Usage: In Use
1064 Length: <OUT OF SPEC>
1065 ID: 4
1066 Characteristics:
1067 3.3 V is provided
1068 Bus Address: 0000:01:00.0
1069
1070Handle 0x003B, DMI type 11, 5 bytes
1071OEM Strings
1072 String 1: LENOVO SystemX
1073
1074Handle 0x003C, DMI type 11, 5 bytes
1075OEM Strings
1076 String 1: $SI Integrated BaseBoard Mgmt Cont 2.50 -[TCOO16P]-
1077
1078Handle 0x003D, DMI type 11, 5 bytes
1079OEM Strings
1080 String 1: $CR CRTM Primary Code 2.50 -[TBE132I]-
1081
1082Handle 0x003E, DMI type 11, 5 bytes
1083OEM Strings
1084 String 1: $CB CRTM Backup Code 2.50 -[TBE132I]-
1085
1086Handle 0x003F, DMI type 11, 5 bytes
1087OEM Strings
1088 String 1: $DS Preboot Diagnostics (DSA) 10.1 -[DSALA6S ]-
1089
1090Handle 0x0040, DMI type 11, 5 bytes
1091OEM Strings
1092 String 1: $MV Min UEFI Version -[TBE121AUS-2.00]-
1093
1094Handle 0x0041, DMI type 11, 5 bytes
1095OEM Strings
1096 String 1: $BB UEFI Backup Version -[TBE132I-2.50]-
1097
1098Handle 0x0042, DMI type 11, 5 bytes
1099OEM Strings
1100 String 1: $QP QPI Version -[04.03.00]-
1101
1102Handle 0x0043, DMI type 11, 5 bytes
1103OEM Strings
1104 String 1: $MR MRC Version -[04.03.00]-
1105
1106Handle 0x0044, DMI type 11, 5 bytes
1107OEM Strings
1108 String 1: $CS CSM Version -[TESTBLDUS]-
1109
1110Handle 0x0045, DMI type 11, 5 bytes
1111OEM Strings
1112 String 1: $ME ME Firmware Version -[3.1.3.38]-
1113
1114Handle 0x0046, DMI type 11, 5 bytes
1115OEM Strings
1116 String 1: $BD -[]-
1117
1118Handle 0x0047, DMI type 11, 5 bytes
1119OEM Strings
1120 String 1: $CF Current UEFI Flash Bank - Primary
1121
1122Handle 0x0048, DMI type 11, 5 bytes
1123OEM Strings
1124 String 1: $BP UEFI Primary Version -[TBE132I-2.50]-
1125
1126Handle 0x0049, DMI type 12, 5 bytes
1127System Configuration Options
1128 Option 1: J7 pin1-2: TPM PP Disable, pin2-3: TPM PP Enable
1129
1130Handle 0x004A, DMI type 13, 22 bytes
1131BIOS Language Information
1132 Language Description Format: Abbreviated
1133 Installable Languages: 1
1134 enUS
1135 Currently Installed Language: enUS
1136
1137Handle 0x004B, DMI type 32, 11 bytes
1138System Boot Information
1139 Status: No errors detected
1140
1141Handle 0x004C, DMI type 38, 18 bytes
1142IPMI Device Information
1143 Interface Type: KCS (Keyboard Control Style)
1144 Specification Version: 2.0
1145 I2C Slave Address: 0x10
1146 NV Storage Device: Not Present
1147 Base Address: 0x0000000000000CC0 (I/O)
1148 Register Spacing: Successive Byte Boundaries
1149
1150Handle 0x004D, DMI type 41, 11 bytes
1151Onboard Device
1152 Reference Designation: Ethernet 1
1153 Type: Ethernet
1154 Status: Enabled
1155 Type Instance: 1
1156 Bus Address: 0000:16:00.0
1157
1158Handle 0x004E, DMI type 41, 11 bytes
1159Onboard Device
1160 Reference Designation: Ethernet 2
1161 Type: Ethernet
1162 Status: Enabled
1163 Type Instance: 2
1164 Bus Address: 0000:16:00.1
1165
1166Handle 0x004F, DMI type 41, 11 bytes
1167Onboard Device
1168 Reference Designation: Ethernet 3
1169 Type: Ethernet
1170 Status: Enabled
1171 Type Instance: 3
1172 Bus Address: 0000:16:00.2
1173
1174Handle 0x0050, DMI type 41, 11 bytes
1175Onboard Device
1176 Reference Designation: Ethernet 4
1177 Type: Ethernet
1178 Status: Enabled
1179 Type Instance: 4
1180 Bus Address: 0000:16:00.3
1181
1182Handle 0x0051, DMI type 41, 11 bytes
1183Onboard Device
1184 Reference Designation: Video
1185 Type: Video
1186 Status: Enabled
1187 Type Instance: 1
1188 Bus Address: 0000:14:00.0
1189
1190Handle 0xFEFF, DMI type 127, 4 bytes
1191End Of Table
1192
diff --git a/checkbox_support/parsers/tests/test_dmidecode.py b/checkbox_support/parsers/tests/test_dmidecode.py
index 3df81a6..c4e94d7 100644
--- a/checkbox_support/parsers/tests/test_dmidecode.py
+++ b/checkbox_support/parsers/tests/test_dmidecode.py
@@ -24,6 +24,8 @@ from __future__ import unicode_literals
24from io import StringIO24from io import StringIO
25from unittest import TestCase25from unittest import TestCase
2626
27from pkg_resources import resource_filename
28
27from checkbox_support.parsers.dmidecode import DmidecodeParser29from checkbox_support.parsers.dmidecode import DmidecodeParser
28from checkbox_support.parsers.tests.test_dmi import TestDmiMixin, DmiResult30from checkbox_support.parsers.tests.test_dmi import TestDmiMixin, DmiResult
2931
@@ -92,12 +94,14 @@ BIOS Information
92\tFirmware Revision: 1.794\tFirmware Revision: 1.7
93"""95"""
9496
97
95class TestDmidecodeArtificialParser(TestCase, TestDmiMixin):98class TestDmidecodeArtificialParser(TestCase, TestDmiMixin):
9699
97 def getParser(self):100 def getParser(self):
98 stream = StringIO(FAKE_DMIDECODE)101 stream = StringIO(FAKE_DMIDECODE)
99 return DmidecodeParser(stream)102 return DmidecodeParser(stream)
100103
104
101class TestDmidecodeRealParser(TestCase):105class TestDmidecodeRealParser(TestCase):
102106
103 """107 """
@@ -159,3 +163,30 @@ class TestDmidecodeRealParser(TestCase):
159 self.assertEqual(device.raw_attributes['sku_number'], "LENOVO_MT_20AM")163 self.assertEqual(device.raw_attributes['sku_number'], "LENOVO_MT_20AM")
160 self.assertEqual(device.raw_attributes['uuid'],164 self.assertEqual(device.raw_attributes['uuid'],
161 "170AFF01-52A1-11CB-A7A6-EB7272884401")165 "170AFF01-52A1-11CB-A7A6-EB7272884401")
166
167
168class TestLenovoSystemX(TestCase):
169
170 def parse(self):
171 resource = 'parsers/tests/dmidecode_data/LENOVO_SYSTEMX.txt'
172 filename = resource_filename('checkbox_support', resource)
173 with open(filename, 'rt', encoding='UTF-8') as stream:
174 parser = DmidecodeParser(stream)
175 result = DmiResult()
176 parser.run(result)
177 return result
178
179 def test_system_product_name(self):
180 result = self.parse()
181 dmi_device = result.getDevice("SYSTEM")
182 self.assertTrue(dmi_device)
183 correct_values = {
184 'vendor': 'LENOVO',
185 'name': 'System x3550 M5: -[5463AC1]-',
186 'version': '07',
187 'serial': '06EEEAR',
188 'uuid': '7b75005c-d029-11e4-9aa6-40f2e9b938a0',
189 'wake_up_type': 'Power Switch',
190 'sku_number': '(none)',
191 'family': 'System X'}
192 self.assertDictEqual(dmi_device.raw_attributes, correct_values)

Subscribers

People subscribed via source and target branches