[PATCH] ltq-dsl-base: only lock the dsl pipe once for all stats

Andre Heider a.heider at gmail.com
Fri Dec 4 08:15:38 EST 2020


On 04/12/2020 13:25, Andre Heider wrote:
> Hi,
> 
> On 04/12/2020 13:03, Jo-Philipp Wich wrote:
>> Hi,
>>
>> is there any reason not to use the flock style below? It should be more
>> reliable wrt. unlocking if the script is prematurely terminated.
> 
> I guess because it gets more difficult to fish out the answer for each 
> command then (I didn't check if it's guaranteed to be one line for each)?
> 
> But with `trap` I introduced it should be just as reliable I think?
> 
> In the end the script is still a mess... The two cleanups I did were 
> just the low hanging fruit.
> 
> The proper performance fix would be to move 'lucistat' to ltq-vdsl-app 
> itself. But there's ltq-adsl-app too, so maybe that's not desired from a 
> maintenance point of view.
> 

I misunderstood, that flock style shound indeed work. Updating patch...



More information about the openwrt-devel mailing list