/******************************************************************************/
/*                       Copyright 2001 Broadcom Corporation                  */
/*                                                                            */
/* This material is the confidential trade secret and proprietary information */
/* of Broadcom Corp.  It may not be reproduced, used, sold or transferred to  */
/* any third party without the prior written consent of Broadcom Corp.        */
/* All rights reserved.                                                       */
/******************************************************************************/
/*   FileName        : bcm_hmiCoreServices.h                                  */
/*   Purpose         : Provide core manager hmi services throuth QA protocol  */
/*   Limitations     : None                                                   */
/*   Author          : Emmanuel Hanssens                                      */
/*   Creation Date   : 18-Sep-2001                                            */
/*   History         : Compiled by CVS                                        */
/******************************************************************************/
/*   $Id: bcm_hmiCoreServices.h,v 1.14 2004/09/17 12:35:34 hanssens Exp $  */
/******************************************************************************/
#ifndef HMI_CORE_SERVICES_H
# define HMI_CORE_SERVICES_H

# include "bcm_hmiCoreMsg.h"
# include "bcm_hmiQA.h"

# define SetDeviceConfiguration(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetDeviceConfiguration), \
  (uint8 *) 0, 0, \
  &SetDeviceConfigurationLayout)

# define GetDeviceConfiguration(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetDeviceConfiguration), \
  &GetDeviceConfigurationLayout)

# define GetLineInterruptStatus(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetLineInterruptStatus), \
  &GetLineInterruptStatusLayout)

# define ChangeLineInterruptMask(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(ChangeLineInterruptMask), \
  (uint8 *) 0, 0, \
  &ChangeLineInterruptMaskLayout)

# define ResetDevice(dev, applicationId) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) 0, 0, \
  &ResetDeviceLayout)

# define GetFirmwareVersionInfo(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetFirmwareVersionInfo), \
  &GetFirmwareVersionInfoLayout)

# define WriteGPIO(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(WriteGPIO), \
  (uint8 *) 0, 0, \
  &WriteGPIOLayout)

# define ReadGPIO(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(ReadGPIO), \
  &ReadGPIOLayout)

# define SetOAMperiodElapsedTime(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetOAMperiodElapsedTime), \
  (uint8 *) 0, 0, \
  &SetOAMperiodElapsedTimeLayout)

# define SetLineDriverPowerModes(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetLineDriverPowerModes), \
  (uint8 *) 0, 0, \
  &SetLineDriverPowerModesLayout)

# define DetectModem(dev, applicationId, msgReq, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(DetectModem), \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(DetectModem), \
  &DetectModemLayout)

# define SetInBandIPconfiguration(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetInBandIPconfiguration), \
  (uint8 *) 0, 0, \
  &SetInBandIPconfigurationLayout)

# define GetInBandIPconfiguration(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetInBandIPconfiguration), \
  &GetInBandIPconfigurationLayout)

# define GetInBandLayer2Config(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetInBandLayer2Config), \
  &GetInBandLayer2ConfigLayout)

# define GetInBandStackStatus(dev, applicationId, msgRep) \
  hmiQA(dev, applicationId, \
  (uint8 *) 0, 0, \
  (uint8 *) msgRep, SIZE_OF_REP_MSG(GetInBandStackStatus), \
  &GetInBandStackStatusLayout)

# define SetLedPattern(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetLedPattern), \
  (uint8 *) 0, 0, \
  &SetLedPatternLayout)

# define SetTxFilter(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetTxFilter), \
  (uint8 *) 0, 0, \
  &SetTxFilterLayout)

# ifdef BCM_USE_BCM6510
# define SetBCM6510afeConnect(dev, applicationId, msgReq) \
  hmiQA(dev, applicationId, \
  (uint8 *) msgReq, SIZE_OF_REQ_MSG(SetBCM6510afeConnect), \
  (uint8 *) 0, 0, \
  &SetBCM6510afeConnectLayout)
# endif

#endif
