[PATCH v4 17/17] eal: add function attributes for allocation functions
David Marchand
david.marchand at redhat.com
Tue Oct 1 14:25:46 CEST 2024
On Tue, Oct 1, 2024 at 2:21 PM Burakov, Anatoly
<anatoly.burakov at intel.com> wrote:
> > +
> > +/**
> > + * Frees the memory space pointed to by the provided pointer.
> > + *
> > + * This pointer must have been returned by a previous call to
> > + * rte_malloc(), rte_zmalloc(), rte_calloc() or rte_realloc(). The behaviour of
> > + * rte_free() is undefined if the pointer does not match this requirement.
> > + *
> > + * If the pointer is NULL, the function does nothing.
> > + *
> > + * @param ptr
> > + * The pointer to memory to be freed.
> > + */
> > +void
> > +rte_free(void *ptr);
> > +
>
> Is there any particular reason why rte_free was moved?
>
> Otherwise,
>
> Acked-by: Anatoly Burakov <anatoly.burakov at intel.com>
I guess this is for the added annotation which points at rte_free symbol.
A forward declaration would be another option.
--
David Marchand
More information about the dev
mailing list