static void fotg210_set_address(struct fotg210_udc *fotg210,
                                struct usb_ctrlrequest *ctrl)
 {
-       if (ctrl->wValue >= 0x0100) {
+       if (le16_to_cpu(ctrl->wValue) >= 0x0100) {
                fotg210_request_error(fotg210);
        } else {
-               fotg210_set_dev_addr(fotg210, ctrl->wValue);
+               fotg210_set_dev_addr(fotg210, le16_to_cpu(ctrl->wValue));
                fotg210_set_cxdone(fotg210);
        }
 }
 
        switch (ctrl->bRequestType & USB_RECIP_MASK) {
        case USB_RECIP_DEVICE:
-               fotg210->ep0_data = 1 << USB_DEVICE_SELF_POWERED;
+               fotg210->ep0_data = cpu_to_le16(1 << USB_DEVICE_SELF_POWERED);
                break;
        case USB_RECIP_INTERFACE:
-               fotg210->ep0_data = 0;
+               fotg210->ep0_data = cpu_to_le16(0);
                break;
        case USB_RECIP_ENDPOINT:
                epnum = ctrl->wIndex & USB_ENDPOINT_NUMBER_MASK;
                if (epnum)
                        fotg210->ep0_data =
-                               fotg210_is_epnstall(fotg210->ep[epnum])
-                               << USB_ENDPOINT_HALT;
+                               cpu_to_le16(fotg210_is_epnstall(fotg210->ep[epnum])
+                                           << USB_ENDPOINT_HALT);
                else
                        fotg210_request_error(fotg210);
                break;