mirror of
https://github.com/varun-r-mallya/Python-BPF.git
synced 2025-12-31 21:06:25 +00:00
format chore
This commit is contained in:
@ -6,6 +6,7 @@ from vmlinux import (
|
||||
from pythonbpf import bpf, section, bpfglobal, compile, compile_to_ir, struct
|
||||
from ctypes import c_int64, c_ubyte, c_ushort, c_uint32
|
||||
|
||||
|
||||
@bpf
|
||||
@struct
|
||||
class iphdr:
|
||||
@ -19,6 +20,7 @@ class iphdr:
|
||||
saddr: c_uint32
|
||||
daddr: c_uint32
|
||||
|
||||
|
||||
@bpf
|
||||
@section("xdp")
|
||||
def ip_detector(ctx: struct_xdp_md) -> c_int64:
|
||||
|
||||
Reference in New Issue
Block a user