aboutsummaryrefslogtreecommitdiffstats
path: root/init
diff options
context:
space:
mode:
authorRobert P. J. Day <rpjday@crashcourse.ca>2008-02-06 04:37:25 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2008-02-06 13:41:06 -0500
commitb25b7819e51f388f8c8d7ae4679a658895dc67cc (patch)
tree8360bd9d79feab0485177825fc6b5997ab653eba /init
parentd99c4f6b13b3149bc83703ab1493beaeaaaf8a2d (diff)
Remove superfluous checks for CONFIG_BLK_DEV_INITRD from initramfs.c
Given that init/Makefile includes initramfs.c in the build only if CONFIG_BLK_DEV_INITRD is defined, there seems to be no point checking for it yet again. Signed-off-by: Robert P. J. Day <rpjday@crashcourse.ca> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'init')
-rw-r--r--init/initramfs.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/init/initramfs.c b/init/initramfs.c
index 1db02a0025db..d53fee8d8604 100644
--- a/init/initramfs.c
+++ b/init/initramfs.c
@@ -503,7 +503,6 @@ static int __init retain_initrd_param(char *str)
503__setup("retain_initrd", retain_initrd_param); 503__setup("retain_initrd", retain_initrd_param);
504 504
505extern char __initramfs_start[], __initramfs_end[]; 505extern char __initramfs_start[], __initramfs_end[];
506#ifdef CONFIG_BLK_DEV_INITRD
507#include <linux/initrd.h> 506#include <linux/initrd.h>
508#include <linux/kexec.h> 507#include <linux/kexec.h>
509 508
@@ -539,15 +538,12 @@ skip:
539 initrd_end = 0; 538 initrd_end = 0;
540} 539}
541 540
542#endif
543
544static int __init populate_rootfs(void) 541static int __init populate_rootfs(void)
545{ 542{
546 char *err = unpack_to_rootfs(__initramfs_start, 543 char *err = unpack_to_rootfs(__initramfs_start,
547 __initramfs_end - __initramfs_start, 0); 544 __initramfs_end - __initramfs_start, 0);
548 if (err) 545 if (err)
549 panic(err); 546 panic(err);
550#ifdef CONFIG_BLK_DEV_INITRD
551 if (initrd_start) { 547 if (initrd_start) {
552#ifdef CONFIG_BLK_DEV_RAM 548#ifdef CONFIG_BLK_DEV_RAM
553 int fd; 549 int fd;
@@ -579,7 +575,6 @@ static int __init populate_rootfs(void)
579 free_initrd(); 575 free_initrd();
580#endif 576#endif
581 } 577 }
582#endif
583 return 0; 578 return 0;
584} 579}
585rootfs_initcall(populate_rootfs); 580rootfs_initcall(populate_rootfs);