• Arnd Bergmann's avatar
    isdn: capi: fix mismatched prototypes · 5ee7d4c7
    Arnd Bergmann authored
    gcc-11 complains about a prototype declaration that is different
    from the function definition:
    
    drivers/isdn/capi/kcapi.c:724:44: error: argument 2 of type ‘u8 *’ {aka ‘unsigned char *’} declared as a pointer [-Werror=array-parameter=]
      724 | u16 capi20_get_manufacturer(u32 contr, u8 *buf)
          |                                        ~~~~^~~
    In file included from drivers/isdn/capi/kcapi.c:13:
    drivers/isdn/capi/kcapi.h:62:43: note: previously declared as an array ‘u8[64]’ {aka ‘unsigned char[64]’}
       62 | u16 capi20_get_manufacturer(u32 contr, u8 buf[CAPI_MANUFACTURER_LEN]);
          |                                        ~~~^~~~~~~~~~~~~~~~~~~~~~~~~~
    drivers/isdn/capi/kcapi.c:790:38: error: argument 2 of type ‘u8 *’ {aka ‘unsigned char *’} declared as a pointer [-Werror=array-parameter=]
      790 | u16 capi20_get_serial(u32 contr, u8 *serial)
          |                                  ~~~~^~~~~~
    In file included from drivers/isdn/capi/kcapi.c:13:
    drivers/isdn/capi/kcapi.h:64:37: note: previously declared as an array ‘u8[8]’ {aka ‘unsigned char[8]’}
       64 | u16 capi20_get_serial(u32 contr, u8 serial[CAPI_SERIAL_LEN]);
          |                                  ~~~^~~~~~~~~~~~~~~~~~~~~~~
    
    Change the definition to make them match.
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    5ee7d4c7
kcapi.c 20.8 KB