Fixed several recently introduced sparse warnings.

git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@1672 d57e44dd-8a1f-0410-8b47-8ef2f437770f
This commit is contained in:
Bart Van Assche
2010-04-30 11:03:38 +00:00
parent c99bd720c8
commit 9f2a7853cd
2 changed files with 9 additions and 9 deletions
+1 -1
View File
@@ -1427,7 +1427,7 @@ static int cmnd_prepare_recv_pdu(struct iscsi_conn *conn,
}
conn->read_iov[i].iov_len = sg_len;
TRACE_DBG("idx=%d, offset=%u, size=%d, sg_len=%zd, addr=%p",
TRACE_DBG("idx=%d, offset=%u, size=%d, sg_len=%u, addr=%p",
idx, offset, size, sg_len, addr);
size -= sg_len;
+8 -8
View File
@@ -802,7 +802,7 @@ void scst_tgt_sysfs_put(struct scst_tgt *tgt)
* Devices directory implementation
*/
ssize_t scst_device_sysfs_type_show(struct kobject *kobj,
static ssize_t scst_device_sysfs_type_show(struct kobject *kobj,
struct kobj_attribute *attr, char *buf)
{
int pos = 0;
@@ -897,9 +897,9 @@ static ssize_t scst_device_sysfs_threads_num_store(struct kobject *kobj,
dev = container_of(kobj, struct scst_device, dev_kobj);
res = strict_strtoul(buf, 0, &newtn);
res = strict_strtol(buf, 0, &newtn);
if (res != 0) {
PRINT_ERROR("strict_strtoul() for %s failed: %d ", buf, res);
PRINT_ERROR("strict_strtol() for %s failed: %d ", buf, res);
goto out;
}
@@ -1544,8 +1544,8 @@ static struct kobj_type acg_dev_ktype = {
.default_attrs = lun_attrs,
};
int scst_create_acg_dev_sysfs(struct scst_acg *acg, unsigned int virt_lun,
struct kobject *parent)
static int scst_create_acg_dev_sysfs(struct scst_acg *acg,
unsigned int virt_lun, struct kobject *parent)
{
int retval;
struct scst_acg_dev *acg_dev = NULL, *acg_dev_tmp;
@@ -2022,7 +2022,7 @@ static ssize_t __scst_acg_io_grouping_type_store(struct scst_acg *acg,
acg->acg_io_grouping_type = SCST_IO_GROUPING_NEVER;
else {
long io_grouping_type;
res = strict_strtoul(buf, 0, &io_grouping_type);
res = strict_strtol(buf, 0, &io_grouping_type);
if ((res != 0) || (io_grouping_type <= 0)) {
PRINT_ERROR("Unknown or not allowed I/O grouping type "
"%s", buf);
@@ -2914,9 +2914,9 @@ static ssize_t scst_threads_store(struct kobject *kobj,
oldtn = scst_main_cmd_threads.nr_threads;
res = strict_strtoul(buf, 0, &newtn);
res = strict_strtol(buf, 0, &newtn);
if (res != 0) {
PRINT_ERROR("strict_strtoul() for %s failed: %d ", buf, res);
PRINT_ERROR("strict_strtol() for %s failed: %d ", buf, res);
goto out_up;
}