Lines Matching refs:IoC

146 #define I2C_DATA_HIGH(IoC)	SK_I2C_SET_BIT(IoC, I2C_DATA)  argument
147 #define I2C_DATA_LOW(IoC) SK_I2C_CLR_BIT(IoC, I2C_DATA) argument
148 #define I2C_DATA_OUT(IoC) SK_I2C_SET_BIT(IoC, I2C_DATA_DIR) argument
149 #define I2C_DATA_IN(IoC) SK_I2C_CLR_BIT(IoC, I2C_DATA_DIR | I2C_DATA) argument
150 #define I2C_CLK_HIGH(IoC) SK_I2C_SET_BIT(IoC, I2C_CLK) argument
151 #define I2C_CLK_LOW(IoC) SK_I2C_CLR_BIT(IoC, I2C_CLK | I2C_DATA_DIR) argument
152 #define I2C_START_COND(IoC) SK_I2C_CLR_BIT(IoC, I2C_CLK) argument
162 SK_IOC IoC, /* I/O Context */ in SkI2cSndBit() argument
165 I2C_DATA_OUT(IoC); in SkI2cSndBit()
167 I2C_DATA_HIGH(IoC); in SkI2cSndBit()
170 I2C_DATA_LOW(IoC); in SkI2cSndBit()
172 SkDgWaitTime(IoC, NS2BCLK(T_DATA_IN_SETUP)); in SkI2cSndBit()
173 I2C_CLK_HIGH(IoC); in SkI2cSndBit()
174 SkDgWaitTime(IoC, NS2BCLK(T_CLK_HIGH)); in SkI2cSndBit()
175 I2C_CLK_LOW(IoC); in SkI2cSndBit()
189 SK_IOC IoC) /* I/O Context */ in SkI2cStart() argument
193 I2C_DATA_OUT(IoC); in SkI2cStart()
194 I2C_DATA_HIGH(IoC); in SkI2cStart()
196 I2C_CLK_HIGH(IoC); in SkI2cStart()
198 SkDgWaitTime(IoC, NS2BCLK(T_START_SETUP)); in SkI2cStart()
201 I2C_DATA_LOW(IoC); in SkI2cStart()
203 SkDgWaitTime(IoC, NS2BCLK(T_START_HOLD)); in SkI2cStart()
206 I2C_START_COND(IoC); in SkI2cStart()
208 SkDgWaitTime(IoC, NS2BCLK(T_CLK_LOW)); in SkI2cStart()
213 SK_IOC IoC) /* I/O Context */ in SkI2cStop() argument
217 I2C_DATA_OUT(IoC); in SkI2cStop()
218 I2C_DATA_LOW(IoC); in SkI2cStop()
220 SkDgWaitTime(IoC, NS2BCLK(T_CLK_2_DATA_OUT)); in SkI2cStop()
223 I2C_CLK_HIGH(IoC); in SkI2cStop()
225 SkDgWaitTime(IoC, NS2BCLK(T_STOP_SETUP)); in SkI2cStop()
232 I2C_DATA_IN(IoC); in SkI2cStop()
239 SkDgWaitTime(IoC, NS2BCLK(T_BUS_IDLE)); in SkI2cStop()
251 SK_IOC IoC) /* I/O Context */ in SkI2cRcvBit() argument
257 I2C_DATA_IN(IoC); in SkI2cRcvBit()
259 SkDgWaitTime(IoC, NS2BCLK(T_CLK_2_DATA_OUT)); in SkI2cRcvBit()
261 I2C_CLK_HIGH(IoC); in SkI2cRcvBit()
263 SkDgWaitTime(IoC, NS2BCLK(T_CLK_HIGH)); in SkI2cRcvBit()
265 SK_I2C_GET_SW(IoC, &I2cSwCtrl); in SkI2cRcvBit()
269 I2C_CLK_LOW(IoC); in SkI2cRcvBit()
270 SkDgWaitTime(IoC, NS2BCLK(T_CLK_LOW-T_CLK_2_DATA_OUT)); in SkI2cRcvBit()
283 SK_IOC IoC) /* I/O Context */ in SkI2cRcvAck() argument
288 return(SkI2cRcvBit(IoC) != 0); in SkI2cRcvAck()
296 SK_IOC IoC) /* I/O Context */ in SkI2cSndNAck() argument
301 SkI2cSndBit(IoC, 1); in SkI2cSndNAck()
309 SK_IOC IoC) /* I/O Context */ in SkI2cSndAck() argument
314 SkI2cSndBit(IoC, 0); in SkI2cSndAck()
324 SK_IOC IoC, /* I/O Context */ in SkI2cSndByte() argument
331 SkI2cSndBit(IoC, 1); in SkI2cSndByte()
334 SkI2cSndBit(IoC, 0); in SkI2cSndByte()
338 return(SkI2cRcvAck(IoC)); in SkI2cSndByte()
348 SK_IOC IoC, /* I/O Context */ in SkI2cRcvByte() argument
356 Byte |= SkI2cRcvBit(IoC); in SkI2cRcvByte()
360 SkI2cSndNAck(IoC); in SkI2cRcvByte()
363 SkI2cSndAck(IoC); in SkI2cRcvByte()
376 SK_IOC IoC, /* I/O Context */ in SkI2cSndDev() argument
380 SkI2cStart(IoC); in SkI2cSndDev()
383 return(SkI2cSndByte(IoC, (Addr<<1) | Rw)); in SkI2cSndDev()
399 SK_IOC IoC, /* I/O Context */ in SkI2cWait() argument
413 SK_I2C_STOP(IoC); in SkI2cWait()
420 SK_I2C_GET_CTL(IoC, &I2cCtrl); in SkI2cWait()
444 SK_IOC IoC) /* I/O Context */ in SkI2cWaitIrq() argument
461 SK_I2C_STOP(IoC); in SkI2cWaitIrq()
468 SK_IN32(IoC, B0_ISRC, &IrqSrc); in SkI2cWaitIrq()
484 SK_IOC IoC, /* I/O Context */ in SkI2cWrite() argument
491 SK_OUT32(IoC, B2_I2C_DATA, I2cData); in SkI2cWrite()
493 SK_I2C_CTL(IoC, I2C_WRITE, I2cDev, I2cDevSize, I2cReg, I2cBurst); in SkI2cWrite()
495 return(SkI2cWait(pAC, IoC, I2C_WRITE)); in SkI2cWrite()
507 SK_IOC IoC, /* I/O Context */ in SkI2cRead() argument
515 SK_OUT32(IoC, B2_I2C_DATA, 0); in SkI2cRead()
516 SK_I2C_CTL(IoC, I2C_READ, I2cDev, I2cDevSize, I2cReg, I2cBurst); in SkI2cRead()
518 if (SkI2cWait(pAC, IoC, I2C_READ) != 0) { in SkI2cRead()
522 SK_IN32(IoC, B2_I2C_DATA, &Data); in SkI2cRead()
541 SK_IOC IoC, /* I/O Context */ in SkI2cReadSensor() argument
545 return((*pSen->SenRead)(pAC, IoC, pSen)); in SkI2cReadSensor()
620 SK_IOC IoC) /* I/O Context */ in SkI2cInit1() argument
632 SK_I2C_CLR_BIT(IoC, I2C_DATA_DIR | I2C_DATA); in SkI2cInit1()
634 SK_I2C_GET_SW(IoC, &I2cSwCtrl); in SkI2cInit1()
643 if (SkI2cWrite(pAC, IoC, 0, LM80_ADDR, I2C_025K_DEV, LM80_CFG, 0) != 0) { in SkI2cInit1()
647 (void)SkI2cWrite(pAC, IoC, 0xffUL, LM80_ADDR, I2C_025K_DEV, LM80_IMSK_1, 0); in SkI2cInit1()
649 (void)SkI2cWrite(pAC, IoC, 0xffUL, LM80_ADDR, I2C_025K_DEV, LM80_IMSK_2, 0); in SkI2cInit1()
651 (void)SkI2cWrite(pAC, IoC, 0, LM80_ADDR, I2C_025K_DEV, LM80_FAN_CTRL, 0); in SkI2cInit1()
653 (void)SkI2cWrite(pAC, IoC, 0, LM80_ADDR, I2C_025K_DEV, LM80_TEMP_CTRL, 0); in SkI2cInit1()
655 (void)SkI2cWrite(pAC, IoC, (SK_U32)LM80_CFG_START, LM80_ADDR, I2C_025K_DEV, in SkI2cInit1()
824 SK_OUT32(IoC, B2_I2C_IRQ, I2C_CLR_IRQ); in SkI2cInit1()
837 SK_IOC IoC) /* I/O Context */ in SkI2cInit2() argument
849 ReadComplete = SkI2cReadSensor(pAC, IoC, pSen); in SkI2cInit2()
882 SK_IOC IoC, /* I/O Context needed in levels 1 and 2 */ in SkI2cInit() argument
890 return(SkI2cInit1(pAC, IoC)); in SkI2cInit()
892 return(SkI2cInit2(pAC, IoC)); in SkI2cInit()
914 SK_IOC IoC) /* I/O Context */ in SkI2cIsr() argument
919 SK_OUT32(IoC, B2_I2C_IRQ, I2C_CLR_IRQ); in SkI2cIsr()
1166 SK_IOC IoC, /* I/O Context */ in SkI2cEvent() argument
1184 ReadComplete = SkI2cReadSensor(pAC, IoC, pSen); in SkI2cEvent()
1205 SkTimerStart(pAC, IoC, &pAC->I2c.SenTimer, Time, in SkI2cEvent()
1214 SkTimerStart(pAC, IoC, &pAC->I2c.SenTimer, SK_I2C_TIM_WATCH, in SkI2cEvent()
1222 SkTimerStop(pAC, IoC, &pAC->I2c.SenTimer); in SkI2cEvent()
1225 ReadComplete = SkI2cReadSensor(pAC, IoC, pSen); in SkI2cEvent()
1246 SkTimerStart(pAC, IoC, &pAC->I2c.SenTimer, Time, in SkI2cEvent()
1253 SK_I2C_STOP(IoC); in SkI2cEvent()
1270 SkTimerStart(pAC, IoC, &pAC->I2c.SenTimer, Time, in SkI2cEvent()