Lines Matching defs:cdevs
3153 /* init here, since reused cdevs cause crashes */
3154 driver->cdevs[index] = cdev_alloc();
3155 if (!driver->cdevs[index])
3157 driver->cdevs[index]->ops = &tty_fops;
3158 driver->cdevs[index]->owner = driver->owner;
3159 err = cdev_add(driver->cdevs[index], dev, count);
3161 kobject_put(&driver->cdevs[index]->kobj);
3162 driver->cdevs[index] = NULL;
3302 if (!(driver->flags & TTY_DRIVER_DYNAMIC_ALLOC) && driver->cdevs[index]) {
3303 cdev_del(driver->cdevs[index]);
3304 driver->cdevs[index] = NULL;
3324 unsigned int cdevs = 1;
3354 cdevs = lines;
3357 driver->cdevs = kzalloc_objs(*driver->cdevs, cdevs);
3358 if (!driver->cdevs) {
3368 kfree(driver->cdevs);
3392 cdev_del(driver->cdevs[0]);
3394 kfree(driver->cdevs);