mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-12-03 09:20:14 -05:00
[PATCH] tty_register_driver: Remove incorrect and superfluous cast
tty_register_driver: Remove incorrect and superfluous cast (expected and passed types are both const char *) Signed-off-by: Geert Uytterhoeven <[email protected]> Acked-by: Alan Cox <[email protected]> Signed-off-by: Linus Torvalds <[email protected]>
This commit is contained in:
parent
1ca9492992
commit
e5717c48ed
1 changed files with 2 additions and 3 deletions
|
|
@ -3713,15 +3713,14 @@ int tty_register_driver(struct tty_driver *driver)
|
|||
|
||||
if (!driver->major) {
|
||||
error = alloc_chrdev_region(&dev, driver->minor_start, driver->num,
|
||||
(char*)driver->name);
|
||||
driver->name);
|
||||
if (!error) {
|
||||
driver->major = MAJOR(dev);
|
||||
driver->minor_start = MINOR(dev);
|
||||
}
|
||||
} else {
|
||||
dev = MKDEV(driver->major, driver->minor_start);
|
||||
error = register_chrdev_region(dev, driver->num,
|
||||
(char*)driver->name);
|
||||
error = register_chrdev_region(dev, driver->num, driver->name);
|
||||
}
|
||||
if (error < 0) {
|
||||
kfree(p);
|
||||
|
|
|
|||
Loading…
Reference in a new issue