Skip to contentSkip to conversation

replace strict_strto calls

PATCH In review Daniel Walter 1 participant 1 message Jun 21, 2014

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 7/9 replace strict_strto calls

Replace obsolete strict_strto with more appropriate kstrto calls

---
 drivers/scsi/pmcraid.c    | 4 ++--
 drivers/scsi/scsi_sysfs.c | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
drivers/scsi/pmcraid.c +2 -2
index be8ce54..3762488 100644
@@ -4213,9 +4213,9 @@ static ssize_t pmcraid_store_log_level(
 {
 	struct Scsi_Host *shost;
 	struct pmcraid_instance *pinstance;
-	unsigned long val;
+	u8 val;
 
-	if (strict_strtoul(buf, 10, &val))
+	if (kstrtou8(buf, 10, &val))
 		return -EINVAL;
 	/* log-level should be from 0 to 2 */
 	if (val > 2)
drivers/scsi/scsi_sysfs.c +2 -2
index 074e8cc..80f715d 100644
@@ -885,9 +885,9 @@ sdev_store_queue_ramp_up_period(struct device *dev,
 				const char *buf, size_t count)
 {
 	struct scsi_device *sdev = to_scsi_device(dev);
-	unsigned long period;
+	unsigned int period;
 
-	if (strict_strtoul(buf, 10, &period))
+	if (kstrtouint(buf, 10, &period))
 		return -EINVAL;
 
 	sdev->queue_ramp_up_period = msecs_to_jiffies(period);
Signature · 1 line
2.0.0.526.g5318336