| @@ -1,14 +1,14 @@ | | | @@ -1,14 +1,14 @@ |
1 | /* $NetBSD: boot.c,v 1.6 2014/08/06 13:55:08 joerg Exp $ */ | | 1 | /* $NetBSD: boot.c,v 1.7 2016/06/11 06:34:00 dholland Exp $ */ |
2 | | | 2 | |
3 | /*- | | 3 | /*- |
4 | * Copyright (c) 2002 The NetBSD Foundation, Inc. | | 4 | * Copyright (c) 2002 The NetBSD Foundation, Inc. |
5 | * All rights reserved. | | 5 | * All rights reserved. |
6 | * | | 6 | * |
7 | * This code is derived from software contributed to The NetBSD Foundation | | 7 | * This code is derived from software contributed to The NetBSD Foundation |
8 | * by Steve C. Woodford. | | 8 | * by Steve C. Woodford. |
9 | * | | 9 | * |
10 | * Redistribution and use in source and binary forms, with or without | | 10 | * Redistribution and use in source and binary forms, with or without |
11 | * modification, are permitted provided that the following conditions | | 11 | * modification, are permitted provided that the following conditions |
12 | * are met: | | 12 | * are met: |
13 | * 1. Redistributions of source code must retain the above copyright | | 13 | * 1. Redistributions of source code must retain the above copyright |
14 | * notice, this list of conditions and the following disclaimer. | | 14 | * notice, this list of conditions and the following disclaimer. |
| @@ -106,27 +106,27 @@ main(void) | | | @@ -106,27 +106,27 @@ main(void) |
106 | panic("mvmeppc-boot: bugsys_ioinq() failed!"); | | 106 | panic("mvmeppc-boot: bugsys_ioinq() failed!"); |
107 | | | 107 | |
108 | if (bid->bi_devtype > 9) | | 108 | if (bid->bi_devtype > 9) |
109 | panic("mvmeppc-boot: Bogus boot device type (%d)", | | 109 | panic("mvmeppc-boot: Bogus boot device type (%d)", |
110 | bid->bi_devtype); | | 110 | bid->bi_devtype); |
111 | | | 111 | |
112 | printf(">> MVMEPPC boot on MVME%x\n", bid->bi_bnumber); | | 112 | printf(">> MVMEPPC boot on MVME%x\n", bid->bi_bnumber); |
113 | | | 113 | |
114 | parse_args(bbi->bbi_argstart, bbi->bbi_argend, &file, &howto, &part); | | 114 | parse_args(bbi->bbi_argstart, bbi->bbi_argend, &file, &howto, &part); |
115 | | | 115 | |
116 | for (;;) { | | 116 | for (;;) { |
117 | if (ask) { | | 117 | if (ask) { |
118 | printf("boot: "); | | 118 | printf("boot: "); |
119 | gets(line); | | 119 | kgets(line, sizeof(line)); |
120 | if (strcmp(line, "halt") == 0) | | 120 | if (strcmp(line, "halt") == 0) |
121 | break; | | 121 | break; |
122 | | | 122 | |
123 | if (line[0]) { | | 123 | if (line[0]) { |
124 | char *cp = line; | | 124 | char *cp = line; |
125 | | | 125 | |
126 | while (cp < (line + sizeof(line) - 1) && *cp) | | 126 | while (cp < (line + sizeof(line) - 1) && *cp) |
127 | cp++; | | 127 | cp++; |
128 | | | 128 | |
129 | bbi->bbi_argstart = line; | | 129 | bbi->bbi_argstart = line; |
130 | bbi->bbi_argend = cp; | | 130 | bbi->bbi_argend = cp; |
131 | parse_args(bbi->bbi_argstart, bbi->bbi_argend, | | 131 | parse_args(bbi->bbi_argstart, bbi->bbi_argend, |
132 | &file, &howto, &part); | | 132 | &file, &howto, &part); |