generic: swconfig: reduce lock duration on sysfs files
authorKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Tue, 13 Feb 2018 13:53:50 +0000 (13:53 +0000)
committerJohn Crispin <john@phrozen.org>
Wed, 14 Feb 2018 06:54:24 +0000 (07:54 +0100)
commit0b4e3b1bed6d0281cdad152724ba9224d5647437
tree5e606355218318584ded2902332ee56308180a18
parenteb8fbc431879a698b5bd8f3bcb8a057ce01793c0
generic: swconfig: reduce lock duration on sysfs files

sysfs attributes 'port_mask' & 'speed_mask' held locks whilst doing
mundane tasks such as sprintf.  Refactor code to reduce length of time
locks are held unnecessarily.

Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
target/linux/generic/files/drivers/net/phy/swconfig_leds.c