Changeset 4a00bc9 in mainline for uspace/lib/usbhost/src/dma_buffer.c


Ignore:
Timestamp:
2018-01-10T13:29:52Z (6 years ago)
Author:
Ondřej Hlavatý <aearsis@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
398a94c
Parents:
f92f6b1
git-author:
Ondřej Hlavatý <aearsis@…> (2018-01-10 13:28:21)
git-committer:
Ondřej Hlavatý <aearsis@…> (2018-01-10 13:29:52)
Message:

xhci: fix errors reported by clang

Asserts were unnecessary, because the transfer type is an enum.
DMAMEM_4GiB is an uintptr_t constant.
There shall be at least one ring segment, and clang cannot infer that.
TRBs shall be 16-byte aligned to take aligned pointers from it.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/usbhost/src/dma_buffer.c

    rf92f6b1 r4a00bc9  
    6262        const size_t aligned_size = ALIGN_UP(size, policy.alignment);
    6363        const size_t real_size = ALIGN_UP(aligned_size, PAGE_SIZE);
    64         const int flags = policy.use64 ? 0 : DMAMEM_4GiB;
     64        const uintptr_t flags = policy.use64 ? 0 : DMAMEM_4GiB;
    6565
    6666        uintptr_t phys;
Note: See TracChangeset for help on using the changeset viewer.