-
Notifications
You must be signed in to change notification settings - Fork 64
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sqm-hotplug: 'ifname' replaced by 'device' #163
Comments
Hmm, right; that code was a bit of a hack in the first place. Maybe moving to using the 'net' hotplug (as @moeller0 suggested back when it was added) will allow us to get rid of that hack entirely? 🤔 |
Yup, when I noticed the problem I started digging through the history and decided against the simple PR with a name change. The real issue looked much deeper than I was able to understand, hence my somewhat terse "it's busted." |
I have been keeping a low profile on this, as I am still on turrisOS which as far as I can see has not yet made that change (being based on OpenWrt21). So I can not actually test any proposed changes for new functionality, only for backward compatibility... |
OK, to answer my own question, the 'net' hotplug event only gives us 'add' and 'remove' events, so we can't just substitute that. We'll have to query the device sections instead... |
I will be able to test the back-ward compatibility later this week, still on turrisOS which has not made the step to OpenWrt22. |
|
I just tested SQM with OpenWrt-23.05! Now submit the SQM system log Mon Aug 21 14:16:39 2023 user.notice SQM: Starting SQM script: piece_of_cake.qos on wan, in: 85000 Kbps, out: 10000 Kbps |
Well, I'm not set up to test, but I did a deep-dive code review and it looks good to me. I then cut out the new code and did some unit testing on the functions, hardcoding the values of DEVICE and INTERFACE to existing and non-existent values, all worked as I expected, for what that's worth... |
Awesome, thank you for testing! I'll merge this and see if we can still get it into OpenWrt 23.05 before the final release :) |
In OpenWrt 22.03,
network.$INTERFACE.ifname
was removed andifname
was renamed todevice
, so the following code no longer functions properly:https://github.com/tohojo/sqm-scripts/blob/master/platform/openwrt/sqm-hotplug#L3
More about this change in first warning box at https://openwrt.org/docs/guide-user/base-system/basic-networking
The text was updated successfully, but these errors were encountered: