Ignore:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/lib/virtio/virtio.c

    r13eecc4 r8d2289c  
    6363        uintptr_t phys;
    6464        errno_t rc = dmamem_map_anonymous(buffers * size, 0,
    65             write ? AS_AREA_WRITE | AS_AREA_READ : AS_AREA_READ, 0, &phys,
    66             &virt);
     65            write ? AS_AREA_WRITE : AS_AREA_READ, 0, &phys, &virt);
    6766        if (rc != EOK)
    6867                return rc;
     
    320319        uint32_t device_features = pio_read_le32(&cfg->device_feature);
    321320
    322         uint32_t reserved_features = VIRTIO_F_VERSION_1;
    323         pio_write_le32(&cfg->device_feature_select, VIRTIO_FEATURES_32_63);
    324         uint32_t device_reserved_features = pio_read_le32(&cfg->device_feature);
    325 
    326         ddf_msg(LVL_NOTE, "offered features %x, reserved features %x",
    327             device_features, device_reserved_features);
     321        ddf_msg(LVL_NOTE, "offered features %x", device_features);
    328322
    329323        if (features != (features & device_features))
     
    331325        features &= device_features;
    332326
    333         if (reserved_features != (reserved_features & device_reserved_features))
    334                 return ENOTSUP;
    335         reserved_features &= device_reserved_features;
    336 
    337327        /* 4. Write the accepted feature flags */
    338328        pio_write_le32(&cfg->driver_feature_select, VIRTIO_FEATURES_0_31);
    339329        pio_write_le32(&cfg->driver_feature, features);
    340         pio_write_le32(&cfg->driver_feature_select, VIRTIO_FEATURES_32_63);
    341         pio_write_le32(&cfg->driver_feature, reserved_features);
    342 
    343         ddf_msg(LVL_NOTE, "accepted features %x, reserved features %x",
    344             features, reserved_features);
     330
     331        ddf_msg(LVL_NOTE, "accepted features %x", features);
    345332
    346333        /* 5. Set FEATURES_OK */
Note: See TracChangeset for help on using the changeset viewer.