On Sun, Jan 29, 2023 at 06:51:37PM +0200, Leon Romanovsky wrote: > In netdev common pattern, extack pointer is forwarded to the drivers > to be filled with error message. However, the caller can easily > overwrite the filled message. > > Instead of adding multiple "if (!extack->_msg)" checks before any > NL_SET_ERR_MSG() call, which appears after call to the driver, let's > add new macro to common code. > > [1] https://lore.kernel.org/all/Y9Irgrgf3uxOjwUm@unreal > Signed-off-by: Leon Romanovsky <leonro@xxxxxxxxxx> Reviewed-by: Simon Horman <simon.horman@xxxxxxxxxxxx>