All of lore.kernel.org
 help / color / mirror / Atom feed
From: Guenter Roeck <linux@roeck-us.net>
To: Hans de Goede <hdegoede@redhat.com>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Heikki Krogerus <heikki.krogerus@linux.intel.com>
Cc: linux-usb@vger.kernel.org
Subject: USB: typec: fsusb302: Drop empty set_current_limit implementation
Date: Sun, 1 Jul 2018 06:58:41 -0700	[thread overview]
Message-ID: <66c50d3b-c7c8-00c9-3bd6-068b8f0ed930@roeck-us.net> (raw)

On 07/01/2018 05:27 AM, Hans de Goede wrote:
> The set_current_limit tcpm_dev callback is optional and the tcpm core
> will already log the passed in values, so there is no need to have an
> empty implementation of this.
> 
> Signed-off-by: Hans de Goede <hdegoede@redhat.com>

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

> ---
>   drivers/usb/typec/fusb302/fusb302.c | 12 ------------
>   1 file changed, 12 deletions(-)
> 
> diff --git a/drivers/usb/typec/fusb302/fusb302.c b/drivers/usb/typec/fusb302/fusb302.c
> index 1e68da10bf17..82bed9810be6 100644
> --- a/drivers/usb/typec/fusb302/fusb302.c
> +++ b/drivers/usb/typec/fusb302/fusb302.c
> @@ -864,17 +864,6 @@ static int tcpm_set_vbus(struct tcpc_dev *dev, bool on, bool charge)
>   	return ret;
>   }
>   
> -static int tcpm_set_current_limit(struct tcpc_dev *dev, u32 max_ma, u32 mv)
> -{
> -	struct fusb302_chip *chip = container_of(dev, struct fusb302_chip,
> -						 tcpc_dev);
> -
> -	fusb302_log(chip, "current limit: %d ma, %d mv (not implemented)",
> -		    max_ma, mv);
> -
> -	return 0;
> -}
> -
>   static int fusb302_pd_tx_flush(struct fusb302_chip *chip)
>   {
>   	return fusb302_i2c_set_bits(chip, FUSB_REG_CONTROL0,
> @@ -1213,7 +1202,6 @@ static void init_tcpc_dev(struct tcpc_dev *fusb302_tcpc_dev)
>   	fusb302_tcpc_dev->set_polarity = tcpm_set_polarity;
>   	fusb302_tcpc_dev->set_vconn = tcpm_set_vconn;
>   	fusb302_tcpc_dev->set_vbus = tcpm_set_vbus;
> -	fusb302_tcpc_dev->set_current_limit = tcpm_set_current_limit;
>   	fusb302_tcpc_dev->set_pd_rx = tcpm_set_pd_rx;
>   	fusb302_tcpc_dev->set_roles = tcpm_set_roles;
>   	fusb302_tcpc_dev->start_drp_toggling = tcpm_start_drp_toggling;
>
---
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

             reply	other threads:[~2018-07-01 13:58 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-01 13:58 Guenter Roeck [this message]
  -- strict thread matches above, loose matches on Subject: below --
2018-07-01 12:27 USB: typec: fsusb302: Drop empty set_current_limit implementation Hans de Goede

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=66c50d3b-c7c8-00c9-3bd6-068b8f0ed930@roeck-us.net \
    --to=linux@roeck-us.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=hdegoede@redhat.com \
    --cc=heikki.krogerus@linux.intel.com \
    --cc=linux-usb@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.