2 * Copyright (C) 2000, 2001 Jeff Dike (jdike@karaya.com)
3 * Licensed under the GPL
12 #include "user_util.h"
13 #include "kern_util.h"
18 int load_initrd(char *filename, void *buf, int size)
22 if((fd = os_open_file(filename, of_read(OPENFLAGS()), 0)) < 0){
23 printk("Opening '%s' failed - errno = %d\n", filename, errno);
26 if((n = read(fd, buf, size)) != size){
27 printk("Read of %d bytes from '%s' returned %d, errno = %d\n",
28 size, filename, n, errno);
35 * Overrides for Emacs so that we follow Linus's tabbing style.
36 * Emacs will notice this stuff at the end of the file and automatically
37 * adjust the settings for this buffer only. This must remain at the end
39 * ---------------------------------------------------------------------------
41 * c-file-style: "linux"