Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

license: Add preamble to non-eBPF C/include files #2

Merged
merged 1 commit into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions interpreter/php/decode_amd64.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64
#include <Zydis/Zydis.h>
#include "decode_amd64.h"
Expand Down
6 changes: 6 additions & 0 deletions interpreter/php/decode_amd64.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64
#ifndef __INCLUDED_PHP_DECODE_X86_64__
#define __INCLUDED_PHP_DECODE_X86_64__
Expand Down
6 changes: 6 additions & 0 deletions interpreter/python/decode_amd64.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#include <Zydis/Zydis.h>
Expand Down
6 changes: 6 additions & 0 deletions interpreter/python/decode_amd64.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#ifndef __PYTHON_DECODE_X86_64__
Expand Down
6 changes: 6 additions & 0 deletions libpf/pfelf/testdata/fixed-address.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

__attribute__((section(".coffee_section")))
int function_at_fixed_address(void) {
return 0;
Expand Down
6 changes: 6 additions & 0 deletions libpf/pfelf/testdata/test.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

#ifndef LINUX_VERSION
#define LINUX_VERSION ""
#endif
Expand Down
6 changes: 6 additions & 0 deletions reporter/testdata/test.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

#include <unistd.h>

int main(int argc, char *argv[]) {
Expand Down
6 changes: 6 additions & 0 deletions tpbase/fsbase_decode_amd64.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#include <Zydis/Zydis.h>
Expand Down
6 changes: 6 additions & 0 deletions tpbase/fsbase_decode_amd64.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#ifndef __FSBASE_DECODE_X86_64__
Expand Down
6 changes: 6 additions & 0 deletions tpbase/libc_decode_amd64.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#include <Zydis/Zydis.h>
Expand Down
6 changes: 6 additions & 0 deletions tpbase/libc_decode_amd64.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

//go:build amd64

#ifndef LIBC_DECODE_X86_64
Expand Down
6 changes: 6 additions & 0 deletions utils/coredump/testsources/c/brokenstack.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

// Example application that intentionally breaks its stack.
//
// cc -O2 -g -o brokenstack brokenstack.c
Expand Down
6 changes: 6 additions & 0 deletions utils/coredump/testsources/c/sig.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

#include<stdio.h>
#include<signal.h>
#include<unistd.h>
Expand Down
6 changes: 6 additions & 0 deletions utils/coredump/testsources/c/stackalign.c
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Apache License 2.0.
* See the file "LICENSE" for details.
*/

// gcc -O3 -fomit-frame-pointer -mavx -ftree-vectorize stackalign.c -o stackalign

#include <unistd.h>
Expand Down
Loading