20 #define LIBSMBIOS_SOURCE
30 #define TODO do { throw NotImplementedImpl(); } while(0)
34 #if defined(DEBUG_TOKEN_DA)
35 # define DCOUT(line) do { cout << line; } while(0)
36 # define DCERR(line) do { cerr << line; } while(0)
38 # define DCOUT(line) do {} while(0)
39 # define DCERR(line) do {} while(0)
47 memcpy( const_cast<calling_interface_token *>(&
token), initToken,
sizeof(
token) );
50 const u8 *ptr =
item->getBufferCopy(size) ;
51 memcpy( const_cast<calling_interface_structure*>(&
structure), ptr,
sizeof(
structure) );
52 delete []
const_cast<u8 *
>(ptr);
109 for(
int i=0; i<2; i++)
116 catch(
const smi::SmiExecutedWithError &)
157 if(byteArray && size >= 2)
159 memset(byteArray, 0, size);
160 memcpy(byteArray, &word,
sizeof(
u16));
164 memcpy(ret, &word,
sizeof(
u16));
180 ci->
setArg( 1, *reinterpret_cast<const u16 *>(byteArray) );
192 std::ios::fmtflags old_opts = cout.flags ();
194 cout << hex << setfill(
'0');
195 cout <<
"DMI type 0x" << setw(2) <<
static_cast<int>(
structure.
type);
199 cout <<
" Type 0x" << setw(4) <<
static_cast<int>(
getType());
200 cout <<
" Location 0x" << setw(4) <<
static_cast<int>(
token.
location);
201 cout <<
" value " << setw(4) <<
static_cast<int>(
token.
value);
203 cout.flags (old_opts);