From: Tom Knot Date: Thu, 14 Jun 2018 08:53:36 +0000 (+0200) Subject: - Changed UART startup ignore to proceed correctly if it cannot finish X-Git-Url: http://git.graph-it.com/?a=commitdiff_plain;h=f2bc2d8b2a1aaf8162571cf17266eb736efef4ed;p=graphit%2Funipi-kernel.git - Changed UART startup ignore to proceed correctly if it cannot finish - Version 0.12 --- diff --git a/modules/unipi/src/unipi_common.h b/modules/unipi/src/unipi_common.h index 7ee0910..d1121f8 100644 --- a/modules/unipi/src/unipi_common.h +++ b/modules/unipi/src/unipi_common.h @@ -51,7 +51,7 @@ #if NEURONSPI_SCHED_REQUIRED > 0 #include #endif -#define NEURONSPI_MAJOR_VERSIONSTRING "Development Beta Version 0.11:06:06:2018" +#define NEURONSPI_MAJOR_VERSIONSTRING "Development Beta Version 0.12:14:06:2018" #define NEURONSPI_MAX_DEVS 3 #define NEURONSPI_MAX_UART 128 diff --git a/modules/unipi/src/unipi_spi.c b/modules/unipi/src/unipi_spi.c index 41716c4..30bfee2 100644 --- a/modules/unipi/src/unipi_spi.c +++ b/modules/unipi/src/unipi_spi.c @@ -1000,13 +1000,7 @@ s32 neuronspi_spi_probe(struct spi_device *spi) memset(n_spi->first_probe_reply, 0, NEURONSPI_PROBE_MESSAGE_LEN); neuronspi_spi_send_message(spi, n_spi->send_buf, n_spi->first_probe_reply, NEURONSPI_PROBE_MESSAGE_LEN, NEURONSPI_DEFAULT_FREQ, 25, 1, 0); i++; - if (i > 1000) { // Sanity check to prevent looping if we get constant UART/0x41 messages - ret = -ENODEV; - kfree(n_spi); - printk(KERN_INFO "NEURONSPI: Probe did not detect a valid Neuron device on CS %d\n", spi->chip_select); - return ret; - } - } while (n_spi->first_probe_reply[0] == 0x41); // UART messages should be ignored + } while (n_spi->first_probe_reply[0] == 0x41 && i < 1000); // UART messages should be ignored if (n_spi->first_probe_reply[0] != 0) { // CRC error sets the first byte to 0 uart_count = n_spi->first_probe_reply[14] & 0x0f; diff --git a/version.txt b/version.txt index 74af88c..d195d5a 100644 --- a/version.txt +++ b/version.txt @@ -1 +1 @@ -Repository:neuron-kernel ActiveBranch:[master] PrecedingRelease:v.0.10 PrecedingRevision:39(9533eb2) LatestCommit:Wed Jun 6 19:08:29 CEST 2018 +Repository:neuron-kernel ActiveBranch:[master] PrecedingRelease:v.0.10 PrecedingRevision:39(2b8571a) LatestCommit:Thu Jun 14 10:53:36 CEST 2018