mtd: convert remaining users to mtd_device_register()
The older add_mtd_device()/add_mtd_partitions() and their removal counterparts will soon be gone. Replace uses with mtd_device_register() and mtd_device_unregister(). Signed-off-by: Jamie Iles <jamie@jamieiles.com> Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com> Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
This commit is contained in:
@@ -376,7 +376,7 @@ void DoCMil_init(struct mtd_info *mtd)
|
||||
this->nextdoc = docmillist;
|
||||
docmillist = mtd;
|
||||
mtd->size = this->totlen;
|
||||
add_mtd_device(mtd);
|
||||
mtd_device_register(mtd, NULL, 0);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@@ -826,7 +826,7 @@ static void __exit cleanup_doc2001(void)
|
||||
this = mtd->priv;
|
||||
docmillist = this->nextdoc;
|
||||
|
||||
del_mtd_device(mtd);
|
||||
mtd_device_unregister(mtd);
|
||||
|
||||
iounmap(this->virtadr);
|
||||
kfree(this->chips);
|
||||
|
Reference in New Issue
Block a user