Loading drivers/leds/aw8697.c +13 −1 Original line number Diff line number Diff line Loading @@ -3143,6 +3143,9 @@ static ssize_t aw8697_activate_mode_store(struct device *dev, unsigned int val = 0; int rc = 0; if (!aw8697->ram_init) return count; rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; Loading Loading @@ -3225,6 +3228,8 @@ static ssize_t aw8697_vmax_store(struct device *dev, rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; if (!aw8697->ram_init) return count; pr_info("%s: value=%d\n", __FUNCTION__, val); mutex_lock(&aw8697->lock); Loading Loading @@ -3264,7 +3269,8 @@ static ssize_t aw8697_gain_store(struct device *dev, rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; if (!aw8697->ram_init) return count; pr_info("%s: value=%d\n", __FUNCTION__, val); mutex_lock(&aw8697->lock); aw8697->gain = val; Loading Loading @@ -3308,6 +3314,9 @@ static ssize_t aw8697_seq_store(struct device *dev, #endif unsigned int databuf[2] = {0, 0}; if (!aw8697->ram_init) return count; if(2 == sscanf(buf, "%x %x", &databuf[0], &databuf[1])) { pr_info("%s: seq%d=0x%x\n", __FUNCTION__, databuf[0], databuf[1]); mutex_lock(&aw8697->lock); Loading Loading @@ -3444,6 +3453,9 @@ static ssize_t aw8697_rtp_store(struct device *dev, struct device_attribute *att int rc = 0; int rtp_is_going_on = 0; if (!aw8697->ram_init) return count; rc = kstrtouint(buf, 0, &val); if (rc < 0) { pr_info("%s: kstrtouint fail\n", __FUNCTION__); Loading Loading
drivers/leds/aw8697.c +13 −1 Original line number Diff line number Diff line Loading @@ -3143,6 +3143,9 @@ static ssize_t aw8697_activate_mode_store(struct device *dev, unsigned int val = 0; int rc = 0; if (!aw8697->ram_init) return count; rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; Loading Loading @@ -3225,6 +3228,8 @@ static ssize_t aw8697_vmax_store(struct device *dev, rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; if (!aw8697->ram_init) return count; pr_info("%s: value=%d\n", __FUNCTION__, val); mutex_lock(&aw8697->lock); Loading Loading @@ -3264,7 +3269,8 @@ static ssize_t aw8697_gain_store(struct device *dev, rc = kstrtouint(buf, 0, &val); if (rc < 0) return rc; if (!aw8697->ram_init) return count; pr_info("%s: value=%d\n", __FUNCTION__, val); mutex_lock(&aw8697->lock); aw8697->gain = val; Loading Loading @@ -3308,6 +3314,9 @@ static ssize_t aw8697_seq_store(struct device *dev, #endif unsigned int databuf[2] = {0, 0}; if (!aw8697->ram_init) return count; if(2 == sscanf(buf, "%x %x", &databuf[0], &databuf[1])) { pr_info("%s: seq%d=0x%x\n", __FUNCTION__, databuf[0], databuf[1]); mutex_lock(&aw8697->lock); Loading Loading @@ -3444,6 +3453,9 @@ static ssize_t aw8697_rtp_store(struct device *dev, struct device_attribute *att int rc = 0; int rtp_is_going_on = 0; if (!aw8697->ram_init) return count; rc = kstrtouint(buf, 0, &val); if (rc < 0) { pr_info("%s: kstrtouint fail\n", __FUNCTION__); Loading