# Re: \[PATCH v2 1/7\] usb: gadget: pch\_udc: Replace cpu\_to\_le32() by lower\_32\_bits()

- From: Linus Walleij \<hidden\>
- Date: 2021-03-25 09:21:30 
- List: linux-usb
- Page: https://ratatoskr.run/linux-usb/2021/03/6314913
- Thread: https://ratatoskr.run/linux-usb/2021/03/6312480/t.md

```text
On Tue, Mar 23, 2021 at 4:36 PM Andy Shevchenko
[ref] wrote:

> Either way ~0 will be in the correct byte order, hence
> replace cpu_to_le32() by lower_32_bits(). Moreover,
> it makes sparse happy, otherwise it complains:
>
> .../pch_udc.c:1813:27: warning: incorrect type in assignment (different base types)
> .../pch_udc.c:1813:27:    expected unsigned int [usertype] dataptr
> .../pch_udc.c:1813:27:    got restricted __le32 [usertype]
>
> Fixes: f646cf94520e ("USB device driver of Topcliff PCH")
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

Nice fix! Also easier to understand.
Reviewed-by: Linus Walleij <redacted>

Yours,
Linus Walleij
```
