blob: 609406d7b5b11f5a4feba986ad1c99defdb04c0c [file] [log] [blame]
Doug Horn1427b6a2018-12-11 13:19:16 -08001// Copyright 2018 The Fuchsia Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5#include <lib/zx/interrupt.h>
6
7#include <zircon/syscalls.h>
8
9namespace zx {
10
11zx_status_t interrupt::create(const resource& resource, uint32_t vector,
12 uint32_t options, interrupt* result) {
13 // Assume |result| uses a distinct container from |resource|, due to
14 // strict aliasing.
15 return zx_interrupt_create(
16 resource.get(), vector, options, result->reset_and_get_address());
17}
18
19} // namespace zx