Last minute 6.25 change
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@5595 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
d51e81d34f
commit
9a05ccdbbc
|
@ -1075,17 +1075,17 @@
|
|||
These unreleased changes are also listed <a href="#pendingchanges">here</a>.
|
||||
</p>
|
||||
<p>
|
||||
This release corresponds with SVN release number: r5594,
|
||||
This release corresponds with SVN release number: r5595,
|
||||
Note that all SVN information has been stripped from the tarballs.
|
||||
If you need the SVN configuration, you should check out directly from SVN.
|
||||
Revision r5594 should equivalent to release 6.25 of NuttX:
|
||||
Revision r5595 should equivalent to release 6.25 of NuttX:
|
||||
</p>
|
||||
<ul><pre>
|
||||
svn checkout -r5594 svn://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
svn checkout -r5595 svn://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
</pre></ul>
|
||||
<p>Or (HTTP):</p>
|
||||
<ul><pre>
|
||||
svn checkout -r5594 http://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
svn checkout -r5595 http://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
</pre></ul>
|
||||
|
||||
<p>
|
||||
|
|
|
@ -3450,17 +3450,17 @@ that release consists of two tarballs: nuttx-6.25.tar.gz and
|
|||
apps-6.25.tar.gz. Both may be needed (see the top-level nuttx/README.txt
|
||||
file for build information).
|
||||
|
||||
This release corresponds with SVN release number: r5594
|
||||
This release corresponds with SVN release number: r5595
|
||||
|
||||
Note that all SVN information has been stripped from the tarballs. If you
|
||||
need the SVN configuration information, you should check out directly from
|
||||
SVN. Revision r5594 should equivalent to release 6.25 of NuttX:
|
||||
SVN. Revision r5595 should equivalent to release 6.25 of NuttX:
|
||||
|
||||
svn checkout -r5594 svn://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
svn checkout -r5595 svn://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
|
||||
Or (HTTP):
|
||||
|
||||
svn checkout -r5594 http://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
svn checkout -r5595 http://svn.code.sf.net/p/nuttx/code/trunk nuttx-code
|
||||
|
||||
Additional new features and extended functionality:
|
||||
|
||||
|
|
|
@ -292,15 +292,6 @@ static ssize_t uart_write(FAR struct file *filep, FAR const char *buffer, size_t
|
|||
ssize_t nread = buflen;
|
||||
int ret;
|
||||
|
||||
#ifdef CONFIG_SERIAL_REMOVABLE
|
||||
/* If the removable device is no longer connected, refuse to write to the device */
|
||||
|
||||
if (dev->disconnected)
|
||||
{
|
||||
return -ENOTCONN;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* We may receive console writes through this path from interrupt handlers and
|
||||
* from debug output in the IDLE task! In these cases, we will need to do things
|
||||
* a little differently.
|
||||
|
@ -308,6 +299,17 @@ static ssize_t uart_write(FAR struct file *filep, FAR const char *buffer, size_t
|
|||
|
||||
if (up_interrupt_context() || getpid() == 0)
|
||||
{
|
||||
#ifdef CONFIG_SERIAL_REMOVABLE
|
||||
/* If the removable device is no longer connected, refuse to write to
|
||||
* the device.
|
||||
*/
|
||||
|
||||
if (dev->disconnected)
|
||||
{
|
||||
return -ENOTCONN;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* up_putc() will be used to generate the output in a busy-wait loop.
|
||||
* up_putc() is only available for the console device.
|
||||
*/
|
||||
|
@ -338,6 +340,18 @@ static ssize_t uart_write(FAR struct file *filep, FAR const char *buffer, size_t
|
|||
return ret;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SERIAL_REMOVABLE
|
||||
/* If the removable device is no longer connected, refuse to write to the
|
||||
* device.
|
||||
*/
|
||||
|
||||
if (dev->disconnected)
|
||||
{
|
||||
uart_givesem(&dev->xmit.sem);
|
||||
return -ENOTCONN;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Loop while we still have data to copy to the transmit buffer.
|
||||
* we add data to the head of the buffer; uart_xmitchars takes the
|
||||
* data from the end of the buffer.
|
||||
|
@ -417,15 +431,6 @@ static ssize_t uart_read(FAR struct file *filep, FAR char *buffer, size_t buflen
|
|||
int16_t tail;
|
||||
int ret;
|
||||
|
||||
#ifdef CONFIG_SERIAL_REMOVABLE
|
||||
/* If the removable device is no longer connected, refuse to read from the device */
|
||||
|
||||
if (dev->disconnected)
|
||||
{
|
||||
return -ENOTCONN;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Only one user can access dev->recv.tail at a time */
|
||||
|
||||
ret = uart_takesem(&dev->recv.sem, true);
|
||||
|
@ -439,6 +444,16 @@ static ssize_t uart_read(FAR struct file *filep, FAR char *buffer, size_t buflen
|
|||
return ret;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SERIAL_REMOVABLE
|
||||
/* If the removable device is no longer connected, refuse to read from the device */
|
||||
|
||||
if (dev->disconnected)
|
||||
{
|
||||
uart_givesem(&dev->recv.sem);
|
||||
return -ENOTCONN;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Loop while we still have data to copy to the receive buffer.
|
||||
* we add data to the head of the buffer; uart_xmitchars takes the
|
||||
* data from the end of the buffer.
|
||||
|
|
Loading…
Reference in New Issue