2004-04-04 Yoshinori K. Okuji <okuji@enbug.org>
All symbols prefixed with PUPA_ and pupa_ are renamed to GRUB_ and grub_, respectively. Because the conversion is trivial and mechanical, I omit the details here. Please refer to the CVS if you need more information.
This commit is contained in:
parent
6a1425510d
commit
4b13b216f4
125 changed files with 6198 additions and 6181 deletions
|
@ -1,9 +1,9 @@
|
|||
/* fs.h - filesystem manager */
|
||||
/*
|
||||
* PUPA -- Preliminary Universal Programming Architecture for GRUB
|
||||
* GRUB -- GRand Unified Bootloader
|
||||
* Copyright (C) 2002,2003 Free Software Foundation, Inc.
|
||||
*
|
||||
* PUPA is free software; you can redistribute it and/or modify
|
||||
* GRUB is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
|
@ -14,62 +14,62 @@
|
|||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with PUPA; if not, write to the Free Software
|
||||
* along with GRUB; if not, write to the Free Software
|
||||
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
*/
|
||||
|
||||
#ifndef PUPA_FS_HEADER
|
||||
#define PUPA_FS_HEADER 1
|
||||
#ifndef GRUB_FS_HEADER
|
||||
#define GRUB_FS_HEADER 1
|
||||
|
||||
#include <pupa/device.h>
|
||||
#include <pupa/symbol.h>
|
||||
#include <pupa/types.h>
|
||||
#include <grub/device.h>
|
||||
#include <grub/symbol.h>
|
||||
#include <grub/types.h>
|
||||
|
||||
/* Forward declaration is required, because of mutual reference. */
|
||||
struct pupa_file;
|
||||
struct grub_file;
|
||||
|
||||
/* Filesystem descriptor. */
|
||||
struct pupa_fs
|
||||
struct grub_fs
|
||||
{
|
||||
/* My name. */
|
||||
const char *name;
|
||||
|
||||
/* Call HOOK with each file under DIR. */
|
||||
pupa_err_t (*dir) (pupa_device_t device, const char *path,
|
||||
grub_err_t (*dir) (grub_device_t device, const char *path,
|
||||
int (*hook) (const char *filename, int dir));
|
||||
|
||||
/* Open a file named NAME and initialize FILE. */
|
||||
pupa_err_t (*open) (struct pupa_file *file, const char *name);
|
||||
grub_err_t (*open) (struct grub_file *file, const char *name);
|
||||
|
||||
/* Read LEN bytes data from FILE into BUF. */
|
||||
pupa_ssize_t (*read) (struct pupa_file *file, char *buf, pupa_ssize_t len);
|
||||
grub_ssize_t (*read) (struct grub_file *file, char *buf, grub_ssize_t len);
|
||||
|
||||
/* Close the file FILE. */
|
||||
pupa_err_t (*close) (struct pupa_file *file);
|
||||
grub_err_t (*close) (struct grub_file *file);
|
||||
|
||||
/* Return the label of the device DEVICE in LABEL. The label is
|
||||
returned in a pupa_malloc'ed buffer and should be freed by the
|
||||
returned in a grub_malloc'ed buffer and should be freed by the
|
||||
caller. */
|
||||
pupa_err_t (*label) (pupa_device_t device, char **label);
|
||||
grub_err_t (*label) (grub_device_t device, char **label);
|
||||
|
||||
/* The next filesystem. */
|
||||
struct pupa_fs *next;
|
||||
struct grub_fs *next;
|
||||
};
|
||||
typedef struct pupa_fs *pupa_fs_t;
|
||||
typedef struct grub_fs *grub_fs_t;
|
||||
|
||||
/* This is special, because block lists are not files in usual sense. */
|
||||
extern struct pupa_fs pupa_fs_blocklist;
|
||||
extern struct grub_fs grub_fs_blocklist;
|
||||
|
||||
void EXPORT_FUNC(pupa_fs_register) (pupa_fs_t fs);
|
||||
void EXPORT_FUNC(pupa_fs_unregister) (pupa_fs_t fs);
|
||||
void EXPORT_FUNC(pupa_fs_iterate) (int (*hook) (const pupa_fs_t fs));
|
||||
pupa_fs_t EXPORT_FUNC(pupa_fs_probe) (pupa_device_t device);
|
||||
void EXPORT_FUNC(grub_fs_register) (grub_fs_t fs);
|
||||
void EXPORT_FUNC(grub_fs_unregister) (grub_fs_t fs);
|
||||
void EXPORT_FUNC(grub_fs_iterate) (int (*hook) (const grub_fs_t fs));
|
||||
grub_fs_t EXPORT_FUNC(grub_fs_probe) (grub_device_t device);
|
||||
|
||||
#ifdef PUPA_UTIL
|
||||
void pupa_fat_init (void);
|
||||
void pupa_fat_fini (void);
|
||||
void pupa_ext2_init (void);
|
||||
void pupa_ext2_fini (void);
|
||||
#endif /* PUPA_UTIL */
|
||||
#ifdef GRUB_UTIL
|
||||
void grub_fat_init (void);
|
||||
void grub_fat_fini (void);
|
||||
void grub_ext2_init (void);
|
||||
void grub_ext2_fini (void);
|
||||
#endif /* GRUB_UTIL */
|
||||
|
||||
#endif /* ! PUPA_FS_HEADER */
|
||||
#endif /* ! GRUB_FS_HEADER */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue