Fix cross compilation (e.g. on Darwin). Following changes to make.tmpl,
[AROS.git] / arch / all-pc / boot / grub2-aros / include / grub / procfs.h
blob8cc331d946f6ec36b22da2ddeb2eeba5de26d73e
1 /*
2 * GRUB -- GRand Unified Bootloader
3 * Copyright (C) 2013 Free Software Foundation, Inc.
5 * GRUB is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
10 * GRUB is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with GRUB. If not, see <http://www.gnu.org/licenses/>.
19 #ifndef GRUB_PROCFS_HEADER
20 #define GRUB_PROCFS_HEADER 1
22 #include <grub/list.h>
23 #include <grub/types.h>
25 struct grub_procfs_entry
27 struct grub_procfs_entry *next;
28 struct grub_procfs_entry **prev;
30 const char *name;
31 char * (*get_contents) (grub_size_t *sz);
34 extern struct grub_procfs_entry *grub_procfs_entries;
36 static inline void
37 grub_procfs_register (const char *name __attribute__ ((unused)),
38 struct grub_procfs_entry *entry)
40 grub_list_push (GRUB_AS_LIST_P (&grub_procfs_entries),
41 GRUB_AS_LIST (entry));
44 static inline void
45 grub_procfs_unregister (struct grub_procfs_entry *entry)
47 grub_list_remove (GRUB_AS_LIST (entry));
51 #endif