[PATCH v2 20/28] net: wan: Add framer framework support

Andrew Lunn andrew at lunn.ch
Tue Aug 1 19:56:12 AEST 2023


> +int framer_pm_runtime_get(struct framer *framer)
> +{
> +	int ret;
> +
> +	if (!framer)
> +		return 0;

Can framer be a NULL pointer? This sort of test often covers up
bugs. So either let it dereference the NULL pointer and opps, or
return -EINVAL.

       Andrew


More information about the Linuxppc-dev mailing list