X-Git-Url: https://git.ucc.asn.au/?a=blobdiff_plain;f=Kernel%2Finclude%2Ftpl_drv_common.h;h=f281c0ee334e2be229cf7f9de505a28180fac5f5;hb=f2fd50e797e6a3b3590e4c2e13b6782dd87c25a2;hp=31edb9cf23c2eacb0fe267a08c73d0790f9c4c63;hpb=5d8abe295dc250ba57e85f0ace5ba4c9e5bbc8ec;p=tpg%2Facess2.git diff --git a/Kernel/include/tpl_drv_common.h b/Kernel/include/tpl_drv_common.h index 31edb9cf..f281c0ee 100644 --- a/Kernel/include/tpl_drv_common.h +++ b/Kernel/include/tpl_drv_common.h @@ -82,6 +82,19 @@ enum eTplDrv_IOCtl { //! These are the official lookup names of the core calls #define DRV_IOCTLNAMES "type", "ident", "version", "lookup" +#define BASE_IOCTLS(_type, _ident, _version, _ioctls) \ + case DRV_IOCTL_TYPE: LEAVE('i', (_type)); return (_type);\ + case DRV_IOCTL_IDENT: {\ + int tmp = ModUtil_SetIdent(Data, (_ident));\ + LEAVE('i', tmp); return tmp;\ + }\ + case DRV_IOCTL_VERSION: LEAVE('x', (_version)); return (_version);\ + case DRV_IOCTL_LOOKUP:{\ + int tmp = ModUtil_LookupString( (char**)(_ioctls), (char*)Data );\ + LEAVE('i', tmp);\ + return tmp;\ + } + /** * \enum eTplDrv_Type * \brief Driver Types returned by DRV_IOCTL_TYPE