[PATCH v7] eal: add bus cleanup to eal cleanup
Stephen Hemminger
stephen at networkplumber.org
Fri Jun 3 17:11:54 CEST 2022
On Fri, 3 Jun 2022 15:36:01 +0100
Kevin Laatz <kevin.laatz at intel.com> wrote:
> +/* Clean up all devices of all buses */
> +int
> +eal_bus_cleanup(void)
> +{
> + int ret = 0;
> + struct rte_bus *bus;
> +
> + TAILQ_FOREACH(bus, &rte_bus_list, next) {
> + if (bus->cleanup == NULL)
> + continue;
> + if (bus->cleanup() != 0)
> + ret = -1;
> + }
> +
> + return ret;
> +}
> +
This is an internal function, and all users of it
look like they don't use the return value.
Why not make the function void eal_bus_cleanup()
and simplify back up the call chain?
More information about the dev
mailing list