xref: /freebsd/lib/csu/common/ignore_init_note.S (revision bdcbfde31e8e9b343f113a1956384bdf30d1ed62)
1/*-
2 * SPDX-License-Identifier: BSD-1-Clause
3 *
4 * Copyright 2012 Konstantin Belousov <kib@FreeBSD.org>
5 * Copyright (c) 2018 The FreeBSD Foundation
6 *
7 * Parts of this software was developed by Konstantin Belousov
8 * <kib@FreeBSD.org> under sponsorship from the FreeBSD Foundation.
9 *
10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions
12 * are met:
13 * 1. Redistributions of source code must retain the above copyright
14 *    notice, this list of conditions and the following disclaimer.
15 *
16 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
17 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
18 * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
19 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
20 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
21 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
22 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
23 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
24 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
25 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 */
27
28#include <machine/asm.h>
29#include <sys/elf_common.h>
30
31#include "notes.h"
32
33	.section .note.tag,"a",%note
34	.p2align	2
35	.4byte		2f-1f
36	.4byte		4f-3f
37	.4byte		NT_FREEBSD_NOINIT_TAG
381:	.asciz		NOTE_FREEBSD_VENDOR
392:	.p2align	2
403:	.4byte		0
414:
42
43	.section .note.GNU-stack,"",%progbits
44
45#ifdef __aarch64__
46/* This is needed in all objects for BTI to be used in the linked elf file */
47GNU_PROPERTY_AARCH64_FEATURE_1_NOTE(GNU_PROPERTY_AARCH64_FEATURE_1_VAL)
48#endif
49