lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 17 Dec 2012 10:34:14 +0100
From:	Kurt Van Dijck <kurt.van.dijck@....be>
To:	Bernd Krumboeck <krumboeck@...versalnet.at>
Cc:	Fabio Baltieri <fabio.baltieri@...il.com>,
	Marc Kleine-Budde <mkl@...gutronix.de>,
	linux-can@...r.kernel.org, Wolfgang Grandegger <wg@...ndegger.com>,
	Oliver Hartkopp <socketcan@...tkopp.net>,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/9] can: add tx/rx LED trigger support

On Mon, Dec 17, 2012 at 08:28:48AM +0100, Bernd Krumboeck wrote:
> Hello Fabio!
> 
> Am 2012-12-16 12:08, schrieb Fabio Baltieri:
> >This patch implements the functions to add two LED triggers, named
> ><ifname>-tx and <ifname>-rx, to a canbus device driver.
> >
> >Triggers are called from specific handlers by each CAN device driver and
> >can be disabled altogether with a Kconfig option.
> >
> >The implementation keeps the LED on when the interface is UP and blinks
> >the LED on network activity at a configurable rate.
> >
> >This only supports can-dev based drivers, as it uses some support field
> >in the can_priv structure.
> >
> >Supported drivers should call devm_can_led_init() and can_led_event() as
> >needed.
> >
> >Cleanup is handled automatically by devres, so no *_exit function is
> >needed.
> >
> >Supported events are:
> >- CAN_LED_EVENT_OPEN: turn on tx/rx LEDs
> >- CAN_LED_EVENT_STOP: turn off tx/rx LEDs
> >- CAN_LED_EVENT_TX: trigger tx LED blink
> >- CAN_LED_EVENT_RX: trigger tx LED blink
> 
> Why there is no patch for any usb can device?
> 
> Can this be done in a more general way, except patching every driver?

There must be a way.
Up to this series, there were a few minor problems:
* determine if a CAN device is can_dev based
* led trigger calls.

After this series, I think it's possible to make this functionality generic.
But up to then, this per-driver code is a working model.

Kind regards,
Kurt
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ