Ignore:
Timestamp:
2011-04-15T19:38:07Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
9dd730d1
Parents:
6b9e85b (diff), b2fb47f (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/drv/generic/remote_hw_res.c

    r6b9e85b r8b655705  
    3333 */
    3434
    35 #include <ipc/ipc.h>
    3635#include <async.h>
    3736#include <errno.h>
    3837
    3938#include "ops/hw_res.h"
    40 #include "driver.h"
     39#include "ddf/driver.h"
    4140
    42 static void remote_hw_res_get_resource_list(device_t *, void *, ipc_callid_t,
     41static void remote_hw_res_get_resource_list(ddf_fun_t *, void *, ipc_callid_t,
    4342    ipc_call_t *);
    44 static void remote_hw_res_enable_interrupt(device_t *, void *, ipc_callid_t,
     43static void remote_hw_res_enable_interrupt(ddf_fun_t *, void *, ipc_callid_t,
    4544    ipc_call_t *);
    4645
     
    5655};
    5756
    58 static void remote_hw_res_enable_interrupt(device_t *dev, void *ops,
     57static void remote_hw_res_enable_interrupt(ddf_fun_t *fun, void *ops,
    5958    ipc_callid_t callid, ipc_call_t *call)
    6059{
     
    6261       
    6362        if (hw_res_ops->enable_interrupt == NULL)
    64                 ipc_answer_0(callid, ENOTSUP);
    65         else if (hw_res_ops->enable_interrupt(dev))
    66                 ipc_answer_0(callid, EOK);
     63                async_answer_0(callid, ENOTSUP);
     64        else if (hw_res_ops->enable_interrupt(fun))
     65                async_answer_0(callid, EOK);
    6766        else
    68                 ipc_answer_0(callid, EREFUSED);
     67                async_answer_0(callid, EREFUSED);
    6968}
    7069
    71 static void remote_hw_res_get_resource_list(device_t *dev, void *ops,
     70static void remote_hw_res_get_resource_list(ddf_fun_t *fun, void *ops,
    7271    ipc_callid_t callid, ipc_call_t *call)
    7372{
     
    7574
    7675        if (hw_res_ops->get_resource_list == NULL) {
    77                 ipc_answer_0(callid, ENOTSUP);
     76                async_answer_0(callid, ENOTSUP);
    7877                return;
    7978        }
    8079       
    81         hw_resource_list_t *hw_resources = hw_res_ops->get_resource_list(dev);
     80        hw_resource_list_t *hw_resources = hw_res_ops->get_resource_list(fun);
    8281        if (hw_resources == NULL){
    83                 ipc_answer_0(callid, ENOENT);
     82                async_answer_0(callid, ENOENT);
    8483                return;
    8584        }
    8685       
    87         ipc_answer_1(callid, EOK, hw_resources->count);
     86        async_answer_1(callid, EOK, hw_resources->count);
    8887
    8988        size_t len;
Note: See TracChangeset for help on using the changeset viewer.