From: Oliver Neukum <oneukum@suse.com>
To: Guenter Roeck <groeck@chromium.org>
Cc: Felipe Balbi <felipe.balbi@linux.intel.com>,
Bin Gao <bin.gao@intel.com>,
Chandra Sekhar Anagani <chandra.sekhar.anagani@intel.com>,
Pranav Tipnis <pranav.tipnis@intel.com>,
Heikki Krogerus <heikki.krogerus@linux.intel.com>,
linux-kernel@vger.kernel.org, linux-usb@vger.kernel.org,
Bruce Ashfield <bruce.ashfield@windriver.com>
Subject: Re: [RFC PATCH 3/4] usb: typec: USB Type-C Port Manager (tcpm)
Date: Wed, 03 Aug 2016 11:18:00 +0200 [thread overview]
Message-ID: <1470215880.4612.3.camel@suse.com> (raw)
In-Reply-To: <1470169975-19941-4-git-send-email-groeck@chromium.org>
On Tue, 2016-08-02 at 13:32 -0700, Guenter Roeck wrote:
> +static int tcpm_set_polarity(struct tcpm_port *port,
> + enum typec_cc_polarity polarity)
> +{
> + tcpm_log(port, "polarity %d", polarity);
> +
> + port->polarity = polarity;
> +
> + return port->tcpc->set_polarity(port->tcpc, port->polarity);
> +}
Here you don't care about the result.
> +
> +static int tcpm_set_vconn(struct tcpm_port *port, bool enable)
> +{
> + int ret = 0;
> +
> + tcpm_log(port, "vconn:=%d", enable);
> +
> + ret = port->tcpc->set_vconn(port->tcpc, enable);
> + if (!ret) {
> + port->con.vconn_role = enable ? TYPEC_SOURCE
> + : TYPEC_SINK;
> + typec_set_vconn_role(port->typec_port,
> port->con.vconn_role);
> + }
> +
> + return ret;
> +}
But here you do. Which is right?
Regards
Oliver
next prev parent reply other threads:[~2016-08-03 9:22 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-02 20:32 [RFC PATCH 0/4] Type-C Port Manager Guenter Roeck
2016-08-02 20:32 ` [RFC PATCH 1/4] usb: typec: Drop locking from class code Guenter Roeck
2016-08-02 20:32 ` [RFC PATCH 2/4] usb: typec: Do not check if connected when setting roles Guenter Roeck
2016-08-02 20:32 ` [RFC PATCH 3/4] usb: typec: USB Type-C Port Manager (tcpm) Guenter Roeck
2016-08-03 9:18 ` Oliver Neukum [this message]
2016-08-03 18:03 ` Guenter Roeck
2016-08-03 9:28 ` Oliver Neukum
2016-08-03 18:46 ` Guenter Roeck
2016-08-02 20:32 ` [RFC PATCH 4/4] usb: typec: Type-C Port Controller Interface driver (tcpci) Guenter Roeck
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=1470215880.4612.3.camel@suse.com \
--to=oneukum@suse.com \
--cc=bin.gao@intel.com \
--cc=bruce.ashfield@windriver.com \
--cc=chandra.sekhar.anagani@intel.com \
--cc=felipe.balbi@linux.intel.com \
--cc=groeck@chromium.org \
--cc=heikki.krogerus@linux.intel.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb@vger.kernel.org \
--cc=pranav.tipnis@intel.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox