Mercurial > hg > Game > Cerium
view TaskManager/kernel/schedule/ListData.h @ 631:30dd8a3deb4a draft
Cell 64 bit tried, but not yet worked.
Cell's list DMA is 32bit.
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 18 Nov 2009 13:32:58 +0900 |
parents | 0bfab105a770 |
children | 715bbf0955b5 |
line wrap: on
line source
#ifndef INCLUDED_LIST_DATA #define INCLUDED_LIST_DATA #include "base.h" #include "types.h" #define MAX_LIST_DMA_SIZE 8 class ListElement { public: BASE_NEW_DELETE(ListElement); int size; #ifdef __CERIUM_CELL__ uint32 addr; // Cell の仕様なんでどうしようもない... // PowerPC 64bit だと動かない可能性も高いんだが... #else memaddr addr; #endif }; typedef ListElement* ListElementPtr; class ListData { public: BASE_NEW_DELETE(ListData); int length; // The number of data (4) int size; // Total size of data (4) int a[2]; // for alignment int bound[MAX_LIST_DMA_SIZE]; // (4 * MAX_LIST_DMA_SIZE) ListElement element[MAX_LIST_DMA_SIZE]; // (8 * MAX_LIST_DMA_SIZE) void clear(void) { length = 0; size = 0; } }; typedef ListData* ListDataPtr; #endif