From: Tomeu Vizoso <tomeu.vizoso@collabora.com>
To: linux-kernel@vger.kernel.org
Cc: "Sameer Nanda" <snanda@chromium.org>,
"Javier Martinez Canillas" <javier@osg.samsung.com>,
"Lee Jones" <lee.jones@linaro.org>,
"Benson Leung" <bleung@chromium.org>,
"Enric Balletbò" <enric.balletbo@collabora.co.uk>,
"Vic Yang" <victoryang@chromium.org>,
"Stephen Boyd" <sboyd@codeaurora.org>,
"Vincent Palatin" <vpalatin@chromium.org>,
"Randall Spangler" <rspangler@chromium.org>,
"Todd Broch" <tbroch@chromium.org>,
"Gwendal Grignou" <gwendal@chromium.org>,
"Tomeu Vizoso" <tomeu.vizoso@collabora.com>,
linux-pm@vger.kernel.org, "Sebastian Reichel" <sre@kernel.org>,
"Dmitry Eremin-Solenikov" <dbaryshkov@gmail.com>,
"Dmitry Torokhov" <dmitry.torokhov@gmail.com>,
"David Woodhouse" <dwmw2@infradead.org>,
linux-input@vger.kernel.org, "Olof Johansson" <olof@lixom.net>
Subject: [PATCH v5 0/6] EC-based USB Power Delivery support for Chrome machines
Date: Mon, 14 Mar 2016 16:44:55 +0100 [thread overview]
Message-ID: <1457970301-24616-1-git-send-email-tomeu.vizoso@collabora.com> (raw)
Hi,
this series contains a driver that exposes a power_supply to userspace
representing a port that support USB PD charging.
Allows userspace to display to the user if the machine is charging and
on which port, and if another device is being charged by a port.
Thanks,
Tomeu
Changes in v5:
- Check explicitly for !EC_RES_SUCCESS as suggested by Benson Leung.
- Fix type of variable passed to do_div.
Changes in v4:
- Calculate correctly the size of the payloads in
cros_ec_get_host_command_version_mask.
- Declare size parameters in ec_command as size_t
Changes in v3:
- Remove duplicated prototype of cros_ec_get_host_event.
- Use do_div so it builds on 32bit (suggested by 0-day kbuild bot).
- Remove sysfs attributes ext_current_lim and ext_voltage_lim because
I don't know yet where they should be placed (and don't have HW to
test them).
- Remove superfluous pre-allocated buffers ec_inbuf and ec_outbuf.
- Lots of misc comments from Stephen Boyd were addressed.
- Unregister notification listener in .remove callback.
- Only register the PD charger device if there are any PD ports in this
EC.
- Dropped patch using EC_CMD_GET_FEATURES to decide whether to create a
charger device because we are now only creating one if a EC has any PD
ports.
- Dropped patch adding power_supply types because it has been merged
already.
Changes in v2:
- Allocate enough for the structs in cros_ec_get_host_command_version_mask,
not their pointers.
- Allocate msg in the stack in get_next_event and
get_keyboard_state_event, as suggested by Gwendal.
- Split out changes to cros_ec_commands.h and the helpers added to
mfd/cros_ec.h from the patch that adds the charger driver, as
suggested by Lee.
- Actually call get_ec_num_ports.
- Move cros_ec_usb_pd_charger_register into cros_ec_dev.c.
Sameer Nanda (1):
power: cros_usbpd-charger: Add EC-based USB PD charger driver
Tomeu Vizoso (4):
mfd: cros_ec: Add cros_ec_cmd_xfer_status helper
mfd: cros_ec: Add cros_ec_get_host_event
mfd: cros_ec: Add more definitions for PD commands
platform/chrome: Register USB PD charger device
Vic Yang (1):
mfd: cros_ec: Add MKBP event support
drivers/input/keyboard/cros_ec_keyb.c | 135 ++----
drivers/mfd/cros_ec.c | 57 ++-
drivers/platform/chrome/cros_ec_dev.c | 44 ++
drivers/platform/chrome/cros_ec_proto.c | 129 ++++++
drivers/power/Kconfig | 10 +
drivers/power/Makefile | 1 +
drivers/power/cros_usbpd-charger.c | 780 ++++++++++++++++++++++++++++++++
include/linux/mfd/cros_ec.h | 62 +++
include/linux/mfd/cros_ec_commands.h | 358 ++++++++++++++-
9 files changed, 1464 insertions(+), 112 deletions(-)
create mode 100644 drivers/power/cros_usbpd-charger.c
--
2.5.0
next reply other threads:[~2016-03-14 15:45 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-14 15:44 Tomeu Vizoso [this message]
2016-03-14 15:44 ` [PATCH v5 1/6] mfd: cros_ec: Add MKBP event support Tomeu Vizoso
2016-03-14 15:44 ` [PATCH v5 2/6] mfd: cros_ec: Add cros_ec_cmd_xfer_status helper Tomeu Vizoso
2016-03-14 17:24 ` Benson Leung
2016-03-14 15:44 ` [PATCH v5 3/6] mfd: cros_ec: Add cros_ec_get_host_event Tomeu Vizoso
2016-03-14 19:23 ` Benson Leung
2016-03-14 15:44 ` [PATCH v5 4/6] mfd: cros_ec: Add more definitions for PD commands Tomeu Vizoso
2016-03-14 15:45 ` [PATCH v5 5/6] power: cros_usbpd-charger: Add EC-based USB PD charger driver Tomeu Vizoso
2016-04-14 9:35 ` Pavel Machek
2016-03-14 15:45 ` [PATCH v5 6/6] platform/chrome: Register USB PD charger device Tomeu Vizoso
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=1457970301-24616-1-git-send-email-tomeu.vizoso@collabora.com \
--to=tomeu.vizoso@collabora.com \
--cc=bleung@chromium.org \
--cc=dbaryshkov@gmail.com \
--cc=dmitry.torokhov@gmail.com \
--cc=dwmw2@infradead.org \
--cc=enric.balletbo@collabora.co.uk \
--cc=gwendal@chromium.org \
--cc=javier@osg.samsung.com \
--cc=lee.jones@linaro.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=olof@lixom.net \
--cc=rspangler@chromium.org \
--cc=sboyd@codeaurora.org \
--cc=snanda@chromium.org \
--cc=sre@kernel.org \
--cc=tbroch@chromium.org \
--cc=victoryang@chromium.org \
--cc=vpalatin@chromium.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).