#include <errno.h>
#include <vconf.h>
#include <tzplatform_config.h>
+#include <libsyscommon/list.h>
#include "common.h"
-#include "list.h"
#include "log.h"
#include "storage-external.h"
[STORAGE_DIRECTORY_OTHERS] = TZ_USER_OTHERS,
};
-static dd_list *st_int_head; /* Internal storage list */
+static GList *st_int_head; /* Internal storage list */
-static dd_list *compat_cb_list;
+static GList *compat_cb_list;
struct compat_cb_info {
storage_state_changed_cb user_cb;
void *user_data;
void add_device(const struct storage_ops *st)
{
- DD_LIST_APPEND(st_int_head, st);
+ SYS_G_LIST_APPEND(st_int_head, st);
}
void remove_device(const struct storage_ops *st)
{
- DD_LIST_REMOVE(st_int_head, st);
+ SYS_G_LIST_REMOVE(st_int_head, st);
}
API int storage_foreach_device_supported(storage_device_supported_cb callback, void *user_data)
{
const struct storage_ops *st;
- dd_list *elem;
- int ret;
+ GList *elem;
+ int ret_val;
bool user = true;
if (!callback) {
if (getuid() <= USER_UID_START)
user = false;
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (user) {
- ret = callback(st->storage_id, st->type, st->get_state(),
+ ret_val = callback(st->storage_id, st->type, st->get_state(),
st->root(), user_data);
/* if the return value is false, will be stop to iterate */
- if (!ret)
+ if (!ret_val)
break;
}
}
if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
_D("Block module is not enabled");
return STORAGE_ERROR_NONE;
+ //LCOV_EXCL_STOP
}
- ret = storage_ext_foreach_device_list(callback, user_data);
- if (ret < 0) {
- _E("Failed to iterate external devices (%d)", ret); //LCOV_EXCL_LINE
- return STORAGE_ERROR_OPERATION_FAILED;
+ ret_val = storage_ext_foreach_device_list(callback, user_data);
+ if (ret_val < 0) {
+ _E("Failed to iterate external devices (%d)", ret_val); //LCOV_EXCL_LINE
+ return STORAGE_ERROR_OPERATION_FAILED; //LCOV_EXCL_LINE
}
return STORAGE_ERROR_NONE;
API int storage_get_root_directory(int storage_id, char **path)
{
const struct storage_ops *st;
- dd_list *elem;
+ GList *elem;
char root[PATH_MAX];
- int ret;
+ int ret_val;
bool extendedint;
bool user = true;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!path) {
_E("Invalid parameger");
user = false;
/* internal storage */
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)
continue;
if (!user) {
}
/* external storage */
- ret = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
- if (ret < 0) {
- _E("Failed to get root path of external storage(%d, %d", storage_id, ret); //LCOV_EXCL_LINE
- return STORAGE_ERROR_INVALID_PARAMETER;
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ ret_val = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
+ if (ret_val < 0) {
+ _E("Failed to get root path of external storage(%d, %d", storage_id, ret_val);
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
*path = strdup(root);
if (!*path) {
- _E("Failed to copy the root string : %d", errno); //LCOV_EXCL_LINE System Error
+ //LCOV_EXCL_START System error
+ _E("Failed to copy the root string : %d", errno);
return STORAGE_ERROR_OUT_OF_MEMORY;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
char root[PATH_MAX];
char temp[PATH_MAX];
char *temp2, *end;
- int ret;
- dd_list *elem;
+ int ret_val;
+ GList *elem;
bool found;
bool extendedint;
bool user = true;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!path) {
_E("Invalid parameger");
/* internal storage */
found = false;
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)
continue;
found = true;
*end = '\0';
snprintf(temp, PATH_MAX, "%s", temp2);
free(temp2);
- } else
- snprintf(temp, PATH_MAX, "%s/%s", root, dir_path[type]);
+ } else {
+ if ((ret_val = snprintf(temp, PATH_MAX, "%s/%s", root, dir_path[type])) > PATH_MAX - 1) {
+ //LCOV_EXCL_START
+ _E("Path is longer than buffer. Need %d size of buffer.", ret_val + 1);
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ //LCOV_EXCL_STOP
+ }
+ }
goto out;
}
/* external storage */
- if (type == STORAGE_DIRECTORY_SYSTEM_RINGTONES) {
- _E("Not support directory : id(%d) type(%d)", storage_id, type); //LCOV_EXCL_LINE
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
}
- ret = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
- if (ret < 0) {
- _E("Failed to get root dir for external storage(id:%d, ret:%d)", storage_id, ret); //LCOV_EXCL_LINE
- return STORAGE_ERROR_NOT_SUPPORTED;
+ if (type == STORAGE_DIRECTORY_SYSTEM_RINGTONES) {
+ _E("Not support directory : id(%d) type(%d)", storage_id, type);
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ }
+
+ ret_val = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
+ if (ret_val < 0) {
+ _E("Failed to get root dir for external storage(id:%d, ret:%d)", storage_id, ret_val);
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
/* The operation is not decided */
if (extendedint)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
- snprintf(temp, sizeof(temp), "%s/%s", root, dir_path[type]);
+ if ((ret_val = snprintf(temp, sizeof(temp), "%s/%s", root, dir_path[type])) > sizeof(temp) - 1) {
+ //LCOV_EXCL_START
+ _E("Path is longer than buffer. Need %d size of buffer.", ret_val + 1);
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ //LCOV_EXCL_STOP
+ }
out:
*path = strdup(temp);
if (!*path) {
- _E("Failed to copy the directory(%d) string : %d", type, errno); //LCOV_EXCL_LINE
+ //LCOV_EXCL_START System error
+ _E("Failed to copy the directory(%d) string : %d", type, errno);
return STORAGE_ERROR_OUT_OF_MEMORY;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
API int storage_get_type(int storage_id, storage_type_e *type)
{
const struct storage_ops *st;
- dd_list *elem;
+ GList *elem;
char root[PATH_MAX];
- int ret;
+ int ret_val;
bool extendedint;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!type) {
_E("Invalid parameger");
}
/* internal storage */
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)
continue;
*type = st->type;
}
/* external storage */
- ret = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
- if (ret < 0) {
- _E("Failed to get type of external storage");
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ ret_val = storage_ext_get_root(storage_id, root, sizeof(root), &extendedint);
+ if (ret_val < 0) {
+ _E("Failed to get type of external storage");
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
if (extendedint)
*type = STORAGE_TYPE_EXTENDED_INTERNAL;
{
const struct storage_ops *ops;
storage_state_e st;
- dd_list *elem;
- int ret;
+ GList *elem;
+ int ret_val;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!state) {
_E("Invalid parameger");
}
/* internal storage */
- DD_LIST_FOREACH(st_int_head, elem, ops) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, ops) {
if (ops->storage_id != storage_id)
continue;
*state = ops->get_state();
}
/* external storage */
- ret = storage_ext_get_state(storage_id, &st);
- if (ret < 0) {
- _E("Failed to get state (storage id(%d), ret(%d))", storage_id, ret); //LCOV_EXCL_LINE
- return STORAGE_ERROR_OPERATION_FAILED;
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ ret_val = storage_ext_get_state(storage_id, &st);
+ if (ret_val < 0) {
+ _E("Failed to get state (storage id(%d), ret_val(%d))", storage_id, ret_val);
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
*state = st;
bool primary, int flags, void *user_data)
{
struct compat_cb_info* ccb_info;
- dd_list *elem;
+ GList *elem;
if (storage_id == STORAGE_TYPE_EXTERNAL && dev == STORAGE_DEV_EXT_SDCARD)
- DD_LIST_FOREACH(compat_cb_list, elem, ccb_info)
+ SYS_G_LIST_FOREACH(compat_cb_list, elem, ccb_info)
ccb_info->user_cb(storage_id, state, ccb_info->user_data);
}
//LCOV_EXCL_STOP
const struct storage_ops *st;
struct storage_cb_info info;
int ret;
- dd_list *elem;
+ GList *elem;
struct compat_cb_info* ccb_info;
static int compat_cb_init = 0;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!callback) {
_E("Invalid parameger");
/* For backward compatability */
if (storage_id == STORAGE_TYPE_EXTERNAL) {
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
if (!compat_cb_init) {
ret = storage_set_changed_cb(STORAGE_TYPE_EXTERNAL, compat_cb, NULL);
if (ret == STORAGE_ERROR_NONE)
return STORAGE_ERROR_OPERATION_FAILED;
ccb_info->user_cb = callback;
ccb_info->user_data = user_data;
- DD_LIST_APPEND(compat_cb_list, ccb_info);
+ SYS_G_LIST_APPEND(compat_cb_list, ccb_info);
return STORAGE_ERROR_NONE;
}
/* Internal storage does not support registering changed callback */
- DD_LIST_FOREACH(st_int_head, elem, st)
+ SYS_G_LIST_FOREACH(st_int_head, elem, st)
if (st->storage_id == storage_id)
return STORAGE_ERROR_NONE;
/* external storage */
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
info.id = storage_id;
info.state_cb = callback;
info.user_data = user_data;
ret = storage_ext_register_cb(STORAGE_CALLBACK_ID, &info);
if (ret < 0) {
- _E("Failed to register callback : id(%d)", storage_id); //LCOV_EXCL_LINE
+ //LCOV_EXCL_START
+ _E("Failed to register callback : id(%d)", storage_id);
return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
{
const struct storage_ops *st;
struct storage_cb_info info;
- int ret;
- dd_list *elem;
+ int ret_val;
+ GList *elem;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!callback) {
_E("Invalid parameger");
/* For backward compatability */
if (storage_id == STORAGE_TYPE_EXTERNAL) {
- dd_list *elem_n;
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ GList *elem_n;
struct compat_cb_info* ccb_info;
- DD_LIST_FOREACH_SAFE(compat_cb_list, elem, elem_n, ccb_info) {
+ SYS_G_LIST_FOREACH_SAFE(compat_cb_list, elem, elem_n, ccb_info) {
if (ccb_info->user_cb == callback) {
- DD_LIST_REMOVE(compat_cb_list, ccb_info);
+ SYS_G_LIST_REMOVE(compat_cb_list, ccb_info);
free(ccb_info);
return STORAGE_ERROR_NONE;
}
}
/* Internal storage does not support registering changed callback */
- DD_LIST_FOREACH(st_int_head, elem, st)
+ SYS_G_LIST_FOREACH(st_int_head, elem, st)
if (st->storage_id == storage_id)
return STORAGE_ERROR_NONE;
/* external storage */
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
info.id = storage_id;
info.state_cb = callback;
- ret = storage_ext_unregister_cb(STORAGE_CALLBACK_ID, &info);
- if (ret < 0) {
- _E("Failed to unregister callback : id(%d)", storage_id); //LCOV_EXCL_LINE
+ ret_val = storage_ext_unregister_cb(STORAGE_CALLBACK_ID, &info);
+ if (ret_val < 0) {
+ //LCOV_EXCL_START
+ _E("Failed to unregister callback : id(%d)", storage_id);
return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
{
const struct storage_ops *st;
unsigned long long total;
- int ret;
- dd_list *elem;
+ int ret_val;
+ GList *elem;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!bytes) {
_E("Invalid parameger");
}
/* internal storage */
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)
continue;
- ret = st->get_space(&total, NULL);
+ ret_val = st->get_space(&total, NULL);
goto out;
}
/* external storage */
- ret = storage_ext_get_space(storage_id, &total, NULL);
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ ret_val = storage_ext_get_space(storage_id, &total, NULL);
out:
- if (ret < 0) {
- _E("Failed to get total memory : id(%d)", storage_id); //LCOV_EXCL_LINE
- if (ret == -ENOTSUP)
- return STORAGE_ERROR_NOT_SUPPORTED;
- return STORAGE_ERROR_OPERATION_FAILED;
+ if (ret_val < 0) {
+ _E("Failed to get total memory : id(%d)", storage_id);
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
*bytes = total;
{
const struct storage_ops *st;
unsigned long long avail;
- int ret;
- dd_list *elem;
+ int ret_val;
+ GList *elem;
if (storage_id < 0)
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
if (!bytes) {
_E("Invalid parameger");
}
/* internal storage */
- DD_LIST_FOREACH(st_int_head, elem, st) {
+ SYS_G_LIST_FOREACH(st_int_head, elem, st) {
if (st->storage_id != storage_id)
continue;
- ret = st->get_space(NULL, &avail);
+ ret_val = st->get_space(NULL, &avail);
goto out;
}
/* external storage */
- ret = storage_ext_get_space(storage_id, NULL, &avail);
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
+ ret_val = storage_ext_get_space(storage_id, NULL, &avail);
out:
- if (ret < 0) {
- _E("Failed to get available memory : id(%d)", storage_id); //LCOV_EXCL_LINE
- if (ret == -ENOTSUP)
- return STORAGE_ERROR_NOT_SUPPORTED;
- return STORAGE_ERROR_OPERATION_FAILED;
+ if (ret_val < 0) {
+ _E("Failed to get available memory : id(%d)", storage_id);
+ if (ret_val == -ENODEV || ret_val == -EINVAL)
+ return STORAGE_ERROR_INVALID_PARAMETER;
+ //LCOV_EXCL_START
+ else if (ret_val == -ENOMEM)
+ return STORAGE_ERROR_OUT_OF_MEMORY;
+ else
+ return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
*bytes = avail;
API int storage_set_changed_cb(storage_type_e type, storage_changed_cb callback, void *user_data)
{
- int ret;
+ int ret_val;
struct storage_cb_info info;
if (type == STORAGE_TYPE_INTERNAL) {
_E("Internal storage is not supported");
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
}
if (type != STORAGE_TYPE_EXTERNAL && type != STORAGE_TYPE_EXTENDED_INTERNAL) {
}
if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
_E("Block module is not enabled");
return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
}
/* external storage */
info.type_cb = callback;
info.user_data = user_data;
- ret = storage_ext_register_cb(STORAGE_CALLBACK_TYPE, &info);
- if (ret < 0) {
- _E("Failed to register storage callback(ret:%d)", ret); //LCOV_EXCL_LINE
+ ret_val = storage_ext_register_cb(STORAGE_CALLBACK_TYPE, &info);
+ if (ret_val < 0) {
+ //LCOV_EXCL_START
+ _E("Failed to register storage callback(ret:%d)", ret_val);
return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
API int storage_unset_changed_cb(storage_type_e type, storage_changed_cb callback)
{
struct storage_cb_info info;
- int ret;
+ int ret_val;
if (type == STORAGE_TYPE_INTERNAL) {
_E("Internal storage is not supported");
- return STORAGE_ERROR_NOT_SUPPORTED;
+ return STORAGE_ERROR_INVALID_PARAMETER;
}
if (type != STORAGE_TYPE_EXTERNAL && type != STORAGE_TYPE_EXTENDED_INTERNAL) {
}
if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
_E("Block module is not enabled");
return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
}
/* external storage */
info.type = type;
info.type_cb = callback;
- ret = storage_ext_unregister_cb(STORAGE_CALLBACK_TYPE, &info);
- if (ret < 0) {
- _E("Failed to unregister storage callback(ret:%d)", ret); //LCOV_EXCL_LINE
+ ret_val = storage_ext_unregister_cb(STORAGE_CALLBACK_TYPE, &info);
+ if (ret_val < 0) {
+ //LCOV_EXCL_START
+ _E("Failed to unregister storage callback(ret:%d)", ret_val);
return STORAGE_ERROR_OPERATION_FAILED;
+ //LCOV_EXCL_STOP
}
return STORAGE_ERROR_NONE;
ret = storage_get_type(storage_id, type);
if (ret != STORAGE_ERROR_NONE) {
+ //LCOV_EXCL_START
_E("Failed to get storage type: %d", ret);
return ret;
+ //LCOV_EXCL_STOP
}
if (*type == STORAGE_TYPE_INTERNAL || *type == STORAGE_TYPE_EXTENDED_INTERNAL)
return STORAGE_ERROR_INVALID_PARAMETER;
+ if (!storage_ext_is_supported()) {
+ //LCOV_EXCL_START
+ _D("Block module is not enabled");
+ return STORAGE_ERROR_NOT_SUPPORTED;
+ //LCOV_EXCL_STOP
+ }
+
ext_dev = calloc(1, sizeof(storage_ext_device));
if (!ext_dev) {
//LCOV_EXCL_START System Error
ret = storage_ext_get_device_info(storage_id, ext_dev);
if (ret < 0) {
_E("Cannot get the storage with id (%d, ret:%d)", storage_id, ret); //LCOV_EXCL_LINE
+ if (ret == -ENODEV) {
+ ret = STORAGE_ERROR_INVALID_PARAMETER;
+ goto out;
+ }
+ //LCOV_EXCL_START
ret = STORAGE_ERROR_OPERATION_FAILED;
goto out;
+ //LCOV_EXCL_STOP
}
if (ext_dev->type == STORAGE_EXT_SCSI)