Merge pull request #89581 from Wenfeng-GAO/simplify
simplify code in topologymanager
This commit is contained in:
@@ -35,10 +35,7 @@ func (p *restrictedPolicy) Name() string {
|
||||
}
|
||||
|
||||
func (p *restrictedPolicy) canAdmitPodResult(hint *TopologyHint) bool {
|
||||
if !hint.Preferred {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
return hint.Preferred
|
||||
}
|
||||
|
||||
func (p *restrictedPolicy) Merge(providersHints []map[string][]TopologyHint) (TopologyHint, bool) {
|
||||
|
@@ -40,10 +40,7 @@ func (p *singleNumaNodePolicy) Name() string {
|
||||
}
|
||||
|
||||
func (p *singleNumaNodePolicy) canAdmitPodResult(hint *TopologyHint) bool {
|
||||
if !hint.Preferred {
|
||||
return false
|
||||
}
|
||||
return true
|
||||
return hint.Preferred
|
||||
}
|
||||
|
||||
// Return hints that have valid bitmasks with exactly one bit set.
|
||||
|
Reference in New Issue
Block a user