diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2013-01-08 21:07:19 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-01-09 00:40:45 (GMT) |
commit | a40b260da6d96ab5231ebdabd06e70568ca81885 (patch) | |
tree | 5f8e6d5a82f5768a69e959197473ff4a10f5e26d /drivers/misc/mei/init.c | |
parent | d91aaed30a938c5daae2641e6758dfab8727862e (diff) | |
download | linux-a40b260da6d96ab5231ebdabd06e70568ca81885.tar.xz |
mei: move me client storage allocation to hbm.c
rename function to mei_me_cl_allocate to match the current
names convention: mei_hbm_me_cl_allocate
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc/mei/init.c')
-rw-r--r-- | drivers/misc/mei/init.c | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/drivers/misc/mei/init.c b/drivers/misc/mei/init.c index 88407df..636639f 100644 --- a/drivers/misc/mei/init.c +++ b/drivers/misc/mei/init.c @@ -278,44 +278,5 @@ void mei_reset(struct mei_device *dev, int interrupts_enabled) } -/** - * allocate_me_clients_storage - allocates storage for me clients - * - * @dev: the device structure - * - * returns none. - */ -void mei_allocate_me_clients_storage(struct mei_device *dev) -{ - struct mei_me_client *clients; - int b; - - /* count how many ME clients we have */ - for_each_set_bit(b, dev->me_clients_map, MEI_CLIENTS_MAX) - dev->me_clients_num++; - - if (dev->me_clients_num <= 0) - return ; - - - if (dev->me_clients != NULL) { - kfree(dev->me_clients); - dev->me_clients = NULL; - } - dev_dbg(&dev->pdev->dev, "memory allocation for ME clients size=%zd.\n", - dev->me_clients_num * sizeof(struct mei_me_client)); - /* allocate storage for ME clients representation */ - clients = kcalloc(dev->me_clients_num, - sizeof(struct mei_me_client), GFP_KERNEL); - if (!clients) { - dev_dbg(&dev->pdev->dev, "memory allocation for ME clients failed.\n"); - dev->dev_state = MEI_DEV_RESETING; - mei_reset(dev, 1); - return ; - } - dev->me_clients = clients; - return ; -} - |