Interface with two device and custom proto collides in OpenWrt 21 syntax?

In OpenWrt 19 syntax, this configuration is correct:

config interface 'ppp0'
        option device '/dev/usb/modem1'
        option ifname 'ppp0'
        option ipv6 '1'
        option keepalive '3'
        option password 'pwd0123'
        option proto 'ppp'
        option username 'user1'

But since OpenWrt 21, there's a new config option called "device" which collides with the device config option of pre OpenWrt 21, so in this case, does the new syntax have any impact here or the old syntax will continue working?

1 Like

It should continue working, without the ifname option. However when upgrading from one major version to another it is encouraged to configure from scratch and not copy the configuration over.

What about:

option device '/dev/usb/modem1'

Doesn't this collide with the new device syntax option?
Or should that option go to a device config type, eg:

config device
        option name 'ppp0'
        option device '/dev/usb/modem1'
        option ipv6 '1'

config interface 'ppp0'
        option device 'ppp0'
        option keepalive '3'
        option password 'pwd0123'
        option proto 'ppp'
        option username 'user1'
1 Like

Hey,

If it is a custom protocol, then the protocol handler script will continue working in 21.02. I don't know about the question of collisions with regular DSA - whether they exist but are ignored, or whether they exist at all, but I am leaning towards "no internal collisions" because netifd continues working normally on 21.02 with interfaces like this. I believe it is for this reason that even in LuCI, if there is an option called device, LuCI does not try to change that option name to something else.

Example 2

I hope someone can chime in and inform us on this

2 Likes