Backport MPLS patches from 5.3 to 4.15

Bug #1851446 reported by Jeff Lane 
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Invalid
Undecided
Unassigned
Bionic
Fix Released
Undecided
Po-Hsu Lin
Disco
Won't Fix
Undecided
Po-Hsu Lin

Bug Description

== SRU Justification ==
Mellanox is requesting a backport of the following commit IDs from 5.3
back to 5.0 and 4.15:
* 5dc9520bf04a ("net/mlx5e: Report netdevice MPLS features")
* 8b6912a50193 ("net: vlan: Inherit MPLS features from parent device")
* 2e770b507ccd ("net: bonding: Inherit MPLS features from slave devices")
* e4683f35f8e5 ("net/mlx5e: Move to HW checksumming advertising")

Netdevice HW MPLS features are not passed from device driver's netdevice
to upper netdevice, specifically VLAN and bonding netdevice which are
created by the kernel when needed.

This prevents enablement and usage of HW offloads, such as TSO and
checksumming for MPLS tagged traffic when running via VLAN or bonding
interface.

The patches introduce changes to the initialization steps of the VLAN
and bonding netdevices to inherit the MPLS features from lower
netdevices to allow the HW offloads.

== Fix ==
* 5dc9520bf04a ("net/mlx5e: Report netdevice MPLS features")
* 8b6912a50193 ("net: vlan: Inherit MPLS features from parent device")
* 2e770b507ccd ("net: bonding: Inherit MPLS features from slave devices")
* e4683f35f8e5 ("net/mlx5e: Move to HW checksumming advertising")

The first two patches can be cherry-picked into Disco, and the rest
will require some context adjustment.

== Test ==
Test kernels can be found here:
https://people.canonical.com/~phlin/kernel/lp-1851446-MPLS-0407/

Kernel tested with positive test result and approved by their QA.

== Regression Potential ==
Low, changes just for adding MPLS feature and comes with positive
test result.

== Original Bug Report ==
Mellanox is requesting a backport of the following commit IDs from 5.3 back to 4.15.

Netdevice HW MPLS features are not passed from device driver's netdevice to upper netdevice, specifically VLAN and bonding netdevice which are created by the kernel when needed.

This prevents enablement and usage of HW offloads, such as TSO and checksumming for MPLS tagged traffic when running via VLAN or bonding interface.

The patches introduce changes to the initialization steps of the VLAN and
bonding netdevices to inherit the MPLS features from lower netdevices to allow the HW offloads.

Ariel Levkovich (2):
  net: bonding: Inherit MPLS features from slave devices
  net: vlan: Inherit MPLS features from parent device

 drivers/net/bonding/bond_main.c | 11 +++++++++++
 net/8021q/vlan_dev.c | 1 +
 2 files changed, 12 insertions(+)

https://<email address hidden>/msg299084.html

Commit IDs (All landed in 5.3)
600bb0318c18e9616d97ad123caaa7c5f7bf222c
8b6912a5019356d7adb1b8a146c9eef5e679bf98
2e770b507ccde8eedc129946e4b78ceed0a22df2

CVE References

Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1851446

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Po-Hsu Lin (cypressyew)
description: updated
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hi Jeff,

can you give this Bionic kernel a try:
https://people.canonical.com/~phlin/kernel/lp-1851446-MPLS/

Thanks!

Changed in linux (Ubuntu Bionic):
status: New → Confirmed
Po-Hsu Lin (cypressyew)
Changed in linux (Ubuntu Bionic):
status: Confirmed → In Progress
Revision history for this message
Jeff Lane  (bladernr) wrote :

Thanks Sam! I'll pass that along and have them test these to ensure it works.

dann frazier (dannf)
Changed in linux (Ubuntu Bionic):
status: In Progress → Incomplete
Revision history for this message
Jeff Lane  (bladernr) wrote :

I can't add a task for Disco but Terry tells me that we need that as well. I validated that the patches were landed in 5.3, I do not believe they are in 5.0, so we'll probably need test kernels built for Disco as well.

Revision history for this message
Talat Batheesh (talat-b87) wrote :

Hi Jeff.
Unfortunately, was missing patch [1] that add the expose the support in the mlx5 driver.

[1]
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?h=v5.5-rc2&id=5dc9520bf04a6b95660a307d7654460d1463d91a

could you please add it ?

Yours,
Talat

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

5dc9520b has landed in Eoan / Focal.

Please give the following B/D kernel a try:
https://people.canonical.com/~phlin/kernel/lp-1851446-MPLS/

They both contains:
  * 5dc9520b (net/mlx5e: Report netdevice MPLS features)
  * 8b6912a5 (net: vlan: Inherit MPLS features from parent device)
  * 2e770b50 (net: bonding: Inherit MPLS features from slave devices)

Commit 600bb0318c18e9616d97ad123caaa7c5f7bf222c is a merge for the 2 commits above, and thus ignored.

Revision history for this message
Jeff Lane  (bladernr) wrote :

Sam, can you provide a link to your git tree with these commits?

Revision history for this message
Terry Rudd (terrykrudd) wrote : Re: [Bug 1851446] Re: Backport MPLS patches from 5.3 to 4.15

On 1/30/20 7:37 AM, Jeff Lane wrote:
> Sam, can you provide a link to your git tree with these commits?
>

Thanks Jeff,

I'll get these on the notice board.. BTW, 4.15 is a long way back and I
cannot guarantee we can do this without issue. JFYI.

--
Terry

Revision history for this message
Jeff Lane  (bladernr) wrote :

Sam, could you please provide a link to your git tree with these commits? The testers ran into issues with MPLS offloads and are asking for a source code link to debug their issues.

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hi Jeff,
sorry I didn't catch this reply in time,

I have no longer have git trees for them, the Bionic kernel was built with 4.15.0-74.84 with these patches applied, Disco with patches on 5.0.0-38.41 back then.

I can build a new one with the latest code and with git trees uploaded. Stayed tuned.

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :
Revision history for this message
Mohammad Heib (mohamadh) wrote :

Hi,
I apologize for the delay in responding.

actually we tested the patches and it seems that some functionality of the features is not working as expected in Bionic/Eoan Kernels.

there is no TSO over MPLS traffic and that because of missing the following upstream patch:
- e4683f35f8e5 ("net/mlx5e: Move to HW checksumming advertising").

so we need also this patch to be able to use TSO for MPLS traffic.

if you please can backport it that will be great. and please let us know if you need any assistance.

Regards,
Mohammad

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hello Mohammad,

As you mentioned Bionic and Eoan here, do you still this patchset for Disco 5.0 kernel?
Thanks

Revision history for this message
Mohammad Heib (mohamadh) wrote :

Hi,
my fault, sorry.
i meant Disco and not Eoan.
Eoan already has the MPLS feature support.

yes we need this path to both Bionic/Disco

Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

Hello Mohammad,
please give these 2 kernels a try:
https://people.canonical.com/~phlin/kernel/lp-1851446-MPLS-0407/

Note that these 2 kernels were built upon the tree in comment #11, the version might be fall behind the current kernel in -updates, you might need to boot to these manually.

Revision history for this message
Mohammad Heib (mohamadh) wrote :

Hi,
we tested it, the feature works completely fine.
So this kernel approved by our QA.

Thank you all for your efforts.

Po-Hsu Lin (cypressyew)
description: updated
Changed in linux (Ubuntu Bionic):
assignee: nobody → Po-Hsu Lin (cypressyew)
Changed in linux (Ubuntu):
status: Incomplete → Invalid
Changed in linux (Ubuntu Disco):
assignee: nobody → Po-Hsu Lin (cypressyew)
status: New → Triaged
Changed in linux (Ubuntu Bionic):
status: Incomplete → In Progress
Changed in linux (Ubuntu Disco):
status: Triaged → In Progress
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :
Changed in linux (Ubuntu Bionic):
status: In Progress → Fix Committed
Changed in linux (Ubuntu Disco):
status: In Progress → Fix Committed
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote :

This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed-bionic' to 'verification-done-bionic'. If the problem still exists, change the tag 'verification-needed-bionic' to 'verification-failed-bionic'.

If verification is not done by 5 working days from today, this fix will be dropped from the source code, and this bug will be closed.

See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you!

tags: added: verification-needed-bionic
Revision history for this message
dann frazier (dannf) wrote :

@Mohammed: Can you also test the official build and set the verification tag as appropriate per comment #18?

Revision history for this message
Mohammad Heib (mohamadh) wrote :

Hi,
looks that everything works fine, I added verification done tag.
Thank you all for your big efforts.

tags: added: verification-done-bionic
removed: verification-needed-bionic
Revision history for this message
Launchpad Janitor (janitor) wrote :
Download full text (12.7 KiB)

This bug was fixed in the package linux - 4.15.0-101.102

---------------
linux (4.15.0-101.102) bionic; urgency=medium

  * bionic/linux: 4.15.0-101.102 -proposed tracker (LP: #1877262)

  * 4.15.0-100.101 breaks userspace builds due to a bug in the headers
    /usr/include/linux/swab.h of linux-libc-dev (LP: #1877123)
    - include/uapi/linux/swab.h: fix userspace breakage, use __BITS_PER_LONG for
      swap

  * bionic snapdragon 4.15 snap failed Certification testing (LP: #1877657)
    - Revert "drm/msm: Use the correct dma_sync calls in msm_gem"
    - Revert "drm/msm: stop abusing dma_map/unmap for cache"

linux (4.15.0-100.101) bionic; urgency=medium

  * bionic/linux: 4.15.0-100.101 -proposed tracker (LP: #1875878)

  * built-using constraints preventing uploads (LP: #1875601)
    - temporarily drop Built-Using data

  * Add debian/rules targets to compile/run kernel selftests (LP: #1874286)
    - [Packaging] add support to compile/run selftests

  * getitimer returns it_value=0 erroneously (LP: #1349028)
    - [Config] CONTEXT_TRACKING_FORCE policy should be unset

  * QEMU/KVM display is garbled when booting from kernel EFI stub due to missing
    bochs-drm module (LP: #1872863)
    - [Config] Enable CONFIG_DRM_BOCHS as module for all archs

  * Backport MPLS patches from 5.3 to 4.15 (LP: #1851446)
    - net/mlx5e: Report netdevice MPLS features
    - net: vlan: Inherit MPLS features from parent device
    - net: bonding: Inherit MPLS features from slave devices
    - net/mlx5e: Move to HW checksumming advertising

  * LIO hanging in iscsit_free_session and iscsit_stop_session (LP: #1871688)
    - scsi: target: remove boilerplate code
    - scsi: target: fix hang when multiple threads try to destroy the same iscsi
      session
    - scsi: target: iscsi: calling iscsit_stop_session() inside
      iscsit_close_session() has no effect

  * Add hw timestamps to received skbs in peak_canfd (LP: #1874124)
    - can: peak_canfd: provide hw timestamps in rx skbs

  * Bionic update: upstream stable patchset 2020-04-23 (LP: #1874502)
    - ARM: dts: sun8i-a83t-tbs-a711: HM5065 doesn't like such a high voltage
    - bus: sunxi-rsb: Return correct data when mixing 16-bit and 8-bit reads
    - net: vxge: fix wrong __VA_ARGS__ usage
    - hinic: fix a bug of waitting for IO stopped
    - hinic: fix wrong para of wait_for_completion_timeout
    - cxgb4/ptp: pass the sign of offset delta in FW CMD
    - qlcnic: Fix bad kzalloc null test
    - i2c: st: fix missing struct parameter description
    - firmware: arm_sdei: fix double-lock on hibernate with shared events
    - null_blk: Fix the null_add_dev() error path
    - null_blk: Handle null_add_dev() failures properly
    - null_blk: fix spurious IO errors after failed past-wp access
    - xhci: bail out early if driver can't accress host in resume
    - x86: Don't let pgprot_modify() change the page encryption bit
    - block: keep bdi->io_pages in sync with max_sectors_kb for stacked devices
    - irqchip/versatile-fpga: Handle chained IRQs properly
    - sched: Avoid scale real weight down to zero
    - selftests/x86/ptrace_syscall_32: Fix no-vDSO segfault
    - PCI/switchtec: Fix init_completio...

Changed in linux (Ubuntu Bionic):
status: Fix Committed → Fix Released
Steve Langasek (vorlon)
Changed in linux (Ubuntu Disco):
status: Fix Committed → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.