|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH v3 3/4] tools/hotplug/Linux: Add bridge VLAN support
Hi Jason, On 2024-05-17 03:19, Jason Andryuk wrote: On Thu, May 16, 2024 at 6:56 AM Leigh Brown <leigh@xxxxxxxxxxxxx> wrote:Update add_to_bridge shell function to read the vlan parameter from xenstore and set the bridge VLAN configuration for the VID. Add additional helper functions to parse the vlan specification, which consists of one or more of the following: a) single VLAN (e.g. 10). b) contiguous range of VLANs (e.g. 10-15). c) discontiguous range with base, increment and count (e.g. 100+10x9 which gives VLAN IDs 100, 110, ... 190). A single VLAN can be suffixed with "p" to indicate the PVID, or "u" to indicate untagged. A range of VLANs can be suffixed with "u" to indicate untagged. A complex example would be: vlan=1p/10-15/20-25u This capability requires the iproute2 bridge command to be installed. An error will be generated if the vlan parameter is set and the bridge command is not available. Signed-off-by: Leigh Brown <leigh@xxxxxxxxxxxxx> ---tools/hotplug/Linux/xen-network-common.sh | 103 ++++++++++++++++++++++1 file changed, 103 insertions(+)diff --git a/tools/hotplug/Linux/xen-network-common.sh b/tools/hotplug/Linux/xen-network-common.shindex 42fa704e8d..fa7615ce0f 100644 --- a/tools/hotplug/Linux/xen-network-common.sh +++ b/tools/hotplug/Linux/xen-network-common.sh Correct. I will add a comment to that effect.
I will make that change, using an array.
That is a hack because readarray adds a newline at the end of the last element (not sure why). I will change the code just to fix up the last element before the loop, and it will be clearer. You guessed correctly that like using (( )) but in this case your suggestion is simpler, so I will make that change. Regards, Jason I am making the changes then will test, after which I will send an updated version. Regards, Leigh.
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |