Ignore:
Timestamp:
Oct 4, 2014, 3:16:21 PM (10 years ago)
Author:
alain
Message:

Introducing fixed format (X_WIDTH / Y_WIDTH / P_WIDTH ) for processor index.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • soft/giet_vm/giet_drivers/mmc_driver.c

    r345 r426  
    159159               unsigned int channel )  // unused
    160160{
    161     unsigned int procid     = _get_procid();
    162     unsigned int cluster_xy = procid / NB_PROCS_MAX;
    163     unsigned int lpid       = procid % NB_PROCS_MAX;
     161    unsigned int gpid       = _get_procid();
     162    unsigned int cluster_xy = gpid >> P_WIDTH;
    164163    unsigned int x          = cluster_xy >> Y_WIDTH;
    165164    unsigned int y          = cluster_xy & ((1<<Y_WIDTH)-1);
     165    unsigned int lpid       = gpid & ((1<<P_WIDTH)-1);
    166166
    167167    _printf("[GIET ERROR] MMC IRQ received by processor[%d,%d,%d]"
Note: See TracChangeset for help on using the changeset viewer.