Changeset 38428aa3 in mainline for kernel/arch/ia64/src/cpu/cpu.c


Ignore:
Timestamp:
2009-08-27T12:23:46Z (15 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
ff211d2
Parents:
c4d11c5
Message:

workaround strict-aliasing rules

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ia64/src/cpu/cpu.c

    rc4d11c5 r38428aa3  
    5454        char vendor[2 * sizeof(uint64_t) + 1];
    5555       
    56         *((uint64_t *) &vendor[0 * sizeof(uint64_t)]) = CPU->arch.cpuid0;
    57         *((uint64_t *) &vendor[1 * sizeof(uint64_t)]) = CPU->arch.cpuid1;
     56        memcpy(vendor, &CPU->arch.cpuid0, 8);
     57        memcpy(vendor + 8, &CPU->arch.cpuid1, 8);
    5858        vendor[sizeof(vendor) - 1] = 0;
    5959       
    60         switch(m->arch.cpuid3.family) {
     60        switch (m->arch.cpuid3.family) {
    6161        case FAMILY_ITANIUM:
    6262                family_str = "Itanium";
Note: See TracChangeset for help on using the changeset viewer.