Remove OTTYDISC, NETLDISC and NTTYDISC definitions.
When I ported most applications away from <sgtty.h>, I noticed none of them were actually using these definitions. I kept them in place, because I didn't want to touch tools like pstat(8) and stty(1). In preparation for the MPSAFE TTY layer, remove these definitions. This doesn't have any impact with respect to binary compatibility (see tty_conf.c). We couldn now add an #error to <sys/ioctl_compat.h> when included outside the kernel. Unfortunately, kdump's mkioctls includes this file unconditionally. Approved by: philip (mentor)
This commit is contained in:
parent
ca528788b8
commit
94a340ae73
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=180559
@ -44,8 +44,6 @@ __FBSDID("$FreeBSD$");
|
|||||||
#include "stty.h"
|
#include "stty.h"
|
||||||
#include "extern.h"
|
#include "extern.h"
|
||||||
|
|
||||||
#include <sys/ioctl_compat.h> /* XXX NTTYDISC is too well hidden */
|
|
||||||
|
|
||||||
static void binit(const char *);
|
static void binit(const char *);
|
||||||
static void bput(const char *);
|
static void bput(const char *);
|
||||||
static const char *ccval(struct cchar *, int);
|
static const char *ccval(struct cchar *, int);
|
||||||
@ -64,9 +62,6 @@ print(struct termios *tp, struct winsize *wp, int ldisc, enum FMT fmt)
|
|||||||
/* Line discipline. */
|
/* Line discipline. */
|
||||||
if (ldisc != TTYDISC) {
|
if (ldisc != TTYDISC) {
|
||||||
switch(ldisc) {
|
switch(ldisc) {
|
||||||
case NTTYDISC:
|
|
||||||
cnt += printf("new tty disc; ");
|
|
||||||
break;
|
|
||||||
case SLIPDISC:
|
case SLIPDISC:
|
||||||
cnt += printf("slip disc; ");
|
cnt += printf("slip disc; ");
|
||||||
break;
|
break;
|
||||||
|
@ -61,8 +61,6 @@ struct ltchars {
|
|||||||
/*
|
/*
|
||||||
* Structure for TIOCGETP and TIOCSETP ioctls.
|
* Structure for TIOCGETP and TIOCSETP ioctls.
|
||||||
*/
|
*/
|
||||||
#ifndef _SGTTYB_
|
|
||||||
#define _SGTTYB_
|
|
||||||
struct sgttyb {
|
struct sgttyb {
|
||||||
char sg_ispeed; /* input speed */
|
char sg_ispeed; /* input speed */
|
||||||
char sg_ospeed; /* output speed */
|
char sg_ospeed; /* output speed */
|
||||||
@ -70,7 +68,6 @@ struct sgttyb {
|
|||||||
char sg_kill; /* kill character */
|
char sg_kill; /* kill character */
|
||||||
short sg_flags; /* mode flags */
|
short sg_flags; /* mode flags */
|
||||||
};
|
};
|
||||||
#endif
|
|
||||||
|
|
||||||
#define OTIOCGETD _IOR('t', 0, int) /* get line discipline */
|
#define OTIOCGETD _IOR('t', 0, int) /* get line discipline */
|
||||||
#define OTIOCSETD _IOW('t', 1, int) /* set line discipline */
|
#define OTIOCSETD _IOW('t', 1, int) /* set line discipline */
|
||||||
@ -152,9 +149,4 @@ struct sgttyb {
|
|||||||
|
|
||||||
#endif /* _KERNEL */
|
#endif /* _KERNEL */
|
||||||
|
|
||||||
/* XXX publish these so stty(1) can still report them */
|
|
||||||
#define OTTYDISC 0
|
|
||||||
#define NETLDISC 1
|
|
||||||
#define NTTYDISC 2
|
|
||||||
|
|
||||||
#endif /* !_SYS_IOCTL_COMPAT_H_ */
|
#endif /* !_SYS_IOCTL_COMPAT_H_ */
|
||||||
|
@ -54,7 +54,6 @@ __FBSDID("$FreeBSD$");
|
|||||||
#include <sys/stat.h>
|
#include <sys/stat.h>
|
||||||
#include <sys/stdint.h>
|
#include <sys/stdint.h>
|
||||||
#include <sys/ioctl.h>
|
#include <sys/ioctl.h>
|
||||||
#include <sys/ioctl_compat.h> /* XXX NTTYDISC is too well hidden */
|
|
||||||
#include <sys/tty.h>
|
#include <sys/tty.h>
|
||||||
#include <sys/blist.h>
|
#include <sys/blist.h>
|
||||||
|
|
||||||
@ -367,9 +366,6 @@ ttyprt(struct xtty *xt)
|
|||||||
case TTYDISC:
|
case TTYDISC:
|
||||||
(void)printf("term\n");
|
(void)printf("term\n");
|
||||||
break;
|
break;
|
||||||
case NTTYDISC:
|
|
||||||
(void)printf("ntty\n");
|
|
||||||
break;
|
|
||||||
case SLIPDISC:
|
case SLIPDISC:
|
||||||
(void)printf("slip\n");
|
(void)printf("slip\n");
|
||||||
break;
|
break;
|
||||||
|
Loading…
Reference in New Issue
Block a user