@@ -56,6 +56,7 @@ pub mod kprobe;
56
56
pub mod links;
57
57
pub mod lirc_mode2;
58
58
pub mod lsm;
59
+ pub mod lsm_cgroup;
59
60
pub mod perf_attach;
60
61
pub mod perf_event;
61
62
pub mod raw_trace_point;
@@ -100,6 +101,7 @@ pub use crate::programs::{
100
101
links:: { CgroupAttachMode , Link , LinkOrder } ,
101
102
lirc_mode2:: LircMode2 ,
102
103
lsm:: Lsm ,
104
+ lsm_cgroup:: LsmCgroup ,
103
105
perf_event:: { PerfEvent , PerfEventScope , PerfTypeId , SamplePolicy } ,
104
106
probe:: ProbeKind ,
105
107
raw_trace_point:: RawTracePoint ,
@@ -295,6 +297,8 @@ pub enum Program {
295
297
RawTracePoint ( RawTracePoint ) ,
296
298
/// A [`Lsm`] program
297
299
Lsm ( Lsm ) ,
300
+ /// A [`LsmCgroup`] program
301
+ LsmCgroup ( LsmCgroup ) ,
298
302
/// A [`BtfTracePoint`] program
299
303
BtfTracePoint ( BtfTracePoint ) ,
300
304
/// A [`FEntry`] program
@@ -332,6 +336,7 @@ impl Program {
332
336
Self :: PerfEvent ( _) => ProgramType :: PerfEvent ,
333
337
Self :: RawTracePoint ( _) => ProgramType :: RawTracePoint ,
334
338
Self :: Lsm ( _) => ProgramType :: Lsm ,
339
+ Self :: LsmCgroup ( _) => ProgramType :: Lsm ,
335
340
// The following program types are a subset of `TRACING` programs:
336
341
//
337
342
// - `BPF_TRACE_RAW_TP` (`BtfTracePoint`)
@@ -371,6 +376,7 @@ impl Program {
371
376
Self :: PerfEvent ( p) => p. pin ( path) ,
372
377
Self :: RawTracePoint ( p) => p. pin ( path) ,
373
378
Self :: Lsm ( p) => p. pin ( path) ,
379
+ Self :: LsmCgroup ( p) => p. pin ( path) ,
374
380
Self :: BtfTracePoint ( p) => p. pin ( path) ,
375
381
Self :: FEntry ( p) => p. pin ( path) ,
376
382
Self :: FExit ( p) => p. pin ( path) ,
@@ -402,6 +408,7 @@ impl Program {
402
408
Self :: PerfEvent ( mut p) => p. unload ( ) ,
403
409
Self :: RawTracePoint ( mut p) => p. unload ( ) ,
404
410
Self :: Lsm ( mut p) => p. unload ( ) ,
411
+ Self :: LsmCgroup ( mut p) => p. unload ( ) ,
405
412
Self :: BtfTracePoint ( mut p) => p. unload ( ) ,
406
413
Self :: FEntry ( mut p) => p. unload ( ) ,
407
414
Self :: FExit ( mut p) => p. unload ( ) ,
@@ -435,6 +442,7 @@ impl Program {
435
442
Self :: PerfEvent ( p) => p. fd ( ) ,
436
443
Self :: RawTracePoint ( p) => p. fd ( ) ,
437
444
Self :: Lsm ( p) => p. fd ( ) ,
445
+ Self :: LsmCgroup ( p) => p. fd ( ) ,
438
446
Self :: BtfTracePoint ( p) => p. fd ( ) ,
439
447
Self :: FEntry ( p) => p. fd ( ) ,
440
448
Self :: FExit ( p) => p. fd ( ) ,
@@ -469,6 +477,7 @@ impl Program {
469
477
Self :: PerfEvent ( p) => p. info ( ) ,
470
478
Self :: RawTracePoint ( p) => p. info ( ) ,
471
479
Self :: Lsm ( p) => p. info ( ) ,
480
+ Self :: LsmCgroup ( p) => p. info ( ) ,
472
481
Self :: BtfTracePoint ( p) => p. info ( ) ,
473
482
Self :: FEntry ( p) => p. info ( ) ,
474
483
Self :: FExit ( p) => p. info ( ) ,
@@ -780,6 +789,7 @@ impl_program_unload!(
780
789
LircMode2 ,
781
790
PerfEvent ,
782
791
Lsm ,
792
+ LsmCgroup ,
783
793
RawTracePoint ,
784
794
BtfTracePoint ,
785
795
FEntry ,
@@ -821,6 +831,7 @@ impl_fd!(
821
831
LircMode2 ,
822
832
PerfEvent ,
823
833
Lsm ,
834
+ LsmCgroup ,
824
835
RawTracePoint ,
825
836
BtfTracePoint ,
826
837
FEntry ,
@@ -927,6 +938,7 @@ impl_program_pin!(
927
938
LircMode2 ,
928
939
PerfEvent ,
929
940
Lsm ,
941
+ LsmCgroup ,
930
942
RawTracePoint ,
931
943
BtfTracePoint ,
932
944
FEntry ,
@@ -1022,6 +1034,7 @@ impl_try_from_program!(
1022
1034
LircMode2 ,
1023
1035
PerfEvent ,
1024
1036
Lsm ,
1037
+ LsmCgroup ,
1025
1038
RawTracePoint ,
1026
1039
BtfTracePoint ,
1027
1040
FEntry ,
@@ -1049,6 +1062,7 @@ impl_info!(
1049
1062
LircMode2 ,
1050
1063
PerfEvent ,
1051
1064
Lsm ,
1065
+ LsmCgroup ,
1052
1066
RawTracePoint ,
1053
1067
BtfTracePoint ,
1054
1068
FEntry ,
0 commit comments