os/kernelhwsrv/kerneltest/e32utils/testusbcldd/inc/kerndefs.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 // Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of the License "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // f32test\testusbcldd\inc\dtestusblogdev.h
    15 // Macro's, typedefs and definitions to account for changes between EKA1 and EKA2.
    16 // 
    17 //
    18 
    19 /**
    20  @file
    21  @internalTechnology
    22 */
    23 
    24 #ifndef __KERNDEFS_H_
    25 #define __KERNDEFS_H_
    26 
    27 #include <kernel/kern_priv.h>
    28 
    29 /** 
    30  *	OS Version Specifics - Macro'd here to facilitate sharing of code between EKA1 and EKA2
    31  */
    32 typedef HBuf8							HBuf8Plat;
    33 #define __NEWPLATBUF(a,b)				a = HBuf8Plat::New(b); if(a) a->SetMax();
    34 #define __KSTRING(x)					x
    35 #define __MEMCPY(a, b, c)				memcpy((a), (b), (c));
    36 #define __THREADWRITE(a, b, c)			Kern::ThreadDesWrite((a), (b), (c), 0);
    37 #define __THREADWRITEOFFSET(a, b, c, d)	Kern::ThreadDesWrite((a), (b), (c), (d), (a));
    38 #define __THREADRAWWRITE(a, b, c, d)	Kern::ThreadRawWrite((a), (b), (c), (d), (a));
    39 #define __THREADREAD(a, b, c)			Kern::ThreadDesRead((a), (b), (c), 0);
    40 #define __THREADRAWREAD(a, b, c, d)		Kern::ThreadRawRead((a), (b), (c), (d));
    41 #define __THREADDESLEN(a, b)			Kern::ThreadGetDesLength((a), (b));
    42 #define __THREADPANIC(a, b)				Kern::ThreadKill((a), EExitPanic, (b), KLitKernExec);
    43 #define __THREADREADPLATBUF(a, b, c, d)	(d) = Kern::ThreadDesRead((a), (b), *(c), 0);
    44 
    45 #endif // __KERNDEFS_H