Virtio-net header in TX direction is at (pages start)+ 4 bytes.
This causes misaligment exception when preparing the packet.
Even this is probably bug of ARM64 code generation, the simplest
solution is to make the virtio-net header to be always at +8 bytes.
Signed-off-by: Yuri Benditovich <[email protected]>
Upon surprise removal all the packets in use must be
collected and completed and further regular releases
disallowed even if the procedure will be called by
misunderstanding. Current commit adds the queue interface
that allows collecting used TX descriptors without using
GetBuf as these packets are not completed by the device.
Signed-off-by: Yuri Benditovich <[email protected]>
Currently when we recieve a suprise remove IRP from Windows we touch
the hardware of the device which is an invalid memory. This doesn't
cause BSOD in HCK/HLK tests as the device is still in qemu and memory is
still valid.
However, when performing hibernate on a given client and
then - while the client is off - we remove the virtio-net from the
command line and boot the client, a BSOD occurs as a result of this
illegal access to memory.
This commit solves this issue by registering the paths for notifications from
the state machine and preventing the driver from touching hardware upon a
suprise removal notification from the state machine.
Signed-off-by: Sameeh Jubran <[email protected]>
Clearing the variables is important as calling the Dotr twice on the
same object will cause BSODs as a result of a double free for example.
Signed-off-by: Sameeh Jubran <[email protected]>
This commit integrates wpp tracing into builds higher than Vista as
Windows Vista requires much more configuration for wpp integration,
however, this integration may be introduced in the future.
The old style of Dprintf is still preserved by this commit and can be
enabled by disabling WPP tracing. This can be accomplished by commenting
the following line in WPPTrace.h:
Signed-off-by: Sameeh Jubran <[email protected]>
The function has no effect and will be removed.
Also deleting the defunct "PublishIndices" config entry.
Signed-off-by: Ladi Prosek <[email protected]>
Move freeing of NB and NBL resources out of locked area.
Protect operations on waiting list by its own spinlock,
rather than spinlock of TX path instance.
Signed-off-by: Yuri Benditovich <[email protected]>
Preparation for further improvements: in case NB completion
and NBL completion are not executed under the same spinlock,
CNB object always must be destroyed first, only then signal
its completion to parent CNBL object.
Signed-off-by: Yuri Benditovich <[email protected]>
When CNBL object creates new CNB objects, it provides
itself as allocator for first CNB and external
allocator (CNB-dedicated pool of CParaNdisTX) for all following CNB.
Signed-off-by: Yuri Benditovich <[email protected]>
No functional changes. We just swap definitions of CNB and CNBL
to make further tracking of changes easier for review.
Due to swap we can't use inline CNB::SendComplete and we
change it to GetParentNBL()->NBComplete()
Signed-off-by: Yuri Benditovich <[email protected]>
Virtqueues are completely reinitialized on power-on so they should
also be completely shutdown/deleted on power-off. We still reuse
the same page-contiguous memory (CVirtQueue::m_SharedMemory) but
pool allocations (virtio 1.0) are freed and then reallocated.
This commit makes all driver API function follow the same
naming pattern:
* virtio_ prefix
* _get_ for getters without side-effects
* _set_ for idempotent setters
Legacy implementation of virtio_device_ops callbacks is renamed
(all functions now have the vio_legacy_ prefix) and reordered to
reflect virtio_device_ops. A few functions are moved to other
files.
It is hard to imagine a situation when seeing the queue name as
a string in the debugger would be of any particular use. There is
a simple and unique mapping from queue indices to queue names for
each virtio device.
This commit deletes the name field from queue data structures
along with all the supporting code.
This commit cleans up struct virtio_device by moving its
function pointers to virtio_config_ops (which is likely
not be the final name of the structure).
There's no reason why some of the functionality should be declared
in a separate header that all drivers need to include. This commit
adds a few virtio_ wrappers to completely abstract away the config
callbacks.
* We are not using the statistics from this handler any more
* On other hand the access to internal information in the queues caused
unnecessary locking
Signed-off-by: Yan Vugenfirer <[email protected]>
Part of the effort to simplify ndis56common.h. This is the first step in
removing kdebugprint.h from ndis56common.h, adding include where needed and
moving some functions implementation from class definitions files.
Signed-off-by: Yan Vugenfirer <[email protected]>
Static driver verifier can benefit from __fallthrough annotations in case
statement without 'break', passing control to the next case statement.
Signed-off-by: Joseph Hindin <[email protected]>
From 94dbe9c0c3a4d68c2efd35392e3b7dea21b2f7db Mon Sep 17 00:00:00 2001
From: Yan Vugenfirer <[email protected]>
Date: Wed, 13 Aug 2014 15:14:41 +0300
Subject: [PATCH] NetKVM: BZ#1121933 - check for VIRTIO_F_ANY_LAYOUT feature
before using optimized layour for data transfer.
This commit is a preparation for multiqueue implementation.
It itroduces changes driver's TX code structure the way
needed to allow creation of multiple independent transmit pathes.
Signed-off-by: Dmitry Fleytman <[email protected]>