diff options
author | Aaro Koskinen <aaro.koskinen@iki.fi> | 2013-07-30 23:42:53 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-07-31 17:49:04 -0700 |
commit | 4918072eb0fa3d430613c11b4cb287e6c3bf1879 (patch) | |
tree | d0a8e3d1d857d9fb77455ed54790d4d7e4f909e1 | |
parent | 8fd070077410b26847ef6f5856850df417e7b83e (diff) |
staging: octeon-usb: cvmx_usb_speed_t -> enum cvmx_usb_speed
Replace cvmx_usb_speed_t with enum cvmx_usb_speed.
Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/staging/octeon-usb/cvmx-usb.c | 4 | ||||
-rw-r--r-- | drivers/staging/octeon-usb/cvmx-usb.h | 21 | ||||
-rw-r--r-- | drivers/staging/octeon-usb/octeon-hcd.c | 2 |
3 files changed, 15 insertions, 12 deletions
diff --git a/drivers/staging/octeon-usb/cvmx-usb.c b/drivers/staging/octeon-usb/cvmx-usb.c index fa029e3f8db1..44f4db0cfd9a 100644 --- a/drivers/staging/octeon-usb/cvmx-usb.c +++ b/drivers/staging/octeon-usb/cvmx-usb.c @@ -151,7 +151,7 @@ typedef struct cvmx_usb_pipe { uint64_t interval; /**< For periodic pipes, the interval between packets in frames */ uint64_t next_tx_frame; /**< The next frame this pipe is allowed to transmit on */ cvmx_usb_pipe_flags_t flags; /**< State flags for this pipe */ - cvmx_usb_speed_t device_speed; /**< Speed of device connected to this pipe */ + enum cvmx_usb_speed device_speed; /**< Speed of device connected to this pipe */ cvmx_usb_transfer_t transfer_type; /**< Type of transaction supported by this pipe */ cvmx_usb_direction_t transfer_dir; /**< IN or OUT. Ignored for Control */ int multi_count; /**< Max packet in a row for the device */ @@ -1103,7 +1103,7 @@ static inline int __cvmx_usb_get_pipe_handle(cvmx_usb_internal_state_t *usb, */ int cvmx_usb_open_pipe(cvmx_usb_state_t *state, cvmx_usb_pipe_flags_t flags, int device_addr, int endpoint_num, - cvmx_usb_speed_t device_speed, int max_packet, + enum cvmx_usb_speed device_speed, int max_packet, cvmx_usb_transfer_t transfer_type, cvmx_usb_direction_t transfer_dir, int interval, int multi_count, int hub_device_addr, int hub_port) diff --git a/drivers/staging/octeon-usb/cvmx-usb.h b/drivers/staging/octeon-usb/cvmx-usb.h index 4b425e5fa8ae..c5ccda34b530 100644 --- a/drivers/staging/octeon-usb/cvmx-usb.h +++ b/drivers/staging/octeon-usb/cvmx-usb.h @@ -235,14 +235,17 @@ #define __CVMX_USB_H__ /** - * Enumerations representing the possible USB device speeds + * enum cvmx_usb_speed - the possible USB device speeds + * + * @CVMX_USB_SPEED_HIGH: Device is operation at 480Mbps + * @CVMX_USB_SPEED_FULL: Device is operation at 12Mbps + * @CVMX_USB_SPEED_LOW: Device is operation at 1.5Mbps */ -typedef enum -{ - CVMX_USB_SPEED_HIGH = 0, /**< Device is operation at 480Mbps */ - CVMX_USB_SPEED_FULL = 1, /**< Device is operation at 12Mbps */ - CVMX_USB_SPEED_LOW = 2, /**< Device is operation at 1.5Mbps */ -} cvmx_usb_speed_t; +enum cvmx_usb_speed { + CVMX_USB_SPEED_HIGH = 0, + CVMX_USB_SPEED_FULL = 1, + CVMX_USB_SPEED_LOW = 2, +}; /** * Enumeration representing the possible USB transfer types. @@ -290,7 +293,7 @@ typedef struct uint32_t port_enabled : 1; /**< 1 = Usb port is enabled, 0 = disabled */ uint32_t port_over_current : 1; /**< 1 = Over current detected, 0 = Over current not detected. Octeon doesn't support over current detection */ uint32_t port_powered : 1; /**< 1 = Port power is being supplied to the device, 0 = power is off. Octeon doesn't support turning port power off */ - cvmx_usb_speed_t port_speed : 2; /**< Current port speed */ + enum cvmx_usb_speed port_speed : 2; /**< Current port speed */ uint32_t connected : 1; /**< 1 = A device is connected to the port, 0 = No device is connected */ uint32_t connect_change : 1; /**< 1 = Device connected state changed since the last set status call */ } cvmx_usb_port_status_t; @@ -413,7 +416,7 @@ extern void cvmx_usb_set_status(cvmx_usb_state_t *state, cvmx_usb_port_status_t extern int cvmx_usb_open_pipe(cvmx_usb_state_t *state, cvmx_usb_pipe_flags_t flags, int device_addr, int endpoint_num, - cvmx_usb_speed_t device_speed, int max_packet, + enum cvmx_usb_speed device_speed, int max_packet, cvmx_usb_transfer_t transfer_type, cvmx_usb_direction_t transfer_dir, int interval, int multi_count, int hub_device_addr, diff --git a/drivers/staging/octeon-usb/octeon-hcd.c b/drivers/staging/octeon-usb/octeon-hcd.c index d156b603ae65..f32d8fc60200 100644 --- a/drivers/staging/octeon-usb/octeon-hcd.c +++ b/drivers/staging/octeon-usb/octeon-hcd.c @@ -217,7 +217,7 @@ static int octeon_usb_urb_enqueue(struct usb_hcd *hcd, if (!ep->hcpriv) { cvmx_usb_transfer_t transfer_type; - cvmx_usb_speed_t speed; + enum cvmx_usb_speed speed; int split_device = 0; int split_port = 0; switch (usb_pipetype(urb->pipe)) { |