From: Fabien Parent <fparent@baylibre.com>
To: Sebastian Reichel <sre@kernel.org>, Lee Jones <lee.jones@linaro.org>
Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
gpain@baylibre.com, Fabien Parent <fparent@baylibre.com>
Subject: [PATCH v2 1/3] mfd: cros: add charger port count command definition
Date: Fri, 10 Aug 2018 15:13:47 +0200 [thread overview]
Message-ID: <20180810131349.3883-2-fparent@baylibre.com> (raw)
In-Reply-To: <20180810131349.3883-1-fparent@baylibre.com>
A new more command has been added to the ChromeOS embedded controller
that allows to get the number of charger port count. Unlike
EC_CMD_USB_PD_PORTS, this new command also includes the dedicated
port if present.
This command will be used to expose the dedicated charger port
in the ChromeOS charger driver.
Signed-off-by: Fabien Parent <fparent@baylibre.com>
Acked-for-MFD-by: Lee Jones <lee.jones@linaro.org>
---
V1 -> V2:
* No change
---
include/linux/mfd/cros_ec_commands.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/include/linux/mfd/cros_ec_commands.h b/include/linux/mfd/cros_ec_commands.h
index 0d926492ac3a..e3187f8bdb7e 100644
--- a/include/linux/mfd/cros_ec_commands.h
+++ b/include/linux/mfd/cros_ec_commands.h
@@ -3005,6 +3005,16 @@ struct ec_params_usb_pd_info_request {
uint8_t port;
} __packed;
+/*
+ * This command will return the number of USB PD charge port + the number
+ * of dedicated port present.
+ * EC_CMD_USB_PD_PORTS does NOT include the dedicated ports
+ */
+#define EC_CMD_CHARGE_PORT_COUNT 0x0105
+struct ec_response_charge_port_count {
+ uint8_t port_count;
+} __packed;
+
/* Read USB-PD Device discovery info */
#define EC_CMD_USB_PD_DISCOVERY 0x0113
struct ec_params_usb_pd_discovery_entry {
--
2.18.0
next prev parent reply other threads:[~2018-08-10 13:17 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-08-10 13:13 [PATCH v2 0/3] power: supply: cros: add support for dedicated port and expose connected ports Fabien Parent
2018-08-10 13:13 ` Fabien Parent [this message]
2018-08-14 17:03 ` [PATCH v2 1/3] mfd: cros: add charger port count command definition Enric Balletbo Serra
2018-08-10 13:13 ` [PATCH v2 2/3] power: supply: cros: add support for dedicated port Fabien Parent
2018-08-10 13:13 ` [PATCH v2 3/3] power: supply: cros: add property to detect connected ports Fabien Parent
2018-09-16 11:08 ` Sebastian Reichel
2018-09-16 11:12 ` [PATCH v2 0/3] power: supply: cros: add support for dedicated port and expose " Sebastian Reichel
2018-09-16 20:37 ` Sebastian Reichel
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=20180810131349.3883-2-fparent@baylibre.com \
--to=fparent@baylibre.com \
--cc=gpain@baylibre.com \
--cc=lee.jones@linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=sre@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 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).