Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/test/test2/test2.c

    r267f235 r1d6dd2a  
    3434#include <stdio.h>
    3535#include <errno.h>
     36#include <str.h>
    3637#include <str_error.h>
    3738#include <ddf/driver.h>
     
    4041#define NAME "test2"
    4142
    42 static int test2_dev_add(ddf_dev_t *dev);
    43 static int test2_dev_remove(ddf_dev_t *dev);
    44 static int test2_dev_gone(ddf_dev_t *dev);
    45 static int test2_fun_online(ddf_fun_t *fun);
    46 static int test2_fun_offline(ddf_fun_t *fun);
     43static errno_t test2_dev_add(ddf_dev_t *dev);
     44static errno_t test2_dev_remove(ddf_dev_t *dev);
     45static errno_t test2_dev_gone(ddf_dev_t *dev);
     46static errno_t test2_fun_online(ddf_fun_t *fun);
     47static errno_t test2_fun_offline(ddf_fun_t *fun);
    4748
    4849static driver_ops_t driver_ops = {
     
    7778 * @param score Device match score.
    7879 */
    79 static int register_fun_verbose(ddf_dev_t *parent, const char *message,
     80static errno_t register_fun_verbose(ddf_dev_t *parent, const char *message,
    8081    const char *name, const char *match_id, int match_score, ddf_fun_t **pfun)
    8182{
    8283        ddf_fun_t *fun;
    83         int rc;
     84        errno_t rc;
    8485
    8586        ddf_msg(LVL_DEBUG, "Registering function `%s': %s.", name, message);
     
    118119 * @return Always EOK.
    119120 */
    120 static int plug_unplug(void *arg)
     121static errno_t plug_unplug(void *arg)
    121122{
    122123        test2_t *test2 = (test2_t *) arg;
    123124        ddf_fun_t *fun_a;
    124         int rc;
     125        errno_t rc;
    125126
    126127        async_usleep(1000);
     
    157158}
    158159
    159 static int fun_remove(ddf_fun_t *fun, const char *name)
    160 {
    161         int rc;
     160static errno_t fun_remove(ddf_fun_t *fun, const char *name)
     161{
     162        errno_t rc;
    162163
    163164        ddf_msg(LVL_DEBUG, "fun_remove(%p, '%s')", fun, name);
     
    178179}
    179180
    180 static int fun_unbind(ddf_fun_t *fun, const char *name)
    181 {
    182         int rc;
     181static errno_t fun_unbind(ddf_fun_t *fun, const char *name)
     182{
     183        errno_t rc;
    183184
    184185        ddf_msg(LVL_DEBUG, "fun_unbind(%p, '%s')", fun, name);
     
    193194}
    194195
    195 static int test2_dev_add(ddf_dev_t *dev)
     196static errno_t test2_dev_add(ddf_dev_t *dev)
    196197{
    197198        test2_t *test2;
     
    224225}
    225226
    226 static int test2_dev_remove(ddf_dev_t *dev)
     227static errno_t test2_dev_remove(ddf_dev_t *dev)
    227228{
    228229        test2_t *test2 = (test2_t *)ddf_dev_data_get(dev);
    229         int rc;
     230        errno_t rc;
    230231
    231232        ddf_msg(LVL_DEBUG, "test2_dev_remove(%p)", dev);
     
    258259}
    259260
    260 static int test2_dev_gone(ddf_dev_t *dev)
     261static errno_t test2_dev_gone(ddf_dev_t *dev)
    261262{
    262263        test2_t *test2 = (test2_t *)ddf_dev_data_get(dev);
    263         int rc;
     264        errno_t rc;
    264265
    265266        ddf_msg(LVL_DEBUG, "test2_dev_gone(%p)", dev);
     
    293294
    294295
    295 static int test2_fun_online(ddf_fun_t *fun)
     296static errno_t test2_fun_online(ddf_fun_t *fun)
    296297{
    297298        ddf_msg(LVL_DEBUG, "test2_fun_online()");
     
    299300}
    300301
    301 static int test2_fun_offline(ddf_fun_t *fun)
     302static errno_t test2_fun_offline(ddf_fun_t *fun)
    302303{
    303304        ddf_msg(LVL_DEBUG, "test2_fun_offline()");
Note: See TracChangeset for help on using the changeset viewer.