diff options
Diffstat (limited to 'meta-skeleton/recipes-kernel/hello-mod/files/hello.c')
-rw-r--r-- | meta-skeleton/recipes-kernel/hello-mod/files/hello.c | 23 |
1 files changed, 7 insertions, 16 deletions
diff --git a/meta-skeleton/recipes-kernel/hello-mod/files/hello.c b/meta-skeleton/recipes-kernel/hello-mod/files/hello.c index f3c0d372eb..4f73455d20 100644 --- a/meta-skeleton/recipes-kernel/hello-mod/files/hello.c +++ b/meta-skeleton/recipes-kernel/hello-mod/files/hello.c | |||
@@ -2,32 +2,23 @@ | |||
2 | * | 2 | * |
3 | * Copyright (C) 2011 Intel Corporation. All rights reserved. | 3 | * Copyright (C) 2011 Intel Corporation. All rights reserved. |
4 | * | 4 | * |
5 | * This program is free software; you can redistribute it and/or modify | 5 | * SPDX-License-Identifier: GPL-2.0-only |
6 | * it under the terms of the GNU General Public License as published by | ||
7 | * the Free Software Foundation; version 2 of the License. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, | ||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See | ||
12 | * the GNU General Public License for more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License | ||
15 | * along with this program; if not, write to the Free Software | ||
16 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
17 | * | 6 | * |
18 | *****************************************************************************/ | 7 | *****************************************************************************/ |
19 | 8 | ||
20 | #include <linux/module.h> | 9 | #include <linux/module.h> |
21 | 10 | ||
22 | int init_module(void) | 11 | static int __init hello_init(void) |
23 | { | 12 | { |
24 | printk("Hello World!\n"); | 13 | pr_info("Hello World!\n"); |
25 | return 0; | 14 | return 0; |
26 | } | 15 | } |
27 | 16 | ||
28 | void cleanup_module(void) | 17 | static void __exit hello_exit(void) |
29 | { | 18 | { |
30 | printk("Goodbye Cruel World!\n"); | 19 | pr_info("Goodbye Cruel World!\n"); |
31 | } | 20 | } |
32 | 21 | ||
22 | module_init(hello_init); | ||
23 | module_exit(hello_exit); | ||
33 | MODULE_LICENSE("GPL"); | 24 | MODULE_LICENSE("GPL"); |