[dpdk-dev] [PATCH v6 06/13] virtio: read virtio_net_config correctly

2015-10-20 Thread Yuanhan Liu
On Tue, Oct 20, 2015 at 09:27:37AM +0200, Thomas Monjalon wrote: > 2015-10-20 15:23, Yuanhan Liu: > > On Tue, Oct 20, 2015 at 09:07:49AM +0200, Thomas Monjalon wrote: > > > 2015-10-09 13:46, Yuanhan Liu: > > > > From: Changchun Ouyang > > > > > > > > The old code adjusts the config bytes we want

[dpdk-dev] [PATCH v6 06/13] virtio: read virtio_net_config correctly

2015-10-20 Thread Yuanhan Liu
On Tue, Oct 20, 2015 at 09:07:49AM +0200, Thomas Monjalon wrote: > 2015-10-09 13:46, Yuanhan Liu: > > From: Changchun Ouyang > > > > The old code adjusts the config bytes we want to read depending on > > what kind of features we have, but we later cast the entire buf we > > read with "struct virt

[dpdk-dev] [PATCH v6 06/13] virtio: read virtio_net_config correctly

2015-10-20 Thread Thomas Monjalon
2015-10-20 15:23, Yuanhan Liu: > On Tue, Oct 20, 2015 at 09:07:49AM +0200, Thomas Monjalon wrote: > > 2015-10-09 13:46, Yuanhan Liu: > > > From: Changchun Ouyang > > > > > > The old code adjusts the config bytes we want to read depending on > > > what kind of features we have, but we later cast t

[dpdk-dev] [PATCH v6 06/13] virtio: read virtio_net_config correctly

2015-10-20 Thread Thomas Monjalon
2015-10-09 13:46, Yuanhan Liu: > From: Changchun Ouyang > > The old code adjusts the config bytes we want to read depending on > what kind of features we have, but we later cast the entire buf we > read with "struct virtio_net_config", which is obviously wrong. When describing a bug, it is impor

[dpdk-dev] [PATCH v6 06/13] virtio: read virtio_net_config correctly

2015-10-09 Thread Yuanhan Liu
From: Changchun Ouyang The old code adjusts the config bytes we want to read depending on what kind of features we have, but we later cast the entire buf we read with "struct virtio_net_config", which is obviously wrong. The right way to go is to read related config bytes when corresponding feat