[OpenWrt-Devel] [PATCH v2 08/14] ath79/mikrotik: use standard caldata functions

Thibaut hacks at slashdirt.org
Mon Apr 20 10:08:15 EDT 2020


Hi,

> Le 20 avr. 2020 à 16:02, <mail at adrianschmutzler.de> <mail at adrianschmutzler.de> a écrit :
> 
> Hi,
> 
>> -----Original Message-----
>> From: openwrt-devel [mailto:openwrt-devel-bounces at lists.openwrt.org]
>> On Behalf Of Thibaut VARÈNE
>> Sent: Montag, 20. April 2020 15:35
>> To: openwrt-devel at lists.openwrt.org
>> Cc: Thibaut VARÈNE <hacks at slashdirt.org>; koen.vandeputte at ncentric.com
>> Subject: [OpenWrt-Devel] [PATCH v2 08/14] ath79/mikrotik: use standard
>> caldata functions
>> 
>> With the implementation of a sysfs interface to access WLAN data, this target
>> no longer needs a special wrapper to extract caldata.
[…]

>> kernel diff --git a/target/linux/ath79/mikrotik/base-
>> files/etc/hotplug.d/firmware/10-ath9k-eeprom
>> b/target/linux/ath79/mikrotik/base-files/etc/hotplug.d/firmware/10-ath9k-
>> eeprom
>> index 86995de890..be2f6aec69 100644
>> --- a/target/linux/ath79/mikrotik/base-files/etc/hotplug.d/firmware/10-
>> ath9k-eeprom
>> +++ b/target/linux/ath79/mikrotik/base-files/etc/hotplug.d/firmware/10-a
>> +++ th9k-eeprom
>> @@ -3,7 +3,9 @@
>> [ -e /lib/firmware/$FIRMWARE ] && exit 0
>> 
>> . /lib/functions/caldata.sh
>> -. /lib/functions/mikrotik-caldata.sh
>> +
>> +wlan_data="/sys/firmware/mikrotik/hard_config/wlan_data"
>> +mac_base="/sys/firmware/mikrotik/hard_config/mac_base"
> 
> I'd use the cat here already as well.
> Note that in contrast to the 02_network case mentioned earlier, this one is _purely_ matter of taste, just wanted to mention it.
> If don't like it, just forget about …

Well on the one hand you can’t do
wlan_data="$(cat /sys/firmware/mikrotik/hard_config/wlan_data)", 

so presentation-wise it looks nicer (to my eye) as it is now, but on the other hand for the sake of consistency with 02_network, it’s probably better to put the cat in the mac_base assignment as well

Will fix.

Thanks!
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


More information about the openwrt-devel mailing list