summaryrefslogtreecommitdiff
path: root/nuttx
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-15 21:35:18 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2012-11-15 21:35:18 +0000
commit51e0c930ca583196bf1075217cff969a0f7e4619 (patch)
treebcb726d801a0f2cd87a8f72764e3d049f7d67703 /nuttx
parentb7ce758f3b0bf5680cc545134a3939bdec40dabf (diff)
downloadpx4-nuttx-51e0c930ca583196bf1075217cff969a0f7e4619.tar.gz
px4-nuttx-51e0c930ca583196bf1075217cff969a0f7e4619.tar.bz2
px4-nuttx-51e0c930ca583196bf1075217cff969a0f7e4619.zip
Mirtoo differences from Konstantin; File system fix from Lorenz Meier
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5360 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx')
-rw-r--r--nuttx/ChangeLog5
-rw-r--r--nuttx/configs/mirtoo/Kconfig5
-rw-r--r--nuttx/configs/mirtoo/README.txt6
-rw-r--r--nuttx/configs/mirtoo/src/up_spi2.c11
-rw-r--r--nuttx/fs/fs_files.c1
5 files changed, 22 insertions, 6 deletions
diff --git a/nuttx/ChangeLog b/nuttx/ChangeLog
index f907cbfcd..9c62db68f 100644
--- a/nuttx/ChangeLog
+++ b/nuttx/ChangeLog
@@ -3628,4 +3628,9 @@
* arch/*/src/Makefile: Remove tftboot install and creation of System.map
for Windows native build. The fist is necessary, the second just needs
re-implemented.
+ * configs/mirtoo: Update Mirtoo pin definitions for Release 2. Provided
+ by Konstantin Dimitrov.
+ * Fixed an uninitialized variable in the file system that can cause
+ assertions if DEBUG on (contributed by Lorenz Meier).
+
diff --git a/nuttx/configs/mirtoo/Kconfig b/nuttx/configs/mirtoo/Kconfig
index fe15952f3..1ff7e4246 100644
--- a/nuttx/configs/mirtoo/Kconfig
+++ b/nuttx/configs/mirtoo/Kconfig
@@ -10,4 +10,9 @@ config ARCH_LEDS
---help---
"Support control of board LEDs by NuttX to indicate system state"
+config MIRTOO_RELEASE
+ int "Mirtoo Release 1 (R1)"
+ default 2
+ ---help---
+ Select the Mirtoo release number
endif
diff --git a/nuttx/configs/mirtoo/README.txt b/nuttx/configs/mirtoo/README.txt
index e0b7dc3bc..488884ba5 100644
--- a/nuttx/configs/mirtoo/README.txt
+++ b/nuttx/configs/mirtoo/README.txt
@@ -199,19 +199,19 @@ PIN PIC32 SIGNAL(s) BOARD SIGNAL/USAGE
--- ------------------------------------------------ ---------------------------------- ----------------------------------
29 VSS VSS Not available off module
--- ------------------------------------------------ ---------------------------------- ----------------------------------
-30 OSC1/CLKI/RPA2/RA2 SO Not available off module
+30 OSC1/CLKI/RPA2/RA2 SO (R1) DIN0 (R2) Not available off module
OSC1 Oscillator crystal input Not available
CLKI External clock source input Not available
RPRA2 Peripheral Selection PORTA, Pin 2 Used for SO
RA2 PORTA, Pin 2 Not available
--- ------------------------------------------------ ---------------------------------- ----------------------------------
-31 OSC2/CLKO/RPA3/RA3 DIN0 PORT0, to X1, pin 2
+31 OSC2/CLKO/RPA3/RA3 DIN0 (R1) DIN3 (R2) PORT0, to X1, pin 2
OSC2 Oscillator crystal output Not available (also X13, pin1)
CLKO Oscillator crystal output Not available
RPA3 Peripheral Selection for PORTA, Pin 3 May be used for peripheral input
RA3 PORTA, Pin 3 May be used for GPIO input
--- ------------------------------------------------ ---------------------------------- ----------------------------------
-32 TDO/RPA8/PMA8/RA8 DIN3 PORT3, to X5, pin 2
+32 TDO/RPA8/PMA8/RA8 DIN3 (R1) S0 (R2) PORT3, to X5, pin 2
TDO JTAG test data output pin Not available (also X13, pin7)
RPA8 PORTA, Pin 8 May be used for peripheral input
PMA8 Parallel Master Port Address bit 8 Not available
diff --git a/nuttx/configs/mirtoo/src/up_spi2.c b/nuttx/configs/mirtoo/src/up_spi2.c
index 3b43497d7..056570710 100644
--- a/nuttx/configs/mirtoo/src/up_spi2.c
+++ b/nuttx/configs/mirtoo/src/up_spi2.c
@@ -74,7 +74,8 @@
* PIN SIGNAL BOARD CONNECTION NOTES
* ------ -------- ------------------------- --------------------------------
* RPA1 SI PGA117 and SST25VF032B SPI2 data OUT (SDO2)
- * RPA2 SO PGA117 and SST25VF032B SPI2 data IN (SDI2)
+ * RPA2 SO PGA117 and SST25VF032B R1, SPI2 data IN (SDI2)
+ * RPA3 SO PGA117 and SST25VF032B R0, SPI2 data IN (SDI2)
* SCK2 SCK PGA117 and SST25VF032B SPI2 clock
*
* RB7 ~CSAI PGA117 PGA117 chip select (active low)
@@ -82,8 +83,12 @@
*/
#define GPIO_SI (GPIO_OUTPUT|GPIO_PORTA|GPIO_PIN1)
-#define GPIO_SO (GPIO_INPUT|GPIO_PORTA|GPIO_PIN1)
-#define GPIO_SCK (GPIO_OUTPUT|GPIO_PORTA|GPIO_PIN1)
+#ifdef CONFIG_MIRTOO_RELEASE == 1
+# define GPIO_SO (GPIO_INPUT|GPIO_PORTA|GPIO_PIN2)
+#else
+# define GPIO_SO (GPIO_INPUT|GPIO_PORTA|GPIO_PIN3)
+#endif
+#define GPIO_SCK (GPIO_OUTPUT|GPIO_PORTB|GPIO_PIN15)
#define GPIO_PGA117_CS (GPIO_OUTPUT|GPIO_VALUE_ONE|GPIO_PORTB|GPIO_PIN7)
#define GPIO_SST25VF032B_CS (GPIO_OUTPUT|GPIO_VALUE_ONE|GPIO_PORTB|GPIO_PIN13)
diff --git a/nuttx/fs/fs_files.c b/nuttx/fs/fs_files.c
index 425e7c73f..4da2d28a5 100644
--- a/nuttx/fs/fs_files.c
+++ b/nuttx/fs/fs_files.c
@@ -400,6 +400,7 @@ int files_allocate(FAR struct inode *inode, int oflags, off_t pos, int minfd)
list->fl_files[i].f_oflags = oflags;
list->fl_files[i].f_pos = pos;
list->fl_files[i].f_inode = inode;
+ list->fl_files[i].f_priv = NULL;
_files_semgive(list);
return i;
}