Project

General

Profile

Bug #11792

ibtl: cast between incompatible function types

Added by Toomas Soome 6 days ago.

Status:
In Progress
Priority:
Normal
Assignee:
Category:
driver - device drivers
Start date:
Due date:
% Done:

90%

Estimated time:
Difficulty:
Medium
Tags:

Description

Build errors with gcc 8:

    ../../common/io/ib/ibtl/ibtl_handlers.c:508:16: error: cast between incompatible function types from 'ibt_async_handler_t' {aka 'void (*)(void *, struct ibtl_hca_s *, enum ibt_async_code_e,  struct ibt_async_event_s *)'} to 'ibt_status_t (*)(ib_guid_t,  uint8_t,  ib_lid_t,  ibt_node_info_t *)' {aka 'enum ibt_status_e (*)(long unsigned int,  unsigned char,  short unsigned int,  struct ibt_node_info_s *)'} [-Werror=cast-function-type]
      ibt_status = ((ibtl_node_info_cb_t)mgrp->mgr_async_handler)(hca_guid,
                    ^
    ../../common/io/ib/ibtl/ibtl_handlers.c: In function 'ibtl_do_hca_asyncs':
    ../../common/io/ib/ibtl/ibtl_handlers.c:743:8: error: cast between incompatible function types from 'ibtl_node_info_cb_t' {aka 'enum ibt_status_e (*)(long unsigned int,  unsigned char,  short unsigned int,  struct ibt_node_info_s *)'} to 'void (*)(void *, struct ibtl_hca_s *, ibt_async_code_t,  ibt_async_event_t *)' {aka 'void (*)(void *, struct ibtl_hca_s *, enum ibt_async_code_e,  struct ibt_async_event_s *)'} [-Werror=cast-function-type]
            (ibt_async_handler_t)ibtl_node_info_cb);
            ^
    cc1: all warnings being treated as errors

Also available in: Atom PDF