Skip to content

Staging: hv: Driver cleanup

K. Y. Srinivasan lkml virtualization 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest117 patches 57 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/117Staging: hv: vmbus: VMBUS is an ACPI enumerated device, get rid of the PCI signaturedrivers/staging/hv/vmbus_drv.c+0 -130 replies
2/117Staging: hv: Replace struct hv_guid with the uuid type already defined in Linuxdrivers/staging/hv/blkvsc_drv.c drivers/staging/hv/channel.c drivers/staging/hv/channel_mgmt.c +6 more+129 -1350 replies
3/117Staging: hv: Add struct hv_vmbus_device_id to mod_devicetable.hinclude/linux/mod_devicetable.h+7 -010 replies
4/117Staging: hv: Add code to parse struct hv_vmbus_device_id tablescripts/mod/file2alias.c+25 -00 replies
5/117Staging: hv: vmbus: Introduce vmbus ID space in struct hv_driverdrivers/staging/hv/hyperv.h+2 -00 replies
6/117Staging: hv: blkvsc: Use the newly introduced vmbus ID in the blockvsc driverdrivers/staging/hv/blkvsc_drv.c+16 -01 reply
7/117Staging: hv: storvsc: Use the newly introduced vmbus ID in storvsc driverdrivers/staging/hv/storvsc_drv.c+16 -00 replies
8/117Staging: hv: netvsc: Use the newly introduced vmbus ID in netvsc driverdrivers/staging/hv/netvsc_drv.c+17 -00 replies
9/117Staging: hv: mousevsc: Use the newly introduced vmbus ID in mouse driverdrivers/staging/hv/hv_mouse.c+16 -00 replies
10/117Staging: hv: util: Make hv_utils a vmbus device driverdrivers/staging/hv/hv_util.c+27 -10 replies
11/117Staging: hv: util: Use the newly introduced vmbus ID in util driverdrivers/staging/hv/hv_util.c+38 -01 reply
12/117Staging: hv: blkvsc: Add the MODULE_DEVICE_TABLE() linedrivers/staging/hv/blkvsc_drv.c+1 -01 reply
13/117Staging: hv: storvsc: Add MODULE_DEVICE_TABLE() linedrivers/staging/hv/storvsc_drv.c+1 -00 replies
14/117Staging: hv: netvsc: Add the MODULE_DEVICE_TABLE() linedrivers/staging/hv/netvsc_drv.c+2 -00 replies
15/117Staging: hv: util: Add the MODULE_DEVICE_TABLE() linedrivers/staging/hv/hv_util.c+1 -00 replies
16/117Staging: hv: mouse: Add the MODULE_DEVICE_TABLE() linedrivers/staging/hv/hv_mouse.c+2 -00 replies
17/117Staging: hv: mouse: Do not auto-load the mouse driverdrivers/staging/hv/hv_mouse.c+4 -11 reply
18/117Staging: hv: vmbus: Cleanup vmbus_match()drivers/staging/hv/vmbus_drv.c+1 -20 replies
19/117Staging: hv: vmbus: Cleanup vmbus_uevent() codedrivers/staging/hv/vmbus_drv.c+10 -464 replies
20/117Staging: hv: vmbus: Support the notion of id tables in vmbus_match()drivers/staging/hv/vmbus_drv.c+16 -54 replies
21/117Staging: hv: vmbus: Get rid of an unnecessary include line in vmbus_drv.cdrivers/staging/hv/vmbus_drv.c+0 -10 replies
22/117Staging: hv: storvsc: Get rid of the DMI signaturedrivers/staging/hv/storvsc_drv.c+0 -220 replies
23/117Staging: hv: netvsc: Get rid of the PCI signaturedrivers/staging/hv/netvsc_drv.c+0 -80 replies
24/117Staging: hv: netvsc: Get rid of the DMI signature in netvsc_drv.cdrivers/staging/hv/netvsc_drv.c+0 -190 replies
25/117Staging: hv: util: Get rid of the DMI signature in hv_util.cdrivers/staging/hv/hv_util.c+0 -200 replies
26/117Staging: hv: util: Get rid of the PCI signature in hv_util.cdrivers/staging/hv/hv_util.c+0 -80 replies
27/117Staging: hv: blkvsc: Get rid of the dev_type guid from blkvsc_drv.cdrivers/staging/hv/blkvsc_drv.c+0 -91 reply
28/117Staging: hv: storvsc: Get rid of the device type guid from storvsc_drv.cdrivers/staging/hv/storvsc_drv.c+0 -110 replies
29/117Staging: hv: netvsc: Get rid of the dev_type guid from netvsc.cdrivers/staging/hv/netvsc.c+0 -100 replies
30/117Staging: hv: netvsc: Initialize the driver name directlydrivers/staging/hv/netvsc_drv.c+3 -10 replies
31/117Staging: hv: netvsc: Get rid of the driver name initialization in netvsc.cdrivers/staging/hv/netvsc.c+0 -51 reply
32/117Staging: hv: netvsc: Get rid of the empty function netvsc_initialize()drivers/staging/hv/hyperv_net.h drivers/staging/hv/netvsc.c drivers/staging/hv/netvsc_drv.c+0 -130 replies
33/117Staging: hv: vmbus: Get rid of the unused name field in struct hv_driverdrivers/staging/hv/hyperv.h+0 -20 replies
34/117Staging: hv: mouse: Get rid of the dev_type guid in hv_mouse.cdrivers/staging/hv/hv_mouse.c+0 -90 replies
35/117Staging: hv: vmbus: Introduce a function to map the dev_type guid to a namedrivers/staging/hv/channel_mgmt.c drivers/staging/hv/hyperv.h+37 -11 reply
36/117Staging: hv: vmbus: Make class_id attribute a human readable stringdrivers/staging/hv/vmbus_drv.c+2 -181 reply
37/117Staging: hv: vmbus: Get rid of the device_id attributedrivers/staging/hv/vmbus_drv.c+0 -201 reply
38/117Staging: hv: vmbus: Get rid of some unnecessary commentsdrivers/staging/hv/vmbus_drv.c+0 -20 replies
39/117Staging: hv: vmbus: Cleanup unnecessary comments in hv.cdrivers/staging/hv/hv.c+0 -80 replies
40/117Staging: hv: vmbus: Cleanup error handling in hv_init()drivers/staging/hv/hv.c+2 -21 reply
41/117Staging: hv: vmbus: Get rid of unnecessay comments in connection.cdrivers/staging/hv/connection.c+0 -20 replies
42/117Staging: hv: vmbus: Get rid of the function dump_gpadl_body()drivers/staging/hv/channel.c+0 -200 replies
43/117Staging: hv: vmbus: Get rid of the function dump_gpadl_header()drivers/staging/hv/channel.c+0 -280 replies
44/117Staging: hv: vmbus: Rename openMsg to open_msg in channel.cdrivers/staging/hv/channel.c+10 -100 replies
45/117Staging: hv: vmbus: Get rid of unnecessary comments in channel.cdrivers/staging/hv/channel.c+0 -40 replies
46/117Staging: hv: vmbus: Change the variable name openInfo to open_info in channel.cdrivers/staging/hv/channel.c+12 -120 replies
47/117Staging: hv: vmbus: Cleanup error values in ringbuffer.cdrivers/staging/hv/blkvsc_drv.c drivers/staging/hv/netvsc.c drivers/staging/hv/ring_buffer.c +1 more+6 -60 replies
48/117Staging: hv: vmbus: Cleanup the error return value in vmbus_recvpacket_raw()drivers/staging/hv/channel.c drivers/staging/hv/hv_mouse.c drivers/staging/hv/netvsc.c+3 -30 replies
49/117Staging: hv: netvsc: Get rid of an unnecessary print statement in netvsc_probe()drivers/staging/hv/netvsc_drv.c+0 -20 replies
50/117Staging: hv: vmbus: Retry vmbus_post_msg() before giving uparch/x86/include/asm/hyperv.h drivers/staging/hv/connection.c+18 -10 replies
51/117Staging: hv: storvsc: Cleanup error handling in storvsc_dev_add()drivers/staging/hv/storvsc.c+6 -60 replies
52/117Staging: hv: storvsc: Cleanup error handling in storvsc_channel_init()drivers/staging/hv/storvsc.c+1 -10 replies
53/117Staging: hv: storvsc: Cleanup error handling in storvsc_connect_to_vsp()drivers/staging/hv/storvsc.c+1 -10 replies
54/117Staging: hv: storvsc: Cleanup error handling in storvsc_do_io()drivers/staging/hv/storvsc.c+1 -10 replies
55/117Storage: hv: storvsc: Get rid of some unnecessary DPRINTs from storvsc.cdrivers/staging/hv/storvsc.c+0 -160 replies
56/117Staging: hv: storvsc: Fix/cleanup some dated comments in storvsc.cdrivers/staging/hv/storvsc.c+3 -50 replies
57/117Staging: hv: storvsc: Cleanup returned error code in storvsc_host_reset()drivers/staging/hv/storvsc_drv.c+1 -10 replies
58/117Staging: hv: storvsc: Cleanup error code returned in storvsc_probe()drivers/staging/hv/storvsc_drv.c+2 -20 replies
59/117Staging: hv: storvsc: Cleanup returned error code in storvsc_drv_init()drivers/staging/hv/storvsc_drv.c+1 -10 replies
60/117Staging: hv: netvsc: Cleanup the returned error code in netvsc_probe()drivers/staging/hv/netvsc_drv.c+1 -10 replies
61/117Staging: hv: netvsc: Cleanup error return codes in netvsc_destroy_recv_buf()drivers/staging/hv/netvsc.c+2 -20 replies
62/117Staging: hv: netvsc: Cleanup error return values in netvsc_init_recv_buf()drivers/staging/hv/netvsc.c+5 -50 replies
63/117Staging: hv: netvsc: Cleanup error returns in netvsc_connect_vsp()drivers/staging/hv/netvsc.c+4 -60 replies
64/117Staging: hv: netvsc: Cleanup error return values in netvsc_send()drivers/staging/hv/netvsc.c+2 -20 replies
65/117Staging: hv: netvsc: Cleanup error return codes in netvsc_device_add()drivers/staging/hv/netvsc.c+1 -30 replies
66/117Staging: hv: netvsc: Cleanup error codes in rndis_filter_receive()drivers/staging/hv/rndis_filter.c+2 -20 replies
67/117Staging: hv: netvsc: Cleanup error code in rndis_filter_query_device()drivers/staging/hv/rndis_filter.c+1 -10 replies
68/117Staging: hv: netvsc: Cleanup error return values in rndis_filter_set_packet_filter()drivers/staging/hv/rndis_filter.c+1 -40 replies
69/117Staging: hv: netvsc: Cleanup error returns in rndis_filter_init_device()drivers/staging/hv/rndis_filter.c+2 -20 replies
70/117Staging: hv: netvsc: Cleanup error code in rndis_filter_device_add()drivers/staging/hv/rndis_filter.c+1 -10 replies
71/117Staging: hv: mouse: Change the jump label Cleanup to cleanupdrivers/staging/hv/hv_mouse.c+11 -110 replies
72/117Staging: hv: mouse: Get rid of the unused PCI signaturedrivers/staging/hv/hv_mouse.c+0 -210 replies
73/117Staging: hv: netvsc: Change the jump label Cleanup to cleanupdrivers/staging/hv/rndis_filter.c+14 -140 replies
74/117Staging: hv: netvsc: Change the jump label Exit to exitdrivers/staging/hv/rndis_filter.c+2 -20 replies
75/117Staging: hv: storvsc: Inline free_stor_device()drivers/staging/hv/storvsc.c+2 -60 replies
76/117Staging: hv: storvsc: Do not aquire an unnecessary reference on stor_devicedrivers/staging/hv/storvsc.c+1 -40 replies
77/117Staging: hv: storvsc: Rename must_get_stor_device()drivers/staging/hv/storvsc.c+3 -30 replies
78/117Staging: hv: storvsc: Rename get_stor_device()drivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc.c drivers/staging/hv/storvsc_drv.c+7 -60 replies
79/117Staging: hv: storvsc: Cleanup alloc_stor_device()drivers/staging/hv/storvsc.c+1 -10 replies
80/117Staging: hv: storvsc: Introduce state to manage the lifecycle of stor devicedrivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc.c+3 -20 replies
81/117Staging: hv: vmbus: Introduce a lock to protect the ext field in hv_devicedrivers/staging/hv/hyperv.h drivers/staging/hv/vmbus_drv.c+4 -04 replies
82/117Staging: hv: storvsc: Use the newly introduced lock in accessing ext fielddrivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc.c+12 -00 replies
83/117Staging: hv: storvsc: Prevent outgoing traffic when stor dev is destroyeddrivers/staging/hv/hyperv_storage.h+2 -10 replies
84/117Staging: hv: storvsc: Get rid of release_stor_device() by inlining the codedrivers/staging/hv/storvsc.c+7 -160 replies
85/117Staging: hv: storvsc: Get rid of final_release_stor_device() by inlining codedrivers/staging/hv/storvsc.c+5 -200 replies
86/117Staging: hv: storvsc: Leverage the spinlock to manage ref_cntdrivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc.c+9 -97 replies
87/117Staging: hv: storvsc: Further cleanup reference counting of stor_devicedrivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc.c+14 -110 replies
88/117Staging: hv: netvsc: Inline the code for free_net_device()drivers/staging/hv/netvsc.c+2 -102 replies
89/117Staging: hv: netvsc: Cleanup alloc_net_device()drivers/staging/hv/netvsc.c+1 -10 replies
90/117Staging: hv: netvsc: Introduce state to manage the lifecycle of net devicedrivers/staging/hv/hyperv_net.h drivers/staging/hv/netvsc.c+4 -00 replies
91/117Staging: hv: netvsc: Use the newly introduced lock in accessing ext fielddrivers/staging/hv/netvsc.c+30 -30 replies
92/117Staging: hv: netvsc: Prevent outgoing traffic when netvsc dev is destroyeddrivers/staging/hv/netvsc.c+2 -10 replies
93/117Staging: hv: netvsc: Get rid of release_outbound_net_device() by inlining the codedrivers/staging/hv/netvsc.c+17 -280 replies
94/117Staging: hv: netvsc: Get rid of release_inbound_net_device() by inlining the codedrivers/staging/hv/netvsc.c+4 -280 replies
95/117Staging: hv: netvsc: Leverage the spinlock to manage refcntdrivers/staging/hv/hyperv_net.h drivers/staging/hv/netvsc.c+10 -100 replies
96/117Staging: hv: netvsc: Further cleanup reference counting of netvsc_devicedrivers/staging/hv/netvsc.c+18 -90 replies
97/117Staging: hv: storvsc: Add code to handle IDE devices using the storvsc driverdrivers/staging/hv/storvsc_drv.c+51 -115 replies
98/117Staging: hv: storvsc: Handle IDE devices using the storvsc driverdrivers/staging/hv/Kconfig drivers/staging/hv/Makefile drivers/staging/hv/storvsc_drv.c+7 -91 reply
99/117Staging: hv: storvsc: Optimize bounce buffer handling for the "write" casedrivers/staging/hv/storvsc_drv.c+6 -60 replies
100/117Staging: hv: storvsc: Optimize the bounce buffer handling in the "read" casedrivers/staging/hv/storvsc_drv.c+4 -60 replies
101/117Staging: hv: storvsc: Include storvsc.c in storvsc_drv.cdrivers/staging/hv/Makefile drivers/staging/hv/storvsc.c drivers/staging/hv/storvsc_drv.c+528 -5270 replies
102/117Staging: hv: storvsc: Cleanup storvsc_drv.c after adding the contents of storvsc.cdrivers/staging/hv/storvsc_drv.c+7 -1000 replies
103/117Staging: hv: storvsc: Add the contents of hyperv_storage.h to storvsc_drv.cdrivers/staging/hv/hyperv_storage.h drivers/staging/hv/storvsc_drv.c+326 -3420 replies
104/117Staging: hv: storvsc: Cleanup storvsc_drv.c after adding the contents of hyperv_storage.hdrivers/staging/hv/storvsc_drv.c+1 -290 replies
105/117Staging: hv: storvsc: Make some non static functions, static functionsdrivers/staging/hv/storvsc_drv.c+3 -30 replies
106/117Staging: hv: storvsc: Fixup srb and scsi status for INQUIRY and MODE_SENSEdrivers/staging/hv/storvsc_drv.c+17 -00 replies
107/117Staging: hv: storvsc: Fix a typodrivers/staging/hv/storvsc_drv.c+3 -30 replies
108/117Staging: hv: storvsc: In case of scsi errors offline the devicedrivers/staging/hv/storvsc_drv.c+9 -10 replies
109/117Staging: hv: storvsc: No need to copy from bounce buffer in case of a failuredrivers/staging/hv/storvsc_drv.c+2 -100 replies
110/117Staging: hv: vmbus: Change the signature of vmbus_child_driver_register()drivers/staging/hv/hv_mouse.c drivers/staging/hv/hv_util.c drivers/staging/hv/hyperv.h +3 more+7 -60 replies
111/117Staging: hv: vmbus: Change the signature of vmbus_child_driver_unregister()drivers/staging/hv/hv_mouse.c drivers/staging/hv/hv_util.c drivers/staging/hv/hyperv.h +3 more+9 -80 replies
112/117Staging: hv: util: Forcefully shutdown when shutdown is requesteddrivers/staging/hv/hv_util.c+1 -10 replies
113/117Staging: hv: util: Adjust guest time in a process contextdrivers/staging/hv/hv_util.c+28 -20 replies
114/117Staging: hv: vmbus: Check before invoking the channel callbackdrivers/staging/hv/connection.c+1 -10 replies
115/117Staging: hv: vmbus: Properly deal with de-registering channel callbackdrivers/staging/hv/channel.c drivers/staging/hv/connection.c+8 -150 replies
116/117Staging: hv: vmbus: Add code to display modalias attributedrivers/staging/hv/vmbus_drv.c+9 -00 replies
117/117Staging: hv: blkvsc: Get rid of blkvsc_drv.c as this code is not useddrivers/staging/hv/blkvsc_drv.c+0 -10340 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0000/0117] Staging: hv: Driver cleanup

Further cleanup of the hv drivers. Back in June I had sent two patch sets to address these issues. I have addressed the comments I got from the community on my earlier patches here:

1) Implement code for autoloading the vmbus drivers without using PCI or DMI signatures. I have implemented this based on Greg's feedback on my earlier implementation.

2) Cleanup error handling across the board and use standard Linux error codes.

3) General cleanup

4) Some bug fixes.

5) Cleanup the reference counting mess for both stor and net devices.

6) Handle all block devices using the storvsc driver. I have modified the implementation here based on Christoph's feedback on my earlier implementation.

7) Accomodate some host side scsi emulation bugs.

8) In case of scsi errors off-line the device.

This patch-set further reduces the size of Hyper-V drivers - the code is about 10% smaller. This reduction is mainly because we have eliminated the blkvsc driver.

Regards,

K. Y