Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/label/src/dummy.c

    r0ecfc62 rdeacc58d  
    3434 */
    3535
    36 #include <block.h>
    3736#include <errno.h>
    3837#include <mem.h>
     
    4140#include "dummy.h"
    4241
    43 static int dummy_open(service_id_t, label_t **);
    44 static int dummy_create(service_id_t, label_t **);
     42static int dummy_open(label_bd_t *, label_t **);
     43static int dummy_create(label_bd_t *, label_t **);
    4544static void dummy_close(label_t *);
    4645static int dummy_destroy(label_t *);
     
    6766};
    6867
    69 static int dummy_open(service_id_t sid, label_t **rlabel)
     68static int dummy_open(label_bd_t *bd, label_t **rlabel)
    7069{
    7170        label_t *label = NULL;
     
    7675        int rc;
    7776
    78         rc = block_get_bsize(sid, &bsize);
     77        rc = bd->ops->get_bsize(bd->arg, &bsize);
    7978        if (rc != EOK) {
    8079                rc = EIO;
     
    8281        }
    8382
    84         rc = block_get_nblocks(sid, &nblocks);
     83        rc = bd->ops->get_nblocks(bd->arg, &nblocks);
    8584        if (rc != EOK) {
    8685                rc = EIO;
     
    101100        label->ops = &dummy_label_ops;
    102101        label->ltype = lt_none;
    103         label->svc_id = sid;
     102        label->bd = *bd;
    104103        label->ablock0 = ba_min;
    105104        label->anblocks = ba_max - ba_min + 1;
     
    129128}
    130129
    131 static int dummy_create(service_id_t sid, label_t **rlabel)
     130static int dummy_create(label_bd_t *bd, label_t **rlabel)
    132131{
    133132        return ENOTSUP;
Note: See TracChangeset for help on using the changeset viewer.