/* * Copyright (c) 1999-2003 Apple Computer, Inc. All rights reserved. * * @APPLE_LICENSE_HEADER_START@ * * Portions Copyright (c) 1999-2003 Apple Computer, Inc. All Rights * Reserved. This file contains Original Code and/or Modifications of * Original Code as defined in and that are subject to the Apple Public * Source License Version 2.0 (the 'License'). You may not use this file * except in compliance with the License. Please obtain a copy of the * License at http://www.apple.com/publicsource and read it before using * this file. * * The Original Code and all software distributed under the License are * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES, * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT. Please see the * License for the specific language governing rights and limitations * under the License. * * @APPLE_LICENSE_HEADER_END@ */ /* * drivers.h - Driver Loading Functions. * * Copyright (c) 2000 Apple Computer, Inc. * * DRI: Josh de Cesare */ #ifndef _BOOT2_DRIVERS_H #define _BOOT2_DRIVERS_H #include #include #include #include "sl.h" #include "bootstruct.h" #include "xml.h" #include "modules.h" #define DEFAULT_DRIVER_SPEC_SIZE 4096 struct compressed_kernel_header { u_int32_t signature; u_int32_t compress_type; u_int32_t adler32; u_int32_t uncompressed_size; u_int32_t compressed_size; u_int32_t reserved[11]; char platform_name[PLATFORM_NAME_LEN]; char root_path[ROOT_PATH_LEN]; u_int8_t data[0]; }; typedef struct compressed_kernel_header compressed_kernel_header; extern long LoadDrivers( char * dirSpec ); extern long DecodeKernel(void *binary, entry_t *rentry, char **raddr, int *rsize); extern long InitDriverSupport(void); extern long FileLoadDrivers(char *dirSpec, long size,long plugin); extern long LoadDriverMKext(char *fileSpec); extern long LoadDriverPList(char *dirSpec, char *name, long bundleType); extern long LoadMatchedModules(void); extern long MatchLibraries(void); #if UNUSED extern long MatchPersonalities(void); #endif #ifdef NBP_SUPPORT extern long NetLoadDrivers(char *dirSpec); #endif typedef long (*FileLoadDrivers_t)(char *dirSpec, long size, long plugin); #endif /* _BOOT2_DRIVERS_H */