usb: typec: Don't prevent using constant typec_mode_desc initializers
authorMats Karrman <mats.dev.list@gmail.com>
Tue, 25 Apr 2017 21:49:47 +0000 (23:49 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 17 May 2017 10:20:53 +0000 (12:20 +0200)
commita86c309e71dc4f43c68483f7e328b1d4f9fef618
tree7cf77aa33e3644ec0a09133a14439d99eed3d3a8
parent614536dac7f33c64a58fab4767a325d52572a7d1
usb: typec: Don't prevent using constant typec_mode_desc initializers

In some situations, e.g. when registering alternate modes for local typec
ports, it may be handy to use constant mode descriptors. Allow this by
changing the mode descriptor arguments of typec_port_register_altmode()
et.al. to using const pointers.

Signed-off-by: Mats Karrman <mats.dev.list@gmail.com>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
Acked-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/typec/typec.c
include/linux/usb/typec.h