Changeset 301032a in mainline for uspace/lib/c/generic/device/hw_res.c


Ignore:
Timestamp:
2013-08-16T14:08:03Z (11 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
537620a8
Parents:
c762ad5
Message:

isa, dma: Fix 64KB dma buffers

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/c/generic/device/hw_res.c

    rc762ad5 r301032a  
    102102 */
    103103int hw_res_dma_channel_setup(async_sess_t *sess,
    104     unsigned channel, uint32_t pa, uint16_t size, uint8_t mode)
     104    unsigned channel, uint32_t pa, uint32_t size, uint8_t mode)
    105105{
    106106        async_exch_t *exch = async_exchange_begin(sess);
    107107        if (exch == NULL)
    108108                return ENOMEM;
    109         const uint32_t packed = size | (mode << 16);
     109        const uint32_t packed = (channel & 0xffff) | (mode << 16);
    110110        const int ret = async_req_4_0(exch, DEV_IFACE_ID(HW_RES_DEV_IFACE),
    111             HW_RES_DMA_CHANNEL_SETUP, channel, pa, packed);
     111            HW_RES_DMA_CHANNEL_SETUP, packed, pa, size);
    112112        async_exchange_end(exch);
    113113
Note: See TracChangeset for help on using the changeset viewer.