/*
 * Copyright (c) 2003 Linuxant inc.
 * Copyright (c) 2001-2003 Conexant Systems, Inc.
 * 
 * 1.   Permitted use. Redistribution and use in source and binary forms,
 * without modification, are permitted under the terms set forth herein.
 * 
 * 2.   Disclaimer of Warranties. LINUXANT, ITS SUPPLIERS, AND OTHER CONTRIBUTORS
 * MAKE NO REPRESENTATION ABOUT THE SUITABILITY OF THIS SOFTWARE FOR ANY PURPOSE.
 * IT IS PROVIDED "AS IS" WITHOUT EXPRESS OR IMPLIED WARRANTIES OF ANY KIND.
 * LINUXANT AND OTHER CONTRIBUTORS DISCLAIMS ALL WARRANTIES WITH REGARD
 * TO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
 * FOR A PARTICULAR PURPOSE, GOOD TITLE AND AGAINST INFRINGEMENT.
 * 
 * This software has not been formally tested, and there is no guarantee that
 * it is free of errors including, but not limited to, bugs, defects,
 * interrupted operation, or unexpected results. Any use of this software is
 * at user's own risk.
 * 
 * 3.   No Liability.
 * 
 * (a) Linuxant, its suppliers, or contributors shall not be responsible for
 * any loss or damage to users, customers, or any third parties for any reason
 * whatsoever, and LINUXANT, ITS SUPPLIERS OR CONTRIBUTORS SHALL NOT BE LIABLE
 * FOR ANY ACTUAL, DIRECT, INDIRECT, SPECIAL, PUNITIVE, INCIDENTAL, OR
 * CONSEQUENTIAL (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED, WHETHER IN CONTRACT, STRICT OR OTHER LEGAL THEORY OF
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY
 * WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY
 * OF SUCH DAMAGE.
 * 
 * (b) User agrees to hold Linuxant, its suppliers, and contributors harmless
 * from any liability, loss, cost, damage or expense, including attorney's fees,
 * as a result of any claims which may be made by any person, including
 * but not limited to User, its agents and employees, its customers, or
 * any third parties that arise out of or result from the manufacture,
 * delivery, actual or alleged ownership, performance, use, operation
 * or possession of the software furnished hereunder, whether such claims
 * are based on negligence, breach of contract, absolute liability or any
 * other legal theory.
 * 
 * 4.   Notices. User hereby agrees not to remove, alter or destroy any
 * copyright, trademark, credits, other proprietary notices or confidential
 * legends placed upon, contained within or associated with the Software,
 * and shall include all such unaltered copyright, trademark, credits,
 * other proprietary notices or confidential legends on or in every copy of
 * the Software.
 * 
 * 5.   Reverse-engineering. User hereby agrees not to reverse engineer,
 * decompile, or disassemble the portions of this software provided solely
 * in object form, nor attempt in any manner to obtain their source-code.
 * 
 * 6.   Redistribution. Redistribution of this software is permitted only
 * for non-beta, officially released versions. Redistribution of versions
 * marked "beta" or "lnxtbeta" requires explicit written approval from
 * Linuxant.
 * 
 */

/*************************************************************************

  File Name: ComTypes.h

  File Description:

  *************************************************************************/

#ifndef __COM_TYPES_H__
#define __COM_TYPES_H__

#if ( USE_PRAGMA_PACK == 1 )
#pragma pack(push,1)   /* Packing compatible with WinAC */
#endif

typedef enum {
	COM_STATUS_SUCCESS, 
	COM_STATUS_FAIL, 
	COM_STATUS_PENDING,
	COM_STATUS_CODE_NOT_SUPPORTED, 
	COM_STATUS_NULL_POINTER,
	COM_STATUS_INST_NOT_CONFIGURED,
	COM_STATUS_INST_NOT_INIT,
	COM_STATUS_INST_NOT_CLOSED,
	COM_STATUS_INVALID_HANDLE,
	COM_STATUS_INVALID_PARAM,
	COM_STATUS_INVALID_MODE,
    COM_STATUS_VALUE_NOT_FOUND,
	COM_STATUS_ALLOC_FAILED,
	COM_STATUS_CREATE_FAILED,
	COM_STATUS_OPEN_FAILED,
	COM_STATUS_BLACKLISTED,
	COM_STATUS_DELAYED,
	COM_STATUS_UNKNOWN
}COM_STATUS;							


typedef VOID (*PFUNC)(VOID);
typedef VOID  ( __stdcall *PCBFUNC)(PVOID);
typedef BOOL  ( __stdcall *PISR)(PVOID);

typedef PVOID (*PALLOC_FUNC)(	int /* Alloc Size */, 
								PVOID /* pRefData */);	
typedef void (*PFREE_FUNC)(		PVOID /* Block Pointer */,
								PVOID /* pRefData */);		

typedef VOID (*DPCFUNC) (PVOID Instance,
                         PVOID DPCArgs);


typedef BOOL  (*DATACB)(PVOID Inst,unsigned char*);
/*typedef VOID ( __fastcall *PSCR_PRINT_FUNC)(PCHAR, PRIORITY_DESCRIPTOR); */

/**/
#if ( (PROJECT == PRJ_SDSL) || (PROJECT == PRJ_OCTOLOADER) )

typedef enum PRIORITY_DESCRIPTOR
{
	Q_RECORD_PRIORITY_NORMAL = 0,
	Q_RECORD_PRIORITY_MED,
	Q_RECORD_PRIORITY_HIGH,
	Q_RECORD_PRIORITY_DUMP
}PRIORITY_DESCRIPTOR;

typedef VOID ( __fastcall *PSCR_PRINT_FUNC)(PCHAR, PRIORITY_DESCRIPTOR);

#else

typedef VOID ( __fastcall *PSCR_PRINT_FUNC)(PCHAR);

#endif
/**/
typedef struct BUFFER_MEM_INFO_TAG
{
    PVOID   LinearAddress;
    PVOID   PhysAddress;
}BUFFER_MEM_INFO_T;

#if ( USE_PRAGMA_PACK == 1 )
#pragma pack(pop)   /* Packing compatible with our VXDs */
#endif

#endif /* __COM_TYPES_H__ */
