Skip to content

Commit

Permalink
tests/nvram_spi: Update to follow api changes.
Browse files Browse the repository at this point in the history
  • Loading branch information
Joakim Gebart committed Jan 27, 2015
1 parent f524173 commit 6fb42bf
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/driver_nvram_spi/main.c
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ int main(void)

memset(buf_out, 0xff, sizeof(buf_out));
for (i = 0; i < TEST_NVRAM_SPI_SIZE; ++i) {
if (dev.write(&dev, i, &buf_out[i], 1) != 1) {
if (dev.write(&dev, &buf_out[i], i, 1) != 1) {
puts("[Failed]\n");
return 1;
}
Expand Down Expand Up @@ -194,7 +194,7 @@ int main(void)
for (i = 0; i < TEST_NVRAM_SPI_SIZE; ++i) {
buf_out[i] = (~(i)) & 0xff;
}
if (dev.write(&dev, 0, buf_out, TEST_NVRAM_SPI_SIZE) != TEST_NVRAM_SPI_SIZE) {
if (dev.write(&dev, buf_out, 0, TEST_NVRAM_SPI_SIZE) != TEST_NVRAM_SPI_SIZE) {
puts("[Failed]\n");
return 1;
}
Expand Down Expand Up @@ -227,7 +227,7 @@ int main(void)
print_buffer(buf_out, sizeof(buf_out));

puts("Writing blockwise data to device");
if (dev.write(&dev, 0, buf_out, TEST_NVRAM_SPI_SIZE) != TEST_NVRAM_SPI_SIZE) {
if (dev.write(&dev, buf_out, 0, TEST_NVRAM_SPI_SIZE) != TEST_NVRAM_SPI_SIZE) {
puts("[Failed]\n");
return 1;
}
Expand Down

0 comments on commit 6fb42bf

Please sign in to comment.