1/** @file 2Analog devices AD7298 ADC. 3 4Copyright (c) 2013-2015 Intel Corporation. 5 6This program and the accompanying materials 7are licensed and made available under the terms and conditions of the BSD License 8which accompanies this distribution. The full text of the license may be found at 9http://opensource.org/licenses/bsd-license.php 10 11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, 12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. 13 14**/ 15 16Device(ADC1) 17{ 18 Name(_HID, "INT3494") // Galileo Version 1 Low-Speed ADC. 19 Name(_CID, "INT3494") 20 Name(RBUF, ResourceTemplate() 21 { 22 // SPI0: mode 2, 4Mhz, 16-bit data length 23 SpiSerialBus (0x0000, PolarityLow, FourWireMode, 16, ControllerInitiated, 4000000, ClockPolarityHigh, ClockPhaseFirst, "\\_SB_.PCI0.SPI0",0x00, ResourceConsumer, ,) 24 25 // GPIO<0> is SPI0_CS_N 26 GpioIO(Shared, PullDefault, 0, 0, IoRestrictionNone, "\\_SB.PCI0.GIP0.GPO_", 0, ResourceConsumer, , ) {QUARK_GPIO0_MAPPING} 27 }) 28 Method(_CRS, 0x0, NotSerialized) 29 { 30 Return(RBUF) 31 } 32 Method(_STA, 0x0, NotSerialized) 33 { 34 // 35 // Only Galileo platform has this device. 36 // EFI_PLATFORM_TYPE enum value Galileo = 6. 37 // 38 If(LNotEqual(PTYP, 6)) 39 { 40 return (0) 41 } 42 Return(0xf) 43 } 44} 45