From nobody Wed May 21 07:28:39 2025 X-Original-To: freebsd-current@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4b2NMM0bRJz5x0BS for ; Wed, 21 May 2025 07:28:47 +0000 (UTC) (envelope-from ivy@FreeBSD.org) Received: from smtp.freebsd.org (smtp.freebsd.org [IPv6:2610:1c1:1:606c::24b:4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "smtp.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4b2NML730Xz3FTw; Wed, 21 May 2025 07:28:46 +0000 (UTC) (envelope-from ivy@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1747812527; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5YXbY+cqrz3R6Cww86ysE8b1REPg2G8eKMsRVbjXEak=; b=G/R9s9r6CFGCIk5CSLvjMYDu2+niIpUdPg2dXFTQYaZ9HVOthQ5W47jc2jyDAJS7KHqxii wqntXHuWi80Tji630g7tJeGEioKFhM0oNeJ85PITk8axG6VPtBWOA9gJpKbZw7Wn3cZbd/ WHCXUOPzNcuNG/gUe0I6QaC5gWpkIRtaFO5M0cT3h1Ewen0MKUTMo6APIrVm45uc1RHNgt Pvx0BQM3u1cShe1Xzce3gW+2FkEE2YMrHbRF2N5QDc3q6uP9iWc0yo4ov90sR7AjOHf0lS ZMs7rS5hSfCYvIt4GEISWciaDgTEeQ76fVZV5nH+rlv1vHgypjbc9nywMqNTwg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1747812527; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=5YXbY+cqrz3R6Cww86ysE8b1REPg2G8eKMsRVbjXEak=; b=H+D+qHoLDzLw+bYAGsNpClppH1LwO+UNRONWNB0gkIWezFkjAdiaNsFTVI6ZfSGgwWMH5z BI8ul6LjkoXsPv+RzYV33DnyE6XTqc03RvP1SxiTb5K/lsa8MrdKTUZUw3Th7pEDTqq6ZS hePwQqplLB8PWfICGFqHjB2V/NZvHFVIJEoGGkysbXce3m7Rs4a0HsG3VTz2HFT8GXIzI5 QTOXfb1SY9b+z3desRxJSSWR0RgT8kZIkhKWSOqIiJV5XJfNnhcxGvGFlg/wRjhK8LIbWP 1wDIK3EcqRw2nKYNEfk0+4ETMY6wYFOv0tDcOiBGp6obrokdMoqZ80EHI2Yfew== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1747812527; a=rsa-sha256; cv=none; b=SqhW1UuAG3LVYhI5taFyg7/5WcAb1MP7P5bcyCQsXZdySFZ315ZDEPSpYizWdq2eMIkmt1 JCXs0qjFd/LWjjHHtue2cU7uK72MmNVXNNv4Jq+xM4hMP4jgW0su0mOBKyjEY2pl+SUkoQ u0213BJNhn8sZlTAgm/snrJUm6D7BBJ4qtIZRjpaNPxc0vwhuj5rFjz77O7vd6c1wga69v tAtoT3vAGfRqLPTMgfABLhh5CkQPPAFFOn4nHTQ7OdS0O46qN3gecjygu7DG2T3+rMV1Jt TjJONZcDFtc2Y3nLTB2Y3Y0YyR1F6HMA+YYDFKiEidIlGqOdBnCk9Ocyii69xg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none Received: from ragweed.eden.le-fay.org (ragweed.eden.le-fay.org [IPv6:2001:8b0:aab5:c401:1::1]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: ivy/mail) by smtp.freebsd.org (Postfix) with ESMTPSA id 4b2NML4Bzxz1R0C; Wed, 21 May 2025 07:28:46 +0000 (UTC) (envelope-from ivy@FreeBSD.org) Date: Wed, 21 May 2025 08:28:39 +0100 From: Lexi Winter To: Poul-Henning Kamp Cc: FreeBSD CURRENT Subject: Re: Un-sucking EINVAL (was: ip# on bridge members) Message-ID: Mail-Followup-To: Poul-Henning Kamp , FreeBSD CURRENT References: <202505210722.54L7MTqw025632@critter.freebsd.dk> List-Id: Discussions about the use of FreeBSD-current List-Archive: https://lists.freebsd.org/archives/freebsd-current List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-current@FreeBSD.org MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="M9e22UoTRQ4GPw55" Content-Disposition: inline In-Reply-To: <202505210722.54L7MTqw025632@critter.freebsd.dk> --M9e22UoTRQ4GPw55 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Poul-Henning Kamp: > The ip# on bridge member interfaces is yet another example of why > "EINVAL" is the undisputedly least helpful errno of them all. >=20 > The laconic "Invalid argument" leaves both the userland programmer > and the user to guess what might be wrong. =20 you are completely right. since we (for some reason, that i don't really understand) can't add new error codes to errno, we should stop using errno to indicate errors except where POSIX requires this. > We should give errno a text-partner, so kernel code can: i am open to other solutions here, but i intend to convert bridge(4) to use netlink for configuration, which allows us to return a real error message that ifconfig can print. --M9e22UoTRQ4GPw55 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYKAB0WIQSyjTg96lp3RifySyn1nT63mIK/YAUCaC2ApgAKCRD1nT63mIK/ YIARAP9oelK6+Xlbz+fnIq2gTtdMP/FbBh/fKw1vbw40tiScRgEA/OUPD1Brui6E Epstclm9GLBwQdgTUa6NcCiGZTPa/A4= =I8Zl -----END PGP SIGNATURE----- --M9e22UoTRQ4GPw55--