1 /* SPDX-License-Identifier: GPL-2.0 */
2 
3 #ifndef __LINUX_INITRD_H
4 #define __LINUX_INITRD_H
5 
6 #define INITRD_MINOR 250 /* shouldn't collide with /dev/ram* too soon ... */
7 
8 /* starting block # of image */
9 extern int rd_image_start;
10 
11 /* size of a single RAM disk */
12 extern unsigned long rd_size;
13 
14 /* 1 if it is not an error if initrd_start < memory_start */
15 extern int initrd_below_start_ok;
16 
17 /* free_initrd_mem always gets called with the next two as arguments.. */
18 extern unsigned long initrd_start, initrd_end;
19 extern void free_initrd_mem(unsigned long, unsigned long);
20 
21 #ifdef CONFIG_BLK_DEV_INITRD
22 extern void __init reserve_initrd_mem(void);
23 extern void wait_for_initramfs(void);
24 #else
reserve_initrd_mem(void)25 static inline void __init reserve_initrd_mem(void) {}
wait_for_initramfs(void)26 static inline void wait_for_initramfs(void) {}
27 #endif
28 
29 extern phys_addr_t phys_initrd_start;
30 extern unsigned long phys_initrd_size;
31 
32 extern unsigned int real_root_dev;
33 
34 extern char __initramfs_start[];
35 extern unsigned long __initramfs_size;
36 
37 void console_on_rootfs(void);
38 
39 #endif /* __LINUX_INITRD_H */
40