* serial.h: Fix prototye for serial_raw().
* ser-bsd.c, ser-termios.c: Fix args for serial_open() & serial_write() to match prototypes. * remote-st2000.c (get_reg_name): Make *p be const.
This commit is contained in:
parent
a904db5348
commit
ed3f6049b4
5 changed files with 50 additions and 43 deletions
|
@ -1,3 +1,10 @@
|
||||||
|
Tue Sep 8 21:05:18 1992 Stu Grossman (grossman at cygnus.com)
|
||||||
|
|
||||||
|
* serial.h: Fix prototye for serial_raw().
|
||||||
|
* ser-bsd.c, ser-termios.c: Fix args for serial_open() &
|
||||||
|
serial_write() to match prototypes.
|
||||||
|
* remote-st2000.c (get_reg_name): Make *p be const.
|
||||||
|
|
||||||
Tue Sep 8 17:24:52 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
|
Tue Sep 8 17:24:52 1992 Ken Raeburn (raeburn@cambridge.cygnus.com)
|
||||||
|
|
||||||
* remote-nindy.c (nindy_fetch_registers): Make return type void,
|
* remote-nindy.c (nindy_fetch_registers): Make return type void,
|
||||||
|
|
|
@ -399,7 +399,8 @@ get_reg_name (regno)
|
||||||
int regno;
|
int regno;
|
||||||
{
|
{
|
||||||
static char buf[50];
|
static char buf[50];
|
||||||
char *p, *b;
|
const char *p;
|
||||||
|
char *b;
|
||||||
|
|
||||||
b = buf;
|
b = buf;
|
||||||
|
|
||||||
|
|
|
@ -67,7 +67,7 @@ static fd_set readfds;
|
||||||
|
|
||||||
int
|
int
|
||||||
serial_open(name)
|
serial_open(name)
|
||||||
char *name;
|
const char *name;
|
||||||
{
|
{
|
||||||
struct sgttyb sgttyb;
|
struct sgttyb sgttyb;
|
||||||
|
|
||||||
|
@ -198,7 +198,7 @@ serial_setbaudrate(rate)
|
||||||
|
|
||||||
int
|
int
|
||||||
serial_write(str, len)
|
serial_write(str, len)
|
||||||
char *str;
|
const char *str;
|
||||||
int len;
|
int len;
|
||||||
{
|
{
|
||||||
int cc;
|
int cc;
|
||||||
|
|
|
@ -70,7 +70,7 @@ static fd_set readfds;
|
||||||
|
|
||||||
int
|
int
|
||||||
serial_open(name)
|
serial_open(name)
|
||||||
char *name;
|
const char *name;
|
||||||
{
|
{
|
||||||
struct termios termios;
|
struct termios termios;
|
||||||
|
|
||||||
|
@ -193,7 +193,7 @@ serial_setbaudrate(rate)
|
||||||
|
|
||||||
int
|
int
|
||||||
serial_write(str, len)
|
serial_write(str, len)
|
||||||
char *str;
|
const char *str;
|
||||||
int len;
|
int len;
|
||||||
{
|
{
|
||||||
int cc;
|
int cc;
|
||||||
|
|
45
gdb/serial.h
45
gdb/serial.h
|
@ -17,6 +17,27 @@ You should have received a copy of the GNU General Public License
|
||||||
along with this program; if not, write to the Free Software
|
along with this program; if not, write to the Free Software
|
||||||
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
|
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
|
||||||
|
|
||||||
|
#ifdef HAVE_TERMIO
|
||||||
|
|
||||||
|
#include <termios.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
|
||||||
|
struct ttystate
|
||||||
|
{
|
||||||
|
int flags; /* Flags from fcntl F_GETFL */
|
||||||
|
struct termios termios; /* old tty driver settings */
|
||||||
|
};
|
||||||
|
|
||||||
|
#else /* not HAVE_TERMIO */
|
||||||
|
|
||||||
|
#include <sgtty.h>
|
||||||
|
|
||||||
|
struct ttystate {
|
||||||
|
int flags; /* Flags from fcntl F_GETFL */
|
||||||
|
struct sgttyb sgttyb; /* old tty driver settings */
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif /* not HAVE_TERMIO */
|
||||||
/* Return a sensible default name for a serial device, something which
|
/* Return a sensible default name for a serial device, something which
|
||||||
can be used as an argument to serial_open. */
|
can be used as an argument to serial_open. */
|
||||||
|
|
||||||
|
@ -28,7 +49,7 @@ int serial_open PARAMS ((const char *name));
|
||||||
|
|
||||||
/* Turn the port into raw mode. */
|
/* Turn the port into raw mode. */
|
||||||
|
|
||||||
void serial_raw PARAMS ((void));
|
void serial_raw PARAMS ((int fd, struct ttystate *oldstate));
|
||||||
|
|
||||||
/* Turn the port into normal mode. */
|
/* Turn the port into normal mode. */
|
||||||
|
|
||||||
|
@ -54,25 +75,3 @@ int serial_write PARAMS ((const char *str , int len));
|
||||||
/* Close the serial port */
|
/* Close the serial port */
|
||||||
|
|
||||||
void serial_close PARAMS ((void));
|
void serial_close PARAMS ((void));
|
||||||
|
|
||||||
#ifdef HAVE_TERMIO
|
|
||||||
|
|
||||||
#include <termios.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
|
|
||||||
struct ttystate
|
|
||||||
{
|
|
||||||
int flags; /* Flags from fcntl F_GETFL */
|
|
||||||
struct termios termios; /* old tty driver settings */
|
|
||||||
};
|
|
||||||
|
|
||||||
#else /* not HAVE_TERMIO */
|
|
||||||
|
|
||||||
#include <sgtty.h>
|
|
||||||
|
|
||||||
struct ttystate {
|
|
||||||
int flags; /* Flags from fcntl F_GETFL */
|
|
||||||
struct sgttyb sgttyb; /* old tty driver settings */
|
|
||||||
};
|
|
||||||
|
|
||||||
#endif /* not HAVE_TERMIO */
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue