#207: Bug fixes in new reboot code

This commit is contained in:
Larry Snizek
2018-01-23 12:30:43 +00:00
parent b4c9ef9fd7
commit 67a9d9b6c4

View File

@@ -1,5 +1,6 @@
#include <xs1.h>
#include <platform.h>
#include <print.h>
#include <xs1_su.h>
#define XS1_SU_PERIPH_USB_ID 0x1
@@ -74,10 +75,10 @@ void device_reboot(void)
#ifdef __XS2A__
/* Reset all even tiles, starting from the remote ones */
for(unsigned int tileNum = tileArrayLength-2; tileNum>=0; tileNum-=2)
for(int tileNum = tileArrayLength-2; tileNum>=0; tileNum-=2)
#else
/* Reset all tiles, starting from the remote ones */
for(unsigned int tileNum = tileArrayLength-1; tileNum>=0; tileNum--)
for(int tileNum = tileArrayLength-1; tileNum>=0; tileNum--)
#endif
{
/* Cannot cast tileref to unsigned! */