|
@@ -302,12 +302,12 @@ void net_auto_load(void)
|
|
|
if (s != NULL && strcmp(s, "NFS") == 0) {
|
|
|
if (net_check_prereq(NFS)) {
|
|
|
/* We aren't expecting to get a serverip, so just accept the assigned IP */
|
|
|
-#ifdef CONFIG_BOOTP_SERVERIP
|
|
|
- net_set_state(NETLOOP_SUCCESS);
|
|
|
-#else
|
|
|
- printf("Cannot autoload with NFS\n");
|
|
|
- net_set_state(NETLOOP_FAIL);
|
|
|
-#endif
|
|
|
+ if (IS_ENABLED(CONFIG_BOOTP_SERVERIP)) {
|
|
|
+ net_set_state(NETLOOP_SUCCESS);
|
|
|
+ } else {
|
|
|
+ printf("Cannot autoload with NFS\n");
|
|
|
+ net_set_state(NETLOOP_FAIL);
|
|
|
+ }
|
|
|
return;
|
|
|
}
|
|
|
/*
|
|
@@ -327,12 +327,12 @@ void net_auto_load(void)
|
|
|
}
|
|
|
if (net_check_prereq(TFTPGET)) {
|
|
|
/* We aren't expecting to get a serverip, so just accept the assigned IP */
|
|
|
-#ifdef CONFIG_BOOTP_SERVERIP
|
|
|
- net_set_state(NETLOOP_SUCCESS);
|
|
|
-#else
|
|
|
- printf("Cannot autoload with TFTPGET\n");
|
|
|
- net_set_state(NETLOOP_FAIL);
|
|
|
-#endif
|
|
|
+ if (IS_ENABLED(CONFIG_BOOTP_SERVERIP)) {
|
|
|
+ net_set_state(NETLOOP_SUCCESS);
|
|
|
+ } else {
|
|
|
+ printf("Cannot autoload with TFTPGET\n");
|
|
|
+ net_set_state(NETLOOP_FAIL);
|
|
|
+ }
|
|
|
return;
|
|
|
}
|
|
|
tftp_start(TFTPGET);
|