OSDN Git Service

usb: pd: Update uevent parameters during hard reset
authorJack Pham <jackp@codeaurora.org>
Tue, 31 Jan 2017 23:23:56 +0000 (15:23 -0800)
committerJack Pham <jackp@codeaurora.org>
Sat, 11 Feb 2017 01:42:29 +0000 (17:42 -0800)
commitda9c7fa2a547c9a05d84fccc48dc693fbdf9b8f8
tree2c7adffa73077b71f7b996072370b006e7960a59
parent47fdec0cf105986642b30e3e901db4930860996f
usb: pd: Update uevent parameters during hard reset

Ensure that a few of the parameters (SELECTED_PDO, REQUESTED_PDO,
RDO) are properly cleared out during hard reset and a uevent
update is sent to notify userspace clients.

Also, don't reset src_cap_id upon disconnect. This makes it a
a monotonically increasing value upon every connection so that
clients can distinguish when a new PD session is established.
Demote it to a u16 in order to have a smaller wraparound (65535).

Change-Id: I622ad1155b3680d3f616d5e9a835d4c6cbca3636
Signed-off-by: Jack Pham <jackp@codeaurora.org>
drivers/usb/pd/policy_engine.c