mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2025-11-16 12:34:45 +00:00
2007-01-29 Ralf Corsépius <ralf.corsepius@rtems.org>
* GT64260/MVME5500I2C.c: Eliminate u32.
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
2007-01-29 Ralf Corsépius <ralf.corsepius@rtems.org>
|
||||
|
||||
* GT64260/MVME5500I2C.c: Eliminate u32.
|
||||
* GT64260/MVME5500I2C.c, pci/pci.c: Eliminate unchar.
|
||||
|
||||
2006-10-30 Joel Sherrill <joel@OARcorp.com>
|
||||
|
||||
@@ -12,23 +12,23 @@
|
||||
*/
|
||||
|
||||
#include <rtems/bspIo.h> /* printk */
|
||||
#include <rtems/stdint.h>
|
||||
#include "bsp/GT64260TWSI.h"
|
||||
|
||||
/* #define I2C_DEBUG*/
|
||||
typedef unsigned int u32;
|
||||
|
||||
unsigned char I2cAddrPack(unsigned char busAddr,u32 offset)
|
||||
unsigned char I2cAddrPack(unsigned char busAddr,uint32_t offset)
|
||||
{
|
||||
return(busAddr | ((offset & 0x700) >> 7));
|
||||
}
|
||||
unsigned char I2cDevByteAddr(u32 devA2A1A0, unsigned char byteNum)
|
||||
unsigned char I2cDevByteAddr(uint32_t devA2A1A0, unsigned char byteNum)
|
||||
{
|
||||
return(( devA2A1A0 >>(byteNum*8)) & 0xff);
|
||||
}
|
||||
/****************************************************************************
|
||||
* I2Cread_eeprom - read EEPROM VPD from the I2C
|
||||
*/
|
||||
int I2Cread_eeprom(unsigned char I2cBusAddr,u32 devA2A1A0,u32 AddrBytes,unsigned char *pBuff,u32 numBytes)
|
||||
int I2Cread_eeprom(unsigned char I2cBusAddr,uint32_t devA2A1A0,uint32_t AddrBytes,unsigned char *pBuff,uint32_t numBytes)
|
||||
{
|
||||
int status=0, lastByte=0;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user