staging: sm750fb: Add void to function definition with no arguments
authorSupriya Karanth <iskaranth@gmail.com>
Wed, 11 Mar 2015 16:11:00 +0000 (01:11 +0900)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 15 Mar 2015 17:41:14 +0000 (18:41 +0100)
Found by checkpatch.pl - ERROR: Bad function definition

A function with no arguments allows for variadic arguments. Add
void in between the empty parentheses to indicate that the function
takes no arguments.

changes made using coccinelle script:
@@
type T;
identifier f;
@@
T f(
+void
 ) {
...
}

Signed-off-by: Supriya Karanth <iskaranth@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/sm750fb/ddk750_chip.c
drivers/staging/sm750fb/ddk750_display.c
drivers/staging/sm750fb/ddk750_dvi.c
drivers/staging/sm750fb/ddk750_power.c
drivers/staging/sm750fb/ddk750_sii164.c
drivers/staging/sm750fb/sm750_hw.c

index b71169ed063ca41357ec22eb8867b1c473a9c42f..3c772073ebe8e19c000be66a99d90f97dc3de75e 100644 (file)
@@ -11,7 +11,7 @@ typedef struct _pllcalparam{
 pllcalparam;
 
 
-logical_chip_type_t getChipType()
+logical_chip_type_t getChipType(void)
 {
        unsigned short physicalID;
        char physicalRev;
@@ -91,7 +91,7 @@ unsigned int getPllValue(clock_type_t clockType, pll_value_t *pPLL)
 }
 
 
-unsigned int getChipClock()
+unsigned int getChipClock(void)
 {
     pll_value_t pll;
 #if 1
@@ -232,7 +232,7 @@ void setMasterClock(unsigned int frequency)
 }
 
 
-unsigned int ddk750_getVMSize()
+unsigned int ddk750_getVMSize(void)
 {
        unsigned int reg;
        unsigned int data;
index a282a9492cc0e231bc09c0541e9335fd1d779817..c84196ac055d5106d2f86422edef5cd489e1e12a 100644 (file)
@@ -273,7 +273,7 @@ void ddk750_setLogicalDispOut(disp_output_t output)
 }
 
 
-int ddk750_initDVIDisp()
+int ddk750_initDVIDisp(void)
 {
     /* Initialize DVI. If the dviInit fail and the VendorID or the DeviceID are
        not zeroed, then set the failure flag. If it is zeroe, it might mean
index 1c083e7dc7105c472741b97f967315c3b8e74d2b..f5932bbf13e85e5fc735f3fb6a3dc16d2a5d5897 100644 (file)
@@ -62,7 +62,7 @@ int dviInit(
  *  Output:
  *      Vendor ID
  */
-unsigned short dviGetVendorID()
+unsigned short dviGetVendorID(void)
 {
     dvi_ctrl_device_t *pCurrentDviCtrl;
 
@@ -82,7 +82,7 @@ unsigned short dviGetVendorID()
  *  Output:
  *      Device ID
  */
-unsigned short dviGetDeviceID()
+unsigned short dviGetDeviceID(void)
 {
     dvi_ctrl_device_t *pCurrentDviCtrl;
 
index 98dfcbde1eb65eaeda361f33cfac9a74f2c73c18..cbb97676b33c96e169e0d92a33c9f92449c7faf6 100644 (file)
@@ -15,7 +15,7 @@ void ddk750_setDPMS(DPMS_t state)
        }
 }
 
-unsigned int getPowerMode()
+unsigned int getPowerMode(void)
 {
        if(getChipType() == SM750LE)
                return 0;
index faf825093e7fab5eb21db9192fa2688f34c3c143..3d224d6a74ff5951abb24d99cb531ab21b5e0145 100644 (file)
@@ -34,7 +34,7 @@ static char *gDviCtrlChipName = "Silicon Image SiI 164";
  *  Output:
  *      Vendor ID
  */
-unsigned short sii164GetVendorID()
+unsigned short sii164GetVendorID(void)
 {
     unsigned short vendorID;
 
@@ -51,7 +51,7 @@ unsigned short sii164GetVendorID()
  *  Output:
  *      Device ID
  */
-unsigned short sii164GetDeviceID()
+unsigned short sii164GetDeviceID(void)
 {
     unsigned short deviceID;
 
@@ -264,7 +264,7 @@ long sii164InitChip(
  *  sii164ResetChip
  *      This function resets the DVI Controller Chip.
  */
-void sii164ResetChip()
+void sii164ResetChip(void)
 {
     /* Power down */
     sii164SetPower(0);
@@ -277,7 +277,7 @@ void sii164ResetChip()
  *      This function returns a char string name of the current DVI Controller chip.
  *      It's convenient for application need to display the chip name.
  */
-char *sii164GetChipString()
+char *sii164GetChipString(void)
 {
     return gDviCtrlChipName;
 }
@@ -375,7 +375,7 @@ void sii164EnableHotPlugDetection(
  *      0   - Not Connected
  *      1   - Connected
  */
-unsigned char sii164IsConnected()
+unsigned char sii164IsConnected(void)
 {
     unsigned char hotPlugValue;
 
@@ -394,7 +394,7 @@ unsigned char sii164IsConnected()
  *      0   - No interrupt
  *      1   - Interrupt occurs
  */
-unsigned char sii164CheckInterrupt()
+unsigned char sii164CheckInterrupt(void)
 {
     unsigned char detectReg;
 
@@ -409,7 +409,7 @@ unsigned char sii164CheckInterrupt()
  *  sii164ClearInterrupt
  *      Clear the hot plug interrupt.
  */
-void sii164ClearInterrupt()
+void sii164ClearInterrupt(void)
 {
     unsigned char detectReg;
 
index c44a50b0c4897d60d30fc95d7494311253c8d542..3050847fa1c671d72cd8f4cc23ad486185969351 100644 (file)
@@ -581,7 +581,7 @@ void hw_sm750_initAccel(struct lynx_share * share)
        share->accel.de_init(&share->accel);
 }
 
-int hw_sm750le_deWait()
+int hw_sm750le_deWait(void)
 {
        int i=0x10000000;
        while(i--){
@@ -598,7 +598,7 @@ int hw_sm750le_deWait()
 }
 
 
-int hw_sm750_deWait()
+int hw_sm750_deWait(void)
 {
        int i=0x10000000;
        while(i--){