|  | // Copyright 2019 The Fuchsia Authors. All rights reserved. | 
|  | // Use of this source code is governed by a BSD-style license that can be | 
|  | // found in the LICENSE file. | 
|  |  | 
|  | library fuchsia.scheduler; | 
|  |  | 
|  | using zx; | 
|  |  | 
|  | // Corresponds to zx_cpu_set_t. | 
|  | [ForDeprecatedCBindings] | 
|  | struct CpuSet { | 
|  | array<uint64>:8 mask; | 
|  | }; | 
|  |  | 
|  | [Discoverable, ForDeprecatedCBindings] | 
|  | protocol ProfileProvider { | 
|  | /// Obtain a profile handle. | 
|  | GetProfile(uint32 priority, string:64 name) -> (zx.status status, zx.handle:PROFILE? profile); | 
|  |  | 
|  | /// Obtain a deadline profile handle. | 
|  | GetDeadlineProfile(uint64 capacity, uint64 deadline, uint64 period, string:64 name) | 
|  | -> (zx.status status, zx.handle:PROFILE? profile); | 
|  |  | 
|  | /// Obtain a handle for a profile that sets CPU affinity. | 
|  | GetCpuAffinityProfile(CpuSet cpu_mask) -> (zx.status status, zx.handle:PROFILE? profile); | 
|  | }; |