Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 66b451b8 authored by Treehugger Robot's avatar Treehugger Robot Committed by Gerrit Code Review
Browse files

Merge "AFDO: Do not mutate on disabled modules" into main

parents cd674738 f8856892
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -176,6 +176,9 @@ func (a *afdoTransitionMutator) IncomingTransition(ctx android.IncomingTransitio

func (a *afdoTransitionMutator) Mutate(ctx android.BottomUpMutatorContext, variation string) {
	if m, ok := ctx.Module().(*Module); ok && m.afdo != nil {
		if !m.Enabled(ctx) {
			return
		}
		if variation == "" {
			// The empty variation is either a module that has enabled AFDO for itself, or the non-AFDO
			// variant of a dependency.