TTY: remove re-assignments to tty_driver members
authorJiri Slaby <jslaby@suse.cz>
Mon, 5 Mar 2012 13:51:52 +0000 (14:51 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 8 Mar 2012 19:37:58 +0000 (11:37 -0800)
All num, magic and owner are set by alloc_tty_driver. No need to
re-set them on each allocation site.

pti driver sets something different to what it passes to
alloc_tty_driver. It is not a bug, since we don't use the lines
parameter in any way. Anyway this is fixed, and now we do the right
thing.

Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Acked-by: Tilman Schmidt <tilman@imap.cc>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
41 files changed:
arch/ia64/hp/sim/simserial.c
arch/m68k/emu/nfcon.c
arch/xtensa/platforms/iss/console.c
drivers/char/pcmcia/synclink_cs.c
drivers/char/ttyprintk.c
drivers/isdn/capi/capi.c
drivers/isdn/gigaset/interface.c
drivers/misc/pti.c
drivers/mmc/card/sdio_uart.c
drivers/net/usb/hso.c
drivers/s390/char/con3215.c
drivers/s390/char/sclp_tty.c
drivers/s390/char/sclp_vt220.c
drivers/s390/char/tty3270.c
drivers/tty/amiserial.c
drivers/tty/bfin_jtag_comm.c
drivers/tty/cyclades.c
drivers/tty/ehv_bytechan.c
drivers/tty/hvc/hvc_console.c
drivers/tty/hvc/hvcs.c
drivers/tty/hvc/hvsi.c
drivers/tty/ipwireless/tty.c
drivers/tty/isicom.c
drivers/tty/moxa.c
drivers/tty/mxser.c
drivers/tty/n_gsm.c
drivers/tty/nozomi.c
drivers/tty/pty.c
drivers/tty/rocket.c
drivers/tty/serial/ifx6x60.c
drivers/tty/serial/msm_smd_tty.c
drivers/tty/serial/serial_core.c
drivers/tty/synclink.c
drivers/tty/synclink_gt.c
drivers/tty/synclinkmp.c
drivers/tty/vt/vt.c
drivers/usb/class/cdc-acm.c
drivers/usb/gadget/u_serial.c
drivers/usb/serial/usb-serial.c
net/bluetooth/rfcomm/tty.c
net/irda/ircomm/ircomm_tty.c

index bff0824cf8a43e0be464de603deecc252c182051..f513dc02bb8799ad2b8ec4d85c75baf859238e97 100644 (file)
@@ -928,7 +928,6 @@ simrs_init (void)
 
        /* Initialize the tty_driver structure */
 
-       hp_simserial_driver->owner = THIS_MODULE;
        hp_simserial_driver->driver_name = "simserial";
        hp_simserial_driver->name = "ttyS";
        hp_simserial_driver->major = TTY_MAJOR;
index ab20dc0ff63bd47075075390abf074b735bb2850..8db25e8069471f03f07335153bf8137c05ef41b4 100644 (file)
@@ -127,7 +127,6 @@ static int __init nfcon_init(void)
        if (!nfcon_tty_driver)
                return -ENOMEM;
 
-       nfcon_tty_driver->owner = THIS_MODULE;
        nfcon_tty_driver->driver_name = "nfcon";
        nfcon_tty_driver->name = "nfcon";
        nfcon_tty_driver->type = TTY_DRIVER_TYPE_SYSTEM;
index 2c723e8b30da4f7b08b9bb7418735356d69639fb..247e9d40a52e5800a281e7c74b26658ba807be75 100644 (file)
@@ -216,7 +216,6 @@ int __init rs_init(void)
 
        /* Initialize the tty_driver structure */
 
-       serial_driver->owner = THIS_MODULE;
        serial_driver->driver_name = "iss_serial";
        serial_driver->name = "ttyS";
        serial_driver->major = TTY_MAJOR;
index 07f6a5abe3722a1143c0dd71ef6e8527caa155bd..c3bcb1221e6b7aa4d1a93d8119ec1ebccf3987a7 100644 (file)
@@ -2836,7 +2836,6 @@ static int __init synclink_cs_init(void)
 
     /* Initialize the tty_driver structure */
 
-    serial_driver->owner = THIS_MODULE;
     serial_driver->driver_name = "synclink_cs";
     serial_driver->name = "ttySLP";
     serial_driver->major = ttymajor;
index eedd5474850c5008fe4ea957d73d5197a86dba14..46b77ede84c01cb2b103b3256e2fab39bf16d889 100644 (file)
@@ -184,12 +184,10 @@ static int __init ttyprintk_init(void)
        if (!ttyprintk_driver)
                return ret;
 
-       ttyprintk_driver->owner = THIS_MODULE;
        ttyprintk_driver->driver_name = "ttyprintk";
        ttyprintk_driver->name = "ttyprintk";
        ttyprintk_driver->major = TTYAUX_MAJOR;
        ttyprintk_driver->minor_start = 3;
-       ttyprintk_driver->num = 1;
        ttyprintk_driver->type = TTY_DRIVER_TYPE_CONSOLE;
        ttyprintk_driver->init_termios = tty_std_termios;
        ttyprintk_driver->init_termios.c_oflag = OPOST | OCRNL | ONOCR | ONLRET;
index 94948be5d366b130bbec5b50046f7c3ff4496464..baf08eba495cc9f6178a78c4c730a7d986a6cc11 100644 (file)
@@ -1287,7 +1287,6 @@ static int __init capinc_tty_init(void)
                kfree(capiminors);
                return -ENOMEM;
        }
-       drv->owner = THIS_MODULE;
        drv->driver_name = "capi_nc";
        drv->name = "capi";
        drv->major = 0;
index ee0a549a933a0176fdf9804e580bcc40557c25ac..648260b07f1a10a1f51ed6c2c3741b55c0a79bd5 100644 (file)
@@ -669,17 +669,15 @@ EXPORT_SYMBOL_GPL(gigaset_if_receive);
 void gigaset_if_initdriver(struct gigaset_driver *drv, const char *procname,
                           const char *devname)
 {
-       unsigned minors = drv->minors;
        int ret;
        struct tty_driver *tty;
 
        drv->have_tty = 0;
 
-       drv->tty = tty = alloc_tty_driver(minors);
+       drv->tty = tty = alloc_tty_driver(drv->minors);
        if (tty == NULL)
                goto enomem;
 
-       tty->magic =            TTY_DRIVER_MAGIC,
        tty->type =             TTY_DRIVER_TYPE_SERIAL,
        tty->subtype =          SERIAL_TYPE_NORMAL,
        tty->flags =            TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV;
@@ -687,9 +685,6 @@ void gigaset_if_initdriver(struct gigaset_driver *drv, const char *procname,
        tty->driver_name =      procname;
        tty->name =             devname;
        tty->minor_start =      drv->minor;
-       tty->num =              drv->minors;
-
-       tty->owner =            THIS_MODULE;
 
        tty->init_termios          = tty_std_termios;
        tty->init_termios.c_cflag  = B9600 | CS8 | CREAD | HUPCL | CLOCAL;
index 9a35db3d27fc8604935332914cbae6c8a07480d5..383133b201a1ce34c73e4432b42c52fc2bc61032 100644 (file)
@@ -907,20 +907,17 @@ static int __init pti_init(void)
 
        /* First register module as tty device */
 
-       pti_tty_driver = alloc_tty_driver(1);
+       pti_tty_driver = alloc_tty_driver(PTITTY_MINOR_NUM);
        if (pti_tty_driver == NULL) {
                pr_err("%s(%d): Memory allocation failed for ptiTTY driver\n",
                        __func__, __LINE__);
                return -ENOMEM;
        }
 
-       pti_tty_driver->owner                   = THIS_MODULE;
-       pti_tty_driver->magic                   = TTY_DRIVER_MAGIC;
        pti_tty_driver->driver_name             = DRIVERNAME;
        pti_tty_driver->name                    = TTYNAME;
        pti_tty_driver->major                   = 0;
        pti_tty_driver->minor_start             = PTITTY_MINOR_START;
-       pti_tty_driver->num                     = PTITTY_MINOR_NUM;
        pti_tty_driver->type                    = TTY_DRIVER_TYPE_SYSTEM;
        pti_tty_driver->subtype                 = SYSTEM_TYPE_SYSCONS;
        pti_tty_driver->flags                   = TTY_DRIVER_REAL_RAW |
index bd4a67cdac3fcd41347f97319b4014be8658b559..5a2cbfac66d23b3197ea548df65b59c8b5f2bbcf 100644 (file)
@@ -1175,7 +1175,6 @@ static int __init sdio_uart_init(void)
        if (!tty_drv)
                return -ENOMEM;
 
-       tty_drv->owner = THIS_MODULE;
        tty_drv->driver_name = "sdio_uart";
        tty_drv->name =   "ttySDIO";
        tty_drv->major = 0;  /* dynamically allocated */
index 304fe78ff60e3b287b608fb4b19bafacb915e315..a73090f4c688ecd9c96d136f41f885d9c0e1331a 100644 (file)
@@ -3313,7 +3313,6 @@ static int __init hso_init(void)
 
        /* fill in all needed values */
        tty_drv->magic = TTY_DRIVER_MAGIC;
-       tty_drv->owner = THIS_MODULE;
        tty_drv->driver_name = driver_name;
        tty_drv->name = tty_filename;
 
@@ -3322,7 +3321,6 @@ static int __init hso_init(void)
                tty_drv->major = tty_major;
 
        tty_drv->minor_start = 0;
-       tty_drv->num = HSO_SERIAL_TTY_MINORS;
        tty_drv->type = TTY_DRIVER_TYPE_SERIAL;
        tty_drv->subtype = SERIAL_TYPE_NORMAL;
        tty_drv->flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV;
index 934458ad55e51782c7b595b48c5f3088393b8495..fe916bfd60f288ed4a9be616b26183e4a082486c 100644 (file)
@@ -1137,7 +1137,6 @@ static int __init tty3215_init(void)
         * proc_entry, set_termios, flush_buffer, set_ldisc, write_proc
         */
 
-       driver->owner = THIS_MODULE;
        driver->driver_name = "tty3215";
        driver->name = "ttyS";
        driver->major = TTY_MAJOR;
index a879c139926ac0deb7ed012684813ca90f934113..40a9d69c898e13fc1dc489d221647bce25bcfacd 100644 (file)
@@ -551,7 +551,6 @@ sclp_tty_init(void)
                return rc;
        }
 
-       driver->owner = THIS_MODULE;
        driver->driver_name = "sclp_line";
        driver->name = "sclp_line";
        driver->major = TTY_MAJOR;
index 5d706e6c946fb37ea87d78dddfef45a628bb00d0..b635472ae660ef42b34758d6a66d31c3d4ad7ba9 100644 (file)
@@ -685,7 +685,6 @@ static int __init sclp_vt220_tty_init(void)
        if (rc)
                goto out_driver;
 
-       driver->owner = THIS_MODULE;
        driver->driver_name = SCLP_VT220_DRIVER_NAME;
        driver->name = SCLP_VT220_DEVICE_NAME;
        driver->major = SCLP_VT220_MAJOR;
index 2db1482b406e67517de0bf6585a673f91468457c..b43445a55cb60e74b6e132548dc8b33c0d219373 100644 (file)
@@ -1784,7 +1784,6 @@ static int __init tty3270_init(void)
         * Entries in tty3270_driver that are NOT initialized:
         * proc_entry, set_termios, flush_buffer, set_ldisc, write_proc
         */
-       driver->owner = THIS_MODULE;
        driver->driver_name = "ttyTUB";
        driver->name = "ttyTUB";
        driver->major = IBM_TTY3270_MAJOR;
index b84c83456dccf276e135cf07e50d7063b7da8440..b42f00d987ae408c75a291af4e6be16eff8a1820 100644 (file)
@@ -1974,7 +1974,6 @@ static int __init amiga_serial_probe(struct platform_device *pdev)
 
        /* Initialize the tty_driver structure */
 
-       serial_driver->owner = THIS_MODULE;
        serial_driver->driver_name = "amiserial";
        serial_driver->name = "ttyS";
        serial_driver->major = TTY_MAJOR;
index 3a997760ec3233ea44d7886a8e343cd54131f8c7..946f799861f54fe19926ebc06f6e90d2857e5990 100644 (file)
@@ -257,7 +257,6 @@ static int __init bfin_jc_init(void)
        if (!bfin_jc_driver)
                goto err_driver;
 
-       bfin_jc_driver->owner        = THIS_MODULE;
        bfin_jc_driver->driver_name  = DRV_NAME;
        bfin_jc_driver->name         = DEV_NAME;
        bfin_jc_driver->type         = TTY_DRIVER_TYPE_SERIAL;
index 5575fee7a55e6cbdfe4315256163d36ab2eeb9ef..bc7b5a5650ba11c067c3a45267babb1ebcf86b81 100644 (file)
@@ -4090,7 +4090,6 @@ static int __init cy_init(void)
 
        /* Initialize the tty_driver structure */
 
-       cy_serial_driver->owner = THIS_MODULE;
        cy_serial_driver->driver_name = "cyclades";
        cy_serial_driver->name = "ttyC";
        cy_serial_driver->major = CYCLADES_MAJOR;
index 1595dba0072c697cd1712269b0aa225762b4d6b7..4813684cb634ed2c7cf5fae1f0dc4b946426a099 100644 (file)
@@ -825,7 +825,6 @@ static int __init ehv_bc_init(void)
                goto error;
        }
 
-       ehv_bc_driver->owner = THIS_MODULE;
        ehv_bc_driver->driver_name = "ehv-bc";
        ehv_bc_driver->name = ehv_bc_console.name;
        ehv_bc_driver->type = TTY_DRIVER_TYPE_CONSOLE;
index b6b2d18fa38dc9827f47a297cfeb6d013f6b21f7..8880adf5fc6f65ae084481dffb8c390ed40c7ad4 100644 (file)
@@ -917,7 +917,6 @@ static int hvc_init(void)
                goto out;
        }
 
-       drv->owner = THIS_MODULE;
        drv->driver_name = "hvc";
        drv->name = "hvc";
        drv->major = HVC_MAJOR;
index df7e7a0a5e6c6deeefe43f12cf3b8571d0cd795f..da0aa476804d204d8b1b73e4bc9409a64ef4431c 100644 (file)
@@ -1499,8 +1499,6 @@ static int __devinit hvcs_initialize(void)
                goto index_fail;
        }
 
-       hvcs_tty_driver->owner = THIS_MODULE;
-
        hvcs_tty_driver->driver_name = hvcs_driver_name;
        hvcs_tty_driver->name = hvcs_device_node;
 
index 1b5f28bd7930a1fffa25c6fba3c60f1346df52f2..60bc451641890043c872d89aa76ef132eab1abc5 100644 (file)
@@ -1088,7 +1088,6 @@ static int __init hvsi_init(void)
        if (!hvsi_driver)
                return -ENOMEM;
 
-       hvsi_driver->owner = THIS_MODULE;
        hvsi_driver->driver_name = "hvsi";
        hvsi_driver->name = "hvsi";
        hvsi_driver->major = HVSI_MAJOR;
index ef92869502a707dc856ade814e0fe82e8ca5008a..6990b3b649d3353479def081bf145e2534bae606 100644 (file)
@@ -614,7 +614,6 @@ int ipwireless_tty_init(void)
        if (!ipw_tty_driver)
                return -ENOMEM;
 
-       ipw_tty_driver->owner = THIS_MODULE;
        ipw_tty_driver->driver_name = IPWIRELESS_PCCARD_NAME;
        ipw_tty_driver->name = "ttyIPWp";
        ipw_tty_driver->major = 0;
index e5c295ab5decd6fb7b7a093f861f7c0f1023f4a7..b3a28b5f02adcb266c4e5c50d048f1c4f253324c 100644 (file)
@@ -1678,7 +1678,6 @@ static int __init isicom_init(void)
                goto error;
        }
 
-       isicom_normal->owner                    = THIS_MODULE;
        isicom_normal->name                     = "ttyM";
        isicom_normal->major                    = ISICOM_NMAJOR;
        isicom_normal->minor_start              = 0;
index d15a071b1a54c54099a9e17cc67f6f4837e8a68c..4a26323a926f7260f7dfbfc519674d62c43881c9 100644 (file)
@@ -1036,7 +1036,6 @@ static int __init moxa_init(void)
        if (!moxaDriver)
                return -ENOMEM;
 
-       moxaDriver->owner = THIS_MODULE;
        moxaDriver->name = "ttyMX";
        moxaDriver->major = ttymajor;
        moxaDriver->minor_start = 0;
index 8998d527232ade4b33f51c8ba234c16122cbe1b1..260d031235247dd07f6bdd8793dc726d08528638 100644 (file)
@@ -2658,12 +2658,9 @@ static int __init mxser_module_init(void)
                MXSER_VERSION);
 
        /* Initialize the tty_driver structure */
-       mxvar_sdriver->owner = THIS_MODULE;
-       mxvar_sdriver->magic = TTY_DRIVER_MAGIC;
        mxvar_sdriver->name = "ttyMI";
        mxvar_sdriver->major = ttymajor;
        mxvar_sdriver->minor_start = 0;
-       mxvar_sdriver->num = MXSER_PORTS + 1;
        mxvar_sdriver->type = TTY_DRIVER_TYPE_SERIAL;
        mxvar_sdriver->subtype = SERIAL_TYPE_NORMAL;
        mxvar_sdriver->init_termios = tty_std_termios;
index fc7bbba585cee2c2b0d5282c42fb986bfb032a0a..c43b683b6eb811babdb7cbc1a1c6bc75eb7ae413 100644 (file)
@@ -3120,7 +3120,6 @@ static int __init gsm_init(void)
                pr_err("gsm_init: tty allocation failed.\n");
                return -EINVAL;
        }
-       gsm_tty_driver->owner   = THIS_MODULE;
        gsm_tty_driver->driver_name     = "gsmtty";
        gsm_tty_driver->name            = "gsmtty";
        gsm_tty_driver->major           = 0;    /* Dynamic */
index 580da78b2d8692c89ce4d6cfb139eabd2b1c97b7..e7592f9037daca81455e9b94d7c31d62fdc5c934 100644 (file)
@@ -1916,7 +1916,6 @@ static __init int nozomi_init(void)
        if (!ntty_driver)
                return -ENOMEM;
 
-       ntty_driver->owner = THIS_MODULE;
        ntty_driver->driver_name = NOZOMI_NAME_TTY;
        ntty_driver->name = "noz";
        ntty_driver->major = 0;
index d505837b34782fa44aa9db5965aa84682945886c..f96ecaec24f81f9157809f173e8184dcde352c99 100644 (file)
@@ -393,7 +393,6 @@ static void __init legacy_pty_init(void)
        if (!pty_slave_driver)
                panic("Couldn't allocate pty slave driver");
 
-       pty_driver->owner = THIS_MODULE;
        pty_driver->driver_name = "pty_master";
        pty_driver->name = "pty";
        pty_driver->major = PTY_MASTER_MAJOR;
@@ -411,7 +410,6 @@ static void __init legacy_pty_init(void)
        pty_driver->other = pty_slave_driver;
        tty_set_operations(pty_driver, &master_pty_ops_bsd);
 
-       pty_slave_driver->owner = THIS_MODULE;
        pty_slave_driver->driver_name = "pty_slave";
        pty_slave_driver->name = "ttyp";
        pty_slave_driver->major = PTY_SLAVE_MAJOR;
@@ -671,7 +669,6 @@ static void __init unix98_pty_init(void)
        if (!pts_driver)
                panic("Couldn't allocate Unix98 pts driver");
 
-       ptm_driver->owner = THIS_MODULE;
        ptm_driver->driver_name = "pty_master";
        ptm_driver->name = "ptm";
        ptm_driver->major = UNIX98_PTY_MASTER_MAJOR;
@@ -690,7 +687,6 @@ static void __init unix98_pty_init(void)
        ptm_driver->other = pts_driver;
        tty_set_operations(ptm_driver, &ptm_unix98_ops);
 
-       pts_driver->owner = THIS_MODULE;
        pts_driver->driver_name = "pty_slave";
        pts_driver->name = "pts";
        pts_driver->major = UNIX98_PTY_SLAVE_MAJOR;
index de88aa5566e5eeb5176ebc910b2a1d37cb055637..b088e1ea43311fcc8a53121feeeecd55cb0b5af8 100644 (file)
@@ -2277,7 +2277,6 @@ static int __init rp_init(void)
         * driver with the tty layer.
         */
 
-       rocket_driver->owner = THIS_MODULE;
        rocket_driver->flags = TTY_DRIVER_DYNAMIC_DEV;
        rocket_driver->name = "ttyR";
        rocket_driver->driver_name = "Comtrol RocketPort";
index 7e925e20cbaaae5a5b65c9e5a5bb17d33f8381da..144cd3987d4cb5c6c108d0488a41a0e1ba8eca73 100644 (file)
@@ -1375,12 +1375,9 @@ static int __init ifx_spi_init(void)
                return -ENOMEM;
        }
 
-       tty_drv->magic = TTY_DRIVER_MAGIC;
-       tty_drv->owner = THIS_MODULE;
        tty_drv->driver_name = DRVNAME;
        tty_drv->name = TTYNAME;
        tty_drv->minor_start = IFX_SPI_TTY_ID;
-       tty_drv->num = 1;
        tty_drv->type = TTY_DRIVER_TYPE_SERIAL;
        tty_drv->subtype = SERIAL_TYPE_NORMAL;
        tty_drv->flags = TTY_DRIVER_REAL_RAW | TTY_DRIVER_DYNAMIC_DEV;
index 4f41dcdcb7719767a790f7bc98f654a3895ead38..b25e6ee7144374e258b646608a41978f1d2f1a3b 100644 (file)
@@ -203,7 +203,6 @@ static int __init smd_tty_init(void)
        if (smd_tty_driver == 0)
                return -ENOMEM;
 
-       smd_tty_driver->owner = THIS_MODULE;
        smd_tty_driver->driver_name = "smd_tty_driver";
        smd_tty_driver->name = "smd";
        smd_tty_driver->major = 0;
index 13056180adf5eff85b9af7a81d2cb12a93c5dae0..9c4c05b2825b2a8646a6f6e7709b171cceddb3ba 100644 (file)
@@ -2230,7 +2230,6 @@ int uart_register_driver(struct uart_driver *drv)
 
        drv->tty_driver = normal;
 
-       normal->owner           = drv->owner;
        normal->driver_name     = drv->driver_name;
        normal->name            = drv->dev_name;
        normal->major           = drv->major;
index ff8017f87914ce777a7d3ec5a0ab7abf8c9f0785..2b2988c779c74d6c1b76eca2312c712005378e12 100644 (file)
@@ -4333,7 +4333,6 @@ static int mgsl_init_tty(void)
        if (!serial_driver)
                return -ENOMEM;
        
-       serial_driver->owner = THIS_MODULE;
        serial_driver->driver_name = "synclink";
        serial_driver->name = "ttySL";
        serial_driver->major = ttymajor;
index 18b48cd3b41ddbbb7a76f1c8898b907fac1b09ca..a8b66be37e6e52b8aec9f855992f1140c8c1ca4a 100644 (file)
@@ -3795,7 +3795,6 @@ static int __init slgt_init(void)
 
        /* Initialize the tty_driver structure */
 
-       serial_driver->owner = THIS_MODULE;
        serial_driver->driver_name = tty_driver_name;
        serial_driver->name = tty_dev_prefix;
        serial_driver->major = ttymajor;
index a7efe538df000e3c005717cd464ae4ed6a80d538..ddabb61c85ba0173ad8466e189115d5499d9837b 100644 (file)
@@ -3977,7 +3977,6 @@ static int __init synclinkmp_init(void)
 
        /* Initialize the tty_driver structure */
 
-       serial_driver->owner = THIS_MODULE;
        serial_driver->driver_name = "synclinkmp";
        serial_driver->name = "ttySLM";
        serial_driver->major = ttymajor;
index e5abceacc2d05a464f1b232d4a034ac54ffb48c5..84c4a7d5603efdba7095dd3986bcdcbb2da1967f 100644 (file)
@@ -2994,7 +2994,7 @@ int __init vty_init(const struct file_operations *console_fops)
        console_driver = alloc_tty_driver(MAX_NR_CONSOLES);
        if (!console_driver)
                panic("Couldn't allocate console driver\n");
-       console_driver->owner = THIS_MODULE;
+
        console_driver->name = "tty";
        console_driver->name_base = 1;
        console_driver->major = TTY_MAJOR;
index 11a1130319d161c1873eafdc72c317bb42c46200..6bb8472155c6a106a35ae111bc241a8b4ed20ce1 100644 (file)
@@ -1670,7 +1670,6 @@ static int __init acm_init(void)
        acm_tty_driver = alloc_tty_driver(ACM_TTY_MINORS);
        if (!acm_tty_driver)
                return -ENOMEM;
-       acm_tty_driver->owner = THIS_MODULE,
        acm_tty_driver->driver_name = "acm",
        acm_tty_driver->name = "ttyACM",
        acm_tty_driver->major = ACM_TTY_MAJOR,
index 6597a6813e438adbd192cb86f3675ddd368c2d7d..490b01dd5d6093dcee11eb03ce587bb494cc6ded 100644 (file)
@@ -1087,7 +1087,6 @@ int __init gserial_setup(struct usb_gadget *g, unsigned count)
        if (!gs_tty_driver)
                return -ENOMEM;
 
-       gs_tty_driver->owner = THIS_MODULE;
        gs_tty_driver->driver_name = "g_serial";
        gs_tty_driver->name = PREFIX;
        /* uses dynamically assigned dev_t values */
index 1e30cc92719c004824d35b0ed3f4850410c6220e..d4e724d9b1f4057602372ed3bfd52b98195a2ff8 100644 (file)
@@ -1235,7 +1235,6 @@ static int __init usb_serial_init(void)
                goto exit_bus;
        }
 
-       usb_serial_tty_driver->owner = THIS_MODULE;
        usb_serial_tty_driver->driver_name = "usbserial";
        usb_serial_tty_driver->name = "ttyUSB";
        usb_serial_tty_driver->major = SERIAL_TTY_MAJOR;
index a2d4f5122a6a2030913814a8ebdc0cf6a381e29d..7adb03ca51c2b2d51023532b8c6249b4cdb88259 100644 (file)
@@ -1157,7 +1157,6 @@ int __init rfcomm_init_ttys(void)
        if (!rfcomm_tty_driver)
                return -ENOMEM;
 
-       rfcomm_tty_driver->owner        = THIS_MODULE;
        rfcomm_tty_driver->driver_name  = "rfcomm";
        rfcomm_tty_driver->name         = "rfcomm";
        rfcomm_tty_driver->major        = RFCOMM_TTY_MAJOR;
index 253695d43fd9db61d674646f36fdb1cc796e521d..828f88603d6cac0eb37f9cac313106d16fd8047b 100644 (file)
@@ -122,7 +122,6 @@ static int __init ircomm_tty_init(void)
                return -ENOMEM;
        }
 
-       driver->owner           = THIS_MODULE;
        driver->driver_name     = "ircomm";
        driver->name            = "ircomm";
        driver->major           = IRCOMM_TTY_MAJOR;