Intel uses the same family/model for several CPUs. Sometimes the stepping must be checked to tell them apart. On x86 there can be at most 16 steppings. Add a steppings bitmask to x86_cpu_id and a X86_MATCH_VENDOR_FAMILY_MODEL_STEPPING_FEATURE macro and support for matching against family/model/stepping. [ bp: Massage. ]
Showing the changes to include/linux (1 of 3 files). Show all
Unified · Split
| @@ -663,6 +663,7 @@ struct x86_cpu_id { · 662 unmodified lines | ||
| 663 | 663 | __u16 vendor; |
| 664 | 664 | __u16 family; |
| 665 | 665 | __u16 model; |
| 666 | + __u16 steppings; | |
| 666 | 667 | __u16 feature; /* bit index */ |
| 667 | 668 | kernel_ulong_t driver_data; |
| 668 | 669 | }; |
| @@ -671,6 +672,7 @@ struct x86_cpu_id { · 2 unmodified lines | ||
| 671 | 672 | #define X86_VENDOR_ANY 0xffff |
| 672 | 673 | #define X86_FAMILY_ANY 0 |
| 673 | 674 | #define X86_MODEL_ANY 0 |
| 675 | +#define X86_STEPPING_ANY 0 | |
| 674 | 676 | #define X86_FEATURE_ANY 0 /* Same as FPU, you can't test for that */ |
| 675 | 677 | |
| 676 | 678 | /* |