mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2 0/6] can: slcan: extend supported features (step 2)
@ 2022-07-25  6:54 Dario Binacchi
  2022-07-25  6:54 ` [PATCH v2 1/6] can: slcan: remove useless header inclusions Dario Binacchi
                   ` (6 more replies)
  0 siblings, 7 replies; 14+ messages in thread
From: Dario Binacchi @ 2022-07-25  6:54 UTC (permalink / raw)
  To: linux-kernel
  Cc: michael, Amarula patchwork, Jeroen Hofstee, Oliver Hartkopp,
	Dario Binacchi, David S. Miller, Eric Dumazet, Jakub Kicinski,
	Marc Kleine-Budde, Paolo Abeni, Wolfgang Grandegger, linux-can,
	netdev

With this series I try to finish the task, started with the series [1],
of completely removing the dependency of the slcan driver from the
userspace slcand/slcan_attach applications.

The series, however, still lacks a patch for sending the bitrate setting
command to the adapter:

slcan_attach -b <btr> <dev>

Without at least this patch the task cannot be considered truly completed.

The idea I got is that this can only happen through the ethtool API.
Among the various operations made available by this interface I would
have used the set_regs (but only the get_regs has been developed), or,
the set_eeprom, even if the setting would not be stored in an eeprom.
IMHO it would take a set_regs operation with a `struct ethtool_wregs'
parameter similar to `struct ethtool_eeprom' without the magic field:

struct ethtool_wregs {
	__u32	cmd;
	__u32	offset;
	__u32	len;
	__u8	data[0];
};

But I am not the expert and if there was an alternative solution already
usable, it would be welcome.

The series also contains patches that remove the legacy stuff (slcan_devs,
SLCAN_MAGIC, ...) and do some module cleanup.

The series has been created on top of the patches:

can: slcan: convert comments to network style comments
can: slcan: slcan_init() convert printk(LEVEL ...) to pr_level()
can: slcan: fix whitespace issues
can: slcan: convert comparison to NULL into !val
can: slcan: clean up if/else
can: slcan: use scnprintf() as a hardening measure
can: slcan: do not report txerr and rxerr during bus-off
can: slcan: do not sleep with a spin lock held

applied to linux-next.

[1] https://lore.kernel.org/all/20220628163137.413025-1-dario.binacchi@amarulasolutions.com/

Changes in v2:
- Re-add headers that export at least one symbol used by the module.
- Update the commit description.
- Drop the old "slcan" name to use the standard canX interface naming.
- Remove comment on listen-only command.
- Update the commit subject and description.
- Add the patch "MAINTAINERS: Add myself as maintainer of the SLCAN driver"
  to the series.

Dario Binacchi (6):
  can: slcan: remove useless header inclusions
  can: slcan: remove legacy infrastructure
  can: slcan: change every `slc' occurrence in `slcan'
  can: slcan: use the generic can_change_mtu()
  can: slcan: add support for listen-only mode
  MAINTAINERS: Add maintainer for the slcan driver

 MAINTAINERS                        |   6 +
 drivers/net/can/slcan/slcan-core.c | 451 +++++++++--------------------
 2 files changed, 139 insertions(+), 318 deletions(-)

-- 
2.32.0


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2022-07-26 12:14 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-07-25  6:54 [PATCH v2 0/6] can: slcan: extend supported features (step 2) Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 1/6] can: slcan: remove useless header inclusions Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 2/6] can: slcan: remove legacy infrastructure Dario Binacchi
2022-07-25 12:38   ` Marc Kleine-Budde
2022-07-26 10:11     ` Dario Binacchi
2022-07-26 11:58       ` Marc Kleine-Budde
2022-07-26 12:11         ` Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 3/6] can: slcan: change every `slc' occurrence in `slcan' Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 4/6] can: slcan: use the generic can_change_mtu() Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 5/6] can: slcan: add support for listen-only mode Dario Binacchi
2022-07-25  6:54 ` [PATCH v2 6/6] MAINTAINERS: Add maintainer for the slcan driver Dario Binacchi
2022-07-25 12:41   ` Marc Kleine-Budde
2022-07-25 13:25 ` [PATCH v2 0/6] can: slcan: extend supported features (step 2) Marc Kleine-Budde
2022-07-26 12:14   ` Dario Binacchi

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®