2
* GRUB -- GRand Unified Bootloader
3
* Copyright (C) 2008,2009 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_ENVBLK_HEADER
20
#define GRUB_ENVBLK_HEADER 1
22
#define GRUB_ENVBLK_SIGNATURE "# GRUB Environment Block\n"
23
#define GRUB_ENVBLK_DEFCFG "grubenv"
32
typedef struct grub_envblk *grub_envblk_t;
34
grub_envblk_t grub_envblk_open (char *buf, grub_size_t size);
35
int grub_envblk_set (grub_envblk_t envblk, const char *name, const char *value);
36
void grub_envblk_delete (grub_envblk_t envblk, const char *name);
37
void grub_envblk_iterate (grub_envblk_t envblk,
38
int hook (const char *name, const char *value));
39
void grub_envblk_close (grub_envblk_t envblk);
42
grub_envblk_buffer (const grub_envblk_t envblk)
47
static inline grub_size_t
48
grub_envblk_size (const grub_envblk_t envblk)
53
#endif /* ! ASM_FILE */
55
#endif /* ! GRUB_ENVBLK_HEADER */