#include "PalmType.h"
#include "Palmchip.h"
#include "p_util.h"

volatile  BOOLEAN Modem_bInUse = FALSE;

#define DisableModemIrq()	if (Modem_bInUse)	XBYTE[INT_ENABLE] &= 0xfb
#define EnableModemIrq()	if (Modem_bInUse)	XBYTE[INT_ENABLE] |= INT_MASK_IO

void SdramWrite(UCHAR iIndexHigh, UCHAR iIndexLow, UCHAR iDWordNum)
{
	DisableModemIrq();
	sdram_write(iIndexHigh, iIndexLow, iDWordNum);
	EnableModemIrq();
}

void SdramRead(UCHAR iIndexHigh, UCHAR iIndexLow, UCHAR iDWordNum)
{
	DisableModemIrq();
	sdram_read(iIndexHigh, iIndexLow, iDWordNum);
	EnableModemIrq();
}

