Displaying 20 results from an estimated 29 matches for "argsz".
Did you mean:
args
2013 Jul 03
6
RFC: vfio interface for platform devices (v2)
...ponds to a "reg" or "ranges" property
-there could be multiple sub-regions per "reg" or "ranges" and
the sub-index within the reg/ranges is needed
There are 5 new flags added to vfio_region_info :
struct vfio_region_info {
__u32 argsz;
__u32 flags;
#define VFIO_REGION_INFO_FLAG_CACHEABLE (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_REG (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_RANGE (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_INDEX (1 << ?)
#define VFIO_DEVTREE_REGION_IN...
2013 Jul 03
6
RFC: vfio interface for platform devices (v2)
...ponds to a "reg" or "ranges" property
-there could be multiple sub-regions per "reg" or "ranges" and
the sub-index within the reg/ranges is needed
There are 5 new flags added to vfio_region_info :
struct vfio_region_info {
__u32 argsz;
__u32 flags;
#define VFIO_REGION_INFO_FLAG_CACHEABLE (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_REG (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_RANGE (1 << ?)
#define VFIO_DEVTREE_REGION_INFO_FLAG_INDEX (1 << ?)
#define VFIO_DEVTREE_REGION_IN...
2013 Jul 04
0
RFC: vfio interface for platform devices (v2)
...;ranges" property
> -there could be multiple sub-regions per "reg" or "ranges" and
> the sub-index within the reg/ranges is needed
>
> There are 5 new flags added to vfio_region_info :
>
> struct vfio_region_info {
> __u32 argsz;
> __u32 flags;
> #define VFIO_REGION_INFO_FLAG_CACHEABLE (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_REG (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_RANGE (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_INDEX (1 << ?)
>...
2013 Jul 03
0
RFC: vfio interface for platform devices (v2)
...;ranges" property
> -there could be multiple sub-regions per "reg" or "ranges" and
> the sub-index within the reg/ranges is needed
>
> There are 5 new flags added to vfio_region_info :
>
> struct vfio_region_info {
> __u32 argsz;
> __u32 flags;
> #define VFIO_REGION_INFO_FLAG_CACHEABLE (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_REG (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_RANGE (1 << ?)
> #define VFIO_DEVTREE_REGION_INFO_FLAG_INDEX (1 << ?)
>...
2013 Jul 02
7
RFC: vfio interface for platform devices
...property
-there could be multiple sub-regions per "reg" or "ranges" and
the sub-index within the reg/ranges is needed
The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
struct vfio_path_info {
__u32 argsz;
__u32 flags;
#define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
__u32 index; /* input: index of region or irq for which we are getting info */
__u32 type; /* input: 0 - get devtree info for a re...
2013 Jul 02
7
RFC: vfio interface for platform devices
...property
-there could be multiple sub-regions per "reg" or "ranges" and
the sub-index within the reg/ranges is needed
The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
struct vfio_path_info {
__u32 argsz;
__u32 flags;
#define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
__u32 index; /* input: index of region or irq for which we are getting info */
__u32 type; /* input: 0 - get devtree info for a re...
2013 Jul 03
0
RFC: vfio interface for platform devices
...sub-regions per "reg" or "ranges" and
> the sub-index within the reg/ranges is needed
>
> The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
>
> ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
>
> struct vfio_path_info {
> __u32 argsz;
> __u32 flags;
> #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
(1 << 0)?
Having flags = 0x0 for regs and 0x1 for ranges is a bit awkward. I'd
suggest a bit for each. Otherwise, what does it mean when this ret...
2013 Jul 03
1
RFC: vfio interface for platform devices
...quot; or "ranges" and
>> the sub-index within the reg/ranges is needed
>>
>> The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
>>
>> ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
>>
>> struct vfio_path_info {
>> __u32 argsz;
>> __u32 flags;
>> #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
>
> (1 << 0)?
>
> Having flags = 0x0 for regs and 0x1 for ranges is a bit awkward. I'd
> suggest a bit for each. Otherwise,...
2013 Jul 03
1
RFC: vfio interface for platform devices
...quot; or "ranges" and
>> the sub-index within the reg/ranges is needed
>>
>> The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
>>
>> ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
>>
>> struct vfio_path_info {
>> __u32 argsz;
>> __u32 flags;
>> #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
>
> (1 << 0)?
>
> Having flags = 0x0 for regs and 0x1 for ranges is a bit awkward. I'd
> suggest a bit for each. Otherwise,...
2019 Sep 03
2
[RFC v3] vhost: introduce mdev based hardware vhost backend
...gt; + case VFIO_DEVICE_GET_INFO:
> + {
> + struct vfio_device_info info;
> +
> + minsz = offsetofend(struct vfio_device_info, num_irqs);
> +
> + if (copy_from_user(&info, (void __user *)arg, minsz)) {
> + ret = -EFAULT;
> + break;
> + }
> +
> + if (info.argsz < minsz) {
> + ret = -EINVAL;
> + break;
> + }
> +
> + info.flags = VFIO_DEVICE_FLAGS_VHOST;
> + info.num_regions = 0;
> + info.num_irqs = 0;
> +
> + if (copy_to_user((void __user *)arg, &info, minsz)) {
> + ret = -EFAULT;
> + break;
> + }
&g...
2019 Sep 03
2
[RFC v3] vhost: introduce mdev based hardware vhost backend
...gt; + case VFIO_DEVICE_GET_INFO:
> + {
> + struct vfio_device_info info;
> +
> + minsz = offsetofend(struct vfio_device_info, num_irqs);
> +
> + if (copy_from_user(&info, (void __user *)arg, minsz)) {
> + ret = -EFAULT;
> + break;
> + }
> +
> + if (info.argsz < minsz) {
> + ret = -EINVAL;
> + break;
> + }
> +
> + info.flags = VFIO_DEVICE_FLAGS_VHOST;
> + info.num_regions = 0;
> + info.num_irqs = 0;
> +
> + if (copy_to_user((void __user *)arg, &info, minsz)) {
> + ret = -EFAULT;
> + break;
> + }
&g...
2013 Jul 16
2
RFC: vfio interface for platform devices
..."ranges" and
> > the sub-index within the reg/ranges is needed
> >
> > The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
> >
> > ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
> >
> > struct vfio_path_info {
> > __u32 argsz;
> > __u32 flags;
> > #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a
> > "ranges" property */
>
> What about distinguishing a normal interrupt from one found in an
> interrupt-map?
I'm not sure we need that. The kerne...
2013 Jul 16
2
RFC: vfio interface for platform devices
..."ranges" and
> > the sub-index within the reg/ranges is needed
> >
> > The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
> >
> > ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
> >
> > struct vfio_path_info {
> > __u32 argsz;
> > __u32 flags;
> > #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a
> > "ranges" property */
>
> What about distinguishing a normal interrupt from one found in an
> interrupt-map?
I'm not sure we need that. The kerne...
2013 Jul 03
0
RFC: vfio interface for platform devices
...ultiple sub-regions per "reg" or "ranges" and
> the sub-index within the reg/ranges is needed
>
> The VFIO_DEVICE_GET_DEVTREE_INFO operates on a device fd.
>
> ioctl: VFIO_DEVICE_GET_DEVTREE_INFO
>
> struct vfio_path_info {
> __u32 argsz;
> __u32 flags;
> #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region is a "ranges" property */
> __u32 index; /* input: index of region or irq for which we are getting info */
> __u32 type; /* input: 0 - get devtr...
2013 Jul 16
0
RFC: vfio interface for platform devices
...Will it
> help any decision that user space makes? Maybe we should just
> drop it.
As long as we can be sure all architectures will map things correctly
without any flags needing to be specified, that's fine.
> > > struct vfio_path_info {
> > > __u32 argsz;
> > > __u32 flags;
> > > #define VFIO_DEVTREE_INFO_RANGES (1 << 3) /* the region
> is a
> > > "ranges" property */
> >
> > What about distinguishing a normal interrupt from one found in an
> > interrupt-map?
>...
2019 Jul 03
0
[RFC v2] vhost: introduce mdev based hardware vhost backend
...; +
> + switch (cmd) {
> + case VFIO_DEVICE_GET_INFO:
> + {
> + struct vfio_device_info info;
> +
> + minsz = offsetofend(struct vfio_device_info, num_irqs);
> +
> + if (copy_from_user(&info, (void __user *)arg, minsz))
> + return -EFAULT;
> +
> + if (info.argsz < minsz)
> + return -EINVAL;
> +
> + ret = vdpa_get_device_info(mdev, &info);
> + if (ret)
> + return ret;
> +
> + if (copy_to_user((void __user *)arg, &info, minsz))
> + return -EFAULT;
> +
> + return 0;
> + }
> + case VFIO_DEVICE_GET_REGION...
2019 Jul 03
4
[RFC v2] vhost: introduce mdev based hardware vhost backend
...mdev_get_drvdata(mdev);
+ if (!vdpa)
+ return -ENODEV;
+
+ switch (cmd) {
+ case VFIO_DEVICE_GET_INFO:
+ {
+ struct vfio_device_info info;
+
+ minsz = offsetofend(struct vfio_device_info, num_irqs);
+
+ if (copy_from_user(&info, (void __user *)arg, minsz))
+ return -EFAULT;
+
+ if (info.argsz < minsz)
+ return -EINVAL;
+
+ ret = vdpa_get_device_info(mdev, &info);
+ if (ret)
+ return ret;
+
+ if (copy_to_user((void __user *)arg, &info, minsz))
+ return -EFAULT;
+
+ return 0;
+ }
+ case VFIO_DEVICE_GET_REGION_INFO:
+ {
+ struct vfio_region_info info;
+ u16 cap_type_...
2019 Jul 03
4
[RFC v2] vhost: introduce mdev based hardware vhost backend
...mdev_get_drvdata(mdev);
+ if (!vdpa)
+ return -ENODEV;
+
+ switch (cmd) {
+ case VFIO_DEVICE_GET_INFO:
+ {
+ struct vfio_device_info info;
+
+ minsz = offsetofend(struct vfio_device_info, num_irqs);
+
+ if (copy_from_user(&info, (void __user *)arg, minsz))
+ return -EFAULT;
+
+ if (info.argsz < minsz)
+ return -EINVAL;
+
+ ret = vdpa_get_device_info(mdev, &info);
+ if (ret)
+ return ret;
+
+ if (copy_to_user((void __user *)arg, &info, minsz))
+ return -EFAULT;
+
+ return 0;
+ }
+ case VFIO_DEVICE_GET_REGION_INFO:
+ {
+ struct vfio_region_info info;
+ u16 cap_type_...
2019 Sep 04
0
[RFC v3] vhost: introduce mdev based hardware vhost backend
...; + struct vfio_device_info info;
> > +
> > + minsz = offsetofend(struct vfio_device_info, num_irqs);
> > +
> > + if (copy_from_user(&info, (void __user *)arg, minsz)) {
> > + ret = -EFAULT;
> > + break;
> > + }
> > +
> > + if (info.argsz < minsz) {
> > + ret = -EINVAL;
> > + break;
> > + }
> > +
> > + info.flags = VFIO_DEVICE_FLAGS_VHOST;
> > + info.num_regions = 0;
> > + info.num_irqs = 0;
> > +
> > + if (copy_to_user((void __user *)arg, &info, minsz)) {
> &g...
2018 Apr 10
0
[RFC] vhost: introduce mdev based hardware vhost backend
...; +
> + switch (cmd) {
> + case VFIO_DEVICE_GET_INFO:
> + {
> + struct vfio_device_info info;
> +
> + minsz = offsetofend(struct vfio_device_info, num_irqs);
> +
> + if (copy_from_user(&info, (void __user *)arg, minsz))
> + return -EFAULT;
> +
> + if (info.argsz < minsz)
> + return -EINVAL;
> +
> + ret = vdpa_get_device_info(mdev, &info);
> + if (ret)
> + return ret;
> +
> + if (copy_to_user((void __user *)arg, &info, minsz))
> + return -EFAULT;
> +
> + return 0;
> + }
> + case VFIO_DEVICE_GET_REGION...