File tree Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Expand file tree Collapse file tree 1 file changed +6
-9
lines changed Original file line number Diff line number Diff line change @@ -37,21 +37,18 @@ static int bd71815gpo_get(struct gpio_chip *chip, unsigned int offset)
37
37
return (val >> offset ) & 1 ;
38
38
}
39
39
40
- static void bd71815gpo_set (struct gpio_chip * chip , unsigned int offset ,
41
- int value )
40
+ static int bd71815gpo_set (struct gpio_chip * chip , unsigned int offset ,
41
+ int value )
42
42
{
43
43
struct bd71815_gpio * bd71815 = gpiochip_get_data (chip );
44
- int ret , bit ;
44
+ int bit ;
45
45
46
46
bit = BIT (offset );
47
47
48
48
if (value )
49
- ret = regmap_set_bits (bd71815 -> regmap , BD71815_REG_GPO , bit );
50
- else
51
- ret = regmap_clear_bits (bd71815 -> regmap , BD71815_REG_GPO , bit );
49
+ return regmap_set_bits (bd71815 -> regmap , BD71815_REG_GPO , bit );
52
50
53
- if (ret )
54
- dev_warn (bd71815 -> dev , "failed to toggle GPO\n" );
51
+ return regmap_clear_bits (bd71815 -> regmap , BD71815_REG_GPO , bit );
55
52
}
56
53
57
54
static int bd71815_gpio_set_config (struct gpio_chip * chip , unsigned int offset ,
@@ -88,7 +85,7 @@ static const struct gpio_chip bd71815gpo_chip = {
88
85
.owner = THIS_MODULE ,
89
86
.get = bd71815gpo_get ,
90
87
.get_direction = bd71815gpo_direction_get ,
91
- .set = bd71815gpo_set ,
88
+ .set_rv = bd71815gpo_set ,
92
89
.set_config = bd71815_gpio_set_config ,
93
90
.can_sleep = true,
94
91
};
You can’t perform that action at this time.
0 commit comments