mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
virtio: allow finalize_features to fail
This will make it easy for transports to validate features and return failure. Signed-off-by: Michael S. Tsirkin <[email protected]>
This commit is contained in:
parent
ce15408f35
commit
5c609a5ef0
9 changed files with 38 additions and 16 deletions
|
|
@ -84,7 +84,7 @@ static u64 mic_get_features(struct virtio_device *vdev)
|
|||
return features;
|
||||
}
|
||||
|
||||
static void mic_finalize_features(struct virtio_device *vdev)
|
||||
static int mic_finalize_features(struct virtio_device *vdev)
|
||||
{
|
||||
unsigned int i, bits;
|
||||
struct mic_device_desc __iomem *desc = to_micvdev(vdev)->desc;
|
||||
|
|
@ -107,6 +107,8 @@ static void mic_finalize_features(struct virtio_device *vdev)
|
|||
iowrite8(ioread8(&out_features[i / 8]) | (1 << (i % 8)),
|
||||
&out_features[i / 8]);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue