summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 9779407)
raw | patch | inline | side by side (parent: 9779407)
PRSDK-7098: Fixing USB diag example after the recent updates REL.PDK.J7.01.00.00.01 REL.PDK.J7.01.00.00.02
author | Mahesh Radhakrishnan <m-radhakrishnan2@ti.com> | |
Tue, 24 Sep 2019 19:52:42 +0000 (15:52 -0400) | ||
committer | Mahesh Radhakrishnan <a0875154@ti.com> | |
Wed, 25 Sep 2019 13:12:17 +0000 (08:12 -0500) |
diff --git a/diag/usb_host/build/am65xx_evm/armv7/makefile b/diag/usb_host/build/am65xx_evm/armv7/makefile
index 873f63462b08eea0ec30b02b25084b5b747e6f1e..a41df5b89481eda8f0fb0fdab8b1b52f4f1309b0 100644 (file)
CSL_INIT_LIB = "$(PDK_INSTALL_PATH)/ti/csl/lib/am65xx/r5f/release/ti.csl.init.aer5f"
OSAL_LIB = "$(PDK_INSTALL_PATH)/ti/osal/lib/nonos/am65xx/r5f/release/ti.osal.aer5f"
SCICLIENT_LIB = "$(PDK_INSTALL_PATH)/ti/drv/sciclient/lib/am65xx/mcu1_0/release/sciclient.aer5f"
-PERIPHERAL_LIB = $(UART_LIB) $(USB_LIB) $(FATFS_LIB) $(CSL_LIB) $(CSL_INIT_LIB) $(SCICLIENT_LIB)
+I2C_LIB = "$(PDK_INSTALL_PATH)/ti/drv/i2c/lib/am65xx/r5f/release/ti.drv.i2c.aer5f"
+PERIPHERAL_LIB = $(UART_LIB) $(USB_LIB) $(FATFS_LIB) $(CSL_LIB) $(CSL_INIT_LIB) $(I2C_LIB) $(SCICLIENT_LIB)
RTSLIB_PATH = "$(TOOLCHAIN_PATH_R5)/lib/libc.a"
LNK_LIBS = -l$(PERIPHERAL_LIB) -l$(BOARD_LIB) -l$(OSAL_LIB) $(RTSLIB_PATH)
diff --git a/diag/usb_host/build/am65xx_evm/armv8/makefile b/diag/usb_host/build/am65xx_evm/armv8/makefile
index c533f9a1036b9481ce065c6cb31e04599f4dddb8..af88af0d04c49b26f4c8d502a3993a832eb49dab 100644 (file)
CSL_LIB = "$(PDK_INSTALL_PATH)/ti/csl/lib/am65xx/a53/release/ti.csl.aa53fg"
CSL_INIT_LIB = "$(PDK_INSTALL_PATH)/ti/csl/lib/am65xx/a53/release/ti.csl.init.aa53fg"
OSAL_LIB = "$(PDK_INSTALL_PATH)/ti/osal/lib/nonos/am65xx/a53/release/ti.osal.aa53fg"
+I2C_LIB = "$(PDK_INSTALL_PATH)/ti/drv/i2c/lib/am65xx/a53/release/ti.drv.i2c.aa53fg"
SCICLIENT_LIB = "$(PDK_INSTALL_PATH)/ti/drv/sciclient/lib/am65xx/mpu1_0/release/sciclient.aa53fg"
-PERIPHERAL_LIB = $(UART_LIB) $(USB_LIB) $(FATFS_LIB) $(CSL_LIB) $(CSL_INIT_LIB) $(SCICLIENT_LIB)
+PERIPHERAL_LIB = $(UART_LIB) $(USB_LIB) $(FATFS_LIB) $(CSL_LIB) $(CSL_INIT_LIB) $(I2C_LIB) $(SCICLIENT_LIB)
# Compiler options
INTERNALDEFS = -Wimplicit -Wall $(DEBUG_FLAG) -D__ARMv8 -D$(BOARD) -DSOC_$(DEVICE) -Dgcc -Wunused -Wunknown-pragmas -ffunction-sections -fdata-sections -c -mcpu=cortex-a53+fp+simd -g -mabi=lp64 -mcmodel=large -mstrict-align -mfix-cortex-a53-835769 -mfix-cortex-a53-843419 -Wno-int-to-pointer-cast -Wno-pointer-to-int-cast -Werror
index e694775842e96211b26bc995ce67ab625d7c4ccf..44bd79f5208841fa8a676943bdd85cc3f85d59a7 100644 (file)
int32_t
FATFSPortUSBDiskInitialize(void)
-
{
- unsigned int ulMSCInstance;
+ void* mscInstance;
- ulMSCInstance = (unsigned int)&g_USBHMSCDevice[0];/* Physical drive number (0) - no hub support */
+ mscInstance = (void *)&g_USBHMSCDevice[0];/* Physical drive number (0) - no hub support */
/* Set the not initialized flag again. If all goes well and the disk is */
/* present, this will be cleared at the end of the function. */
USBStat |= STA_NOINIT;
/* Find out if drive is ready yet. */
- if (USBHMSCDriveReady(ulMSCInstance)) return(FR_NOT_READY);
+ if (USBHMSCDriveReady(mscInstance)) return(FR_NOT_READY);
/* Clear the not init flag. */
USBStat &= ~STA_NOINIT;
uint32_t sector, /* Starting sector */
uint32_t count) /* Sector count (1..255) */
{
- unsigned int ulMSCInstance;
+ void* mscInstance;
if(USBStat & STA_NOINIT)
{
return(RES_NOTRDY);
}
- ulMSCInstance = (unsigned int)&g_USBHMSCDevice[0]; // no hub support so only one drive
+ mscInstance = (void *)&g_USBHMSCDevice[0]; // no hub support so only one drive
/* READ BLOCK */
- if (USBHMSCBlockRead(ulMSCInstance, sector, buff, count) == 0)
+ if (USBHMSCBlockRead(mscInstance, sector, buff, count) == 0)
return RES_OK;
return RES_ERROR;
uint32_t sector, /* Start sector number (LBA) */
uint32_t count) /* Sector count (1..255) */
{
- unsigned int ulMSCInstance;
+ void* mscInstance;
- ulMSCInstance = (unsigned int)&g_USBHMSCDevice[0]; /* Physical drive number (0) */
+ mscInstance = (void *)&g_USBHMSCDevice[0]; /* Physical drive number (0) */
if (!count) return RES_PARERR;
if (USBStat & STA_PROTECT) return RES_WRPRT;
/* WRITE BLOCK */
- if(USBHMSCBlockWrite(ulMSCInstance, sector, (uint8_t *)buff, count) == 0)
+ if(USBHMSCBlockWrite(mscInstance, sector, (uint8_t *)buff, count) == 0)
return RES_OK;
return RES_ERROR;
index 2fb0dad440d5ffcecc1d29d86d9d963e0973d159..77a4568fdaf4b0fa02e16e785b6245c72bea247b 100644 (file)
* from the system.
*
*/
-void MSCCallback(uint32_t ulInstance, uint32_t ulEvent, void *pvData)
+void MSCCallback(void *ulInstance, uint32_t ulEvent, void *pvData)
{
/* Determine the event.*/
switch(ulEvent)
index 80d32c5464c45a4d3a0e0500b88d8008d1e1f3c1..64e0cb7927e8bb69e40639db84574e8819684992 100644 (file)
#endif
#if defined(am65xx_evm)
#include "board_cfg.h"
-#include "board_i2c_io_exp.h"
-#include "board_internal.h"
+#include "ti/board/src/evmKeystone3/include/board_i2c_io_exp.h"
+#include "ti/board/src/evmKeystone3/include/board_internal.h"
#endif
#ifdef __cplusplus
/* The instance data for the MSC driver. */
-unsigned int g_ulMSCInstance = 0U;
+void* g_ulMSCInstance = (void*)NULL;
#if defined(BUILD_ARM) && (defined(SOC_OMAPL137) || defined(SOC_OMAPL138))
/* USB param struture variable should be used as global variable because
* the callback.
*
*/
-void MSCCallback(uint32_t ulInstance, uint32_t ulEvent, void *pvData);
+void MSCCallback(void *ulInstance, uint32_t ulEvent, void *pvData);
/**
* \brief Setting up the MMU for USB.
index 8cefd247c0f4ea93f6c11d48dedc2b113b164cbb..ac5ef486f5bc34f7c053fa0da0e4b10c76f10337 100644 (file)
// The instance data for the MSC driver.
//
//*****************************************************************************
-unsigned int g_ulMSCInstance = 0;
+void * g_ulMSCInstance = (void *)NULL;
#if defined(BUILD_ARM) && (defined(SOC_OMAPL137) || defined(SOC_OMAPL138))
/* USB param struture variable should be used as global variable because
/* Prototypes */
/* ========================================================================== */
void usbHostIntrConfig(USB_Params* usbParams);
-void MSCCallback(uint32_t ulInstance, uint32_t ulEvent, void *pvData);
+void MSCCallback(void *ulInstance, uint32_t ulEvent, void *pvData);
void consolePrintf(const char *pcString, ...);
void setupMMUForUSB(void);
//
//*****************************************************************************
void
-MSCCallback(uint32_t ulInstance, uint32_t ulEvent, void *pvData)
+MSCCallback(void *ulInstance, uint32_t ulEvent, void *pvData)
{
//
// Determine the event.