Received: by 2002:ac0:e34a:0:0:0:0:0 with SMTP id g10csp628862imn; Tue, 26 Jul 2022 05:28:19 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tjfTig5g3FI4aBv6yvdhP0N5yFxkugNfSBAjdTNMBti0sTPmnO+objEQCM79aKtPsg0xht X-Received: by 2002:a05:6402:1159:b0:43b:bc82:5ddb with SMTP id g25-20020a056402115900b0043bbc825ddbmr17774892edw.355.1658838499343; Tue, 26 Jul 2022 05:28:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1658838499; cv=none; d=google.com; s=arc-20160816; b=Je6XQOAgsx9bQ+Vul2x0F844S/RqQVBNkXQKELDnt5AF5SxpfzResZFs+NHlJA6BaK WiJY8ULsPQvRQ+s2pg2yJOuTHu+w57K03at0FCMkdhgVw5QATrMMFUrk9xlqzPyfaXHL A6U7UTwoSN4HCZfmC11J10yvwfbaN4W6r9kJs0t7ASbHYllm/lHH4F7TFF6WVh8fQ5qH t1wzzhEpN0DTnG/ivynB1OIO7K3ylg6LZNesTJKfFE8ZNCsUzF5mq0vkor69oGFZZFVI 6Va62SW5EAflDo5T6avXzje6gXA0FOtVgVVAInWMICvmVrd8/+AQY9e60NM1QUD8gict hGpA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date; bh=/x37t9x4zXaD8TQ5BjktVo4X5OR3wECdlo+w15kKxNI=; b=bIGDYpYRRuyPuCHOFb7r+1JvSruXEYXxdpc5aV0kg6R+Le8lwdakMmnJ3v05SjJxJn eli+5N4xCPwX93NgoXaXXh6grSKPf5IGj0UMBwvi7AoUZQWlCM/RR3SbXz1XIHAlzLQ4 p3KqhHCafGIqRkX4pk9A5den97c8s1kTbG7XdRU6B5w5YGhL8j+y4ejG64EXz6S9g/6n N/tdY+LKa0VcTUgGc/nDZRK2gjIompHyBrS9yDJZogHbfZa0lmGeSyiNFW0USBc188yc /BripM5/WfuXlWIqALngV8cS1upkvlrqgcrLt6An6md7IyjvS2CQ3EUUhf5xOercHGve hEuw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id q17-20020a056402519100b0043586d19cf9si17274791edd.465.2022.07.26.05.27.54; Tue, 26 Jul 2022 05:28:19 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238955AbiGZL7T (ORCPT + 99 others); Tue, 26 Jul 2022 07:59:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37132 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238915AbiGZL7C (ORCPT ); Tue, 26 Jul 2022 07:59:02 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EBB2833355 for ; Tue, 26 Jul 2022 04:58:59 -0700 (PDT) Received: from gallifrey.ext.pengutronix.de ([2001:67c:670:201:5054:ff:fe8d:eefb] helo=bjornoya.blackshift.org) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1oGJD6-0001C9-Dj; Tue, 26 Jul 2022 13:58:48 +0200 Received: from pengutronix.de (unknown [IPv6:2a01:4f8:1c1c:29e9:22:41ff:fe00:1400]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) (Authenticated sender: mkl-all@blackshift.org) by smtp.blackshift.org (Postfix) with ESMTPSA id B7658BAB69; Tue, 26 Jul 2022 11:58:45 +0000 (UTC) Date: Tue, 26 Jul 2022 13:58:45 +0200 From: Marc Kleine-Budde To: Dario Binacchi Cc: linux-kernel@vger.kernel.org, michael@amarulasolutions.com, Amarula patchwork , Jeroen Hofstee , Oliver Hartkopp , Max Staudt , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Wolfgang Grandegger , linux-can@vger.kernel.org, netdev@vger.kernel.org Subject: Re: [PATCH v2 2/6] can: slcan: remove legacy infrastructure Message-ID: <20220726115845.4ywgubfpqfbl7qa3@pengutronix.de> References: <20220725065419.3005015-1-dario.binacchi@amarulasolutions.com> <20220725065419.3005015-3-dario.binacchi@amarulasolutions.com> <20220725123804.ofqpq4j467qkbtzn@pengutronix.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="xy3wdhkpwrvkuzu6" Content-Disposition: inline In-Reply-To: X-SA-Exim-Connect-IP: 2001:67c:670:201:5054:ff:fe8d:eefb X-SA-Exim-Mail-From: mkl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --xy3wdhkpwrvkuzu6 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 26.07.2022 12:11:33, Dario Binacchi wrote: > Hello Marc, >=20 > On Mon, Jul 25, 2022 at 2:38 PM Marc Kleine-Budde wr= ote: > > > > On 25.07.2022 08:54:15, Dario Binacchi wrote: > > > Taking inspiration from the drivers/net/can/can327.c driver and at the > > > suggestion of its author Max Staudt, I removed legacy stuff like > > > `SLCAN_MAGIC' and `slcan_devs' resulting in simplification of the code > > > and its maintainability. > > > > > > The use of slcan_devs is derived from a very old kernel, since slip.c > > > is about 30 years old, so today's kernel allows us to remove it. > > > > > > The .hangup() ldisc function, which only called the ldisc .close(), h= as > > > been removed since the ldisc layer calls .close() in a good place > > > anyway. > > > > > > The old slcanX name has been dropped in order to use the standard canX > > > interface naming. It has been assumed that this change does not break > > > the user space as the slcan driver provides an ioctl to resolve from = tty > > > fd to netdev name. > > > > Is there a man page that documents this iotcl? Please add it and/or the > > IOCTL name. >=20 > I have not found documentation of the SIOCGIFNAME ioctl for the line disc= ipline, > but only for netdev (i. e. > https://man7.org/linux/man-pages/man7/netdevice.7.html), Ok - What about: The old slcanX name has been dropped in order to use the standard canX interface naming. The ioctl SIOCGIFNAME can be used to query the name of the created interface. Further There are several ways to get stable interfaces names in user space, e.g. udev or systemd-networkd. Marc --=20 Pengutronix e.K. | Marc Kleine-Budde | Embedded Linux | https://www.pengutronix.de | Vertretung West/Dortmund | Phone: +49-231-2826-924 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | --xy3wdhkpwrvkuzu6 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEBsvAIBsPu6mG7thcrX5LkNig010FAmLf1vIACgkQrX5LkNig 011rngf9GVw2jclmH7AgQ2YMJ298ay62e8P8qgG9f8WGzHWFkxrwZaQF4shqgtS1 yJ0ppY9R4Y5cNe4UxdfSGjaN3IahaWxlsuDmhx5K86dhtQf9e+FY6Cr4PQbH/aOc +F8RD0Yq4uLLFTC3VMHxB8/0xLcQqkltMHZX24B+ikqyeWTYn/YeXlC0nOSXpepl X0OyGNOWGJmgkwVW1ZTgvzfer+ToWoMFslh4HAf6QdJU5sj2gdK55d0sL5RiDvAb fTCCS5DbOhDxoSG5uzMTe4pXPuVw1u0LvTrypoTm5PmMIdWOI+FAtEEaZ37Te0OA 58JS72ONsO55drbB5JEydbJCzeeuNQ== =R+7A -----END PGP SIGNATURE----- --xy3wdhkpwrvkuzu6--