BPF Filtering issues with 20.04.5/5.4.0-126
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu |
Invalid
|
Undecided
|
Unassigned | ||
linux (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Good morning,
we are currently porting an old kernel driver to Linux kernel 5.4.0-126 on Ubuntu 20.04.5 LTS and noted odd behaviour that doesn't occur with the same kernel version on Ubuntu 20.04.6 LTS.
The installation is fresh and based on the Ubuntu Server images + OpenSSH and the generic kernel.
ii linux-headers-
ii linux-headers-
ii linux-image-
ii linux-modules-
The driver basically opens a raw socket and configures mac address filtering based on BPF with sock_setsockopt.
struct sock_filter lsf_code[] = {
{ 0x20, 0, 0, 0x00000008 },
{ 0x15, 0, 3, 0xcc112233 },
{ 0x28, 0, 0, 0x00000006 },
{ 0x15, 0, 1, 0x0000aabb },
{ 0x6, 0, 0, 0x0000ffff },
{ 0x6, 0, 0, 0x00000000 },
};
struct sock_fprog lsf = {
.len = ARRAY_SIZE(
.filter = lsf_code,
};
lsf_code[1].k = ntohl(*((__u32 *)&eci-
lsf_code[3].k = ntohl(*((__u32 *)&eci-
if ((result = kernel_
PRINTE(
eci->dev, result);
return (result);
}
Thank you very much and Best Regards,
Florian Scholz
description: | updated |
Thank you for taking the time to report this bug and helping to make Ubuntu better. It seems that your bug report is not filed about a specific source package though, rather it is just filed against Ubuntu in general. It is important that bug reports be filed about source packages so that people interested in the package can find the bugs about it. You can find some hints about determining what package your bug might be about at https:/ /wiki.ubuntu. com/Bugs/ FindRightPackag e. You might also ask for help in the #ubuntu-bugs irc channel on Libera.chat.
To change the source package that this bug is filed about visit https:/ /bugs.launchpad .net/ubuntu/ +bug/2069807/ +editstatus and add the package name in the text box next to the word Package.
[This is an automated message. I apologize if it reached you inappropriately; please just reply to this message indicating so.]