Example #1
0
bool PC8739x::probePort()
{	

	UInt8 id = listenPortByte(SUPERIO_CHIP_ID_REGISTER);	
	revision = listenPortByte(NSC_CHIP_REVISION_REGISTER);
	DebugLog("testing NSC id=%04x rev=%04x", id, revision);
	if (id == 0 || id == 0xff || revision == 0 || revision == 0xff)
		return false;
		
	if (id == 0xfc) {
		selectLogicalDevice(NSC_HARDWARE_MONITOR_LDN);
		
		if (!getLogicalDeviceAddress(SUPERIO_BASE_ADDRESS_REGISTER)){
			DebugLog("NSC no getLogicalDeviceAddress");
			//return false;
		}
//		m_Address = ListenPortWord(SUPERIO_BASE_ADDRESS_REGISTER);
		if (!listenPortByte(NSC_LDN_PRESENT)){
			DebugLog(" no NSC_LDN_PRESENT");
			return false;
		}
		
		switch (revision) {
			default:
				model = PC8739xx;
				break;
		}
		InfoLog("NSC: Found supported chip ID=0x%x REVISION=0x%x ", id, revision);
		return true;
	}
	
	return false;
}
Example #2
0
bool IT87x::probePort()
{	
	UInt16 id = listenPortWord(SUPERIO_CHIP_ID_REGISTER);
	
	if (id == 0 || id == 0xffff)
		return false;
	
	switch (id)
	{
		case IT8512F:
		case IT8712F:
		case IT8716F:
		case IT8718F:
		case IT8720F: 
		case IT8721F: 
		case IT8726F:
		case IT8728F:
		case IT8752F:
			model = id; 
			break; 
		default:
			WarningLog("found unsupported chip ID=0x%x", id);
			return false;
	}
	
	selectLogicalDevice(ITE_ENVIRONMENT_CONTROLLER_LDN);
	
	if (!getLogicalDeviceAddress())
		return false;
	
	bool* valid;
	
	UInt8 vendor = readByte(ITE_VENDOR_ID_REGISTER, valid);
	
	if (!valid || vendor != ITE_VENDOR_ID)
		return false;
	
	if ((readByte(ITE_CONFIGURATION_REGISTER, valid) & 0x10) == 0)
		return false;
	
	if (!valid)
		return false;
	
	return true;
}
Example #3
0
bool IT87x::probePort()
{	
	UInt16 id = listenPortWord(SUPERIO_CHIP_ID_REGISTER);
	
	if (id == 0 || id == 0xffff) {
    DebugLog("invalid super I/O chip ID=0x%x", id);
		return false;
  }
	hasSmartGuardian = false;
	switch (id)
	{
		case IT8512F:
		case IT8712F:
		case IT8716F:
		case IT8718F:
		case IT8720F: 
		case IT8721F: 
		case IT8726F:
		case IT8728F:
		case IT8752F:
    case IT8772E:
			model = id; 
			break; 
		default:
			DebugLog("found unsupported chip ID=0x%x", id);
			return false;
	}
  
	selectLogicalDevice(ITE_ENVIRONMENT_CONTROLLER_LDN);
  
  IOSleep(50);
	
	if (!getLogicalDeviceAddress()) {
    DebugLog("can't get monitoring LDN address");
		return false;
  }
  
	UInt8 vendor16 = readByte(address, ITE_VENDOR_ID_REGISTER);
	
	if (vendor16 != ITE_VENDOR_ID) {
    DebugLog("invalid vendor ID=0x%x", vendor16);
		return false;
  }
	
	if ((readByte(address, ITE_CONFIGURATION_REGISTER) & 0x10) == 0) {
    DebugLog("invalid configuration register value");
		return false;
  }
	
  if (id == IT8721F || id == IT8728F || id == IT8772E)
    voltageGain = 12;
  else
    voltageGain = 16;
  
  UInt8 version = readByte(address, ITE_VERSION_REGISTER) & 0x0F;
  
  if (id == IT8712F && version < 8)
    has16bitFanCounter = false;
  else
    has16bitFanCounter = true;
	
	return true;
}