[PATCH] ppc64 iSeries: obvious code simplifications

This patch does some obvious code cleanups in the iSeries headers files.
	- simplifies the bodies of lots of inline functions
	- parenthesises a macros result
	- removes C++ wrapping
	- adds "extern" to some function declarations
There are no semantic changes.

Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
diff --git a/include/asm-ppc64/iSeries/HvCallEvent.h b/include/asm-ppc64/iSeries/HvCallEvent.h
index a595478..5d9a327 100644
--- a/include/asm-ppc64/iSeries/HvCallEvent.h
+++ b/include/asm-ppc64/iSeries/HvCallEvent.h
@@ -82,13 +82,11 @@
 static inline void HvCallEvent_getOverflowLpEvents(u8 queueIndex)
 {
 	HvCall1(HvCallEventGetOverflowLpEvents, queueIndex);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline void HvCallEvent_setInterLpQueueIndex(u8 queueIndex)
 {
 	HvCall1(HvCallEventSetInterLpQueueIndex, queueIndex);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline void HvCallEvent_setLpEventStack(u8 queueIndex,
@@ -99,7 +97,6 @@
 	abs_addr = virt_to_abs(eventStackAddr);
 	HvCall3(HvCallEventSetLpEventStack, queueIndex, abs_addr,
 			eventStackSize);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline void HvCallEvent_setLpEventQueueInterruptProc(u8 queueIndex,
@@ -107,22 +104,18 @@
 {
 	HvCall2(HvCallEventSetLpEventQueueInterruptProc, queueIndex,
 			lpLogicalProcIndex);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline HvLpEvent_Rc HvCallEvent_signalLpEvent(struct HvLpEvent *event)
 {
 	u64 abs_addr;
-	HvLpEvent_Rc retVal;
 
 #ifdef DEBUG_SENDEVENT
 	printk("HvCallEvent_signalLpEvent: *event = %016lx\n ",
 			(unsigned long)event);
 #endif
 	abs_addr = virt_to_abs(event);
-	retVal = (HvLpEvent_Rc)HvCall1(HvCallEventSignalLpEvent, abs_addr);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall1(HvCallEventSignalLpEvent, abs_addr);
 }
 
 static inline HvLpEvent_Rc HvCallEvent_signalLpEventFast(HvLpIndex targetLp,
@@ -132,8 +125,6 @@
 		u64 eventData1, u64 eventData2, u64 eventData3,
 		u64 eventData4, u64 eventData5)
 {
-	HvLpEvent_Rc retVal;
-
 	/* Pack the misc bits into a single Dword to pass to PLIC */
 	union {
 		struct HvCallEvent_PackedParms	parms;
@@ -148,67 +139,49 @@
 	packed.parms.xSourceInstId	= sourceInstanceId;
 	packed.parms.xTargetInstId	= targetInstanceId;
 
-	retVal = (HvLpEvent_Rc)HvCall7(HvCallEventSignalLpEventParms,
-			packed.dword, correlationToken, eventData1,eventData2,
-			eventData3,eventData4, eventData5);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall7(HvCallEventSignalLpEventParms, packed.dword,
+			correlationToken, eventData1, eventData2,
+			eventData3, eventData4, eventData5);
 }
 
 static inline HvLpEvent_Rc HvCallEvent_ackLpEvent(struct HvLpEvent *event)
 {
 	u64 abs_addr;
-	HvLpEvent_Rc retVal;
 
 	abs_addr = virt_to_abs(event);
-	retVal = (HvLpEvent_Rc)HvCall1(HvCallEventAckLpEvent, abs_addr);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall1(HvCallEventAckLpEvent, abs_addr);
 }
 
 static inline HvLpEvent_Rc HvCallEvent_cancelLpEvent(struct HvLpEvent *event)
 {
 	u64 abs_addr;
-	HvLpEvent_Rc retVal;
 
 	abs_addr = virt_to_abs(event);
-	retVal = (HvLpEvent_Rc)HvCall1(HvCallEventCancelLpEvent, abs_addr);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall1(HvCallEventCancelLpEvent, abs_addr);
 }
 
 static inline HvLpInstanceId HvCallEvent_getSourceLpInstanceId(
 		HvLpIndex targetLp, HvLpEvent_Type type)
 {
-	HvLpInstanceId retVal;	
-
-	retVal = HvCall2(HvCallEventGetSourceLpInstanceId, targetLp, type);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall2(HvCallEventGetSourceLpInstanceId, targetLp, type);
 }
 
 static inline HvLpInstanceId HvCallEvent_getTargetLpInstanceId(
 		HvLpIndex targetLp, HvLpEvent_Type type)
 {
-	HvLpInstanceId retVal;	
-
-	retVal = HvCall2(HvCallEventGetTargetLpInstanceId, targetLp, type);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall2(HvCallEventGetTargetLpInstanceId, targetLp, type);
 }
 
 static inline void HvCallEvent_openLpEventPath(HvLpIndex targetLp,
 		HvLpEvent_Type type)
 {
 	HvCall2(HvCallEventOpenLpEventPath, targetLp, type);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline void HvCallEvent_closeLpEventPath(HvLpIndex targetLp,
 		HvLpEvent_Type type)
 {
 	HvCall2(HvCallEventCloseLpEventPath, targetLp, type);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
 }
 
 static inline HvLpDma_Rc HvCallEvent_dmaBufList(HvLpEvent_Type type,
@@ -220,7 +193,6 @@
 		/* Do these need to be converted to absolute addresses? */
 		u64 localBufList, u64 remoteBufList, u32 transferLength)
 {
-	HvLpDma_Rc retVal;
 	/* Pack the misc bits into a single Dword to pass to PLIC */
 	union {
 		struct HvCallEvent_PackedDmaParms	parms;
@@ -237,11 +209,8 @@
 	packed.parms.xLocalInstId	= localInstanceId;
 	packed.parms.xRemoteInstId	= remoteInstanceId;
 
-	retVal = (HvLpDma_Rc)HvCall4(HvCallEventDmaBufList,
-			packed.dword, localBufList, remoteBufList,
-			transferLength);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall4(HvCallEventDmaBufList, packed.dword, localBufList,
+			remoteBufList, transferLength);
 }
 
 static inline HvLpDma_Rc HvCallEvent_dmaSingle(HvLpEvent_Type type,
@@ -252,7 +221,6 @@
 		HvLpDma_AddressType remoteAddressType,
 		u64 localAddrOrTce, u64 remoteAddrOrTce, u32 transferLength)
 {
-	HvLpDma_Rc retVal;
 	/* Pack the misc bits into a single Dword to pass to PLIC */
 	union {
 		struct HvCallEvent_PackedDmaParms	parms;
@@ -269,24 +237,17 @@
 	packed.parms.xLocalInstId	= localInstanceId;
 	packed.parms.xRemoteInstId	= remoteInstanceId;
 
-	retVal = (HvLpDma_Rc)HvCall4(HvCallEventDmaSingle,
-			packed.dword, localAddrOrTce, remoteAddrOrTce,
-			transferLength);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return (HvLpDma_Rc)HvCall4(HvCallEventDmaSingle, packed.dword,
+			localAddrOrTce, remoteAddrOrTce, transferLength);
 }
 
 static inline HvLpDma_Rc HvCallEvent_dmaToSp(void *local, u32 remote,
 		u32 length, HvLpDma_Direction dir)
 {
 	u64 abs_addr;
-	HvLpDma_Rc retVal;
 
 	abs_addr = virt_to_abs(local);
-	retVal = (HvLpDma_Rc)HvCall4(HvCallEventDmaToSp, abs_addr, remote,
-			length, dir);
-	// getPaca()->adjustHmtForNoOfSpinLocksHeld();
-	return retVal;
+	return HvCall4(HvCallEventDmaToSp, abs_addr, remote, length, dir);
 }
 
 #endif /* _HVCALLEVENT_H */