summaryrefslogtreecommitdiff
path: root/drivers/staging/hv/RndisFilter.c
AgeCommit message (Collapse)AuthorFilesLines
2009-09-15Staging: hv: remove use of internal list routines in RndisFilterBill Pemberton1-11/+6
The hv driver has it's own linked list routines. This removes them from RndisFilter.c Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove function pointer typedefs from NetVscApi.hGreg Kroah-Hartman1-1/+1
function pointer typedefs are allowed in the kernel, but only if they make sense, which they really do not here, as they are not passed around with any kind of frequency. So just spell them all out, it makes the code smaller and easier to understand overall. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: rename struct NETVSC_DEVICEGreg Kroah-Hartman1-6/+6
The Linux kernel doesn't have all caps structures, we don't like to shout at our programmers, it makes them grumpy. Instead, we like to sooth them with small, rounded letters, which puts them in a nice, compliant mood, and makes them more productive and happier, allowing them more fufilling lives overall. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: coding style cleanup for RndisFilter.cGreg Kroah-Hartman1-400/+285
It's much better now. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove typedefs from RndisFilter.cGreg Kroah-Hartman1-86/+65
Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: move NetVscApi.hGreg Kroah-Hartman1-1/+1
Move it out of the include subdirectory. No code changes here, just file movements. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: move logging.hGreg Kroah-Hartman1-1/+1
Move it out of the include subdirectory. No code changes here, just file movements. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: fix up typedefs in NetVscApi.hGreg Kroah-Hartman1-6/+3
It's now all clean from a coding style standpoint. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: typedef removal for VmbusApi.hGreg Kroah-Hartman1-1/+1
The function pointers still have ugly names, but the structures are now cleaned up. Note, a comment was added where the driver structure is pointing at a problem that needs to be fixed up later in the code. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: rndis.h: typedef removal, part 1Greg Kroah-Hartman1-69/+50
This removes about half of the typedefs in rndis.h Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: move osd.hGreg Kroah-Hartman1-1/+1
This moves osd.h out of the include/ subdirectory. No code changes are made here. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: osd: add osd_ prefix to global functionsGreg Kroah-Hartman1-5/+5
Put a "osd_" prefix on the osd.c functions in order for us to play nicer in the kernel namespace. Cc: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: osd: remove physical address wrapper functionsGreg Kroah-Hartman1-2/+3
Use the real functions the kernel provides, so that people can see what is actually going on in the code easier. Cc: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove wrapper functions around kmap_Bill Pemberton1-4/+6
Remove PageMapVirtualAddress() and PageUnmapVirtualAddress() which were wrappers around kmap_atomic() and kunmap_atomic() Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove wrapper functions for atomic operationsBill Pemberton1-3/+3
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove WaitEventClose()Bill Pemberton1-1/+1
All WaitEventClose() close did was call kfree(), so get rid of it and replace it with a call to kfree() Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: fix sparse static warningsGreg Kroah-Hartman1-2/+2
This fixes up all of the sparse warnings about static functions. Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: Remove typedef NETVSC_PACKET and PNETVSC_PACKETNicolas Palix1-8/+8
typedef NETVSC_PACKET and PNETVSC_PACKET are removed and their usages are replace by the use of struct hv_netvsc_packet and struct hv_netvsc_packet * respectively. Here is the semantic patch generated to perform this transformation: (http://coccinelle.lip6.fr/) //<smpl> @rm_NETVSC_PACKET@ @@ -typedef struct _NETVSC_PACKET +struct hv_netvsc_packet {...} -NETVSC_PACKET ; @rm_PNETVSC_PACKET@ @@ -typedef struct _NETVSC_PACKET *PNETVSC_PACKET; +struct hv_netvsc_packet; @fixtypedef_NETVSC_PACKET@ typedef NETVSC_PACKET; @@ -NETVSC_PACKET +struct hv_netvsc_packet @fixstruct__NETVSC_PACKET@ @@ struct -_NETVSC_PACKET +hv_netvsc_packet @fixtypedef_PNETVSC_PACKET@ typedef PNETVSC_PACKET; @@ -PNETVSC_PACKET +struct hv_netvsc_packet* //</smpl> Signed-off-by: Nicolas Palix <npalix@diku.dk> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: Remove typedef DRIVER_OBJECT and PDRIVER_OBJECTNicolas Palix1-2/+2
typedef DRIVER_OBJECT and PDRIVER_OBJECT are removed and their usages are replace by the use of struct hv_driver and struct hv_driver * respectively. Here is the semantic patch generated to perform this transformation: (http://coccinelle.lip6.fr/) //<smpl> @rm_DRIVER_OBJECT@ @@ -typedef struct _DRIVER_OBJECT +struct hv_driver {...} -DRIVER_OBJECT ; @rm_PDRIVER_OBJECT@ @@ -typedef struct _DRIVER_OBJECT *PDRIVER_OBJECT; +struct hv_driver; @fixtypedef_DRIVER_OBJECT@ typedef DRIVER_OBJECT; @@ -DRIVER_OBJECT +struct hv_driver @fixstruct__DRIVER_OBJECT@ @@ struct -_DRIVER_OBJECT +hv_driver @fixtypedef_PDRIVER_OBJECT@ typedef PDRIVER_OBJECT; @@ -PDRIVER_OBJECT +struct hv_driver* //</smpl> Signed-off-by: Nicolas Palix <npalix@diku.dk> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: properly fix the printk() warningsGreg Kroah-Hartman1-3/+3
This fixes the printk() warnings on all platforms now (x86-64 and i386). Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove more printk() warningsGreg Kroah-Hartman1-3/+3
This should fix up the rest of the printk() warnings on an i386 build Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove WAITEVENT typedefBill Pemberton1-1/+1
Remove the WAITEVENT typedef and also replace HANDLE types that use the WaitEvent calls with struct osd_waitevent. Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: Transform PDEVICE_OBJECT and DEVICE_OBJECT typedefs into their ↵Nicolas Palix1-12/+12
corresponding structs Remove typedef DEVICE_OBJECT and use a struct named hv_device instead. Remove typedef PDEVICE_OBJECT which aliases a pointer and use struct hv_device * instead. Here is the semantic patch to perform this transformation: (http://coccinelle.lip6.fr/) //<smpl> @rm_PDEVICE_OBJECT@ @@ -typedef struct _DEVICE_OBJECT *PDEVICE_OBJECT; @rm_DEVICE_OBJECT@ @@ -typedef struct _DEVICE_OBJECT +struct hv_device {...} -DEVICE_OBJECT ; @fixtypedef_PDEVICE_OBJECT@ typedef PDEVICE_OBJECT; @@ -PDEVICE_OBJECT +struct hv_device* @fixtypedef_DEVICE_OBJECT@ typedef DEVICE_OBJECT; @@ -DEVICE_OBJECT +struct hv_device @fixstruct__DEVICE_OBJECT@ @@ struct -_DEVICE_OBJECT +hv_device //</smpl> Signed-off-by: Nicolas Palix <npalix@diku.dk> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove NETVSC_DEVICE typedefBill Pemberton1-7/+7
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: RndisFilter.c: fix print formattingBill Pemberton1-3/+3
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: Remove C99 commentsBill Pemberton1-68/+68
Remove C99 // comments with traditional /* */ comments Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: Remove compatibility ifdefryMoritz Muehlenhoff1-2/+0
Signed-off-by: Moritz Muehlenhoff <jmm@debian.org> Cc: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: make Device->RequestLock a real spinlockGreg Kroah-Hartman1-14/+12
Don't use the wrapper functions for this lock, make it a real lock so that we know what is going on. I don't think we really want to be doing a irqsave for this code, but I left it alone to preserve the original codepath. It should be reviewed later. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: osd: remove MemFree wrapperGreg Kroah-Hartman1-4/+4
Use the "real" kfree call instead of a wrapper function. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: osd: remove MemAllocZeroed wrapperGreg Kroah-Hartman1-2/+2
Use the "real" kzalloc call instead of a wrapper function. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: osd: remove MemAlloc wrapperGreg Kroah-Hartman1-1/+0
Use the "real" kmalloc call instead of a wrapper function. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove TRUE, FALSE, and NULL usageGreg Kroah-Hartman1-5/+5
Don't define things that are either already provided (like NULL), or you shouldn't use (like TRUE and FALSE). Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove PAGE_SIZE and PAGE_SHIFT and __builtin functionsGreg Kroah-Hartman1-0/+1
The kernel provides all of this, and actually gets it correct, so don't try to redefine these types of things. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove BOOL and BOOLEAN typedefsGreg Kroah-Hartman1-1/+1
The BOOL and BOOLEAN typedefs are now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove ULONG_PTR typedefGreg Kroah-Hartman1-8/+8
The ULONG_PTR typedef is now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove UINT64 and INT64 and UCHAR typedefsGreg Kroah-Hartman1-1/+1
The UINT64 and INT64 and UCHAR typedefs are now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove UINT32 and INT32 typedefsGreg Kroah-Hartman1-20/+20
The UINT32 and INT32 typedefs are now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove UINT8 and INT8 typedefsGreg Kroah-Hartman1-0/+1
The UINT8 and INT8 typedefs are now removed from the Hyper-V driver code. Had to include <linux/kernel.h> in a few places to get the build to work properly as well. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: remove VOID typedefGreg Kroah-Hartman1-2/+2
The VOID typedef is now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: make the Hyper-V virtual network driver buildGreg Kroah-Hartman1-2/+3
The #define KERNEL_2_6_27 needs to be set, and I adjusted the include directories a bit to get things to build properly. The driver was changed to use net_device_ops, as that is needed to build and operate properly now. The hv_netvsc code should now build with no errors. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-09-15Staging: hv: add the Hyper-V virtual network driverHank Janssen1-0/+1162
This is the virtual network driver when running Linux on top of Hyper-V. Signed-off-by: Hank Janssen <hjanssen@microsoft.com> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>