Commit Graph

18 Commits

Author SHA1 Message Date
Sepherosa Ziehau
d64ec3506d hyperv/vmbus: Redefine channel packet.
The channel packet header will be shared w/ PRP (physical region page)
list channel packet and SG (scatter gather) list channel packet.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D7155
2016-07-15 06:16:39 +00:00
Sepherosa Ziehau
f15c787ae7 hyperv/vmbus: Switch to vmbus channel message macros
Prepare for more cleanup.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D7094
2016-07-14 05:49:14 +00:00
Sepherosa Ziehau
e979461031 hyperv/vmbus: Move channel offer message definition to vmbus_reg.h
- Avoid bit fields.
- Avoid unnecessary indirection.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D7093
2016-07-14 05:33:33 +00:00
Sepherosa Ziehau
e2d8dbe438 hyperv/vmbus: Cleanup channel rescind
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D7090
2016-07-13 09:44:24 +00:00
Sepherosa Ziehau
8c8cf3f2e2 hyperv/vmbus: Reorganize MNF event sending.
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D7088
2016-07-13 09:28:46 +00:00
Sepherosa Ziehau
99e315276a hyperv/vmbus: Fix sub-channel re-open support.
For multi-channel devices, once the primary channel is closed,
a set of 'rescind' messages for sub-channels will be delivered
by Hypervisor.  Sub-channel MUST be freed according to these
'rescind' messages; directly re-openning sub-channels in the
same fashion as the primary channel's re-opening does NOT work
at all.

After the primary channel is re-opened, requested # of sub-
channels will be delivered though 'channel offer' messages, and
this set of newly offered channels can be opened along side with
the primary channel.

This unbreaks the MTU setting for hn(4), which requires re-
openning all existsing channels upon MTU change.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6978
2016-07-12 08:38:03 +00:00
Sepherosa Ziehau
f24517f037 hyperv/vmbus: Minor renaming
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6919
2016-07-12 05:55:11 +00:00
Sepherosa Ziehau
e90ec741f9 hyperv/vmbus: Use post message Hypercall APIs for GPA disconnect
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6912
2016-07-12 03:32:07 +00:00
Sepherosa Ziehau
e9bd7c4417 hyperv/vmbus: Use post message Hypercall APIs for channel close
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6906
2016-07-12 03:25:36 +00:00
Sepherosa Ziehau
2bf62f9a89 hyperv/vmbus: Use post message Hypercall APIs for GPADL connect.
This also fixes memory leakge if sub-connect messages are needed.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6878
2016-07-12 03:19:40 +00:00
Sepherosa Ziehau
fc1208d658 hyperv/vmbus: Use post message Hypercall APIs for channel open
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6876
2016-07-12 03:09:10 +00:00
Sepherosa Ziehau
1ecb24660f hyperv/vmbus: Use post message Hypercall APIs for unload
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6861
2016-07-11 07:28:15 +00:00
Sepherosa Ziehau
c1cc5bdfe8 hyperv/vmbus: Use post message Hypercall APIs for channel request
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6831
2016-07-11 06:11:24 +00:00
Sepherosa Ziehau
236764b1c2 hyperv/vmbus: Implement a new set of APIs for post message Hypercall
And use this new APIs for Initial Contact post message Hypercall.
More post message Hypercalls will be converted.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6830
2016-07-11 04:52:11 +00:00
Sepherosa Ziehau
51a9a000ee hyperv/vmbus: Change tx_evtflags type to u_long to match vmbus_evtflags
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6745
2016-06-08 07:47:21 +00:00
Sepherosa Ziehau
fa4828b0ab hyperv/vmbus: Define type for channel messages.
And fix message processing; only channel messages are supported.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6706
2016-06-06 06:18:18 +00:00
Sepherosa Ziehau
417afb00cb hyperv/vmbus: Redefine event flags.
- Nuke unnecessary union.
- Avoid convoluted macro indirection.

MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6671
2016-06-01 06:51:44 +00:00
Sepherosa Ziehau
3ae6d31281 hyperv/vmbus: Redefine SynIC message.
- Avoid unnecessary indirection.
- Avoid bit fields.
- Use __packed.

Reviewed by:	Jun Su <junsu microsoft com>
MFC after:	1 week
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D6636
2016-05-31 05:18:55 +00:00