Fork us on GitHub Follow us on Facebook Follow us on Twitter

Ignore:
Timestamp:
2010-05-08T07:53:23Z (12 years ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
lfn, master
Children:
051bc69a
Parents:
6c39a907 (diff), 1317380 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/sparc64/src/smp/sun4v/smp.c

    r6c39a907 r25a76ab8  
    417417static bool wake_cpu(uint64_t cpuid)
    418418{
    419 
    420419#ifdef CONFIG_SIMICS_SMP_HACK
    421420        ipi_unicast_to((void (*)(void)) 1234, cpuid);
     
    424423        if (__hypercall_fast1(CPU_STOP, cpuid) != EOK)
    425424                return false;
    426 
     425       
    427426        /* wait for the CPU to stop */
    428427        uint64_t state;
    429         __hypercall_fast_ret1(cpuid, 0, 0, 0, 0,
    430                 CPU_STATE, &state);
    431         while (state == CPU_STATE_RUNNING) {
    432                 __hypercall_fast_ret1(cpuid, 0, 0, 0, 0,
    433                         CPU_STATE, &state);
    434         }
    435 
     428        __hypercall_fast_ret1(cpuid, 0, 0, 0, 0, CPU_STATE, &state);
     429        while (state == CPU_STATE_RUNNING)
     430                __hypercall_fast_ret1(cpuid, 0, 0, 0, 0, CPU_STATE, &state);
     431       
    436432        /* make the CPU run again and execute HelenOS code */
    437         if (__hypercall_fast4(
    438                 CPU_START, cpuid,
    439                 (uint64_t) KA2PA(kernel_image_start),
    440                 KA2PA(trap_table), bootinfo.physmem_start                       
    441                 ) != EOK)
    442                         return false;
     433        if (__hypercall_fast4(CPU_START, cpuid,
     434            (uint64_t) KA2PA(kernel_image_start), KA2PA(trap_table),
     435            physmem_start) != EOK)
     436                return false;
    443437#endif
    444 
     438       
    445439        if (waitq_sleep_timeout(&ap_completion_wq, 10000000, SYNCH_FLAGS_NONE) ==
    446                         ESYNCH_TIMEOUT)
    447                 printf("%s: waiting for processor (cpuid = %" PRIu32
    448                 ") timed out\n", __func__, cpuid);
    449 
     440            ESYNCH_TIMEOUT)
     441                printf("%s: waiting for processor (cpuid = %" PRIu32 ") timed out\n",
     442                    __func__, cpuid);
     443       
    450444        return true;
    451445}
Note: See TracChangeset for help on using the changeset viewer.