search for: macvtap_is_little_endian

Displaying 20 results from an estimated 49 matches for "macvtap_is_little_endian".

2015 Apr 23
0
[PATCH v5 3/8] macvtap: introduce macvtap_is_little_endian() helper
...- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c index 27ecc5c..a2f2958 100644 --- a/drivers/net/macvtap.c +++ b/drivers/net/macvtap.c @@ -49,14 +49,19 @@ struct macvtap_queue { #define MACVTAP_VNET_LE 0x80000000 +static inline bool macvtap_is_little_endian(struct macvtap_queue *q) +{ + return q->flags & MACVTAP_VNET_LE; +} + static inline u16 macvtap16_to_cpu(struct macvtap_queue *q, __virtio16 val) { - return __virtio16_to_cpu(q->flags & MACVTAP_VNET_LE, val); + return __virtio16_to_cpu(macvtap_is_little_endian(q), val); } static...
2015 Apr 24
0
[PATCH v6 3/8] macvtap: introduce macvtap_is_little_endian() helper
...- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c index 27ecc5c..a2f2958 100644 --- a/drivers/net/macvtap.c +++ b/drivers/net/macvtap.c @@ -49,14 +49,19 @@ struct macvtap_queue { #define MACVTAP_VNET_LE 0x80000000 +static inline bool macvtap_is_little_endian(struct macvtap_queue *q) +{ + return q->flags & MACVTAP_VNET_LE; +} + static inline u16 macvtap16_to_cpu(struct macvtap_queue *q, __virtio16 val) { - return __virtio16_to_cpu(q->flags & MACVTAP_VNET_LE, val); + return __virtio16_to_cpu(macvtap_is_little_endian(q), val); } static...
2015 Jun 01
1
[PATCH v6 3/8] macvtap: introduce macvtap_is_little_endian() helper
...> > diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c > index 27ecc5c..a2f2958 100644 > --- a/drivers/net/macvtap.c > +++ b/drivers/net/macvtap.c > @@ -49,14 +49,19 @@ struct macvtap_queue { > > #define MACVTAP_VNET_LE 0x80000000 > > +static inline bool macvtap_is_little_endian(struct macvtap_queue *q) > +{ > + return q->flags & MACVTAP_VNET_LE; > +} > + > static inline u16 macvtap16_to_cpu(struct macvtap_queue *q, __virtio16 val) > { > - return __virtio16_to_cpu(q->flags & MACVTAP_VNET_LE, val); > + return __virtio16_to_cpu(macvtap...
2015 Jun 01
1
[PATCH v6 3/8] macvtap: introduce macvtap_is_little_endian() helper
...> > diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c > index 27ecc5c..a2f2958 100644 > --- a/drivers/net/macvtap.c > +++ b/drivers/net/macvtap.c > @@ -49,14 +49,19 @@ struct macvtap_queue { > > #define MACVTAP_VNET_LE 0x80000000 > > +static inline bool macvtap_is_little_endian(struct macvtap_queue *q) > +{ > + return q->flags & MACVTAP_VNET_LE; > +} > + > static inline u16 macvtap16_to_cpu(struct macvtap_queue *q, __virtio16 val) > { > - return __virtio16_to_cpu(q->flags & MACVTAP_VNET_LE, val); > + return __virtio16_to_cpu(macvtap...
2017 Jan 20
4
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...--git a/drivers/net/macvtap.c b/drivers/net/macvtap.c index 5c26653..4026185 100644 --- a/drivers/net/macvtap.c +++ b/drivers/net/macvtap.c @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, return -EINVAL; if (virtio_net_hdr_from_skb(skb, &vnet_hdr, - macvtap_is_little_endian(q))) + macvtap_is_little_endian(q), true)) BUG(); if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != diff --git a/drivers/net/tun.c b/drivers/net/tun.c index cd8e02c..2cd10b2 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@ -1360,7 +1360,7 @@ static ssize_t tun_put...
2017 Jan 20
4
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...--git a/drivers/net/macvtap.c b/drivers/net/macvtap.c index 5c26653..4026185 100644 --- a/drivers/net/macvtap.c +++ b/drivers/net/macvtap.c @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, return -EINVAL; if (virtio_net_hdr_from_skb(skb, &vnet_hdr, - macvtap_is_little_endian(q))) + macvtap_is_little_endian(q), true)) BUG(); if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != diff --git a/drivers/net/tun.c b/drivers/net/tun.c index cd8e02c..2cd10b2 100644 --- a/drivers/net/tun.c +++ b/drivers/net/tun.c @@ -1360,7 +1360,7 @@ static ssize_t tun_put...
2017 Jan 22
2
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...3..4026185 100644 >> --- a/drivers/net/macvtap.c >> +++ b/drivers/net/macvtap.c >> @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, >> return -EINVAL; >> >> if (virtio_net_hdr_from_skb(skb, &vnet_hdr, >> - macvtap_is_little_endian(q))) >> + macvtap_is_little_endian(q), true)) >> BUG(); >> >> if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != >> diff --git a/drivers/net/tun.c b/drivers/net/tun.c >> index cd8e02c..2cd10b2 100644 >> --- a/drivers/net/tun.c &g...
2017 Jan 22
2
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...3..4026185 100644 >> --- a/drivers/net/macvtap.c >> +++ b/drivers/net/macvtap.c >> @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, >> return -EINVAL; >> >> if (virtio_net_hdr_from_skb(skb, &vnet_hdr, >> - macvtap_is_little_endian(q))) >> + macvtap_is_little_endian(q), true)) >> BUG(); >> >> if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != >> diff --git a/drivers/net/tun.c b/drivers/net/tun.c >> index cd8e02c..2cd10b2 100644 >> --- a/drivers/net/tun.c &g...
2015 May 12
2
[PATCH v6 0/8] vhost: support for cross endian guests
...to do... Do you still plan to apply shortly ? Would you also have time to comment the QEMU part ? Thanks. -- Greg > > Greg Kurz (8): > > virtio: introduce virtio_is_little_endian() helper > > tun: add tun_is_little_endian() helper > > macvtap: introduce macvtap_is_little_endian() helper > > vringh: introduce vringh_is_little_endian() helper > > vhost: introduce vhost_is_little_endian() helper > > virtio: add explicit big-endian support to memory accessors > > vhost: cross-endian support for legacy devices > > mac...
2015 May 12
2
[PATCH v6 0/8] vhost: support for cross endian guests
...to do... Do you still plan to apply shortly ? Would you also have time to comment the QEMU part ? Thanks. -- Greg > > Greg Kurz (8): > > virtio: introduce virtio_is_little_endian() helper > > tun: add tun_is_little_endian() helper > > macvtap: introduce macvtap_is_little_endian() helper > > vringh: introduce vringh_is_little_endian() helper > > vhost: introduce vhost_is_little_endian() helper > > virtio: add explicit big-endian support to memory accessors > > vhost: cross-endian support for legacy devices > > mac...
2015 Apr 24
27
[PATCH v6 0/8] vhost: support for cross endian guests
Only cosmetic and documentation changes since v5. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: cross-endian support for legacy devices macvtap/tun: cross-endian support for little-endian h...
2015 Apr 24
27
[PATCH v6 0/8] vhost: support for cross endian guests
Only cosmetic and documentation changes since v5. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: cross-endian support for legacy devices macvtap/tun: cross-endian support for little-endian h...
2017 Jan 22
0
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...gt; > --- a/drivers/net/macvtap.c > > > +++ b/drivers/net/macvtap.c > > > @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, > > > return -EINVAL; > > > if (virtio_net_hdr_from_skb(skb, &vnet_hdr, > > > - macvtap_is_little_endian(q))) > > > + macvtap_is_little_endian(q), true)) > > > BUG(); > > > if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != > > > diff --git a/drivers/net/tun.c b/drivers/net/tun.c > > > index cd8e02c..2cd10b2 100644 > > > --...
2015 Apr 10
16
[PATCH v4 0/8] vhost: support for cross endian guests
...ries is enough to have vhost_net working flawlessly. I could succesfully reboot guests from ppc64 to ppc64le and vice-versa on ppc64 and ppc64le hosts. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: feature to set the vring endianness macvtap/tun: add VNET_BE flag drivers/net/Kconfig...
2015 Apr 10
16
[PATCH v4 0/8] vhost: support for cross endian guests
...ries is enough to have vhost_net working flawlessly. I could succesfully reboot guests from ppc64 to ppc64le and vice-versa on ppc64 and ppc64le hosts. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: feature to set the vring endianness macvtap/tun: add VNET_BE flag drivers/net/Kconfig...
2015 Apr 23
16
[PATCH v5 0/8] vhost: support for cross endian guests
...My experimental QEMU tree is here: https://github.com/gkurz/qemu.git vhost/cross-endian I'd be glad if this series could make it to 4.1. Cheers. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: cross-endian support for legacy devices macvtap/tun: cross-endian support for little-endian h...
2015 Apr 23
16
[PATCH v5 0/8] vhost: support for cross endian guests
...My experimental QEMU tree is here: https://github.com/gkurz/qemu.git vhost/cross-endian I'd be glad if this series could make it to 4.1. Cheers. --- Greg Kurz (8): virtio: introduce virtio_is_little_endian() helper tun: add tun_is_little_endian() helper macvtap: introduce macvtap_is_little_endian() helper vringh: introduce vringh_is_little_endian() helper vhost: introduce vhost_is_little_endian() helper virtio: add explicit big-endian support to memory accessors vhost: cross-endian support for legacy devices macvtap/tun: cross-endian support for little-endian h...
2017 Jan 20
0
[PATCH net] virtio-net: restore VIRTIO_HDR_F_DATA_VALID on receiving
...net/macvtap.c > index 5c26653..4026185 100644 > --- a/drivers/net/macvtap.c > +++ b/drivers/net/macvtap.c > @@ -825,7 +825,7 @@ static ssize_t macvtap_put_user(struct macvtap_queue *q, > return -EINVAL; > > if (virtio_net_hdr_from_skb(skb, &vnet_hdr, > - macvtap_is_little_endian(q))) > + macvtap_is_little_endian(q), true)) > BUG(); > > if (copy_to_iter(&vnet_hdr, sizeof(vnet_hdr), iter) != > diff --git a/drivers/net/tun.c b/drivers/net/tun.c > index cd8e02c..2cd10b2 100644 > --- a/drivers/net/tun.c > +++ b/drivers/net/tun.c >...
2015 Apr 23
2
[PATCH v5 6/8] virtio: add explicit big-endian support to memory accessors
...files changed, 28 insertions(+), 15 deletions(-) > > diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c > index a2f2958..6cf6b3e 100644 > --- a/drivers/net/macvtap.c > +++ b/drivers/net/macvtap.c > @@ -51,7 +51,10 @@ struct macvtap_queue { > > static inline bool macvtap_is_little_endian(struct macvtap_queue *q) > { > - return q->flags & MACVTAP_VNET_LE; > + if (q->flags & MACVTAP_VNET_LE) > + return true; > + else > + return virtio_legacy_is_little_endian(); simply: return (q->flags & MACVTAP_VNET_LE) || virtio_legacy_is_little_...
2015 Apr 23
2
[PATCH v5 6/8] virtio: add explicit big-endian support to memory accessors
...files changed, 28 insertions(+), 15 deletions(-) > > diff --git a/drivers/net/macvtap.c b/drivers/net/macvtap.c > index a2f2958..6cf6b3e 100644 > --- a/drivers/net/macvtap.c > +++ b/drivers/net/macvtap.c > @@ -51,7 +51,10 @@ struct macvtap_queue { > > static inline bool macvtap_is_little_endian(struct macvtap_queue *q) > { > - return q->flags & MACVTAP_VNET_LE; > + if (q->flags & MACVTAP_VNET_LE) > + return true; > + else > + return virtio_legacy_is_little_endian(); simply: return (q->flags & MACVTAP_VNET_LE) || virtio_legacy_is_little_...