FROMLIST: platform/chrome: cros_ec_typec: Tolerate unrecognized mux flags

On occasion, the Chrome Embedded Controller (EC) can send a mux
configuration which doesn't map to a particular data mode. For instance,
dedicated Type C chargers, when connected, may cause only
USB_PD_MUX_POLARITY_INVERTED to be set. This is a valid flag combination
and should not lead to a driver abort.

Modify the mux configuration handling to not return an error when an
unrecognized mux flag combination is encountered. Concordantly, make the
ensuing print a debug level print so as to not pollute the kernel logs.

BUG=b:172389428
TEST=None
Cc: Keith Short <keithshort@chromium.org>
Signed-off-by: Prashant Malani <pmalani@chromium.org>
(am from https://lore.kernel.org/patchwork/patch/1333901/)
Change-Id: I482b9650f550bc0031ab5e248f85af529694cd35
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/2553039
Reviewed-by: Sean Paul <seanpaul@chromium.org>
Reviewed-by: Benson Leung <bleung@google.com>
Reviewed-by: Srikanth Nandamuri <srikanth.nandamuri@intel.corp-partner.google.com>
Tested-by: Srikanth Nandamuri <srikanth.nandamuri@intel.corp-partner.google.com>
(cherry picked from commit de8228c271101a4adb2f14efc7189f1509f863fa)
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/third_party/kernel/+/2556557
Reviewed-by: Alex Levin <levinale@google.com>
1 file changed