linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [1/2] usb: typec: fusb302: Correct spelling mistake for toggling state
@ 2018-09-26 15:23 Opensource [Adam Thomson]
  0 siblings, 0 replies; 3+ messages in thread
From: Opensource [Adam Thomson] @ 2018-09-26 15:23 UTC (permalink / raw)
  To: Guenter Roeck, Heikki Krogerus, Greg Kroah-Hartman
  Cc: linux-usb, linux-kernel, support.opensource

There's a typo in the enum name of the 'OFF' state for toggling
(TOGGLINE instead of TOGGLING). This commit resolves that trivial
spelling inconsistency.

Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>
---
 drivers/usb/typec/tcpm/fusb302.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/drivers/usb/typec/tcpm/fusb302.c b/drivers/usb/typec/tcpm/fusb302.c
index 6e9370a..fd851d8 100644
--- a/drivers/usb/typec/tcpm/fusb302.c
+++ b/drivers/usb/typec/tcpm/fusb302.c
@@ -42,7 +42,7 @@
 #define T_BC_LVL_DEBOUNCE_DELAY_MS 30
 
 enum toggling_mode {
-	TOGGLINE_MODE_OFF,
+	TOGGLING_MODE_OFF,
 	TOGGLING_MODE_DRP,
 	TOGGLING_MODE_SNK,
 	TOGGLING_MODE_SRC,
@@ -594,7 +594,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
 	chip->intr_comp_chng = false;
 	/* configure toggling mode: none/snk/src/drp */
 	switch (mode) {
-	case TOGGLINE_MODE_OFF:
+	case TOGGLING_MODE_OFF:
 		ret = fusb302_i2c_mask_write(chip, FUSB_REG_CONTROL2,
 					     FUSB_REG_CONTROL2_MODE_MASK,
 					     FUSB_REG_CONTROL2_MODE_NONE);
@@ -626,7 +626,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
 		break;
 	}
 
-	if (mode == TOGGLINE_MODE_OFF) {
+	if (mode == TOGGLING_MODE_OFF) {
 		/* mask TOGDONE interrupt */
 		ret = fusb302_i2c_set_bits(chip, FUSB_REG_MASKA,
 					   FUSB_REG_MASKA_TOGDONE);
@@ -702,7 +702,7 @@ static int tcpm_set_cc(struct tcpc_dev *dev, enum typec_cc_status cc)
 		ret = -EINVAL;
 		goto done;
 	}
-	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
+	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
 	if (ret < 0) {
 		fusb302_log(chip, "cannot stop toggling, ret=%d", ret);
 		goto done;
@@ -1292,7 +1292,7 @@ static int fusb302_handle_togdone_snk(struct fusb302_chip *chip,
 		tcpm_cc_change(chip->tcpm_port);
 	}
 	/* turn off toggling */
-	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
+	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
 	if (ret < 0) {
 		fusb302_log(chip,
 			    "cannot set toggling mode off, ret=%d", ret);
@@ -1388,7 +1388,7 @@ static int fusb302_handle_togdone_src(struct fusb302_chip *chip,
 		tcpm_cc_change(chip->tcpm_port);
 	}
 	/* turn off toggling */
-	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
+	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
 	if (ret < 0) {
 		fusb302_log(chip,
 			    "cannot set toggling mode off, ret=%d", ret);

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [1/2] usb: typec: fusb302: Correct spelling mistake for toggling state
@ 2018-09-26 16:27 Guenter Roeck
  0 siblings, 0 replies; 3+ messages in thread
From: Guenter Roeck @ 2018-09-26 16:27 UTC (permalink / raw)
  To: Adam Thomson
  Cc: Heikki Krogerus, Greg Kroah-Hartman, linux-usb, linux-kernel,
	support.opensource

On Wed, Sep 26, 2018 at 04:23:51PM +0100, Adam Thomson wrote:
> There's a typo in the enum name of the 'OFF' state for toggling
> (TOGGLINE instead of TOGGLING). This commit resolves that trivial
> spelling inconsistency.
> 
> Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>

Reviewed-by: Guenter Roeck <linux@roeck-us.net>

> ---
>  drivers/usb/typec/tcpm/fusb302.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/usb/typec/tcpm/fusb302.c b/drivers/usb/typec/tcpm/fusb302.c
> index 6e9370a..fd851d8 100644
> --- a/drivers/usb/typec/tcpm/fusb302.c
> +++ b/drivers/usb/typec/tcpm/fusb302.c
> @@ -42,7 +42,7 @@
>  #define T_BC_LVL_DEBOUNCE_DELAY_MS 30
>  
>  enum toggling_mode {
> -	TOGGLINE_MODE_OFF,
> +	TOGGLING_MODE_OFF,
>  	TOGGLING_MODE_DRP,
>  	TOGGLING_MODE_SNK,
>  	TOGGLING_MODE_SRC,
> @@ -594,7 +594,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
>  	chip->intr_comp_chng = false;
>  	/* configure toggling mode: none/snk/src/drp */
>  	switch (mode) {
> -	case TOGGLINE_MODE_OFF:
> +	case TOGGLING_MODE_OFF:
>  		ret = fusb302_i2c_mask_write(chip, FUSB_REG_CONTROL2,
>  					     FUSB_REG_CONTROL2_MODE_MASK,
>  					     FUSB_REG_CONTROL2_MODE_NONE);
> @@ -626,7 +626,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
>  		break;
>  	}
>  
> -	if (mode == TOGGLINE_MODE_OFF) {
> +	if (mode == TOGGLING_MODE_OFF) {
>  		/* mask TOGDONE interrupt */
>  		ret = fusb302_i2c_set_bits(chip, FUSB_REG_MASKA,
>  					   FUSB_REG_MASKA_TOGDONE);
> @@ -702,7 +702,7 @@ static int tcpm_set_cc(struct tcpc_dev *dev, enum typec_cc_status cc)
>  		ret = -EINVAL;
>  		goto done;
>  	}
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip, "cannot stop toggling, ret=%d", ret);
>  		goto done;
> @@ -1292,7 +1292,7 @@ static int fusb302_handle_togdone_snk(struct fusb302_chip *chip,
>  		tcpm_cc_change(chip->tcpm_port);
>  	}
>  	/* turn off toggling */
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip,
>  			    "cannot set toggling mode off, ret=%d", ret);
> @@ -1388,7 +1388,7 @@ static int fusb302_handle_togdone_src(struct fusb302_chip *chip,
>  		tcpm_cc_change(chip->tcpm_port);
>  	}
>  	/* turn off toggling */
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip,
>  			    "cannot set toggling mode off, ret=%d", ret);
> -- 
> 1.9.1
>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [1/2] usb: typec: fusb302: Correct spelling mistake for toggling state
@ 2018-09-27 10:54 Heikki Krogerus
  0 siblings, 0 replies; 3+ messages in thread
From: Heikki Krogerus @ 2018-09-27 10:54 UTC (permalink / raw)
  To: Adam Thomson
  Cc: Guenter Roeck, Greg Kroah-Hartman, linux-usb, linux-kernel,
	support.opensource

On Wed, Sep 26, 2018 at 04:23:51PM +0100, Adam Thomson wrote:
> There's a typo in the enum name of the 'OFF' state for toggling
> (TOGGLINE instead of TOGGLING). This commit resolves that trivial
> spelling inconsistency.
> 
> Signed-off-by: Adam Thomson <Adam.Thomson.Opensource@diasemi.com>

Reviewed-by:  Heikki Krogerus <heikki.krogerus@linux.intel.com>

> ---
>  drivers/usb/typec/tcpm/fusb302.c | 12 ++++++------
>  1 file changed, 6 insertions(+), 6 deletions(-)
> 
> diff --git a/drivers/usb/typec/tcpm/fusb302.c b/drivers/usb/typec/tcpm/fusb302.c
> index 6e9370a..fd851d8 100644
> --- a/drivers/usb/typec/tcpm/fusb302.c
> +++ b/drivers/usb/typec/tcpm/fusb302.c
> @@ -42,7 +42,7 @@
>  #define T_BC_LVL_DEBOUNCE_DELAY_MS 30
>  
>  enum toggling_mode {
> -	TOGGLINE_MODE_OFF,
> +	TOGGLING_MODE_OFF,
>  	TOGGLING_MODE_DRP,
>  	TOGGLING_MODE_SNK,
>  	TOGGLING_MODE_SRC,
> @@ -594,7 +594,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
>  	chip->intr_comp_chng = false;
>  	/* configure toggling mode: none/snk/src/drp */
>  	switch (mode) {
> -	case TOGGLINE_MODE_OFF:
> +	case TOGGLING_MODE_OFF:
>  		ret = fusb302_i2c_mask_write(chip, FUSB_REG_CONTROL2,
>  					     FUSB_REG_CONTROL2_MODE_MASK,
>  					     FUSB_REG_CONTROL2_MODE_NONE);
> @@ -626,7 +626,7 @@ static int fusb302_set_toggling(struct fusb302_chip *chip,
>  		break;
>  	}
>  
> -	if (mode == TOGGLINE_MODE_OFF) {
> +	if (mode == TOGGLING_MODE_OFF) {
>  		/* mask TOGDONE interrupt */
>  		ret = fusb302_i2c_set_bits(chip, FUSB_REG_MASKA,
>  					   FUSB_REG_MASKA_TOGDONE);
> @@ -702,7 +702,7 @@ static int tcpm_set_cc(struct tcpc_dev *dev, enum typec_cc_status cc)
>  		ret = -EINVAL;
>  		goto done;
>  	}
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip, "cannot stop toggling, ret=%d", ret);
>  		goto done;
> @@ -1292,7 +1292,7 @@ static int fusb302_handle_togdone_snk(struct fusb302_chip *chip,
>  		tcpm_cc_change(chip->tcpm_port);
>  	}
>  	/* turn off toggling */
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip,
>  			    "cannot set toggling mode off, ret=%d", ret);
> @@ -1388,7 +1388,7 @@ static int fusb302_handle_togdone_src(struct fusb302_chip *chip,
>  		tcpm_cc_change(chip->tcpm_port);
>  	}
>  	/* turn off toggling */
> -	ret = fusb302_set_toggling(chip, TOGGLINE_MODE_OFF);
> +	ret = fusb302_set_toggling(chip, TOGGLING_MODE_OFF);
>  	if (ret < 0) {
>  		fusb302_log(chip,
>  			    "cannot set toggling mode off, ret=%d", ret);
> -- 
> 1.9.1

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-09-27 10:54 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-09-27 10:54 [1/2] usb: typec: fusb302: Correct spelling mistake for toggling state Heikki Krogerus
  -- strict thread matches above, loose matches on Subject: below --
2018-09-26 16:27 Guenter Roeck
2018-09-26 15:23 Opensource [Adam Thomson]

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).