Commit 0ccafb36 authored by Greg Kroah-Hartman's avatar Greg Kroah-Hartman
Browse files

Staging: hv: osd.h: codingstyle cleanups



This fixes up the coding style issues in osd.h, with the exception of
the typedefs, they will be removed later.

Cc: Hank Janssen <hjanssen@microsoft.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 4983b39a
Loading
Loading
Loading
Loading
+16 −20
Original line number Diff line number Diff line
@@ -27,12 +27,13 @@


/* Defines */



#define ALIGN_UP(value, align)			( ((value) & (align-1))? ( ((value) + (align-1)) & ~(align-1) ): (value) )
#define ALIGN_UP(value, align)	(((value) & (align-1)) ?		\
				 (((value) + (align-1)) & ~(align-1)) :	\
				 (value))
#define ALIGN_DOWN(value, align)	((value) & ~(align-1))
#define NUM_PAGES_SPANNED(addr, len)	( (ALIGN_UP(addr+len, PAGE_SIZE) - ALIGN_DOWN(addr, PAGE_SIZE)) >> PAGE_SHIFT )
#define NUM_PAGES_SPANNED(addr, len)	((ALIGN_UP(addr+len, PAGE_SIZE) - \
					 ALIGN_DOWN(addr, PAGE_SIZE)) >>  \
					 PAGE_SHIFT)

#define LOWORD(dw)	((unsigned short)(dw))
#define HIWORD(dw)	((unsigned short)(((unsigned int) (dw) >> 16) & 0xFFFF))
@@ -42,11 +43,6 @@ typedef struct _DLIST_ENTRY {
	struct _DLIST_ENTRY *Blink;
} DLIST_ENTRY;


/* Other types */

/* typedef unsigned char		GUID[16]; */

typedef struct {
	unsigned char Data[16];
} GUID;
@@ -68,8 +64,8 @@ extern void osd_WaitEventSet(struct osd_waitevent *waitEvent);
extern int osd_WaitEventWait(struct osd_waitevent *waitEvent);

/* If >0, waitEvent got signaled. If ==0, timeout. If < 0, error */
extern int osd_WaitEventWaitEx(struct osd_waitevent *waitEvent, u32 TimeoutInMs);

extern int osd_WaitEventWaitEx(struct osd_waitevent *waitEvent,
			       u32 TimeoutInMs);

int osd_schedule_callback(struct workqueue_struct *wq,
			  void (*func)(void *),