treewide: remove redundant IS_ERR() before error code check
[linux/fpc-iii.git] / drivers / staging / uwb / umc-drv.c
blobed3bd220e8c2ffbc5174d15aff7be657e4b3f882
1 // SPDX-License-Identifier: GPL-2.0-only
2 /*
3 * UWB Multi-interface Controller driver management.
5 * Copyright (C) 2007 Cambridge Silicon Radio Ltd.
6 */
7 #include <linux/kernel.h>
8 #include <linux/export.h>
9 #include "include/umc.h"
11 int __umc_driver_register(struct umc_driver *umc_drv, struct module *module,
12 const char *mod_name)
14 umc_drv->driver.name = umc_drv->name;
15 umc_drv->driver.owner = module;
16 umc_drv->driver.mod_name = mod_name;
17 umc_drv->driver.bus = &umc_bus_type;
19 return driver_register(&umc_drv->driver);
21 EXPORT_SYMBOL_GPL(__umc_driver_register);
23 /**
24 * umc_driver_register - unregister a UMC capabiltity driver.
25 * @umc_drv: pointer to the driver.
27 void umc_driver_unregister(struct umc_driver *umc_drv)
29 driver_unregister(&umc_drv->driver);
31 EXPORT_SYMBOL_GPL(umc_driver_unregister);