mirror of
https://mirrors.bfsu.edu.cn/git/linux.git
synced 2024-11-11 12:28:41 +08:00
[PATCH] devfs: Remove the tty_driver devfs_name field as it's no longer needed
Also fixes all drivers that set this field. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
parent
264f48646e
commit
f4eaa37017
@ -5250,7 +5250,6 @@ cy_init(void)
|
||||
cy_serial_driver->owner = THIS_MODULE;
|
||||
cy_serial_driver->driver_name = "cyclades";
|
||||
cy_serial_driver->name = "ttyC";
|
||||
cy_serial_driver->devfs_name = "tts/C";
|
||||
cy_serial_driver->major = CYCLADES_MAJOR;
|
||||
cy_serial_driver->minor_start = 0;
|
||||
cy_serial_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -1232,7 +1232,6 @@ static int __init pc_init(void)
|
||||
|
||||
pc_driver->owner = THIS_MODULE;
|
||||
pc_driver->name = "ttyD";
|
||||
pc_driver->devfs_name = "tts/D";
|
||||
pc_driver->major = DIGI_MAJOR;
|
||||
pc_driver->minor_start = 0;
|
||||
pc_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -2449,7 +2449,6 @@ static int __init espserial_init(void)
|
||||
|
||||
esp_driver->owner = THIS_MODULE;
|
||||
esp_driver->name = "ttyP";
|
||||
esp_driver->devfs_name = "tts/P";
|
||||
esp_driver->major = ESP_IN_MAJOR;
|
||||
esp_driver->minor_start = 0;
|
||||
esp_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -820,7 +820,6 @@ int __init hvc_init(void)
|
||||
return -ENOMEM;
|
||||
|
||||
drv->owner = THIS_MODULE;
|
||||
drv->devfs_name = "hvc/";
|
||||
drv->driver_name = "hvc";
|
||||
drv->name = "hvc";
|
||||
drv->major = HVC_MAJOR;
|
||||
|
@ -1364,7 +1364,6 @@ static int __init hvcs_module_init(void)
|
||||
|
||||
hvcs_tty_driver->driver_name = hvcs_driver_name;
|
||||
hvcs_tty_driver->name = hvcs_device_node;
|
||||
hvcs_tty_driver->devfs_name = hvcs_device_node;
|
||||
|
||||
/*
|
||||
* We'll let the system assign us a major number, indicated by leaving
|
||||
|
@ -1154,7 +1154,6 @@ static int __init hvsi_init(void)
|
||||
return -ENOMEM;
|
||||
|
||||
hvsi_driver->owner = THIS_MODULE;
|
||||
hvsi_driver->devfs_name = "hvsi/";
|
||||
hvsi_driver->driver_name = "hvsi";
|
||||
hvsi_driver->name = "hvsi";
|
||||
hvsi_driver->major = HVSI_MAJOR;
|
||||
|
@ -671,7 +671,6 @@ ip2_loadmain(int *iop, int *irqp, unsigned char *firmware, int firmsize)
|
||||
|
||||
ip2_tty_driver->owner = THIS_MODULE;
|
||||
ip2_tty_driver->name = "ttyF";
|
||||
ip2_tty_driver->devfs_name = "tts/F";
|
||||
ip2_tty_driver->driver_name = pcDriver_name;
|
||||
ip2_tty_driver->major = IP2_TTY_MAJOR;
|
||||
ip2_tty_driver->minor_start = 0;
|
||||
|
@ -1581,7 +1581,6 @@ static int __devinit isicom_register_tty_driver(void)
|
||||
|
||||
isicom_normal->owner = THIS_MODULE;
|
||||
isicom_normal->name = "ttyM";
|
||||
isicom_normal->devfs_name = "isicom/";
|
||||
isicom_normal->major = ISICOM_NMAJOR;
|
||||
isicom_normal->minor_start = 0;
|
||||
isicom_normal->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -342,7 +342,6 @@ static int __init moxa_init(void)
|
||||
init_MUTEX(&moxaBuffSem);
|
||||
moxaDriver->owner = THIS_MODULE;
|
||||
moxaDriver->name = "ttyMX";
|
||||
moxaDriver->devfs_name = "tts/a";
|
||||
moxaDriver->major = ttymajor;
|
||||
moxaDriver->minor_start = 0;
|
||||
moxaDriver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -264,7 +264,6 @@ static void __init legacy_pty_init(void)
|
||||
pty_driver->owner = THIS_MODULE;
|
||||
pty_driver->driver_name = "pty_master";
|
||||
pty_driver->name = "pty";
|
||||
pty_driver->devfs_name = "pty/m";
|
||||
pty_driver->major = PTY_MASTER_MAJOR;
|
||||
pty_driver->minor_start = 0;
|
||||
pty_driver->type = TTY_DRIVER_TYPE_PTY;
|
||||
@ -282,7 +281,6 @@ static void __init legacy_pty_init(void)
|
||||
pty_slave_driver->owner = THIS_MODULE;
|
||||
pty_slave_driver->driver_name = "pty_slave";
|
||||
pty_slave_driver->name = "ttyp";
|
||||
pty_slave_driver->devfs_name = "pty/s";
|
||||
pty_slave_driver->major = PTY_SLAVE_MAJOR;
|
||||
pty_slave_driver->minor_start = 0;
|
||||
pty_slave_driver->type = TTY_DRIVER_TYPE_PTY;
|
||||
|
@ -1634,7 +1634,6 @@ static inline int rc_init_drivers(void)
|
||||
memset(IRQ_to_board, 0, sizeof(IRQ_to_board));
|
||||
riscom_driver->owner = THIS_MODULE;
|
||||
riscom_driver->name = "ttyL";
|
||||
riscom_driver->devfs_name = "tts/L";
|
||||
riscom_driver->major = RISCOM8_NORMAL_MAJOR;
|
||||
riscom_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
riscom_driver->subtype = SERIAL_TYPE_NORMAL;
|
||||
|
@ -2427,7 +2427,6 @@ static int __init rp_init(void)
|
||||
|
||||
rocket_driver->owner = THIS_MODULE;
|
||||
rocket_driver->flags = TTY_DRIVER_NO_DEVFS;
|
||||
rocket_driver->devfs_name = "tts/R";
|
||||
rocket_driver->name = "ttyR";
|
||||
rocket_driver->driver_name = "Comtrol RocketPort";
|
||||
rocket_driver->major = TTY_ROCKET_MAJOR;
|
||||
|
@ -2235,7 +2235,6 @@ scrn[1] = '\0';
|
||||
/* Initialize the tty_driver structure */
|
||||
|
||||
cy_serial_driver->owner = THIS_MODULE;
|
||||
cy_serial_driver->devfs_name = "tts/";
|
||||
cy_serial_driver->name = "ttyS";
|
||||
cy_serial_driver->major = TTY_MAJOR;
|
||||
cy_serial_driver->minor_start = 64;
|
||||
|
@ -3075,7 +3075,6 @@ static int __init stl_init(void)
|
||||
stl_serial->owner = THIS_MODULE;
|
||||
stl_serial->driver_name = stl_drvname;
|
||||
stl_serial->name = "ttyE";
|
||||
stl_serial->devfs_name = "tts/E";
|
||||
stl_serial->major = STL_SERIALMAJOR;
|
||||
stl_serial->minor_start = 0;
|
||||
stl_serial->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -1152,7 +1152,6 @@ static int __init viocons_init2(void)
|
||||
viotty_driver = alloc_tty_driver(VTTY_PORTS);
|
||||
viotty_driver->owner = THIS_MODULE;
|
||||
viotty_driver->driver_name = "vioconsole";
|
||||
viotty_driver->devfs_name = "vcs/";
|
||||
viotty_driver->name = "tty";
|
||||
viotty_driver->name_base = 1;
|
||||
viotty_driver->major = TTY_MAJOR;
|
||||
|
@ -147,7 +147,6 @@ static int scc_init_drivers(void)
|
||||
scc_driver->owner = THIS_MODULE;
|
||||
scc_driver->driver_name = "scc";
|
||||
scc_driver->name = "ttyS";
|
||||
scc_driver->devfs_name = "tts/";
|
||||
scc_driver->major = TTY_MAJOR;
|
||||
scc_driver->minor_start = SCC_MINOR_BASE;
|
||||
scc_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -2662,7 +2662,6 @@ int __init vty_init(void)
|
||||
if (!console_driver)
|
||||
panic("Couldn't allocate console driver\n");
|
||||
console_driver->owner = THIS_MODULE;
|
||||
console_driver->devfs_name = "vc/";
|
||||
console_driver->name = "tty";
|
||||
console_driver->name_base = 1;
|
||||
console_driver->major = TTY_MAJOR;
|
||||
|
@ -1336,7 +1336,6 @@ static int capinc_tty_init(void)
|
||||
|
||||
drv->owner = THIS_MODULE;
|
||||
drv->driver_name = "capi_nc";
|
||||
drv->devfs_name = "capi/";
|
||||
drv->name = "capi";
|
||||
drv->major = capi_ttymajor;
|
||||
drv->minor_start = 0;
|
||||
|
@ -41,7 +41,6 @@ MODULE_PARM_DESC(cidmode, "Call-ID mode");
|
||||
#define GIGASET_MINORS 1
|
||||
#define GIGASET_MINOR 16
|
||||
#define GIGASET_MODULENAME "bas_gigaset"
|
||||
#define GIGASET_DEVFSNAME "gig/bas/"
|
||||
#define GIGASET_DEVNAME "ttyGB"
|
||||
|
||||
/* length limit according to Siemens 3070usb-protokoll.doc ch. 2.1 */
|
||||
@ -2349,8 +2348,7 @@ static int __init bas_gigaset_init(void)
|
||||
/* allocate memory for our driver state and intialize it */
|
||||
if ((driver = gigaset_initdriver(GIGASET_MINOR, GIGASET_MINORS,
|
||||
GIGASET_MODULENAME, GIGASET_DEVNAME,
|
||||
GIGASET_DEVFSNAME, &gigops,
|
||||
THIS_MODULE)) == NULL)
|
||||
&gigops, THIS_MODULE)) == NULL)
|
||||
goto error;
|
||||
|
||||
/* allocate memory for our device state and intialize it */
|
||||
|
@ -1092,14 +1092,12 @@ EXPORT_SYMBOL_GPL(gigaset_freedriver);
|
||||
* minors Number of minors this driver can handle
|
||||
* procname Name of the driver
|
||||
* devname Name of the device files (prefix without minor number)
|
||||
* devfsname Devfs name of the device files without %d
|
||||
* return value:
|
||||
* Pointer to the gigaset_driver structure on success, NULL on failure.
|
||||
*/
|
||||
struct gigaset_driver *gigaset_initdriver(unsigned minor, unsigned minors,
|
||||
const char *procname,
|
||||
const char *devname,
|
||||
const char *devfsname,
|
||||
const struct gigaset_ops *ops,
|
||||
struct module *owner)
|
||||
{
|
||||
@ -1139,7 +1137,7 @@ struct gigaset_driver *gigaset_initdriver(unsigned minor, unsigned minors,
|
||||
drv->cs[i].minor_index = i;
|
||||
}
|
||||
|
||||
gigaset_if_initdriver(drv, procname, devname, devfsname);
|
||||
gigaset_if_initdriver(drv, procname, devname);
|
||||
|
||||
spin_lock_irqsave(&driver_lock, flags);
|
||||
list_add(&drv->list, &drivers);
|
||||
|
@ -769,7 +769,6 @@ void gigaset_block_channels(struct cardstate *cs);
|
||||
struct gigaset_driver *gigaset_initdriver(unsigned minor, unsigned minors,
|
||||
const char *procname,
|
||||
const char *devname,
|
||||
const char *devfsname,
|
||||
const struct gigaset_ops *ops,
|
||||
struct module *owner);
|
||||
|
||||
@ -892,7 +891,7 @@ int gigaset_fill_inbuf(struct inbuf_t *inbuf, const unsigned char *src,
|
||||
|
||||
/* initialize interface */
|
||||
void gigaset_if_initdriver(struct gigaset_driver *drv, const char *procname,
|
||||
const char *devname, const char *devfsname);
|
||||
const char *devname);
|
||||
/* release interface */
|
||||
void gigaset_if_freedriver(struct gigaset_driver *drv);
|
||||
/* add minor */
|
||||
|
@ -673,10 +673,9 @@ EXPORT_SYMBOL_GPL(gigaset_if_receive);
|
||||
* drv Driver
|
||||
* procname Name of the driver (e.g. for /proc/tty/drivers)
|
||||
* devname Name of the device files (prefix without minor number)
|
||||
* devfsname Devfs name of the device files without %d
|
||||
*/
|
||||
void gigaset_if_initdriver(struct gigaset_driver *drv, const char *procname,
|
||||
const char *devname, const char *devfsname)
|
||||
const char *devname)
|
||||
{
|
||||
unsigned minors = drv->minors;
|
||||
int ret;
|
||||
@ -700,7 +699,6 @@ void gigaset_if_initdriver(struct gigaset_driver *drv, const char *procname,
|
||||
tty->num = drv->minors;
|
||||
|
||||
tty->owner = THIS_MODULE;
|
||||
tty->devfs_name = devfsname;
|
||||
|
||||
tty->init_termios = tty_std_termios; //FIXME
|
||||
tty->init_termios.c_cflag = B9600 | CS8 | CREAD | HUPCL | CLOCAL; //FIXME
|
||||
|
@ -41,7 +41,6 @@ MODULE_PARM_DESC(cidmode, "Call-ID mode");
|
||||
#define GIGASET_MINORS 1
|
||||
#define GIGASET_MINOR 8
|
||||
#define GIGASET_MODULENAME "usb_gigaset"
|
||||
#define GIGASET_DEVFSNAME "gig/usb/"
|
||||
#define GIGASET_DEVNAME "ttyGU"
|
||||
|
||||
#define IF_WRITEBUF 2000 //FIXME // WAKEUP_CHARS: 256
|
||||
@ -896,8 +895,7 @@ static int __init usb_gigaset_init(void)
|
||||
/* allocate memory for our driver state and intialize it */
|
||||
if ((driver = gigaset_initdriver(GIGASET_MINOR, GIGASET_MINORS,
|
||||
GIGASET_MODULENAME, GIGASET_DEVNAME,
|
||||
GIGASET_DEVFSNAME, &ops,
|
||||
THIS_MODULE)) == NULL)
|
||||
&ops, THIS_MODULE)) == NULL)
|
||||
goto error;
|
||||
|
||||
/* allocate memory for our device state and intialize it */
|
||||
|
@ -1890,7 +1890,6 @@ isdn_tty_modem_init(void)
|
||||
if (!m->tty_modem)
|
||||
return -ENOMEM;
|
||||
m->tty_modem->name = "ttyI";
|
||||
m->tty_modem->devfs_name = "isdn/ttyI";
|
||||
m->tty_modem->major = ISDN_TTY_MAJOR;
|
||||
m->tty_modem->minor_start = 0;
|
||||
m->tty_modem->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -1785,7 +1785,6 @@ tty3270_init(void)
|
||||
* proc_entry, set_termios, flush_buffer, set_ldisc, write_proc
|
||||
*/
|
||||
driver->owner = THIS_MODULE;
|
||||
driver->devfs_name = "ttyTUB/";
|
||||
driver->driver_name = "ttyTUB";
|
||||
driver->name = "ttyTUB";
|
||||
driver->major = IBM_TTY3270_MAJOR;
|
||||
|
@ -1745,7 +1745,6 @@ int __init zs_init(void)
|
||||
/* Not all of this is exactly right for us. */
|
||||
|
||||
serial_driver->owner = THIS_MODULE;
|
||||
serial_driver->devfs_name = "tts/";
|
||||
serial_driver->name = "ttyS";
|
||||
serial_driver->major = TTY_MAJOR;
|
||||
serial_driver->minor_start = 64;
|
||||
|
@ -1145,7 +1145,6 @@ static int __init acm_init(void)
|
||||
acm_tty_driver->owner = THIS_MODULE,
|
||||
acm_tty_driver->driver_name = "acm",
|
||||
acm_tty_driver->name = "ttyACM",
|
||||
acm_tty_driver->devfs_name = "usb/acm/",
|
||||
acm_tty_driver->major = ACM_TTY_MAJOR,
|
||||
acm_tty_driver->minor_start = 0,
|
||||
acm_tty_driver->type = TTY_DRIVER_TYPE_SERIAL,
|
||||
|
@ -588,7 +588,6 @@ static int __init gs_module_init(void)
|
||||
gs_tty_driver->owner = THIS_MODULE;
|
||||
gs_tty_driver->driver_name = GS_SHORT_NAME;
|
||||
gs_tty_driver->name = "ttygs";
|
||||
gs_tty_driver->devfs_name = "usb/ttygs/";
|
||||
gs_tty_driver->major = GS_MAJOR;
|
||||
gs_tty_driver->minor_start = GS_MINOR_START;
|
||||
gs_tty_driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
@ -1059,7 +1059,6 @@ static int __init usb_serial_init(void)
|
||||
|
||||
usb_serial_tty_driver->owner = THIS_MODULE;
|
||||
usb_serial_tty_driver->driver_name = "usbserial";
|
||||
usb_serial_tty_driver->devfs_name = "usb/tts/";
|
||||
usb_serial_tty_driver->name = "ttyUSB";
|
||||
usb_serial_tty_driver->major = SERIAL_TTY_MAJOR;
|
||||
usb_serial_tty_driver->minor_start = 0;
|
||||
|
@ -157,7 +157,6 @@ struct tty_driver {
|
||||
struct cdev cdev;
|
||||
struct module *owner;
|
||||
const char *driver_name;
|
||||
const char *devfs_name;
|
||||
const char *name;
|
||||
int name_base; /* offset of printed name */
|
||||
int major; /* major device number */
|
||||
|
@ -1025,7 +1025,6 @@ int rfcomm_init_ttys(void)
|
||||
|
||||
rfcomm_tty_driver->owner = THIS_MODULE;
|
||||
rfcomm_tty_driver->driver_name = "rfcomm";
|
||||
rfcomm_tty_driver->devfs_name = "bluetooth/rfcomm/";
|
||||
rfcomm_tty_driver->name = "rfcomm";
|
||||
rfcomm_tty_driver->major = RFCOMM_TTY_MAJOR;
|
||||
rfcomm_tty_driver->minor_start = RFCOMM_TTY_MINOR;
|
||||
|
@ -124,7 +124,6 @@ static int __init ircomm_tty_init(void)
|
||||
driver->owner = THIS_MODULE;
|
||||
driver->driver_name = "ircomm";
|
||||
driver->name = "ircomm";
|
||||
driver->devfs_name = "ircomm";
|
||||
driver->major = IRCOMM_TTY_MAJOR;
|
||||
driver->minor_start = IRCOMM_TTY_MINOR;
|
||||
driver->type = TTY_DRIVER_TYPE_SERIAL;
|
||||
|
Loading…
Reference in New Issue
Block a user