numam-dpdk/lib/eal/include
David Marchand 2ca92f5441 malloc: fix size annotation for NUMA-aware realloc
__rte_alloc_size is mapped to compiler alloc_size attribute.

Quoting gcc documentation:
"""
alloc_size
    The alloc_size attribute is used to tell the compiler that the
    function return value points to memory, where the size is given by
    one or two of the functions parameters. GCC uses this information
    to improve the correctness of __builtin_object_size.

    The function parameter(s) denoting the allocated size are specified
    by one or two integer arguments supplied to the attribute.
    The allocated size is either the value of the single function
    argument specified or the product of the two function arguments
    specified. Argument numbering starts at one.
"""

In rte_realloc_socket case, only 'size' matters.

Note: this has been spotted by Maxime trying to use rte_realloc_socket
and compiling with gcc 11.

Fixes: 17b347dab7 ("malloc: add alloc_size attribute to functions")
Cc: stable@dpdk.org

Signed-off-by: David Marchand <david.marchand@redhat.com>
Tested-by: Maxime Coquelin <maxime.coquelin@redhat.com>
2021-06-11 11:03:38 +02:00
..
generic
meson.build
rte_alarm.h
rte_bitmap.h bitmap: fix buffer overrun in bitmap init 2021-06-11 11:03:25 +02:00
rte_bitops.h
rte_branch_prediction.h
rte_bus.h
rte_class.h
rte_common.h
rte_compat.h
rte_debug.h
rte_dev.h
rte_devargs.h
rte_eal_interrupts.h
rte_eal_memconfig.h
rte_eal_paging.h eal: fix memory mapping on 32-bit target 2021-05-11 23:01:06 +02:00
rte_eal_trace.h
rte_eal.h
rte_errno.h
rte_fbarray.h
rte_function_versioning.h
rte_hexdump.h
rte_hypervisor.h
rte_interrupts.h
rte_keepalive.h
rte_launch.h
rte_lcore.h
rte_log.h
rte_malloc.h malloc: fix size annotation for NUMA-aware realloc 2021-06-11 11:03:38 +02:00
rte_memory.h
rte_memzone.h
rte_pci_dev_feature_defs.h
rte_pci_dev_features.h
rte_per_lcore.h
rte_random.h
rte_reciprocal.h
rte_service_component.h
rte_service.h
rte_string_fns.h
rte_tailq.h
rte_test.h
rte_thread.h
rte_time.h
rte_trace_point_register.h
rte_trace_point.h
rte_trace.h
rte_uuid.h
rte_version.h
rte_vfio.h