Re: [PATCHv2] SO_ZEROCOPY should return -EOPNOTSUPP rather than -ENOTSUPP
From: Willem de Bruijn
Date: Mon Mar 07 2022 - 18:28:40 EST
On Mon, Mar 7, 2022 at 5:31 PM Samuel Thibault <samuel.thibault@xxxxxxxx> wrote:
>
> ENOTSUPP is documented as "should never be seen by user programs",
> and thus not exposed in <errno.h>, and thus applications cannot safely
> check against it (they get "Unknown error 524" as strerror). We should
> rather return the well-known -EOPNOTSUPP.
>
> This is similar to 2230a7ef5198 ("drop_monitor: Use correct error
> code") and 4a5cdc604b9c ("net/tls: Fix return values to avoid
> ENOTSUPP"), which did not seem to cause problems.
>
> Signed-off-by: Samuel Thibault <samuel.thibault@xxxxxxxx>
Acked-by: Willem de Bruijn <willemb@xxxxxxxxxx>
>From what I can tell, the first of the two referenced patches went to
net-next, the second one to net and stable. I would suggest only
net-next for this. Else, we should also add a Fixes tag.
Small nit, for future patches: preferred syntax is commit $SHA1
("subject"), including the commit keyword.